My shopkeeper uncle wanna know how many customers visit his shop in a day. So let's make an IoT-based Customer Counter for him which will notify him of how many customers visit his shop in a day through SMS.
Hardware SetupIn the below image I am specifying the left sensor as sensor 1 and the right sensor as sensor 2.
Step 1: Connect Vcc and GND of sensor 1 to Vcc and GND of sensor 2 respectively.
Step 2: Connect Vcc and GND of sensor 1 to 5v and GND of Arduino respectively.
Step 3: Connect Trig and Echo Pin of sensor 1 to Pin 7 and Pin 8 of the Arduino respectively.
Step 4: Connect Trig and Echo Pin of sensor 2 to Pin 5 and Pin 6 of the Arduino respectively.
Step 5: Connect RX and TX of Bolt Wifi Module to TX and RX of the Arduino respectively.
Step 6: Connect the positive and negative terminal of one LED to Pin 11 and the GND of the Arduino respectively.
Step 7: Connect the positive and negative terminal of the other LED to Pin 9 and Pin 10 of the Arduino respectively.
Note: If operating voltage of your LEDs is less that 5v then it is neccessary to connect resistors accross them. Otherwise your LEDs may get damaged.
Step 8: Connect 5v and GND of the Bolt Wifi Module to Vcc and GND of the sensor 2 respectively.
Step 1: Connect the Bolt device to Bolt Cloud.
Step 2: Create an account in Twilio and log in to your account.
To know how to set up Whatsapp sandbox click on this LINK.
Step 3: Get the Codes.
Download python_code.py and arduino_code.ino. Upload arduino_code.ino code to Arduino.
Step 4: Changes in Code.
In the python_code.py file change SID, AUTH_TOKEN, FROM_NUMBER, TO_NUMBER, API_KEY and DEVICE_ID. Make sure your Computer has Python installed on it and don’t forget to add Bolt Library to it. Use the command “pip install boltiot”.
Step 5: Run the python code.
Now you are all set up and ready to get Whatsapp message.
It makes my uncle's work very easy. He doesn't even need to count the number of customers manually. Everything is automatic. He will get a Whatsapp message regarding the Visitor count in his shop.
This system can also be used in Exam Centres to determine the number of students attended the exam.
Comments