Hola estimados,
En Foto2 se muestra uno de los mensajes que se presentan cuando lo conecto a USB.
En Foto1 se muestra uno de los mensajes que se presentan cuando lo conecto a fuente.
En Foto3 se muestra la forma de conexion.
Este es mi codigo:
#include <LiquidCrystal.h>
#include <Keypad.h>
//---------------------------------------------------------------------------------------
//General
//PushButton
const int pulsador = 4; // Entrada digital para el pulsador, con pull down = 10k, rojo
//Indicadores
const int ledPin = 7; // Indicador de error general, amarillo
const int ledPin2 = 6; //Indicador de inicio y fin de lectura, marron
const int ledPin3 = 5; //Indicador de lectura incorrecta (se sobrepaso el tiempo requerido), naranja
const int tiempoAntirrebote = 15; // tiempo en ms para evitar el rebote
int estadoBoton;
int estadoBotonAnterior;
int ledState = LOW; // ledState used to set the LED
int PBState = LOW;
const long Finish = 120000;
long vax;
uint8_t low, high;
String pruebix = "";
String pruebix2 = "";
int16_t val = 0;
int16_t val1 = 0;
int16_t val2 = 0;
unsigned int factor = 0;
byte PesoCal, PesoMax;
long i = 0;
int j;
byte R17, TstMode;
char K = '0';
// The value will quickly become too large for an int to store
unsigned long previous = 0; // will store last time LED was updated
// constants won't change :
const long interval = 700; // interval at which to blink (microseconds)
unsigned long current;
//---------------------------------------------------------------------------------------
//Teclado
const byte Filas = 4; //Cuatro filas
const byte Cols = 4; //Cuatro columnas
byte Pins_Filas[] = {26, 28, 30, 32}; //Pines Arduino para las filas --> morado,rojo,blanco,azul
byte Pins_Cols[] = { 34, 36, 38, 40}; // Pines Arduinopara las columnas --> plomo,naranja,marron,amarillo
char Teclas [ Filas ][ Cols ] =
{
{'1','2','3','A'},
{'4','5','6','B'},
{'7','8','9','C'},
{'*','0','#','D'}
};
Keypad Teclado1 = Keypad(makeKeymap(Teclas), Pins_Filas, Pins_Cols, Filas, Cols);
char pulsacion;
char Data[8]; //7 numeros + null
//---------------------------------------------------------------------------------------
//Display
//VCC(ROJO), GND(VERDE)
//Crear el objeto LCD con los números correspondientes (rs, en, d4, d5, d6, d7) --> RW(amarillo) = 0
LiquidCrystal lcd(8, 9, 10, 11, 12, 13); //negro,marron,verde,morado,azul,plomo
byte N[8] = {B11111, B10001, B10001, B10001, B10001, B10001, B10001, B00000,};
byte A[8] = {B11111, B10001, B10001, B10001, B10001, B11111, B10001, B00000,};
byte Y[8] = {B10001, B10001, B10001, B10001, B11111, B00100, B00100, B00000,};
byte L[8] = {B10000, B10000, B10000, B10000, B10000, B10000, B11111, B00000,};
byte M[8] = {B11111, B10101, B10101, B10101, B10101, B10101, B10101, B00000,};
byte P[8] = {B11111, B10001, B10001, B10001, B11111, B10000, B10000, B00000,};
byte cara[8] = {B00000, B10001, B00000, B00000, B10001, B01110, B00000, B00000};
byte cuerpo[8] = {B01110, B01110, B00100, B11111, B00100, B01010, B10001, B00000,};
//---------------------------------------------------------------------------------------
//---------------------------------------------------------------------------------------
//---------------------------------------------------------------------------------------
void setup () {
pinMode(ledPin, OUTPUT); // Indicador de error general
digitalWrite(ledPin, LOW);
pinMode(ledPin2, OUTPUT); //Indicador de inicio y fin de lectura
digitalWrite(ledPin2, LOW);
pinMode(ledPin3, OUTPUT); //Indicador de lectura incorrecta (se sobrepaso el tiempo requerido)
digitalWrite(ledPin3, LOW);
pinMode(pulsador, INPUT); // PIN digital del pulsador como entrada
//CreateChar();
lcd.begin (20, 4);
lcd.setCursor(0, 1);
lcd.print(" Iniciando ... ");
delay(5000);
}
//--------------------------------------------------------------------------
void loop () {
lcd.clear();
lcd.setCursor(0, 2);
lcd.print(" Tecnodinamica SRL ");
delay(5000);
lcd.clear();
lcd.setCursor(0, 2);
lcd.print(" pRUEBA ");
delay(5000);
}
//--------------------------------------------------------------------------
void CreateChar(){
lcd.createChar (0,N);
lcd.createChar (1,A);
lcd.createChar (2,Y);
lcd.createChar (3,L);
lcd.createChar (4,M);
lcd.createChar (5,P);
lcd.createChar (6,cara);
lcd.createChar (7,cuerpo);
}
Al medir los voltajes en LD1117 se obtiene lo siguiente:
VIN = 7.27
VOUT = 5V
Agradeceré indicarme alguna idea.
utper