BLE Support for XIAO MG24 in PlatformIO

Hi,

I’m using the XIAO MG24 Sense and noticed that there are tutorials for using BLE with the SiLabs stack in the Arduino IDE, as well as another one for getting started with PlatformIO. However, I haven’t been able to get BLE working in PlatformIO, and there doesn’t seem to be any clear documentation or examples for this.

Is there any official support or guidance on how to use the SiLabs BLE stack with PlatformIO for the XIAO MG24? Or has anyone successfully set this up?

Any help or pointers would be appreciated.

Cheers,
Matt

PlatformIO doesn’t have first-class support for the Gecko SDK (which includes BLE support).
SiLabs BLE stack is tightly integrated with Simplicity Studio, and its BLE APIs rely on a lot of autogenerated code and project configuration files (.slcp, .hwconf, etc.).
The Arduino core for XIAO MG24 available in PlatformIO is limited and doesn’t include BLE functionality like in Simplicity Studio. If your main goal is BLE, Simplicity Studio is currently the best-supported environment.

1 Like

Hi there,

May I see the Platform .INI you are using?
something like this…?

; PlatformIO Project Configuration File
;
;   Build options: build flags, source filter
;   Upload options: custom upload port, speed and extra flags
;   Library options: dependencies, extra library storages
;   Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:xiaoblesense]
platform = https://github.com/maxgerhardt/platform-nordicnrf52
board = xiaoblesense
framework = arduino
debug_tool = jlink

lib_extra_dirs = ~/Documents/Arduino/libraries
lib_deps = seeed-studio/Seeed Arduino LSM6DS3@^2.0.3
   arduino-libraries/ArduinoBLE@^1.3.2 :point_left: :face_with_hand_over_mouth:
   ;adafruit/Adafruit GFX Library
   adafruit/Adafruit BusIO
   Wire
   olikraus/U8g2@^2.34.4
   ;SPI

HTH
GL :slight_smile: PJ :v: