#include <Adafruit_Fingerprint.h>
#include<Arduino.h>
#include <SoftwareSerial.h>
#include <Wire.h>
#include <LiquidCrystal.h>
int getFingerprintIDez();
uint8_t getFingerprintEnroll();
// pin #2 is IN from sensor (GREEN wire)
// pin #3 is OUT from arduino (WHITE wire)
SoftwareSerial mySerial(2, 3);
Adafruit_Fingerprint finger = Adafruit_Fingerprint(&mySerial);
// On Leonardo/Micro or others with hardware serial, use those! #0 is green wire, #1 is white
//Adafruit_Fingerprint finger = Adafruit_Fingerprint(&Serial1);
LiquidCrystal lcd(12, 11, 6, 5, 4, 3);
int sensorInterrupt = 0; // interrupt 0
int sensorPin = 2; //Digital Pin 2
int FingerMode = 0 ;
int SkipHead = 0;
int state[11];
uint8_t id;
unsigned int SetPoint = 400; //400 milileter
/The hall-effect flow sensor outputs pulses per second per litre/minute of flow./
float calibrationFactor = 4.5; //You can change according to your datasheet
volatile byte pulseCount = 0;
float flowRate = 0.0;
unsigned int flowMilliLitres = 0;
unsigned long totalMilliLitres = 0;
unsigned long oldTime = 0;
void setup()
{
pinMode(8, INPUT_PULLUP); //orange finger detect
pinMode(9, INPUT_PULLUP); //white enroll
pinMode(10, OUTPUT); //relay
digitalWrite(10, LOW);
lcd.begin(16, 2); // initialize the lcd
// lcd.backlight(); //default backlight on
lcd.clear();
// while (!Serial); // For Yun/Leo/Micro/Zero/...
Serial.begin(9600);
pinMode(sensorPin, INPUT);
digitalWrite(sensorPin, HIGH);
attachInterrupt(sensorInterrupt, pulseCounter, FALLING); //you can use Rising or Falling
lcd.print("finger detect");
// delay(100);
// set the data rate for the sensor serial port
finger.begin(57600);
if (finger.verifyPassword()) {
// lcd.print("Found fingerprint!");
} else {
// lcd.print("Did not find fingerprint sensor :(");
while (1);
}
}
....
can u solve something in this,,,..
errorr is
Arduino: 1.8.6 Hourly Build 2018/01/03 03:33 (Windows 10), Board: "Arduino Mega ADK"
C:\Users\imman\Desktop\raw\raw.ino: In function 'void setup()':
raw:74: error: 'pulseCounter' was not declared in this scope
attachInterrupt(sensorInterrupt, pulseCounter, FALLING); //you can use Rising or Falling
^
C:\Users\imman\Desktop\raw\raw.ino: At global scope:
raw:263: error: expected constructor, destructor, or type conversion before '(' token
delay(1500);
^
raw:264: error: 'lcd' does not name a type
lcd.clear();
^
raw:265: error: 'lcd' does not name a type
lcd.setCursor(0, 0);
^
raw:266: error: 'lcd' does not name a type
lcd.print("Place");
^
raw:267: error: 'lcd' does not name a type
lcd.setCursor(0, 1);
^
raw:268: error: 'lcd' does not name a type
lcd.print("your Finger..!");
^
raw:269: error: 'Serial' does not name a type
Serial.print(" with confidence of "); Serial.println(finger.confidence);
^
raw:269: error: 'Serial' does not name a type
Serial.print(" with confidence of "); Serial.println(finger.confidence);
^
raw:270: error: expected unqualified-id before 'return'
return finger.fingerID;
^
raw:271: error: expected declaration before '}' token
}
^
Multiple libraries were found for "Adafruit_Fingerprint.h"
Used: C:\Users\imman\Desktop\arduino_flow\arduino-nightly\libraries\Adafruit_Fingerprint_Sensor_Library-1.1.1
Not used: C:\Users\imman\Desktop\arduino_flow\arduino-nightly\libraries\FingerPrint
Multiple libraries were found for "SoftwareSerial.h"
Used: C:\Users\imman\Desktop\arduino_flow\arduino-nightly\hardware\arduino\avr\libraries\SoftwareSerial
Not used: C:\Users\imman\Desktop\arduino_flow\arduino-nightly\libraries\SoftwareSerial
exit status 1
'pulseCounter' was not declared in this scope
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.