i have arduino + ethernet shield + fingerprint scanner + lcd display 16x2.
my lcd can work ethernet shield , fingerprint scanner can work ethernet shield. if join them, program hang @ setup, @ fps.open , fps.setled(true) commands section. finger print scanner led doesn't want turn on. think because of there 1 or more ports cannot used either fingerprint scanner or lcd together. i've experienced lcd + ethernet shield before when cannot connect lcd port 10-13 because it's used ethernet shield.
here code :
it hang @ fps.open , fps.setled(true);
because lcd , piezo still works before commands. when put fps.open , fps.setled before lcd.begin command, lcd , piezo didnt work.
for information use arduino uno, fingerprint scanner (gt-511c3), , lcd display 16x2.
any appreciated.s
my lcd can work ethernet shield , fingerprint scanner can work ethernet shield. if join them, program hang @ setup, @ fps.open , fps.setled(true) commands section. finger print scanner led doesn't want turn on. think because of there 1 or more ports cannot used either fingerprint scanner or lcd together. i've experienced lcd + ethernet shield before when cannot connect lcd port 10-13 because it's used ethernet shield.
here code :
code: [select]
#include <spi.h>
#include <ethernet.h>
#include <keypad.h>
#include <liquidcrystal.h>
#include <fps_gt511c3.h>
#include <softwareserial.h>
//declare fps pin
fps_gt511c3 fps(2,3);
int piezopin = a0; //declare pin piezo
int y = 0; //variable lcd column
liquidcrystal lcd(9, 8, 7, 6, 5, 4); //declare lcd used pin. dont ever use pin 11 , 12 if have ethernet shield attached
const byte rows = 4; // 4 rows
const byte cols = 3; // 3 columns
// define keymap
char keys[rows][cols] = {
{'1','2','3',},
{'4','5','6',},
{'7','8','9',},
{'*','0','#',}
};
byte rowpins[rows] = { 13, 10, a1, a2 };// connect keypad row0, row1, row2 , row3 these arduino pins.
byte colpins[cols] = { a3, a4, a5 };// connect keypad col0, col1 , col2 these arduino pins.
// create keypad
keypad keypad = keypad( makekeymap(keys), rowpins, colpins, rows, cols );
// enter mac address controller below.
// newer ethernet shields have mac address printed on sticker on shield
byte mac[] = {
0x00, 0xaa, 0xbb, 0xcc, 0xde, 0x02 }; //if don't know write here, use random mac address.
// initialize ethernet client library
// ip address , port of server
// want connect (port 80 default http):
ethernetclient client;
char server[] = "192.168.88.251"; //server ip address or domain
void setup() {
// open serial communications , wait port open:
serial.begin(9600);
// check needed on leonardo:
while (!serial) {
; // wait serial port connect. needed leonardo only
}
//initializing lcd, give short animation
lcd.begin(16, 2);
lcd.print("initializing....");
delay(2000);
for (int x=0; x<16; x++) {
lcd.scrolldisplayleft();
delay(250);
}
beep1long(); //give 1 long beep before begin
//change lcd display
lcd.clear();
lcd.setcursor(0,0);
lcd.print("press finger :");
//starting fingerprint
delay(100);
fps.open();
fps.setled(true);
}
it hang @ fps.open , fps.setled(true);
because lcd , piezo still works before commands. when put fps.open , fps.setled before lcd.begin command, lcd , piezo didnt work.
for information use arduino uno, fingerprint scanner (gt-511c3), , lcd display 16x2.
any appreciated.s
does know ?
Arduino Forum > Using Arduino > Installation & Troubleshooting > SOLVED Issues With LCD Display + Fingerprint Scanner + Ethernet Shield
arduino
Comments
Post a Comment