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
int led = 13; | |
void setup(){ | |
Serial.begin(9600); | |
pinMode(led,OUTPUT); | |
} | |
void loop(){ | |
char caracter = Serial.read(); | |
if (caracter == '1') { | |
digitalWrite(led,HIGH); | |
} |
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
int led1 = 2; | |
int led2 = 3; | |
int estado01 = LOW; | |
int estado02 = LOW; | |
char leitura; | |
void setup(){ | |
Serial.begin(9600); |
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
int led = 13; | |
int estado = LOW; | |
char leitura; | |
void setup(){ | |
Serial.begin(9600); | |
pinMode(led, OUTPUT); | |
} | |
void loop(){ | |
if(Serial.available()){ | |
leitura = Serial.read(); |
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
int portSpeak(9); | |
//melodia do MARIO THEME | |
int melodia[] = {660,660,660,510,660,770,380,510,380,320,440,480,450,430,380,660,760,860,700,760,660,520,580,480,510,380,320,440,480,450,430,380,660,760,860,700,760,660,520,580,480,500,760,720,680,620,650,380,430,500,430,500,570,500,760,720,680,620,650,1020,1020,1020,380,500,760,720,680,620,650,380,430,500,430,500,570,585,550,500,380,500,500,500,500,760,720,680,620,650,380,430,500,430,500,570,500,760,720,680,620,650,1020,1020,1020,380,500,760,720,680,620,650,380,430,500,430,500,570,585,550,500,380,500,500,500,500,500,500,500,580,660,500,430,380,500,500,500,500,580,660,870,760,500,500,500,500,580,660,500,430,380,660,660,660,510,660,770,380}; | |
//duraçao de cada nota | |
int duracaodasnotas[] = {100,100,100,100,100,100,100,100,100,100,100,80,100,100,100,80,50,100,80,50,80,80,80,80,100,100,100,100,80,100,100,100,80,50,100,80,50,80,80,80,80,100,100,100,100,150,150,100,100,100,100,100,100,100,100,100,100,150,200,80,80,80,100,100,100,100,100,150,150,100,100,100,100,100,100,100,1 |
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 <Keypad.h> | |
char* senha = "159D"; | |
int position = 0; | |
const byte LINHAS = 4; | |
const byte COLUNAS = 4; | |
char teclas[LINHAS][COLUNAS] = { | |
{'1','2','3','A'}, | |
{'4','5','6','B'}, | |
{'7','8','9','C'}, | |
{'*','0','#','D'} |
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
//Baseado no programa original de Michael McRoberts | |
#include <AFMotor.h> | |
AF_DCMotor motor_esq(1); //Seleciona o motor 1 | |
AF_DCMotor motor_dir(4); //Seleciona o motor 1 | |
int SENSOR1, SENSOR2, SENSOR3; | |
//deslocamentos de calibracao |
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
int rele1 = A0; | |
int rele2 = A1; | |
int rele3 = A2; | |
int rele4 = A3; | |
int rele5 = A4; | |
int rele6 = A5; | |
int rele01 = LOW; | |
int rele02 = LOW; | |
int rele03 = LOW; |
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
/***************************************\ | |
** CARRINHO DE CONTROLE REMOTO ** | |
* * | |
** Nilsinho Pessim ** | |
\***************************************/ | |
#include <AFMotor.h> | |
AF_DCMotor m1(1); | |
AF_DCMotor m2(2); |
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 motor; | |
int serial; | |
void setup(){ | |
Serial.begin(9600); | |
motor.attach(6); | |
} |
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
String voz; | |
int | |
led1 = 9, | |
led2 = 10, | |
led3 = 11, | |
led4 = 12, | |
led5 = 13; | |
void allon(){ | |
digitalWrite(led1, HIGH); |
OlderNewer