This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Arduino String Manipulation | |
For more details, visit: https://techzeero.com/arduino-tutorials/arduino-string-functionality/ | |
*/ | |
void setup() { | |
char my_str[] = "I love arduino and programming"; // create a string | |
Serial.begin(9600); | |
// (1) print the string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Arduino String Functionality | |
For more details, visit: https://techzeero.com/arduino-tutorials/arduino-string-functionality/ | |
*/ | |
void setup() { | |
char my_str[] = "Hello"; | |
Serial.begin(9600); | |
Serial.println(my_str); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Arduino String Functionality | |
For more details, visit: https://techzeero.com/arduino-tutorials/arduino-string-functionality/ | |
*/ | |
void setup() { | |
char my_str[6]; // an array of 5 character string | |
Serial.begin(9600); | |
my_str[0] = 'H'; | |
my_str[1] = 'e'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Relay with Arduino and LDR | |
For more details, visit: | |
*/ | |
int sensorPin = A0; | |
int relayPin = 9; | |
void setup() | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
IR Receiver Control Signals Through Arduino | |
For more details, visit: https://techzeero.com/arduino-tutorials/control-tv-with-an-arduino/ | |
*/ | |
#include<IRremote.h> //IR remote control library | |
const int numberOfKeys = 5; | |
int firstKey = 4; //first pin of the 5 sequential pins connected to buttons | |
boolean buttonState[numberOfKeys]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Scrolling Text on LCD 16x2 | |
For more details, visit: https://techzeero.com/arduino-tutorials/how-to-use-an-lcd-display-with-arduino/ | |
*/ | |
#include<LiquidCrystal.h> | |
LiquidCrystal lcd(12,11,5,4,3,2); | |
int numRows = 2; | |
int numCols = 16; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Turning the Cursor and Display On or Off | |
For more details, visit: https://techzeero.com/arduino-tutorials/how-to-use-an-lcd-display-with-arduino/ | |
*/ | |
#include<LiquidCrystal.h> | |
LiquidCrystal lcd(12,11,5,4,3,2); | |
void setup() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Display Double-Height Characters on 16×2 LCD | |
For more details, visit: https://techzeero.com/arduino-tutorials/custom-characters-on-16x2-lcd/ | |
*/ | |
#include<LiquidCrystal.h> | |
LiquidCrystal lcd(12,11,5,4,3,2); | |
byte glyphs[5][8]={ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Display Custom Characters on 16×2 LCD | |
For more details, visit: https://techzeero.com/arduino-tutorials/custom-characters-on-16x2-lcd/ | |
*/ | |
#include<LiquidCrystal.h> | |
LiquidCrystal lcd(12,11,5,4,3,2); | |
byte smile[8] = {0b00000,0b01010,0b00000,0b00000,0b10001,0b01110,0b00000,0b00000}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
DS3231 RTC and LCD with Arduino | |
For more details, visit: https://techzeero.com/arduino-tutorials/ds3231-rtc-with-arduino-arduino-real-time-clock/ | |
*/ | |
#include <DS3231.h> | |
#include <LiquidCrystal.h> // includes the LiquidCrystal Library | |
DS3231 rtc(SDA, SCL); |