cancel
Showing results for 
Search instead for 
Did you mean: 

st7 Dev #define wrong value

brianbrian9
Associate II
Posted on October 21, 2016 at 18:30

Hi, have a really strange problem if I use

#define fred 0 and then LD A,#fred, A = 6 (Wrong)

If I use #define fred 00 and then LD A,#fred, A = 0 (Right)

If I use #define fred $0 and then LD A,#fred, A = 0 (Right)

If I move the the #define fred 0 to different area of code it also works ok

I see there is a max of 4096 #define statements that can be used but I am nowhere near that.

Any thoughts

Regards, Brian  
0 REPLIES 0