The below code displays > 13 on the LCD I jumper D7 and 8 and no change as well. Any ideas?
~~~
#chip mega328p, 16
#include <UNO_mega328p.h>
HI2CMode Master
#define HI2C_DATA
#define LCD_IO 10
#define LCD_I2C_Address 0x4e '// Change to 0xFE for SainSmart ELSE 4E
#define LCD_Backlight_On_State 1 '// These may need to be reversed
#define LCD_Backlight_Off_State 0
Do
'Get key
Temp = KeypadData
'If a key is pressed, then display it
If Temp <> KEY_NONE Then
Print Temp
'Wait until key is released
wait while KeypadData <> KEY_NONE
End If
Loop
End
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The below code displays > 13 on the LCD I jumper D7 and 8 and no change as well. Any ideas?
~~~
#chip mega328p, 16
#include <UNO_mega328p.h>
HI2CMode Master
#define HI2C_DATA
#define LCD_IO 10
#define LCD_I2C_Address 0x4e '// Change to 0xFE for SainSmart ELSE 4E
#define LCD_Backlight_On_State 1 '// These may need to be reversed
#define LCD_Backlight_Off_State 0
#define KEYPAD_ROW_1 DIGITAL_11
#define KEYPAD_ROW_2 DIGITAL_10
#define KEYPAD_ROW_3 DIGITAL_9
#define KEYPAD_ROW_4 DIGITAL_8
#define KEYPAD_COL_1 DIGITAL_7
#define KEYPAD_COL_2 DIGITAL_6
#define KEYPAD_COL_3 DIGITAL_5
#define KEYPAD_COL_4 DIGITAL_4
dim Temp as Byte
' Main
cls
print "> "
Do
'Get key
Temp = KeypadData
'If a key is pressed, then display it
If Temp <> KEY_NONE Then
Print Temp
'Wait until key is released
wait while KeypadData <> KEY_NONE
End If
Loop
End