@@ -25,12 +25,68 @@ For more information about ArduinoBLE library please visit the official web page
2525https://www.arduino.cc/en/Reference/ArduinoBLE
2626
2727# Configuration
28+
29+ ### STM32WB
30+
2831STM32Cube_WPAN has several configuration options, which are set in the ` app_conf.h ` .
2932This package has a default configuration named ` app_conf_default.h ` .
3033The user can include the file ` app_conf_custom.h ` to customize the BLE application.
3134Options wrapped in ` #ifndef ` , ` #endif ` in ` app_conf_default.h ` can be overwritten.
3235Additional options can be added.
3336
37+ ### Shield
38+
39+ The user can include the file ` ble_spi_conf.h ` to define which shield and configuration to use from the following list:
40+
41+ * [ X-NUCLEO-IDB05A2] ( https://www.st.com/en/ecosystems/x-nucleo-idb05a2.html )
42+ * ` IDB05A2_SPI_CLOCK_D3 ` : SPI clock on D3
43+ * ` IDB05A2_SPI_CLOCK_D13 ` SPI clock on D13
44+ * [ X-NUCLEO-IDB05A1] ( https://www.st.com/en/ecosystems/x-nucleo-idb05a1.html )
45+ * ` IDB05A1_SPI_CLOCK_D3 ` : SPI clock on D3
46+ * ` IDB05A1_SPI_CLOCK_D13 ` : SPI clock on D13
47+ * [ X-NUCLEO-BNRG2A1] ( https://www.st.com/en/ecosystems/x-nucleo-bnrg2a1.html )
48+ * ` BNRG2A1_CLOCK_D3 ` : SPI clock on D3
49+ * ` BNRG2A1_CLOCK_D13 ` : SPI clock on D13
50+ * ` CUSTOM_BLE_SPI ` : define a custom configuration, it requires below definition:
51+ * ` BLE_SPI_MISO ` : SPI MISO pin
52+ * ` BLE_SPI_MOSI ` : SPI MOSI pin
53+ * ` BLE_SPI_CLK ` : SPI CLocK pin
54+ * ` BLE_SPI_CS ` : SPI Chip Select pin
55+ * ` BLE_SPI_IRQ ` : SPI IRQ pin
56+ * ` BLE_SPI_FREQ ` : SPI bus frequency
57+ * ` BLE_SPI_MODE ` : can be one of the below ` SPIMode ` :
58+ * ` SPI_MODE0 `
59+ * ` SPI_MODE1 `
60+ * ` SPI_MODE2 `
61+ * ` SPI_MODE0 `
62+ * ` BLE_CHIP_TYPE ` : can be one of the below ` BLEChip_t ` :
63+ * ` SPBTLE_RF `
64+ * ` SPBTLE_1S `
65+ * ` BLUENRG_M2SP `
66+ * ` BLUENRG_M0 `
67+ * ` BLUENRG_LP `
68+ * ` BLE_RESET ` : BLE reset pin
69+
70+ #### Examples
71+
72+ To use the [ X-NUCLEO-IDB05A2] ( https://www.st.com/en/ecosystems/x-nucleo-idb05a2.html ) with SPI clock on D3, define in ` ble_spi_conf.h ` :
73+ ``` C
74+ #define IDB05A2_SPI_CLOCK_D3
75+ ```
76+ This is equivalent to the below configuration using the ` CUSTOM_BLE_SPI ` :
77+ ``` C
78+ #define CUSTOM_BLE_SPI
79+ #define BLE_SPI_MISO D12
80+ #define BLE_SPI_MOSI D11
81+ #define BLE_SPI_CLK D3
82+ #define BLE_SPI_CS A1
83+ #define BLE_SPI_IRQ A0
84+ #define BLE_SPI_FREQ 8000000
85+ #define BLE_SPI_MODE SPI_MODE0
86+ #define BLE_CHIP_TYPE BLUENRG_M0
87+ #define BLE_RESET D7
88+ ```
89+
3490## License
3591
3692```
0 commit comments