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.

【求助】2407读取程序区的数据



做一个通过CAN更新2407程序的bootloader。芯片上电后首先进入bootloader然后检查指定flash地址的数据。

在2812上我直接用指针就可实现了,但貌似2407上是读取的RAM里的数据,咋把程序空间的数据读出来啊?

  • 你可以通过CMD文件将你要读取的Flash 数据放在一个已知的地址,然后读取的时候再通过类似于* ((volatile int *) 0xxxxxx)这种语句读取数据。

  • he yuanjie 说:

    做一个通过CAN更新2407程序的bootloader。芯片上电后首先进入bootloader然后检查指定flash地址的数据。

    在2812上我直接用指针就可实现了,但貌似2407上是读取的RAM里的数据,咋把程序空间的数据读出来啊?

    memcopy()在已知地址和长度的情况下,复制到一个数组里面可以么, 28可以,2407没试过,