LPC1114 indirect register access

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

LPC1114 indirect register access

232 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wyorin on Thu Aug 14 07:50:55 MST 2014
This may be a dumb question, but I would like to set up pointers in Flash memory to the configuration registers for the I/O on an LPC1114 processor, e,g. registers of the form LPC_IOCON->PIO0_1. Is this possible.?
标签 (1)
0 项奖励
1 回复

212 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by nerd herd on Thu Aug 14 10:04:10 MST 2014
Hello,

The multiplexed pins most certainly can be structured to be user friendly and readable in the way you are mentioning. In fact, our software platform called LPCOpen provides software examples that structure things in this way, as well as easy API calls. Here's a link to the LPCOpen downloads:
http://www.lpcware.com/content/nxpfile/lpcopen-software-development-platform-lpc11xx-packages-0

Even if your board is not supported, it would be helpful to look at the way things are declared. A quick glance at the UART example shows that the registers can be indirectly accessed like so: pIOCON->PIO0[pin].
0 项奖励