Failure in SAM-BA writes to device using XMODEM

1 post / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

 

I'm trying to write to an ATSAM3U4E using SAM-BA over UART. I'm relying only on the ROM in the chip, and writing to the chip using a python script via the EFC and the SAM-BA Monitor (which reports itself as v1.1)

 

This works fine as long as I write word by word. However, when I attempt to send blocks using Xmodem, it fails.

 

While the device writes and does not report errors, when I read the flash back, I find that each word in the flash is filled only with the first byte, ie, if a word to be written is 0xAB123727, the contents of flash after the writing are 0xABABABAB. This seems to happen for every single word of every single page.

 

The blocks I send are only as large as a single page, and so SRAM isn't an issue. I have tried increasing the flash wait states to 6 (FWS=6, as suggested by the Errata in the datasheet) by writing to the EFC FMR via the SAM-BA monitor, and this does not help.