Accelerate3g5 -- unicornteam » History » Version 24
laforge, 11/07/2023 03:51 PM
1 | 24 | laforge | {{include(MacroLegacy)}} |
---|---|---|---|
2 | {{include(Disclaimer-user-content)}} |
||
3 | |||
4 | 19 | Alin | h1. Accelerate3g5 -- Unicorn Team |
5 | 1 | Alin | |
6 | Journal |
||
7 | |||
8 | 2017/03/15 -- Received the package of nano3G. |
||
9 | 2 | Alin | |
10 | 5 | Alin | !C7aK_6IVAAALB5Z.jpg! |
11 | 4 | Alin | |
12 | 5 | Alin | |
13 | 3 | Alin | 2017/04/10 |
14 | 4 | Alin | |
15 | 2 | Alin | h2. Building from source |
16 | * PC:Ubuntu16.04 |
||
17 | * HardWare:ip.access nano3G |
||
18 | 4 | Alin | * SoftWare:Osmocom |
19 | 1 | Alin | |
20 | 5 | Alin | !C7aK_5_U0AAN1Co.jpg! |
21 | 1 | Alin | |
22 | 5 | Alin | h3. 1.1 Install cross-compilation environment |
23 | |||
24 | 2 | Alin | <pre> |
25 | sudo apt-get update |
||
26 | |||
27 | 8 | Alin | sudo apt-get install libtool shtool autoconf git-core pkg-config make gcc build-essential libgmp3-dev libmpfr-dev libx11-6 libx11-dev texinfo flex bison libncurses5 libncurses5-dbg libusb-0.1-4 libpcsclite1 libccid pcscd libncurses5-dev libncursesw5 libncursesw5-dbg libncursesw5-dev zlibc zlib1g-dev libmpfr4 libmpc-dev libpcsclite-dev |
28 | sudo ldconfig |
||
29 | |||
30 | 7 | Alin | mkdir osm |
31 | 6 | Alin | cd osm |
32 | 2 | Alin | mkdir build install src |
33 | wget http://bb.osmocom.org/trac/raw-attachment/wiki/GnuArmToolchain/gnu-arm-build.3.sh |
||
34 | cd src |
||
35 | wget http://ftp.gnu.org/gnu/gcc/gcc-4.8.2/gcc-4.8.2.tar.bz2 |
||
36 | wget http://ftp.gnu.org/gnu/binutils/binutils-2.21.1a.tar.bz2 |
||
37 | wget ftp://sources.redhat.com/pub/newlib/newlib-1.19.0.tar.gz |
||
38 | |||
39 | cd .. |
||
40 | chmod +x gnu-arm-build.3.sh |
||
41 | sudo bash gnu-arm-build.3.sh |
||
42 | 1 | Alin | </pre> |
43 | 2 | Alin | |
44 | 5 | Alin | h3. 1.2 Add Cross compiler environment |
45 | 4 | Alin | |
46 | 2 | Alin | <pre> |
47 | cd install/bin |
||
48 | pwd |
||
49 | |||
50 | vi ~/./.bashrc |
||
51 | export PATH=$PATH:/home/$username(change this to your name)/osm/install/bin |
||
52 | |||
53 | #save and quit |
||
54 | 9 | Alin | cd ../../ |
55 | 1 | Alin | source ~/.bashrc |
56 | </pre> |
||
57 | 2 | Alin | |
58 | 5 | Alin | h3. 0x02 build CalypsoBTS |
59 | 4 | Alin | |
60 | 5 | Alin | h3. 2.1 Build libosmo-dsp |
61 | 4 | Alin | |
62 | 2 | Alin | <pre> |
63 | 23 | laforge | git clone https://gitea.osmocom.org/sdr/libosmo-dsp |
64 | 2 | Alin | cd libosmo-dsp/ |
65 | autoreconf -i |
||
66 | ./configure |
||
67 | make |
||
68 | 1 | Alin | sudo make install |
69 | 2 | Alin | cd .. |
70 | </pre> |
||
71 | |||
72 | |||
73 | 5 | Alin | h3. 2.2 Build osmocom-bb |
74 | 2 | Alin | |
75 | <pre> |
||
76 | 23 | laforge | git clone https://gitea.osmocom.org/phone-side/osmocom-bb trx |
77 | 2 | Alin | cd trx/ |
78 | git checkout jolly/testing |
||
79 | cd src/ |
||
80 | |||
81 | # It needs TX support |
||
82 | # Just uncomment 'CFLAGS += -DCONFIG_TX_ENABLE' in target/firmware/Makefile |
||
83 | 1 | Alin | |
84 | 2 | Alin | # And make with transceiver support |
85 | make HOST_layer23_CONFARGS=--enable-transceiver |
||
86 | </pre> |
||
87 | |||
88 | 1 | Alin | |
89 | 5 | Alin | h3. 2.3 Install dependency package |
90 | 4 | Alin | |
91 | 2 | Alin | <pre> |
92 | sudo apt-get install sqlite3 libdbi-dev libdbd-sqlite3 libsctp-dev |
||
93 | </pre> |
||
94 | |||
95 | 5 | Alin | h3. 2.4 Build Ortp |
96 | 2 | Alin | |
97 | <pre> |
||
98 | wget http://download.savannah.gnu.org/releases/linphone/ortp/sources/ortp-0.22.0.tar.gz |
||
99 | tar -xvf ortp-0.22.0.tar.gz |
||
100 | cd ortp-0.22.0/ |
||
101 | 1 | Alin | ./configure |
102 | 2 | Alin | make |
103 | sudo make install |
||
104 | sudo ldconfig |
||
105 | cd .. |
||
106 | </pre> |
||
107 | |||
108 | |||
109 | 5 | Alin | h3. 2.5 Build libosmo-abis |
110 | 2 | Alin | |
111 | <pre> |
||
112 | 23 | laforge | git clone https://gitea.osmocom.org/osmocom/libosmo-abis |
113 | 1 | Alin | cd libosmo-abis |
114 | 2 | Alin | autoreconf -i |
115 | ./configure |
||
116 | make |
||
117 | sudo make install |
||
118 | sudo ldconfig |
||
119 | cd .. |
||
120 | </pre> |
||
121 | |||
122 | 5 | Alin | h3. 2.6 Build libosmo-netif |
123 | 2 | Alin | |
124 | <pre> |
||
125 | 23 | laforge | git clone https://gitea.osmocom.org/osmocom/libosmo-netif |
126 | 2 | Alin | cd libosmo-netif/ |
127 | autoreconf -i |
||
128 | ./configure |
||
129 | make |
||
130 | sudo make install |
||
131 | sudo ldconfig |
||
132 | cd .. |
||
133 | </pre> |
||
134 | |||
135 | 5 | Alin | h3. 2.7 Build openbsc |
136 | 2 | Alin | |
137 | 10 | Alin | install PCAP library frist |
138 | 1 | Alin | <pre> |
139 | 10 | Alin | apt-cache search PCAP |
140 | sudo pat-get install libpcap-dev libpcap0.8 libpcap0.8-dbg libpcap0.8-dev |
||
141 | sudo ldconfig |
||
142 | |||
143 | 23 | laforge | git clone https://gitea.osmocom.org/cellular-infrastructure/openbsc |
144 | 2 | Alin | cd openbsc/openbsc/ |
145 | autoreconf -i |
||
146 | ./configure |
||
147 | make |
||
148 | sudo make install |
||
149 | cd ../.. |
||
150 | |||
151 | </pre> |
||
152 | |||
153 | 5 | Alin | h3. 2.8 Build osmo-bts |
154 | 1 | Alin | |
155 | 2 | Alin | <pre> |
156 | 23 | laforge | git clone https://gitea.osmocom.org/cellular-infrastructure/osmo-bts |
157 | 2 | Alin | cd osmo-bts |
158 | autoreconf -i |
||
159 | ./configure --enable-trx |
||
160 | make |
||
161 | sudo make install |
||
162 | cd .. |
||
163 | </pre> |
||
164 | 1 | Alin | |
165 | |||
166 | 5 | Alin | h3. 2.9 Create configuration folder for OpenBSC |
167 | 4 | Alin | |
168 | 2 | Alin | <pre> |
169 | # Create the configuration folder if it isn't exist yet |
||
170 | mkdir ~/.osmocom |
||
171 | cd ~/.osmocom |
||
172 | touch ~/.osmocom/open-bsc.cfg |
||
173 | touch ~/.osmocom/osmo-bts.cfg |
||
174 | </pre> |
||
175 | |||
176 | |||
177 | 5 | Alin | h3. 0x03 Build Cellular Infrastructure |
178 | 2 | Alin | |
179 | 5 | Alin | h3. 3.1 Clone |
180 | 2 | Alin | |
181 | <pre> |
||
182 | 23 | laforge | git clone https://git.osmocom.org/osmocom/libosmocore |
183 | git clone https://git.osmocom.org/osmocom/libosmo-abis |
||
184 | git clone https://git.osmocom.org/osmocom/openbsc |
||
185 | git clone https://git.osmocom.org/osmocom/libosmo-netif |
||
186 | git clone https://git.osmocom.org/osmocom/libosmo-sccp |
||
187 | git clone https://git.osmocom.org/cellular-infrastructure/libsmpp34 |
||
188 | git clone https://git.osmocom.org/cellular-infrastructure/openggsn |
||
189 | 2 | Alin | </pre> |
190 | |||
191 | |||
192 | 5 | Alin | h3. 3.2 Download and run build script |
193 | 4 | Alin | |
194 | 2 | Alin | <pre> |
195 | wget https://osmocom.org/attachments/download/2438/build_2G.sh |
||
196 | chmod 777 build_2G.sh |
||
197 | sudo bash build_2G.sh |
||
198 | </pre> |
||
199 | 11 | Alin | h3. Run BTS |
200 | |||
201 | Terminal 1: |
||
202 | <pre> |
||
203 | osmo-nitb -c ~/.osmocom/open-bsc.cfg -l ~/.osmocom/hlr.sqlite3 -P -C --debug=DRLL:DCC:DMM:DRR:DRSL:DNM |
||
204 | </pre> |
||
205 | |||
206 | Terminal 2: |
||
207 | <pre> |
||
208 | telnet localhost 4242 |
||
209 | </pre> |
||
210 | |||
211 | !2017-04.png! |
||
212 | 12 | Alin | |
213 | <pre> |
||
214 | OpenBSC> show version |
||
215 | OpenBSC 0.15.0.726-ca27 (OpenBSC). |
||
216 | Copyright (C) 2008-2016 Harald Welte, Holger Freyther |
||
217 | Contributions by Daniel Willmann, Jan Lübbe, Stefan Schmidt |
||
218 | Dieter Spaar, Andreas Eversberg, Sylvain Munaut, Neels Hofmeyr |
||
219 | |||
220 | License AGPLv3+: GNU AGPL version 3 or later <http://gnu.org/licenses/agpl-3.0.html> |
||
221 | This is free software: you are free to change and redistribute it. |
||
222 | There is NO WARRANTY, to the extent permitted by law. |
||
223 | |||
224 | </pre> |
||
225 | 13 | Alin | |
226 | 14 | Alin | 2017/04/11 |
227 | |||
228 | 13 | Alin | h2. Configuring the ip.access nano3G |
229 | 1 | Alin | |
230 | 15 | Alin | !network.jpg! |
231 | |||
232 | 14 | Alin | h3. PC |
233 | |||
234 | IP:192.168.31.147 (With WiFi) |
||
235 | |||
236 | h3. Route |
||
237 | |||
238 | IP:192.168.31.1 |
||
239 | |||
240 | h3. 3G Access Point |
||
241 | |||
242 | IP:unkonw |
||
243 | |||
244 | <pre> |
||
245 | cd openbsc/openbsc/src/ipaccess |
||
246 | #or |
||
247 | cd openbsc/openbsc/build-2G/src/ipaccess |
||
248 | |||
249 | sudo ./abisip-find |
||
250 | |||
251 | </pre> |
||
252 | |||
253 | !ipfind.png! |
||
254 | |||
255 | <pre> |
||
256 | telnet 3G Access Point's IP 8090 |
||
257 | </pre> |
||
258 | |||
259 | !telnet.png! |
||
260 | |||
261 | 16 | Alin | |
262 | 14 | Alin | <pre> |
263 | 17 | Alin | ssh -oKexAlgorithms=+diffie-hellman-group1-sha1 root@192.168.31.136 |
264 | 16 | Alin | password:newsys |
265 | </pre> |
||
266 | |||
267 | !Snip20170411_2.png! |
||
268 | |||
269 | 18 | Alin | <pre> |
270 | 14 | Alin | init3@0xroot:~/osm/openbsc/openbsc/src/ipaccess$ ./ipaccess-config --help |
271 | ipaccess-config (C) 2009-2010 by Harald Welte and others |
||
272 | This is FREE SOFTWARE with ABSOLUTELY NO WARRANTY |
||
273 | |||
274 | Usage: ipaccess-config IP_OF_BTS |
||
275 | Commands for writing to the BTS: |
||
276 | -u --unit-id UNIT_ID Set the Unit ID of the BTS |
||
277 | -o --oml-ip IP Set primary OML IP (IP of your BSC) |
||
278 | -i --ip-address IP/MASK Set static IP address + netmask of BTS |
||
279 | -g --ip-gateway IP Set static IP gateway of BTS |
||
280 | -r --restart Restart the BTS (after other operations) |
||
281 | -n --nvram-flags FLAGS/MASK Set NVRAM attributes |
||
282 | -S --nvattr-set FLAG Set one additional NVRAM attribute |
||
283 | -U --nvattr-unset FLAG Set one additional NVRAM attribute |
||
284 | -l --listen TESTNR Perform specified test number |
||
285 | -L --Listen TEST_NAME Perform specified test |
||
286 | -s --stream-id ID Set the IPA Stream Identifier for OML |
||
287 | -d --software FIRMWARE Download firmware into BTS |
||
288 | |||
289 | Miscellaneous commands: |
||
290 | -h --help this text |
||
291 | -H --HELP Print parameter details. |
||
292 | -f --firmware FIRMWARE Provide firmware information |
||
293 | -w --write-firmware This will dump the firmware parts to the filesystem. Use with -f. |
||
294 | -p --loop Loop the tests executed with the --listen command. |
||
295 | </pre> |
||
296 | |||
297 | <pre> |
||
298 | init3@0xroot:~/osm/openbsc/openbsc/src/ipaccess$ ./ipaccess-proxy --help |
||
299 | Usage: ipaccess-proxy [options] |
||
300 | ipaccess-proxy is a proxy BTS. |
||
301 | -h --help. This help text. |
||
302 | -l --listen IP. The ip to listen to. |
||
303 | -b --bsc IP. The BSC IP address. |
||
304 | -g --gprs IP. Take GPRS NS from that IP. |
||
305 | |||
306 | -s --disable-color. Disable the color inside the logging message. |
||
307 | -e --log-level number. Set the global loglevel. |
||
308 | -T --timestamp. Prefix every log message with a timestamp. |
||
309 | -V --version. Print the version of OpenBSC. |
||
310 | </pre> |
||
311 | 13 | Alin | |
312 | h2. Femto Config |
||
313 | |||
314 | 21 | Alin | 2017/06/06: |
315 | phone call work fine. |
||
316 | SMS work fine. |
||
317 | Internet Date not work -.-! |
||
318 | 1 | Alin | |
319 | 21 | Alin | 2017/06/20: |
320 | Internet Date work fine :) |
||
321 | |||
322 | !20170606270232.png! |
||
323 | 1 | Alin | |
324 | 22 | Alin | h2. Clone and Build from script |
325 | |||
326 | <pre> |
||
327 | wget https://osmocom.org/attachments/download/2726/3G-config-example.tar |
||
328 | tar zxvf 3G-config-example.tar |
||
329 | cd 3G-config-example/build |
||
330 | ./clone_and_build_osmocom_3g.sh |
||
331 | sudo apt-get install rxvt-unicode |
||
332 | </pre> |
||
333 | |||
334 | add subscribers with auth keys in the HLR database: |
||
335 | https://osmocom.org/projects/cellular-infrastructure/wiki/Getting_Started_with_3G |
||
336 | |||
337 | https://osmocom.org/projects/cellular-infrastructure/wiki/Configuring_the_ipaccess_nano3G |
||
338 | |||
339 | !IMG_3088.PNG! |
||
340 | 21 | Alin | |
341 | 20 | Alin | h2. Demo |
342 | 1 | Alin | |
343 | 21 | Alin | 2017/07/06: |
344 | 20 | Alin | !20170606241837.png! |
345 | [[https://youtu.be/PFH_-vID3AA]] |