Calypso firmware update (work in progress)

Werner Almesberger werner at
Mon Nov 17 01:21:38 CET 2008

Dieter Spaar wrote:
> Anyone remembers GSM  related differences between GTA01 and GTA02 ?

I remember that the multiplexer required some attention, but I don't
recall if that actually required differences between the GSM firmware
versions for GTA01 and GTA02. One of the voices in my head says that
they ought to be the same.

Perhaps Tony or Harald can remember ?

> You mentioned already that FLUID has to be used differently on GTA01, is
> this something related to FLUID itself or the way how the UART connection
> is handled in GTA01 ?

The difference is how we reset the GSM modem. The story goes like

In the beginning (pre-production GTA01), we had a transistor to pull
the modem's TESTRSTZ line low. That transistor connected to a GPIO of
the CPU.

So the process of establishing communication with FLUID was to fire
it up, and then to reset the modem through this line. As part of its
reset process, the modem would look for FLUID, find it, ... and they
lived happily ever after.

Then we noticed that, when powering the system down (PMU going into
STANDBY state), the CPU would "jerk" its GPIOs in the last moment.
This sometimes (I don't remember if it happened all the time or only
some of the time) caused the GSM modem to get reset, after which it
would happily stay powered up.

Since we couldn't find a quick fix for the CPU's last struggle, we
removed the transistor and devised a new mechanism: when sending the
AT at POFF command to the modem, it would power down. That had already
been implemented for other reasons. Activating the modem's PWON line,
which is controlled by a transistor driven by another of the CPU's
many GPIOs, would wake the modem up again.

This "button" signal is operated by writing to the sysfs file

PWON acts basically like the power button you would find on many
phones. So it does a full power-on reset of the modem. This of course
means that the modem also goes through the phase that lets FLUID
establish communication with it. So once again, order was restored.
And this is the situation in all production GTA01 devices.

In GTA02, we had learned from our past mistakes and left the
troublesome transistor on TESTRSTZ off right from the beginning. So
the AT at POFF-PWON sequence was the standard reset mechanism.

However, another change had happened since GTA01, and that's the
addition of an electronic switch to cut power to the GSM subsystem.
The GSM subsystem receives its power directly from the battery and
does not go trough the PMU. Therefore, you could never be quite sure
that it was really off, and not secretly drawing power or informing
the Ministry of Love and Happiness of your whereabouts.

Unfortunately, this switch ended up being controlled by the very same
power_on file that also triggered the PWON signal. I don't remember
the details, but this arrangement threw off the reset process such
that FLUID would not establish communication with the modem.

Since we didn't want to change this interface for what was a bit of
a fringe use, we had to find a way to operate PWON without affecting
the power switch. That's why there is the mysterious tweaking of GPIO
line B7 in the GTA02 flashing procedure.

Alas, the minions of evil had planned ahead and equipped the GSM
modem with the ability to detect the presence of such a switch
between itself and the battery. This manifested itself by the GSM
modem not working properly if that switch was there.

So we eventually removed that switch in some GTA02 models, and they
may now in fact be virtually identical to GTA01 when it comes to
resetting the modem. However, the slightly more arcane procedure
involving meddling with GPIOs works also in GTA02 after the change.

Thus we have the following situation: on all GTA01, the modem can be
reset to communicate with FLUID by first shutting it down with
AT at POFF, and then writing to power_on (I don't recall the correct
value to write offhand).

On all GTA02, the same is accomplished by shutting it down with
AT at POFF and then pulling PWON low (by setting GPB7 high).

- Scheherazade ;-)

More information about the devel mailing list