Home / Features / Product Reviews / Featured: DFRobot Bluno M3

Featured: DFRobot Bluno M3

Last time I featured DFRobot’s Bluno M0, an arduino compatible board with embedded bluetooth chip. Now, I will write about the Bluno M3, an STM32 powered board which strikingly looks similar to the M0. Is it the same board or does it offer more?

Bluno M3 Overview

To start, here’s the Bluno M3 compared to the Bluno M0 and the Arduino UNO:

Specs

Bluno M3

Bluno M0

Arduino UNO

Microcontroller

STM32F103RET6

ARM Cortex M0 Nuvoton NUC123ZD4AN0

ATMega328P

No. of I/O Pins

50 (11 analog)

31

21 (6 PWM, 6 analog)

I/O Pin Voltage

3.3V

5V

5V

Flash (Program) Memory

512 kB

68 kB

32 kB

PWM Pins

16

6 (2 soft PWM)

6

Clock Speed

72 MHz

72 MHz

16 MHz

Other Features

SPI, I2C, Bluetooth 4.0

SPI, I2C, I2S, dual USB ports, Bluetooth 4.0

SPI, I2C

The program memory of the Bluno M3 have the same memory size of the Arduino Due albeit a slower clock speed. But arguably the most striking feature is the number of I/O pins. You have 39 digital and 11 analog pins! That’s more than twice that of the Arduino UNO at the same board size.

Having a STM32 as a microcontroller means all those I/O pins have 3.3V operating voltage which could be a problem, considering most sensors operate at 5V.

Here’s the board layout:

As mentioned, the Bluno M3 is arduino-compatible so it comes with the same female header arrangement. The extra I/O pins are placed as two-row male headers on the right side. There are other male headers for debugging the Bluetooth CC2540 and the STM32.

Getting Started

To be able to use the Arduino IDE for programming the Bluno M3, we must install the development environment first. Open the IDE and go to File > Preferences. Under the Additional Boards Manager field, paste this:

Click OK to close the dialog box.

Next, go to Tools > Board > Board Manager. On the search field, type Bluno M3. One entry should pop out. Click install:

After that, the Bluno M3 should appear on Tools > Board:

If your PC detected the Bluno M3 when you plugged in the microUSB cable then good for you. If not, download the zip file.

Extract the contents of the zip file in a convenient location on your PC. Then open the drivers folder and locate the file Bluno M3.inf. Right click on this file and choose install. The driver should install and the board should now be detected.

If you are encountering the “The third party INF does not contain digital signature information” error, hold the shift key and click restart. Then on the next screen, select Troubleshoot then Advanced Options then Startup Settings. Click the Restart button. After your computer restarts, select (7) Disable driver signature enforcement. Try to install the Bluno M3.inf file again and choose Install when a pop-up box appears. That’s it!

Bluno M3 Peculiars

Besides support for the same Arduino programming environment, the Bluno M3 has its own commands.

ADC

First is the inclusion of functions adcMode() and adcRead(). The adcMode() function allows you to set the number of bits for the ADC.

This is the same as the analogReadSolution() for the Arduino Due, Zero and MKR boards. Here are the possible modes:

  • ADC_8_BIT
  • ADC_10_BIT
  • ADC_12_BIT

The ulPin is any of the analog pins (A0 to A5).

The adcRead() function is the same as the analogRead() function only that it follows what mode is set through adcMode().

In short, if you used adcMode() besides 10-bit, you must use adcRead().

Here’s an example sketch using both functions:

PWM

The other unique feature of the Bluno M3 is how it implements PWM. It contains two functions, pwmMode() and pwmWrite().

pwmMode() allows you to specify the PWM frequency and resolution:

ulPin can be any pin with the ~ symbol on the board. The range of frequency values is determined by the chosen mode:

  • MODE_8_BIT
  • MODE_12_BIT

In 8-bit mode, the possible frequency range is 4 Hz to 281250 Hz. In 12-bit mode, the frequency range is 1 Hz to 17578 Hz.

The pwmWrite() function outputs a 1kHz PWM signal to any PWM pin assigned to ulPin:

The ulValue is the duty cycle value from 0 to 255. The actual duty cycle is calculated using the formula

Here’s an example sketch that uses both function:

USART

The Bluno M3 boasts of 5 USARTs with the on-board Bluetooth module using one of those USARTs (USART1)

  • Serial1 at pins 0(Rx1) & 1(Tx1)
  • Serial2 at pins 22(Rx2) & 21(Tx2)
  • Serial3 at pins 30(Rx3) & 29(Tx3)
  • Serial4 at pins 8(Rx4) & 9(Tx4)
  • Serial5 at pins 25(Rx5) & 23(Tx5)

Using these terminals is very much like how you would use it with the Arduino UNO.

There are other examples found on Examples >DFRobotBlunoM3 some of which are the same with the default Arduino example while others are a bit complex but useful.

I was expecting they’d have an example that uses the on-board BLE. And by BLE I mean the real features of BLE and not wireless serial port BLE. Anyway, I’ll be looking deeper into this and will make a post about it ASAP.

Leave a Reply

Your email address will not be published. Required fields are marked *