SneaKSz
Member
Hello,
I'm new to C , but I had C++ @ school. I'm trying to define a PORT and then use the name to set a bit of that port.
I don't know how to set the pin LCD_RS from LCD_PORT high , in other words LATC,4
Hopefully someone can help me with this small question
Thanks !
I'm new to C , but I had C++ @ school. I'm trying to define a PORT and then use the name to set a bit of that port.
Code:
#define LCD_PORT LATC
#define LCD_RS 0x04
......
LCD_PORTbits.LCD_RS = 1; // doesn't work
LCD_PORT.LCD_RS = 1; // doesn't work
LCD_PORTbits(.LCD_RS) = 1; // doesn't work
I don't know how to set the pin LCD_RS from LCD_PORT high , in other words LATC,4
Hopefully someone can help me with this small question
Thanks !