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> | |
int PinServo[5] = {A0, A1, A2, A3, A4}; | |
int Pmax[5] = {140, 160, 160, 160, 20}; | |
int Pmin[5] = {40, 0, 0, 20, 160}; | |
int Pactual[5] = {90, 90, 90, 90, 90}; | |
int Ppasado[5] = {90, 90, 90, 90, 90}; | |
Servo Dedo[5]; | |
int VMaxSensor = 0; |
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> | |
int PinServo[5] = {A0, A1, A2, A3, A4}; //A4 MEÑIQUE,A3 ANULAR,A2 MEDIO,A1 INDICE,A0 PALMA | |
int Pmax[5] = {140, 160, 160, 160, 160}; | |
int Pmin[5] = {40, 0, 0, 20, 20}; | |
int Pactual[5] = {90, 90, 90, 90, 90}; | |
Servo Dedo[5]; | |
int PinSensor = A5; | |
int VMaxSensor = 0; |
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
modified 8 Nov 2013 | |
by Scott Fitzgerald | |
http://www.arduino.cc/en/Tutorial/Sweep | |
*/ | |
#include <Servo.h> | |
int PinServo[5] = {A0, A1, A2, A3, | |
}; | |
Servo Dedo[5]; |
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
#ifdef ARDUINO_ARCH_ESP32 | |
#include <WiFi.h> | |
#include <WiFiMulti.h> | |
WiFiMulti wifiMulti; | |
#else | |
#include <ESP8266WiFi.h> | |
#include <ESP8266WiFiMulti.h> | |
ESP8266WiFiMulti wifiMulti; | |
#endif | |
#include "PCD8544.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
#ifdef ARDUINO_ARCH_ESP32 | |
#include <WiFi.h> | |
#include <WiFiMulti.h> | |
WiFiMulti wifiMulti; | |
#else | |
#include <ESP8266WiFi.h> | |
#include <ESP8266WiFiMulti.h> | |
ESP8266WiFiMulti wifiMulti; | |
#endif |
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
#ifdef ARDUINO_ARCH_ESP32 | |
#include <WiFi.h> | |
#include <WiFiMulti.h> | |
WiFiMulti wifiMulti; | |
#else | |
#include <ESP8266WiFi.h> | |
#include <ESP8266WiFiMulti.h> | |
ESP8266WiFiMulti wifiMulti; | |
#endif |
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> | |
#include <WiFi.h> | |
#include <WiFiMulti.h> | |
#include <PubSubClient.h> | |
const char* ssid = "No Es De Choto"; | |
const char* password = "99568550"; | |
const char* mqtt_server = "iot.eclipse.org"; | |
int mqtt_port = 1883; |
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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<script src="https://raw.githubusercontent.com/eclipse/paho.mqtt.javascript/master/src/paho-mqtt.js" type="text/javascript"></script> | |
<script src="./mqtt.js" type="text/javascript"></script | |
<title>MQTT Demo</title> | |
</head> | |
<body> | |
<h1>MQTT is awesome!</h1> |
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
// Create a client instance | |
var client = new Paho.MQTT.Client('test.mosquitto.org', 1883, "clientId"); | |
// set callback handlers | |
client.onConnectionLost = onConnectionLost; | |
client.onMessageArrived = onMessageArrived; | |
// connect the client | |
client.connect({onSuccess:onConnect}); |
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> | |
#include <WiFi.h> | |
#include <PubSubClient.h> | |
const char* ssid = "ALSW"; | |
const char* password = "2526-4897"; | |
const char* mqtt_server = "test.mosquitto.org"; | |
int mqtt_port = 1883; | |
WiFiClient espClient; |