diff options
Diffstat (limited to 'libraries/LiquidCrystal/examples')
-rw-r--r-- | libraries/LiquidCrystal/examples/HelloWorld/HelloWorld.pde | 12 | ||||
-rw-r--r-- | libraries/LiquidCrystal/examples/SerialDisplay/SerialDisplay.pde | 19 |
2 files changed, 31 insertions, 0 deletions
diff --git a/libraries/LiquidCrystal/examples/HelloWorld/HelloWorld.pde b/libraries/LiquidCrystal/examples/HelloWorld/HelloWorld.pde new file mode 100644 index 0000000..d514215 --- /dev/null +++ b/libraries/LiquidCrystal/examples/HelloWorld/HelloWorld.pde @@ -0,0 +1,12 @@ +#include <LiquidCrystal.h> + +LiquidCrystal lcd(12, 11, 2, 7, 8, 9, 10); + +void setup() +{ + lcd.print("hello, world!"); +} + +void loop() +{ +} diff --git a/libraries/LiquidCrystal/examples/SerialDisplay/SerialDisplay.pde b/libraries/LiquidCrystal/examples/SerialDisplay/SerialDisplay.pde new file mode 100644 index 0000000..c1f405a --- /dev/null +++ b/libraries/LiquidCrystal/examples/SerialDisplay/SerialDisplay.pde @@ -0,0 +1,19 @@ +#include <LiquidCrystal.h> + +LiquidCrystal lcd(12, 11, 2, 7, 8, 9, 10); + +void setup() +{ + Serial.begin(9600); +} + +void loop() +{ + if (Serial.available()) { + delay(100); + lcd.clear(); + while (Serial.available() > 0) { + lcd.write(Serial.read()); + } + } +} |