Skip to main content

Arduino : Configuring HM-10 as iBeacon

I was so excited when found out that this HM-10 Bluetooth can be configured as iBeacon device. Bluetooth Low Energy beacon which the protocol was developed by Apple. But we will call this device or module as beacon.


The beacons will broadcast it's identifier to any nearby electronic devices. With this information, mobile app can perform actions if in the range or close to the device. The proximity to the device grouped by the range or regions which are Far, Near and Immediate. Each region can trigger the app to do call to action presented to the user. This range can be adjusted by configuring the transmitting power of the beacon.

For example we have store and beacons configured for some special products. When customer walk or pass in to the store, the app can present promo, sale or any interesting store information to the customer. When customer pass near to the discounted or sale product user can be presented with the discount information or product details. Then when customer put the device very close to the product, the app can add product to the app cart or do checkout automatically.

That is one of the scenario on the real world implementation. You can find many resources on the internet that explained better about iBeacon and examples of it's implementation. But on this post I'll try to explain how to configure HM-10 as iBeacon device. See screenshot below.



Commands explanation.
  1. AT+RENEW: restore software to factory default
  2. AT+RESET: reboot device
  3. AT: check at command is accepted by device, if its OK you are good to go
  4. AT+MARJ0xAAAA: set major device number in hexadecimal
  5. AT+MINO0xBBBB: set minor device number in hexadecimal
  6. AT+ADVI5: set advertisement interval to 5 second
  7. AT+NAMESMBEACON: set beacon name to SMBEACON
  8. AT+IBEA1: enable beacon mode
  9. AT+PRWM0: enable power on mode, this will save power
  10. AT+RESET: reboot device
So your bluetooth now ready to broadcast it's identifier to nearby supported device. Test using Beacon scanner available on the playstore or appstore. Here I tested the device using Beacon Scanner android app.



We can also modify device UUID by using AT command. On the real world implementation as example above, this UUID can be used for identify the store building then major number used as the store level and the minor number used to identify specific location or product on that store level. Then we can create the app that respond to those beacons. We can put as many beacons on but make sure to change major and minor number. I'll try to create app to demo the beacon usage.

Update September 16, 2016

Here is the video.




Resources and links

  1. How to : http://www.blueluminance.com/HM-10-as-iBeacon.pdf
  2. 10 things about beacon : https://www.youtube.com/watch?v=L44m7otNI7o




Comments

Popular posts from this blog

Arduino : Controlling PL9823-F8 RGB LED

I have great passion about electronics since I was in middle school then high school. With some of my school friend that has same passion in electronics, we built radio transmitter so we can communicate each other at anytime. It was so cool back then. Thats why I took study on electrical Engineering. Instead of working on Electrical engineering field, I end up become web programmer. Something I found interesting when i was in college. That's old story. But lately I get bored and try to get another hobby. I have many hobbies and creating electronics stuff is one of it. So I bought my self Arduino Uno and few electronic components to get started learning Arduino programming. So my first project is controlling RGB Led. Here what you need: Arduino Uno with usb data cable and Arduino IDE Install Adafruit Neopixel library 3 PL9823 RGB led Breadboard Jumper cables (mostly male to male) First you need to install Arduino IDE. You can download it here .  That would depend

Using LCD 2004a I2C on project with Arduino

On previous post measurement sensor results displayed on serial monitor. This is good when we are on development stage. When we want something more independent we need external display. I have purchased a few type of display. For now we will use LCD 2004 for external display.

RDA5807M FM radio module for Arduino

I was surprised with it's ability to receive FM radio broadcast without any problem in such a small module. The size is not bigger than a coin, really small. It may a bit difficult for wiring but it can be done. You can also add small power audio amplifier and use small speaker directly. Here is the module chip, small power amplifier in prototyping pcb.