This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Using sbit on MCB2100 - LPC2129

Hi,
I'm using a MCB2100 dev board with LPC2129 chip. I am used to using a 8051 based chip and have used the sbit declaration for pin assignment previously. However it doesn't really like it with my new board. How do I go about reading from an individual pin?
thanks
Andy

Parents
  • "how do I read from a specific pin?"

    Strange as it may seem, the 'C' programming language has nothing for manipulating individual bits!

    The 8051 has some special bit-addressable hardware, so Keil added extensions in C51 to use it; in the absence of such extensions, you will just have to use the standard 'C' techniques of masking with the bitwise operators.

Reply
  • "how do I read from a specific pin?"

    Strange as it may seem, the 'C' programming language has nothing for manipulating individual bits!

    The 8051 has some special bit-addressable hardware, so Keil added extensions in C51 to use it; in the absence of such extensions, you will just have to use the standard 'C' techniques of masking with the bitwise operators.

Children
No data