I'm getting an error trying to compile the sample code for SainSmart's
SainSmart LCD Keypad Shield For Arduino Duemilanove UNO MEGA2560 MEGA1280
SKU:20-011-901
The sample code directory structure is
home
me
sketchbook
keypad_lcd
keypad_1602for_1.0
DFR_Key.h
DFR_Key.cpp
examples
Key_Grab
Key_Grab.ino
<filename made of strange characters>.c
Part of the .zip file expansion:
creating: keypad_lcd/keypad_1602for_1.0/
inflating: keypad_lcd/keypad_1602for_1.0/DFR_Key.cpp
inflating: keypad_lcd/keypad_1602for_1.0/DFR_Key.h
inflating: keypad_lcd/keypad_1602for_1.0/README.txt
creating: keypad_lcd/keypad_1602for_1.0/examples/
creating: keypad_lcd/keypad_1602for_1.0/examples/Key_Grab/
inflating: keypad_lcd/keypad_1602for_1.0/examples/Key_Grab/Key_Grab.ino
inflating: keypad_lcd/keypad_1602for_1.0/examples/Key_Grab/ð┬¢¿╬─▒¥╬─ÁÁ.c
inflating: keypad_lcd/keypad_1602for_1.0/keywords.txt
The error:
/opt/arduino-1.6.4/hardware/tools/avr/bin/avr-g++ -c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -mmcu=atmega8 -DF_CPU=16000000L -DARDUINO=10604 -DARDUINO_AVR_NG -DARDUINO_ARCH_AVR -I/opt/arduino-1.6.4/hardware/arduino/avr/cores/arduino -I/opt/arduino-1.6.4/hardware/arduino/avr/variants/standard -I/opt/arduino-1.6.4/libraries/LiquidCrystal/src /tmp/build551086873859939019.tmp/Key_Grab.cpp -o /tmp/build551086873859939019.tmp/Key_Grab.cpp.o
Key_Grab.ino:22:21: fatal error: DFR_Key.h: No such file or directory
compilation terminated.
Error compiling.
Why am I getting the error? I have tried putting a copy of DFR_Key.h in Key_Grab with Key_Grab.ino and still get the error. The only way I could get Key_Grab.ino to compile is to copy DFR_Key.h into Key_Grab.ino and delete the #include line.
I tried another example and got the same result. The .h file could not be found.
I'm using Arduino IDE 1.6.4 but I got the same result with 1.6.3.
My system is Gentoo Linux.
Thanks