annotate doc/Pirelli-Howto @ 44:70c9bb37bd74

configs/fcdev3b-std: DISABLE_SLEEP=1 for the current state of the hw
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 09 Sep 2017 16:23:19 +0000
parents cb00b90edaff
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
28
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 How to play with FreeCalypso GSM firmware on a Pirelli DP-L10
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 =============================================================
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 One very useful special feature of the Pirelli DP-L10 is its very large RAM:
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 8 MiB. Having such large RAM allows us to run our experimental fw on this
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 target entirely from RAM, without touching the flash. When you compile a
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 FreeCalypso Citrine fw image for the Pirelli target, by default a ramImage will
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 be built instead of a flashImage. It is possible to build a flashable image of
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 the fw in the same configuration and program it into flash with fc-loadtool,
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 but doing so is not recommended: our current fw has no battery management code,
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 so the charging hardware circuit will never be enabled and the battery will
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 discharge even with a USB power source connected; keeping Pirelli's original
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 fw in flash will allow the phone to charge its battery and otherwise function
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 normally when you are not in the middle of a FreeCalypso firmware experiment.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 If you are ready to play with our experimental GSM pseudo-modem fw on your
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 Pirelli, the steps are as follows:
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 1. Build the firmware in the pirelli-gsm-rvtat configuration - see the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 Compiling document for more details.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 2. Connect a USB cable from your GNU/Linux PC/laptop to the phone. If the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 phone was off but the battery is present, it will go through a charger-plug
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 power-on event; if the flash contains Pirelli's original fw, it will boot in
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 the charging mode. If the battery is not present, the Calypso won't power
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 on (it needs VBAT and can't run on VCHG power instead), but the /dev/ttyUSBx
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 device will still show up, as the CP2102 USB-serial chip inside the phone is
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 powered strictly from the USB side.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 3. Run a command like the following:
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 fc-xram -h pirelli /dev/ttyUSB0 finlink/ramImage.srec rvinterf
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 Adjust the paths to your /dev/ttyUSBx device and your ramImage.srec as
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 appropriate, and add rvinterf logging or other options as desired.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 Specifying rvinterf on the fc-xram command line directs fc-xram to exec
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 rvinterf and pass the serial channel to it immediately as soon as the code
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 image has been loaded into target RAM and jumped to; this direct passing of
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 the serial channel from fc-xram to rvinterf is appropriate because the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 loaded fw will immediately start emitting binary trace packets in TI's RVTMUX
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 format.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 4. Induce the phone to execute its Calypso boot path: if the battery was
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 removed, insert it now; if Pirelli's regular fw is running, execute its
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 power-off sequence.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 Once the Calypso chip in the Pirelli phone executes its boot path with fc-xram
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 running, the boot path will be diverted and our experimental firmware will be
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 loaded into target device RAM and jumped to. Our fw will now run, and the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 rvinterf process on the host will maintain communication with it.
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 To exercise our firmware further, you will need to open another terminal window
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 on your driving PC/laptop and run fc-shell. This program will connect to the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 already running rvinterf process via a local socket, and it will enable you to
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55 send various commands to the running fw on the target, the most important ones
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 being standard AT commands. Send the following sequence of AT commands to
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 bring up GSM functionality:
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 AT+CMEE=2 -- enable verbose error responses
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 AT+CFUN=1 -- enable radio and SIM interfaces
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 AT+COPS=0 -- register to the default GSM network
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 When you are done playing with our experimental fw, you can either yank the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 battery and kill the host side rvinterf and fc-shell processes, or you can
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 issue a 'tgtreset' command at the fc-shell prompt. The latter will cause the
cb00b90edaff documentation write-ups imported from freecalypso-sw and updated for Citrine
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 target to reset and boot back into its regular firmware.