Project

General

Profile

OpenMoko » History » Version 9

laforge, 01/19/2022 08:34 AM
add title

1 9 laforge
h1. OpenMoko
2
3 1
Open source phone project: see http://wiki.openmoko.org/wiki/Main_Page for details.
4
5 7 gnutoo
6
h2. How to load osmocom-bb from the phone Application CPU:
7
8 2
Osmocom can be run directly on the phone. The communication flow is:
9
10 8 laforge
!osmocon-on-OpenMoko.png!
11 1
12 8 laforge
For details see [[osmocon]] and [[CalypsoRomloader]]. IP networking between the host and the phone must be set up.
13 1
14
15 7 gnutoo
h3. On the phone:
16
17
18
* disable ogsmd, ousaged, ophoned via /etc/frameworkd.conf
19
* prevent fsogsmd from accessing modem by commenting following variables in /etc/freesmartphone/conf/GTA02/fsogsmd.conf:
20
*** device_port
21
*** modem_access
22
* re-check that nothing uses the modem: fuser /dev/ttySAC0
23
* open three SSH terminals to the phone
24
* transfer layer1.highram.bin and osmocon binary to the phone
25
* in the first terminal, make L2 socket externally available via socat:
26
<pre>
27 1
socat -v -x tcp-l:16661,reuseaddr,fork unix-connect:/tmp/osmocom_l2
28 7 gnutoo
</pre>
29
* in the second terminal, run osmocon:
30
<pre>
31 1
./osmocon -i 13 -m romload -p /dev/ttySAC0 layer1.highram.bin
32 7 gnutoo
</pre>
33
* in the third terminal, turn power off/on:
34
<pre>
35 1
echo 0 >/sys/bus/platform/devices/gta02-pm-gsm.0/power_on && echo 1 >/sys/bus/platform/devices/gta02-pm-gsm.0/power_on
36 7 gnutoo
</pre>
37 1
38 2
39 7 gnutoo
h3. on the host machine
40
41
42
* Connect the socket:
43
<pre>
44 2
socat -v -x unix-l:/var/tmp/l2,fork  tcp:192.168.7.2:16661,fork
45 7 gnutoo
</pre>
46 1
Note: 192.168.7.2 is default address of the device when you use shr-core linux distribution.
47
48 4 gnutoo
After this you can run various tools on host machine, for example:
49 7 gnutoo
<pre>
50 5 gnutoo
./cell_log -s /var/tmp/l2 -l /var/tmp/osmocom.log
51 7 gnutoo
</pre>
52 4 gnutoo
53 7 gnutoo
54
h2. How to load osmocom-bb from a computer
55
56 4 gnutoo
Alternatively you can also load a firmware on the openmoko modem from your computer, without needing to cross compile or install something on the phone CPU running GNU/Linux.
57
58 7 gnutoo
* like with the previous explanations be sure that nothing access the modem.
59
* Then run the following command on the phone:
60
<pre>
61 4 gnutoo
echo 1 > /sys/bus/platform/devices/gta02-pm-gsm.0/download
62 7 gnutoo
</pre>
63 4 gnutoo
That will connect the second serial port of the modem(named IRDA) to the audio jack.
64 7 gnutoo
* Then connect a 3.3V serial cable(a normal serial port will probably kill your modem because of the higher voltage) to the audio jack(for the pins you can refer to the schematics of the phone that are freely available)
65 4 gnutoo
Then on a computer do(replace /dev/ttyUSB0 by your computer serial port):
66 7 gnutoo
<pre>
67 4 gnutoo
./osmocon -i 13 -m romload -p /dev/ttyUSB0 layer1.highram.bin
68 7 gnutoo
</pre>
69 1
And back on the phone do:
70 7 gnutoo
<pre>
71 1
echo 0 >/sys/bus/platform/devices/gta02-pm-gsm.0/power_on && echo 1 >/sys/bus/platform/devices/gta02-pm-gsm.0/power_on
72 7 gnutoo
</pre>
73 1
That will load the firmware, and you will be able to interact with it from your computer like if it was a regular supported(by osmocom-bb) feature phone.
Add picture from clipboard (Maximum size: 48.8 MB)