Downloading PSoC firmware in the field

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

We are using the PSoC in a product for which we must be able to update the firmware in the field. Our device contains a radio module in addition to the PSoC, so our code on the PSoC will need to somehow receive the new firmware from the radio module (via the UART interface) and write this to the PSoC flash memory.



Obviously this is not a trivial problem. It would be much simpler if there was at least 50% of the flash memory available; then we could download the new firmware to the free half of the flash before setting a flag to tell the boot code to start up by jumping to the newly downloaded firmware version. However, we are using about 95% of our flash memory, so this is infeasible.



I imagine the only solution is to create our own boot loader, which contains the minimal code necessary to receive firmware updates from the radio module. Then, the PSoC could be reset, and the boot loader can receive the new firmware and incrementally erase/write the flash memory as bits of the firmware are received.



It would be imperative that the boot loader could recover from a failed firmware download attempt, since it is highly probable that at least one packet of data will be dropped or corrupted once in a while.



I just found application note AN2273 (I2C Bootloader for PSoC, 16-Byte Packet Transfer), but are there any other resources that could be helpful?



Thanks for any suggestions.



Regards,

Colin D. Bennett

Venture Design Services, Inc.



   
    
   
   



Field Firmware Upgrade Resources

This is a list of resources related to upgrading PSoC firmware in the field. Please contribute any other resources you think might be applicable.

   
  •     
         Application note AN2100 (PSoC flash programming over UART with bootloader)     
         
        
  •    
  •     
         Application note AN2273 (I2C Bootloader for PSoC, 16-Byte Packet Transfer)     
         
        
  •    
  •     
  • 0 Likes
    3 Replies
    Anonymous
    Not applicable
            You can also refer to AN2100 and AN2273 which provide more information on bootloaders.   
    0 Likes
    ronoc_298001
    Level 1
    Level 1
    10 sign-ins 5 sign-ins Welcome!
            Hi Colin,   
       
    I have written a small but powerfull UART bootloader. It is still in development phase, and I am writing an application note for it.   
       
    You can have a preview of the bootloader application note:   
        www.nooteboom.biz/downloads/PSoC1 UART Bootloader Application Note.pdf   
       
    Please PM me if you have any questions.   
       
    Best regards,   
       
    Rolf   
    0 Likes
    ronoc_298001
    Level 1
    Level 1
    10 sign-ins 5 sign-ins Welcome!
            The bootloader is now published under GPL right here:   
        http://www.psocdeveloper.com/f...wtopic.php?f=3&t=5658    
       
    Regards,   
    Rolf   
    0 Likes