flashjs is a command line replacement for the Freescale bootloader GUI (formerly called ICP) utility that allow to flash a blank S08JS USB MCU using the bootloader included in the MCU ROM without the aid of a BDM or any other developer tool.
flashjs is based on the information provided by Freescale application note AN3958 and uses libusb for USB access.
The main advantages of flashjs vs. the Freescale bootloader GUI are:
- Multiplatform - flashjs supports any platforms supported by libusb
- Command line - can be easily integrated in scripts
- Free Software - Licensed under the GPL
- read S19 files
- mass erase (restore to factory new condition)
- partial erase (preserve the configuration block)
- flash program/upgrade (upgrade will skip any data in the configuration block)
- check the CRC of a flashed image
- reboot the MCU
Mass erase the MCU. This will restore the MCU to factory new conditions
partial erase. This will preserve the configuration blocks
program file.s19 into the MCU. Should be used only after a mass erase command or a brand new device
flashjs p file.s19
program file.s19 into the MCU (automatically skips data in the configuration block).
flashjs u file.s19
uses the MCU internal CRC generator to check if the image was flashed successfully
Reboot the MCU. If the flashed image is valid the MCU will execute the firmware instead of the bootloader.
The S-record file must not contain S1 lines with more than 32 data bytes each. The S08JS ROM bootloader cannot handle more than 32 bytes and flashjs currently does not reformat the data before sending it to the MCU.