Software apps and online services
In this application, a sense2goL pulse board is used to make a blindspot detector for a bicycle that can be mounted on the back of a bicycle to alert the rider about an approaching vehicle, without having the rider to lose concentration on the road in front of him.1/ Hardware Setup
The pin 4.6 on the XMC board is attached to digital pin 2 of the Arduino and the ground of the XMC to the ground of Arduino MKR Wi-Fi 1010. The circuit is complete. The Arduino is powered with a lithium polymer battery of at least 1024 mAh range, you can also power it by connecting it to the JST PH-2 connection area which is more secure. make sure that the lipo has a JST-PH 2 connector attached to it or if you have a Lipo battery of a similar mAh range you can solder the PH-2 connectors to the terminals and use it to power Arduino. You can find JST connectors in online stores like amazon, Conrad for a cheap price.
You can also connect the piezoelectric sensor to the digital pin 4 and add extra lines of code so that it will buzz to warn you. This can be used as a redundant warning system in case the notification to the cell phone can not detected by you.
tone(buzzer, 1000); // Send 1KHz sound signal...
delay(1000); //...for 1 sec
noTone(buzzer); // Stop sound...
add the above code in line 038 of the IDE code and the buzzer will notify you by buzzing for 1 second, if you want more time, increase the delay from 1000 to 2000 for 2 seconds and 3000 for 3 seconds, and so on.2/ Software Setup
This section describes the software setup for the Arduino IDE and firmware update for Arduino MKR Wi-Fi 1010
2.1/ Arduino IDE
To program the Arduino we need the IDE from Arduino which can be downloaded here https://www.arduino.cc/en/main/software
2.2/ Arduino Packages
2.2.1/ Boards packages
The board package can be downloaded by going into Arduino IDE and tools--> boards--> board manager and install the SAMD board’s package.
Arduino boards require several libraries that enable them to communicate with other devices. Go to -- >tools-->manage libraries
Also install BLE Library, BLYNK, and WIFI NINA
2.2.3/ Update Firmware
- We can install the latest firmware to the Arduino board using the updater sketch.
- After selecting the board -->updater sketch-->upload the sketch-->test connection-->update firmware -- >upload Wi-Fi certificates.
2.3/ Mobile App Configuration
The BLYNK mobile app can be used in this case to communicate with Arduino to retrieve the current state of the sensors. The app can be found on the app stores of android and IOS Here is a link to help you set it up
Select the notification widget from the box and place it on the project, take the project key, and mail it to yourself from the project settings.