This page shows you how to upgrade RN4020 firmware to the latest version via the Over-The-Air (OTA) process using Microchip's "Bluetooth Smart Data" app running on an iOS device. The following conditions must be met when the RN4020 performs a Device Firmware Update (DFU) through OTA:
- Only a one-to-one connection is allowed between the device whose firmware is to be updated and the device that provides the update image
- Avoid RF interference whenever possible
- The module that is streaming the image to the remote device must have UART hardware flow control enabled
RN4020 Bluetooth Low Energy PICtail™/PICtail Plus
This lab requires the following software tools:
A host is required to enter commands that place the RN4020 into OTA DFU mode with MLDP (Microchip Low-energy Data Profile) enabled and advertising enabled. The following connections are required at a minimum:
Detailed Steps – RN4020 Device Under Test (DUT) – RN-4020-PICTail Card
Ensure that the minimum signal connections as shown in the diagram above are connected. If you are using the RN4020 PICTail, they are already connected.
Connect the RN-4020-PICTail to the PC via supplied USB cable (make sure jumper JP1 is in the OFF position).
Determine which COM port number has been assigned.
Start TeraTerm (115200, 8, n, 1, none)
and enter the following:
+ // echo on
SF,2 // perform complete factory reset
SR,10008000 // support MLDP, enable OTA (peripheral mode is enabled by default)
R,1 // reboot to apply settings
// wait for "CMD"
A // start advertising
Detailed Steps – iOS Device
On your iOS device, go to the App Store, search for "Bluetooth Smart Data" and install it.
Launch the app and enable your Bluetooth interface (if required). The app will then begin scanning for devices. Once finished, select your device from the list shown.
The Module will output "Connected" when a connection is made. Also, the module's PIO1 (CONNECTION) pin will go high (GREEN LED on the PICTail Card).
On the Status activity window, select "DFU-OTA" option at the bottom of the screen.
Select "Download RN4020 DFU File" to pull the image from the Apple iTunes store.
Once the file is downloaded to your device, click the "Browse" button to browse to the DFU file.
On the Status activity window, move the "Module to DFU Mode" Slider Switch to the ON position.
You will see a download status bar displaying status of the download.
Upon successful completion, you will see the following dialog on success. Click OK.
The module will reboot and output CMD
Type V in TeraTerm to verify the new firmware version: