RFID with HC06 bluetooth and ESP wifi module
Dependencies: mbed MFRC522 ESP8266
Revision 5:6ee9d8e3d385, committed 2019-04-21
- Comitter:
- rajas1812
- Date:
- Sun Apr 21 15:36:13 2019 +0000
- Parent:
- 4:834deb7037ff
- Commit message:
- RFID with HC06 bluetooth and ESP8286 wifi module
Changed in this revision
| ESP8266.lib | Show annotated file Show diff for this revision Revisions of this file |
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ESP8266.lib Sun Apr 21 15:36:13 2019 +0000 @@ -0,0 +1,1 @@ +https://developer.mbed.org/users/janhavi/code/ESP8266/#4f24e7e803a1
--- a/main.cpp Sat Apr 20 17:18:17 2019 +0000
+++ b/main.cpp Sun Apr 21 15:36:13 2019 +0000
@@ -94,6 +94,7 @@
pc.printf("\r\nMilk is in the fridge");
blue.printf("\r\nMilk is in the fridge");
counter1 = 1;
+
}
else if(counter1 == 1){
pc.printf("\r\nMilk is out of the fridge");
@@ -183,7 +184,8 @@
void esp_send(void)
{
-
+ int field1 = 0;
+ int field2 = 0;
//ESP updates the Status of Thingspeak channel//
strcpy(snd,"AT+CIPSTART=");
@@ -198,7 +200,7 @@
pc.printf("R\r\n%s",rcv);
wait(1);
- sprintf(snd,"GET https://api.thingspeak.com/update?key=XE2W5EIXWN6LA234&field1=%d&field2=%d\r\n",counter1,counter2);
+ sprintf(snd,"GET https://api.thingspeak.com/update?key=XE2W5EIXWN6LA234&field1=%d&field2=%d\r\n",field1,field2);
int i=0;
for(i=0;snd[i]!='\0';i++);
@@ -228,3 +230,4 @@
pc.printf("R\r\n%s",rcv);
}
+