Skip to content

Instantly share code, notes, and snippets.

Sagar Sapkota buildcircuit

View GitHub Profile
View RGB-Test_LCD.ino
// include the library code:
#include <LiquidCrystal.h>
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(13, 12, 10, 9, 8, 7);
int REDLED = 3; // the PWM pin the LED is attached to
int BLUELED = 5;
int GREENLED= 6;
View Fade_LCD.ino
// include the library code:
#include <LiquidCrystal.h>
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(13, 12, 10, 9, 8, 7);
int led = 11; // the PWM pin the LED is attached to
int brightness = 0; // how bright the LED is
int fadeAmount = 5; // how many points to fade the LED by
@buildcircuit
buildcircuit / blink_LCD.ino
Created Jul 2, 2020
Blink 5mm LED on the LCD Shield
View blink_LCD.ino
@buildcircuit
buildcircuit / cd4029_ldr.ino
Created Jun 30, 2020
CD4029 up and down counter module responding to sensor
View cd4029_ldr.ino
int sensorPin = A0; // select the input pin for the photoresistor
int CLK = 13; // Pin 13 of Arduino gives pulse to CD4029 module
int sensorValue = 0; // variable to store the value coming from the sensor
int RESET=11; // connect to reset pin of CD4029
int UD=12; // connect to UD pin of CD4029
void setup() {
Serial.begin(9600);
@buildcircuit
buildcircuit / cd4029.ino
Last active Jun 30, 2020
CD4029 up and down counter
View cd4029.ino
// Basic test of CD4029 up and down counter module
// Module designed by Sagar Sapkota from www.buildcircuit.net
void setup() {
pinMode(13, OUTPUT);// Connect pin 13 to CLK pinl
pinMode(12,OUTPUT); // Connect pin 12 to UD
//RESET THE COUNTER
// Connect Pin 11 of Arduino to RST Pin
pinMode(11,OUTPUT);
digitalWrite(11,HIGH);
@buildcircuit
buildcircuit / esp8266-led-blink.ino
Created Oct 29, 2015
ESP8266 LED Blink Project
View esp8266-led-blink.ino
View RGB-SMD-LED.ino
/* ---------------------------------------------------------
* | Experimentation Kit for Arduino Example Code |
* | CIRC-RGB .: Colourful Light :. (RGB LED) |
* ---------------------------------------------------------
*
* We've blinked an LED and controlled eight in sequence now it's time to
* control colour. Using an RGB LED (actual 3 LEDs in a single housing)
* we can generate any colour our heart desires.
*
* (we'll also use a few programming shortcuts to make the code
View TTP226.ino
/*arduino touch 8
VCC-----------5V
GND-----------GND
OUT1-----------2
OUT2-----------3
OUT3-----------4
OUT4-----------5
OUT5-----------6
OUT6-----------7
OUT7-----------8
View rgb-led.ino
/* FILE: ARD_RGB_LED_MODULE_HCARDU0021_Example.pde
DATE: 04/07/12
VERSION: 0.1
This is a simple example of how to use the HobbyComponents RGB LED module
(HCARDU0021). The module has 3 separate LED's (Red, Green & Blue) which
Can be individually driven by applying a voltage to the appropriate module pin.
This example uses the standard Arduino analogWrite (PWM) function to cycle
through the full range of colours this module is capable of producing.
Please be aware that this module does NOT include current limiting
View adxl335.ino
//Analog read pins
const int xPin = 0;
const int yPin = 1;
const int zPin = 2;
//The minimum and maximum values that came from
//the accelerometer while standing still
//You very well may need to change these
int minVal =270;
int maxVal =440;
You can’t perform that action at this time.