Panel Cookies
IoT Push Notification with E-Mail

Help me by sharing this post


PREVIOUS TUTORIAL       NEXT TUTORIAL

PART 5.1 - The Arduino code

Now go below and download the Arduino code. Extract the zip file and open the folder. This code is for deep sleep of the Arduino and the ESP8266. Later you will have a different code that will send the data each 2 seconds without going to sleep. Open the NOOBIX_V1_ISR.ino file and change the data in the red square as below. Change the wifi name and password with the names you have. Then change the host from electronoobs.com to your own domain without using the "www". Do the same in the ESP8266_CONNECT but this time with the "www". Add the id and password of your noobix. In my case I've made that id 1 and password 12345. Save the file adn upload it to the arduino.





PART 5.2 - Serial software error

If you compile the code at this moment, you will get an error. That’s because the software serial library is not compatible with the sleep library. For that search the software serial library on your computer. Usually is in :\Program Files (x86)\Arduino\hardware\arduino\avr\libraries adn there you find the SoftwareSerial folder. First make a backup of the software serial folder, in case that you mess it up. Open that and open the src folder. Then, open the softerserial.cpp file with administrator rights. Now search and delete the lines below. These vectors are in conflict with the sleep library. Save the file. Compile again and you will see no more errors. So, compile and upload it to the Arduino. Read the Arduino code step by step to understand more. Any way, upload, go to the website, move the magnet from the sensor and see how you will receive the error.


Arduino ESP8266 alarm email sms



PART 5.3 - Second code

Go below and download the second Arduino code. Extract the zip file and open the folder. This code will constantly send the analog value from analog Read A0 of the Arduino each 2 seconds. Upload it and test.





PART 6 - Demo video




PART 7 - Tutorial video






Help me by sharing this post












yt_link
insta_link
fb_link
twitter_link

See video tutorial


Affiliate Disclosure

ADVERTISERS



PCBWAY PCB service





Curso Arduino Online nivel bajo