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 turbidity meter Project // | |
// // | |
// www.edisonsciencecorner.blogspot.com // | |
///////////////////////////////////////////////////////////////// | |
#include <LiquidCrystal_I2C.h> | |
LiquidCrystal_I2C lcd(0x27, 2, 16); | |
int sensorPin = A0; |
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
/* | |
Sketch generated by the Arduino IoT Cloud Thing "Untitled" | |
https://create.arduino.cc/cloud/things/96da2ac8-336f-496e-9206-e9c105ec58b0 | |
Arduino IoT Cloud Variables description | |
The following variables are automatically generated and updated when changes are made to the Thing | |
bool led; | |
CloudTemperatureSensor temperature; |
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
#include <Wire.h> | |
#include "LedControl.h" | |
LedControl lc=LedControl(12,10,11,4); // Pins: DIN,CLK,CS, # of Display connected | |
struct point | |
{ | |
int y, x; | |
int aX, aY; | |
}; |
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
#include "DFRobot_DF2301Q.h" | |
#define whiteLed 8 | |
#define blueLed 9 | |
//I2C communication | |
DFRobot_DF2301Q_I2C asr; | |
void setup() { | |
Serial.begin(115200); |
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
// EDISON SCIENCE CORNER | |
// EDISON SCIENCE CORNER | |
// EDISON SCIENCE CORNER | |
// EDISON SCIENCE CORNER | |
// EDISON SCIENCE CORNER | |
// EDISON SCIENCE CORNER | |
#include <CapacitiveSensor.h> |
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
/*www.edisonsciencecorner.blogspot.com*/ | |
int ledpins[] = {2,3,4,5}; | |
int groundpins[] = {6,7}; | |
void setup () | |
{ | |
for(int i = 0; i < 4; i++) | |
{ | |
pinMode(ledpins[i],OUTPUT); | |
} |
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
//www.edisonsciencecorner.blogspot.com | |
//www.edisonsciencecorner.blogspot.com | |
//www.edisonsciencecorner.blogspot.com | |
#include <LiquidCrystal_I2C.h> | |
LiquidCrystal_I2C lcd(0x27, 2, 16); | |
const int Up_buttonPin = 2; // the pin that the pushbutton is attached to | |
const int Down_buttonPin = 3; | |
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
#include <FastLED.h> | |
#define NUM_LEDS 2 | |
#define DATA_PIN 6 | |
#define CLOCK_PIN 13 | |
CRGB leds[NUM_LEDS]; | |
void setup() { | |
pinMode (3,INPUT); | |
pinMode (2,OUTPUT); | |
FastLED.addLeds<NEOPIXEL, DATA_PIN>(leds, NUM_LEDS); | |
} |
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
//EDISON SCIENCE CORNER | |
//EDISON SCIENCE CORNER | |
//EDISON SCIENCE CORNER | |
//EDISON SCIENCE CORNER | |
//EDISON SCIENCE CORNER | |
int digit1 = 11; //PWM Display pin 12 (digit1 is common anonds A1 from right side) | |
int digit2 = 10; //PWM Display pin 9 (digit2 is common A2) | |
int digit3 = 9; //PWM Display pin 8 (digit3 is common anods A3) | |
int digit4 = 6; //PWM Display pin 6 (digit4 is common anods, from left side) | |
int segA = 2; //Display pin 11 |
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
#include <Servo.h> | |
Servo ESC; // create servo object to control the ESC | |
int potValue; // value from the analog pin | |
void setup() { | |
// Attach the ESC on pin 9 | |
ESC.attach(9,1000,2000); // (pin, min pulse width, max pulse width in microseconds) | |
} | |
void loop() { | |
potValue = analogRead(A0); // reads the value of the potentiometer (value between 0 and 1023) |
NewerOlder