Motorola C139

Initial flash


Download the C139 Magnetite firmware:

release=20190129
 
mkdir ~/freecalypso
cd ~/freecalypso
 
wget ftp://ftp.freecalypso.org/pub/GSM/FreeCalypso/c1xx-fcmag-$release.tar.bz2
mkdir c1xx-fcmag-$release
tar -xf c1xx-fcmag-$release.tar.bz2 -C c1xx-fcmag-$release
rm c1xx-fcmag-$release.tar.bz2

Create a phone variables directory:

imei=<see *#06#>
 
cd ~/freecalypso
mkdir $imei
cd $imei

Backup the stock firmware:

/opt/freecalypso/bin/fc-loadtool -h compal -c 1004 /dev/ttyUSB0
[[ Power on phone ]]
> flash dump2bin c139_backup.bin
> exit

Extract the calibration values:

/opt/freecalypso/bin/c1xx-calextr -b rfbin c139_backup.bin 0x3FC000

Flash the bootloader and firmware:

cd ~/freecalypso/c1xx-fcmag-$release/build-c139-hybrid-ui-vo
cp ../compal-flash-boot-for-fc.bin .
 
/opt/freecalypso/bin/fc-loadtool -h compal -c 1004 /dev/ttyUSB0
[[ Power on phone ]]
> flash erase-program-boot compal-flash-boot-for-fc.bin
> exec flash-script
 
# Make room for the filesystem
> flash erase 0x3C0000 0x30000
> exit

Initialize filesystem:

cd ~/freecalypso/$imei
[[ Power on phone ]]
 
/opt/freecalypso/bin/fc-fsio -p /dev/ttyUSB0
> format /
> mk-std-dirs
 
# Add IMEI
> set-imeisv fc $imei
 
# Configure radio and charging profile
> set-rfcap dual-eu
> upload-subtree rfbin /gsm/rf
> write-charging-config /opt/freecalypso/charging/c1xx/standard
> exit

Set it up:

[[ Power off phone ]]
[[ Insert SIM ]]
[[ Power on phone ]]


Updates


Update the firmware:

cd ~/freecalypso/c1xx-fcmag-$release/build-c139-hybrid-ui-vo
/opt/freecalypso/bin/fc-loadtool -h compal /dev/ttyUSB0
[[ Power on phone ]]
> exec flash-script