Skip to content

Commit 60d2609

Browse files
authored
Merge pull request arduino-libraries#17 from FRASTM/wb55_BLE
BLE on the stm32wb55
2 parents 3813996 + 8f0e116 commit 60d2609

28 files changed

+5208
-220
lines changed

examples/Central/LedControl/LedControl.ino

+5
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,11 @@ SPIClass SpiHCI(PC12, PC11, PC10);
2828
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2929
BLELocalDevice BLE(&HCISpiTransport);
3030
const int buttonPin = PC13; // set buttonPin to digital pin PC13
31+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
32+
/* PNUCLEO_WB55RG */
33+
HCISharedMemTransportClass HCISharedMemTransport;
34+
BLELocalDevice BLE(&HCISharedMemTransport);
35+
const int buttonPin = PC4; // set buttonPin to digital pin PC4
3136
#else
3237
/* Shield IDB05A2 with SPI clock on D3 */
3338
SPIClass SpiHCI(D11, D12, D3);

examples/Central/PeripheralExplorer/PeripheralExplorer.ino

+4
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ BLELocalDevice BLE(&HCISpiTransport);
2525
SPIClass SpiHCI(PC12, PC11, PC10);
2626
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2727
BLELocalDevice BLE(&HCISpiTransport);
28+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
29+
/* PNUCLEO_WB55RG */
30+
HCISharedMemTransportClass HCISharedMemTransport;
31+
BLELocalDevice BLE(&HCISharedMemTransport);
2832
#else
2933
/* Shield IDB05A2 with SPI clock on D3 */
3034
SPIClass SpiHCI(D11, D12, D3);

examples/Central/Scan/Scan.ino

+4
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ BLELocalDevice BLE(&HCISpiTransport);
2222
SPIClass SpiHCI(PC12, PC11, PC10);
2323
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2424
BLELocalDevice BLE(&HCISpiTransport);
25+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
26+
/* PNUCLEO_WB55RG */
27+
HCISharedMemTransportClass HCISharedMemTransport;
28+
BLELocalDevice BLE(&HCISharedMemTransport);
2529
#else
2630
/* Shield IDB05A2 with SPI clock on D3 */
2731
SPIClass SpiHCI(D11, D12, D3);

examples/Central/ScanCallback/ScanCallback.ino

+4
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@ BLELocalDevice BLE(&HCISpiTransport);
2424
SPIClass SpiHCI(PC12, PC11, PC10);
2525
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2626
BLELocalDevice BLE(&HCISpiTransport);
27+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
28+
/* PNUCLEO_WB55RG */
29+
HCISharedMemTransportClass HCISharedMemTransport;
30+
BLELocalDevice BLE(&HCISharedMemTransport);
2731
#else
2832
/* Shield IDB05A2 with SPI clock on D3 */
2933
SPIClass SpiHCI(D11, D12, D3);

examples/Central/SensorTagButton/SensorTagButton.ino

+4
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ BLELocalDevice BLE(&HCISpiTransport);
2626
SPIClass SpiHCI(PC12, PC11, PC10);
2727
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2828
BLELocalDevice BLE(&HCISpiTransport);
29+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
30+
/* PNUCLEO_WB55RG */
31+
HCISharedMemTransportClass HCISharedMemTransport;
32+
BLELocalDevice BLE(&HCISharedMemTransport);
2933
#else
3034
/* Shield IDB05A2 with SPI clock on D3 */
3135
SPIClass SpiHCI(D11, D12, D3);

examples/Peripheral/ButtonLED/ButtonLED.ino

+5
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@ SPIClass SpiHCI(PC12, PC11, PC10);
2929
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
3030
BLELocalDevice BLE(&HCISpiTransport);
3131
const int buttonPin = PC13; // set buttonPin to digital pin PC13
32+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
33+
/* PNUCLEO_WB55RG */
34+
HCISharedMemTransportClass HCISharedMemTransport;
35+
BLELocalDevice BLE(&HCISharedMemTransport);
36+
const int buttonPin = PC4; // set buttonPin to digital pin PC4
3237
#else
3338
/* Shield IDB05A2 with SPI clock on D3 */
3439
SPIClass SpiHCI(D11, D12, D3);

examples/Peripheral/CallbackLED/CallbackLED.ino

+4
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ BLELocalDevice BLE(&HCISpiTransport);
2727
SPIClass SpiHCI(PC12, PC11, PC10);
2828
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2929
BLELocalDevice BLE(&HCISpiTransport);
30+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
31+
/* PNUCLEO_WB55RG */
32+
HCISharedMemTransportClass HCISharedMemTransport;
33+
BLELocalDevice BLE(&HCISharedMemTransport);
3034
#else
3135
/* Shield IDB05A2 with SPI clock on D3 */
3236
SPIClass SpiHCI(D11, D12, D3);

examples/Peripheral/LED/LED.ino

+4
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ BLELocalDevice BLE(&HCISpiTransport);
2525
SPIClass SpiHCI(PC12, PC11, PC10);
2626
HCISpiTransportClass HCISpiTransport(SpiHCI, SPBTLE_RF, PD13, PE6, PA8, 8000000, SPI_MODE0);
2727
BLELocalDevice BLE(&HCISpiTransport);
28+
#elif defined(ARDUINO_PNUCLEO_WB55RG)
29+
/* PNUCLEO_WB55RG */
30+
HCISharedMemTransportClass HCISharedMemTransport;
31+
BLELocalDevice BLE(&HCISharedMemTransport);
2832
#else
2933
/* Shield IDB05A2 with SPI clock on D3 */
3034
SPIClass SpiHCI(D11, D12, D3);

src/STM32duinoBLE.h

+4
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@
2424
#include "BLEProperty.h"
2525
#include "BLEStringCharacteristic.h"
2626
#include "BLETypedCharacteristics.h"
27+
28+
#if defined(STM32WBxx)
29+
#include "utility/HCISharedMemTransport.h"
30+
#endif
2731
#include "utility/HCISpiTransport.h"
2832

2933
#endif

0 commit comments

Comments
 (0)