怎么按寄存器地址直接访问寄存器,比如 TACCR0的地址是0x0394u,TACCR1的地址是 0x0396u,我需要像访问数组一样,顺序读写他们,请问怎么写代码呢?
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.
怎么按寄存器地址直接访问寄存器,比如 TACCR0的地址是0x0394u,TACCR1的地址是 0x0396u,我需要像访问数组一样,顺序读写他们,请问怎么写代码呢?
Flash_ptrC = (char *) 0x1040; // Initialize Flash segment C pointer
Flash_ptrD = (char *) 0x1000; // Initialize Flash segment D pointer
for (i=0; i<64; i++)
{
*Flash_ptrD++ = *Flash_ptrC++; // copy value segment C to segment D
}
如此操作