We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi All,
Do anyone has idea how i can assign the bit allocation to certain memory address?
For now i could only use the _at_ to assign the character.
I am actually try to emulate the following assembly code. The SET_KEY is actually 2C.0, MINUS is 2C.1 and the PLUS is 2C.2. Anybody knows how i can do it in C using KEIL?
KEYS_NEW EQU 02CH ; TEST EQU 062H ; TEST key current status MINUS EQU 063H ; MINUS key current status PLUS EQU 064H ; PLUS key current status
So what's the problem with that?
The specific purpose of the _at_ keyword extension is precisely to locate a variable at the given address!
You use _at_ to assign a variable in BDATA, and then define the specific bits within that variable...
http://www.keil.com/support/man/docs/c51/c51_le_bitaddrobj.htm
http://www.keil.com/support/man/docs/c51/c51_le_bdata.htm
Thanks Andrew,
I got it works.