Join the Ben Heck team every week for amazing hacks! Watch them build and mod community-inspired projects using electronics! | Community Feedback | |
Featured Bonus Content | ||
See All Episodes |
Ben, Karen, and Felix are joined by Bob Baddeley, a local electrical engineer, for their IoT on Wheels Design Challenge project. Ben works on the mechanical design in Autodesk Fusion 360, Felix gets started working with the Nucleo Board, and Bob shows them how to connect Bluetooth expansion board to an iOS app. |
Join the IoT on Wheels Design Challenge:
IoT on Wheels Design Challenge
The team is working on a device that fits onto your bicycle and communicates with your smartphone over Bluetooth LE to pass information back and forth. It will be able to send a message to an administrator if you hit a pothole, there will be an alarm built into it, vibration and tilt detection, and more. This project is for the IoT on Wheels Design Challenge on element14. They'll be using the ST microelectronics Nucleo64 along with a Bluetooth expansion module. Felix brought in a bicycle for the team to base their measurements on.
Once they know how much room they have to work with Ben goes to work drafting a design in Autodesk Fusion 360. It won’t be a one size fits all solution, it will work for this Design Challenge as it will be specific to this build. They won’t be printing the tubes they are drafting, but the drawing will give them a good reference for their build. With the Fusion 360 symmetrical extrusion, you specify length from center, not the total length. After he’s done they’ll know where to put the surface of their object and where to put their mounting clamp.
Felix gets started working with the Nucleo Board by going to the ARM mbed OS developer site. Clicking on compiler will take you to the online integrated development environment so you can begin working with your programs. You could install IDE’s and compiler toolchains but the online development saves you from the hassle because online development handles all of this for you. He firsts walks you through selecting the Nucleo-L476RG (Nucleo 64) as your hardware platform and then gets a blinky example going. Coding examples such as the blinky example are common when working when writing programs for your microcontroller. Once the blinky example is compiled he saves it as a .bin file on his local machine. The nucleo that is plugged in shows up as a mass storage device. He grabs the binary file and simply drags and drops it into he nucleo.
Bob Baddeley joins Felix to help him understand how the provided Bluetooth example, a heart rate monitor program, is connecting with the other Bluetooth devices. They modify the existing Bluetooth demo for their purposes because it’s the fastest way to understand how it works. When a Bluetooth LE device starts up it will advertise its presence, the smart phone will get a list of services that are available to connect to, within those services such as heart rate monitor are defined characteristics associated with them. Characteristics have attributes like read or write or notify. Notify will tell you when there is an update to the value. The phone app that they will create needs to send and receive data from Nucleo board, including setting the Real Time Clock. For their example, they are going to write their wown service and within that service they’ll have characteristics like button 1 pressed, button 2 pressed, and shake. They’ll need a characteristic they can write to for the alarm enabling and disabling. They’ll also have to send information to it for configuring the date and time. They’ll need to write a timestamp for every time it connects.
Bob Baddely uses an app on his IOS device called LightBlue from a a company called Punch Through. LightBlue (iOS) acts like a serial terminal for connected Bluetooth devices. He walks Ben and Felix through the Bluetooth services that can be connected to while using the app. This program can also send data to the Bluetooth device. Now that Ben has a basic idea of how the hardware is going to work, he continues working on the mechanical design in Fusion 360.
Top Comments