This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Compiler/CC2642R: Receive and copy relatively large amount of data files into external flash

Part Number: CC2642R

Tool/software: TI C/C++ Compiler

Hi everyone,

I need to scan files through UART (~160kB) coming from GSM modem, which need to be saved. Scanning data arriving from UART managed by an interrupt routine. After the file receive process had been started, the dataflow is continuous. Since the CC2652R1 internal RAM is not enough to receive such size of data, I need to process the copy to an external memory.
The interrupt routine has a 1kB RAM buffer. When this gets full, I would like to write out its content immediately to an external flash memory.

The problem is by experience, when I call the writeFlash() function implemented in the interrupt routine, the software freeze. When i try to use writeFlash() outside of the interruption routine that is no problem occur.

The perfect solution would be if the interrupt routine buffered data could be written directly to the external flash. Is there anyway to do this?

Many Thanks for your help and soonest reply,

Leslie

  • Hi Laszlo,

    It seems like it is a possibility that this function can only be called from a task context and not a HWI or SWI...but I'd have to double check It's also not recommended to perform complex tasks in an ISR.

    I would recommend having a separate task to handle you writing to flash and having your ISR call and quickly return from that.

    Thanks,

    Alexis