• Skip to primary navigation
  • Skip to main content
  • Skip to footer

Codemotion Magazine

We code the future. Together

  • Discover
    • Events
    • Community
    • Partners
    • Become a partner
    • Hackathons
  • Magazine
    • Backend
    • Frontend
    • AI/ML
    • DevOps
    • Dev Life
    • Soft Skills
    • Infographics
  • Talent
    • Discover Talent
    • Jobs
    • Manifesto
  • Companies
  • For Business
    • EN
    • IT
    • ES
  • Sign in

CodemotionDecember 14, 2022

Web Progressive Apps: Creating Bluetooth Robots

IoT
web progressive apps, bluetooth, robots
facebooktwitterlinkedinreddit

In this video, Developer Nico Martin shares how, thanks to having some extra time during quarantine, he started experimenting with Browser APIs (Web Progressive Apps) that allowed him to communicate with hardware devices using JavaScript.

He bought a RaspBerry pi 0w. This microcomputer allowed him to run JavaScript and Nodejs files. That’s how he created a small prototype of a toy car as a first experiment, but he decided to experiment further.

Recommended article
IoT app
October 10, 2024

The IoT Journey: From Prototype to App

Matteo Crippa

Matteo Crippa

IoT

Watch the video below to discover more about his amazing journey into the world of robotics.


Loading the player...

What is Bluetooth LE and why is it key in robotics?

WebBluetooth plays a key role when it comes to connecting APIs and hardware. In the video, Nico explains that Bluetooth uses the same frequencies as wireless LAN, but instead Bluetooth was designed to send very short commands over short distances.

Classic Bluetooth was buggy and had many problems, but now, Bluetooth BLE is here to solve all the previous problems.

Bluetooth LE is used in the world of IoT because of the many benefits it brings compared to the initial versions of Bluetooth. These benefits include:

  • Energy efficiency
  • Encryption for data security between clients and servers
  • Increased range and speed
  • Much better compatibility with devices from different brands

The Generic Attribute Profile GATT

In the video, Nico also explains the role of GATT (Generic Attribute Profile). This is what allows the interchange of data, and communication of different statuses (such as battery level, for example). It also enables different operations to perform. The GATT is formed by the following elements:

  • GATT Server
  • GATT Service
  • GATT Characteristic
  • GATT Value

You can find a more complete explanation of this in the materials kindly shared by Nico here.

After the coding is done, Nico shows how, using his browser, he is able to turn a PlayBulb Sphere from blue to red. Of course, that’s just the beginning and the very basics. Everything turns more complex afterward!

SpeedWheels (Bluetooth LE + Arduino) and more inventions

Nico Martin then moved on to a more difficult experiment called “SpeedWheels”. An Arduino Nano RP2040 connected to two motors with wheels (and Lego bricks, of course!) You can check out the whole process in this Twitter thread he shared.

After my beloved #RapberryPi based SpeedWheels left me hanging on stage for the second time now, I had to resort to drastic measures. I will rewrite everything, this time with the #ArduinoNano RP2040 as a basis.

— 🤷 nico.dev (@nic_o_martin) March 30, 2022

Also, you can find more details on his GitHub repository here: https://github.com/nico-martin/speed-wheels-ble-arduino. Remember to thank Nico for his generosity!

Nico knows how to have fun with Bluetooth and “SpeedWheels” wasn’t his last invention. Another project of his is the “BLE Boozer”. This invention of his is able to switch slides of his presentation also using an Arduino microcontroller. He describes it as “An Arduino Sketch that provides a Bluetooth Low Energy Service whose buzzer characteristic exposes a value of “00” or “FF” depending on whether the buzzer is currently pressed or not, it also has an LED that gives feedback about the current status.”

You can check the process on his Twitter below:

Welcome to another episode of “Fun with #bluetooth – presented by Nico Martin”.
Today: the #Arduino based #BLE #Buzzer pic.twitter.com/pL3qpd7ggY

— 🤷 nico.dev (@nic_o_martin) April 22, 2022

Nico also shared the whole code involved in his GitHub repository. Check it out here.

More about the video’s author

Nico Martin is a self-taught web developer and Google Developer Expert in Web Technologies from Switzerland. As the founder of the digital agency “say hello”, he learned early on how to use the web platform to efficiently meet the needs of customers.

He has contributed his know-how as a frontend development freelancer and consultant in various large projects, while constantly experimenting with modern browser technologies and sharing his learnings in workshops, articles, and talks.

Related Posts

This article shares essential IoT security best practices for developers. From encryption to user identity management.

IoT Security Best Practices for Developers

Gilad David Maayan
May 23, 2024
underwater IoT, wsense

Discover How an Italian Company is Breaking Ground in Underwater IoT

Codemotion
December 14, 2023
IoT security, AI Tools and security

This is How Mathematics Keeps Your IoT Device Safe

Norman Di Palo
January 26, 2023
Blazor, IoT solutions for industry

Developing Industrial IoT Applications with Blazor

Paolo Caressa
December 6, 2022
Share on:facebooktwitterlinkedinreddit

Tagged as:Bluetooth Web Developer

Codemotion
Articles wirtten by the Codemotion staff. Tech news, inspiration, latest treends in software development and more.
Green Cloud Computing Strategies and Best Practices
Previous Post
How To Write A Web Developer Resume That Will Leave a Great First Impression
Next Post

Footer

Discover

  • Events
  • Community
  • Partners
  • Become a partner
  • Hackathons

Magazine

  • Tech articles

Talent

  • Discover talent
  • Jobs

Companies

  • Discover companies

For Business

  • Codemotion for companies

About

  • About us
  • Become a contributor
  • Work with us
  • Contact us

Follow Us

© Copyright Codemotion srl Via Marsala, 29/H, 00185 Roma P.IVA 12392791005 | Privacy policy | Terms and conditions