0
登录后你可以
  • 下载海量资料
  • 学习在线课程
  • 观看技术视频
  • 写文章/发帖/加入社区
会员中心
创作中心
发布
  • 发文章

  • 发资料

  • 发帖

  • 提问

  • 发视频

创作活动
STEVAL-IDB007V1

STEVAL-IDB007V1

  • 厂商:

    STMICROELECTRONICS(意法半导体)

  • 封装:

    -

  • 描述:

    EVAL BOARD FOR BLUENRG-1

  • 数据手册
  • 价格&库存
STEVAL-IDB007V1 数据手册
UM2071 User manual BlueNRG-1, BlueNRG-2 development kits Introduction The BlueNRG-1 and BlueNRG-2 devices are low power Bluetooth Low Energy (BLE) systems-on-chip that are compliant with the Bluetooth® specification and support master, slave and simultaneous master-and-slave roles. BlueNRG-2 also supports the Bluetooth Low Energy data length extension feature. The following BlueNRG-1, BlueNRG-2 kits are available: 1. BlueNRG-1 development platforms (order code: STEVAL-IDB007V1(1), STEVAL-IDB007V2) 2. BlueNRG-2 development platforms (order code: STEVAL-IDB008V1(1), STEVAL-IDB008V2, STEVAL-IDB009V1, STEVALIDB008V1M) 1. This board is no longer available for purchase The development platforms feature hardware resources for a wide range of application scenarios: sensor data (accelerometer, pressure and temperature sensor), remote control interfaces (buttons and LEDs) and debug message management through USB virtual COM. Three power options are available (USB only, battery only and external power supply plus USB) for high application development and testing flexibility. RELATED LINKS The document content is also valid for the BlueNRG-1 STEVAL-IDB007V1M evaluation platform based on the SPBTLE-1S module with 32 MHz HS crystal. UM2071 - Rev 14 - October 2021 For further information contact your local STMicroelectronics sales office. www.st.com UM2071 Development platforms 1 Development platforms Figure 1. STEVAL-IDB007V1 development platform This item is no longer available for sale Figure 2. STEVAL-IDB007V2 development platform based on BlueNRG-1 SoC Figure 3. STEVAL-IDB008V1 development platform based on BlueNRG-2 SoC UM2071 - Rev 14 page 2/92 UM2071 Development platforms Figure 4. STEVAL-IDB008V2 development platform based on BlueNRG-2 SoC Figure 5. STEVAL-IDB009V1 development platform based on BlueNRG-2 SoC in QFN48 package UM2071 - Rev 14 page 3/92 UM2071 Development platforms Figure 6. STEVAL-IDB008V1M development platform based on BlueNRG-M2SA module with embedded BlueNRG-2 SoC UM2071 - Rev 14 page 4/92 UM2071 Getting started 2 Getting started 2.1 Kit contents The STEVAL-IDB007Vx/STEVAL-IDB008Vx kits include respectively: • • • a BlueNRG-132 (QFN32 package)/BlueNRG-232 (QFN32 package) development platform a 2.4 GHz Bluetooth antenna a USB cable The STEVAL-IDB009Vx kit includes: • • • a BlueNRG-248 (QFN48 package) development platform a 2.4 GHz Bluetooth antenna a USB cable The STEVAL-IDB008V1M kit includes: • • 2.2 a BlueNRG-M2SA certified module based on the BlueNRG-2 Bluetooth low energy system-on-chip a USB cable System requirements The BlueNRG-1, BlueNRG-2 Navigator and Radio Init Parameters Wizard PC applications require: • • • • • 2.3 PC with Intel® or AMD® processor running Windows 7/10 At least 128 MB of RAM USB ports At least 40 MB of available hard disk space Adobe Acrobat Reader 6.0 or later BlueNRG-1, BlueNRG-2 development kits setup The following BlueNRG-1, BlueNRG-2 DK software packages are available: BlueNRG-1_2 DK SW package for BlueNRG-1, BlueNRG-2 BLE stack v2.x family (STSW-BLUENRG1-DK). After downloading the selected software package (STSW-BLUENRG1-DK) from www.st.com, extract en.stswbluenrg1-dk.zip contents to a temporary directory, launch BlueNRG-1_2-DK-x.x.x-Setup.exe and follow the onscreen instructions. Note: UM2071 - Rev 14 EWARM Compiler 8.40.1 or later, Keil MDK-ARM v5.27 or later and WiSE-Studio v1.0.0 or later are required for building the related BlueNRG1_2_DK_x.x.x demonstration applications. page 5/92 UM2071 Hardware description 3 Hardware description 3.1 STEVAL-IDB007Vx/STEVAL-IDB008Vx/STEVAL-IDB009Vx board overview The BlueNRG-1/BlueNRG-2 devices in the STEVAL-IDB007Vx/STEVAL-IDB008Vx/STEVAL-IDB009Vx development kits lets you experiment with BlueNRG-1/BlueNRG-2 system on chip functions. They feature: • • • • • • • • • • • • • • • • • • • Bluetooth® Low Energy (BLE) board based on the BlueNRG-1/BlueNRG-2 Bluetooth low energy system on chip Associated development kit SW package including firmware and documentation Up to +8 dBm available output power (at antenna connector) Excellent receiver sensitivity (-88 dBm) Very low power consumption: 7.7 mA RX and 8.3 mA TX at -2 dBm Bluetooth® low energy compliant, supports master, slave and simultaneous master-and-slave roles Integrated balun which integrates a matching network and harmonics filter (only on STEVAL-IDB007Vx/ STEVAL-IDB008Vx) Discrete matching network on STEVAL-IDB009V1 BlueNRG-M2SA certified module based on the BlueNRG-2 Bluetooth LE SoC on STEVAL-IDB008V1M SMA connector for antenna or measuring equipment (not available on STEVAL-IDB007V1M/8V1M) 3 user LEDs 2 user buttons 3D digital accelerometer and 3D digital gyroscope MEMS pressure sensor with embedded temperature sensor Battery holder JTAG debug connector USB to serial bridge for providing I/O channel with the BlueNRG-1/BlueNRG-2 device Jumper for measuring current for BlueNRG-1/BlueNRG-2 only RoHS compliant The following figure and table describe physical sections of the board. Figure 7. STEVAL-IDB007Vx board components UM2071 - Rev 14 page 6/92 UM2071 STEVAL-IDB007Vx/STEVAL-IDB008Vx/STEVAL-IDB009Vx board overview Figure 8. STEVAL-IDB008Vx board components Figure 9. STEVAL-IDB009V1 board components Table 1. STEVAL-IDB007Vx/STEVAL-IDB008Vx/STEVAL-IDB009Vx board component descriptions Region Description BlueNRG-132 SoC on STEVAL-IDB007Vx A(1) BlueNRG-232 SoC on STEVAL-IDB008Vx BlueNRG-248 SoC on STEVAL-IDB009Vx UM2071 - Rev 14 C Micro USB connector for power supply and I/O O JTAG connector M RESET button N Two USER buttons H LPS25HB MEMS pressure sensor with embedded temperature page 7/92 UM2071 BlueNRG-1, BlueNRG-2 SoC connections Region Description I LSM6DS3 3D digital accelerometer and 3D digital gyroscope G PWR LED P Three user LEDs Back of the PCB Battery holder for two AAA batteries J, L Two rows of Arduino-compliant connectors S Integrated balun with matching network and harmonics filter (BALF-NRG-01D3 on STEVAL-IDB007V1/ STEVAL-IDB008V1 and BALF-NRG-02D3 on STEVAL-IDB007V2/STEVAL-IDB008V2). Discrete matching network on STEVAL-IDB009V1. Q STM32L151CBU6 48-pin microcontroller (USB to serial bridge for I/O channel to PC communication) (2) R ST2378E level translator to adapt voltage level between STM32 and BlueNRG-1 16 MHz High Speed Crystal on STEVAL-IDB007Vx T 32 MHz High Speed Crystal on STEVAL-IDB008Vx, STEVAL-IDB009Vx, STEVAL-IDB009Vx, STEVALIDB007V1M/8V1M 1. On STEVAL-IDB008V1M, region A contains the BlueNRG-M2SA module On STEVAL-IDB007V1M, region A contains the SPBTLE-1S module 2. STM32 is not intended to be programmed by users 3.2 BlueNRG-1, BlueNRG-2 SoC connections The BlueNRG-132, BlueNRG-232 very low power Bluetooth low energy (BLE) single-mode system on chip (Figure 7. STEVAL-IDB007Vx board components – region A /Figure 8. STEVAL-IDB008Vx board components region A) have respectively 160 KB, 256 KB of Flash, 24 KB of RAM, a 32-bit core ARM Cortex-M0 processor and several peripherals (ADC, 15 GPIOs, I²C, SPI, Timers, UART, WDG and RTC). The BlueNRG-248 very low power Bluetooth low energy (BLE) single-mode system on chip has 256 KB of Flash, 24 KB of RAM, a 32-bit core ARM cortex-M0 processor and several peripherals (ADC, 26 GPIOs, I²C, SPI, Timers, UART, WDG and RTC). The microcontroller is connected to various components such as buttons, LEDs and sensors. The following table describes the microcontroller pin functions. Table 2. BlueNRG-1, BlueNRG-2 pins description with board functions Pin no. Pin name Board function 3D accelerometer and gyroscope QFN3 2(1) QFN4 8(2) DIO10 1 46 JTMSSWTDI O DIO9 2 47 JTCKSWTCK DIO8 3 4 DIO7 4 5 DL2 DIO6 5 5 DL1 VBAT3 6 40 DIO5 7 9 LEDs Micro Buttons Pressure sensor TXD (PA2) CN1 pin 1 (IO8) CN2 CN3 pin 6 (SCL) pin 7 (IO6) (PUSH2 button) CN4 pin 2 (TX) pin 2 (IO9) SDA UM2071 - Rev 14 JTAG pin 5 (SDA) pin 9 (SDA) page 8/92 UM2071 BlueNRG-1, BlueNRG-2 SoC connections Pin no. Pin name Board function 3D accelerometer and gyroscope QFN3 2(1) QFN4 8(2) DIO4 8 13 DIO3 9 14 SDO/SA0 pin 5 (MISO) pin 6 (IO5) DIO2 10 15 SDA pin 4 (MOSI) pin 5 (IO4) DIO1 11 16 CS JTAGTDO pin 3 (CS) DIO0 12 18 SCL JTAGTDI pin 6 (SCK) DIO14/ ANATES 13 T0 21/23 ANATES 14 T1 24 ADC1 15 25 ADC2 16 26 FXTAL1 17 27 FXTAL0 18 28 VBAT2 19 29 RF1 20 30 RF0 21 31 SXTAL1 22 33 SXTAL0 23 34 VBAT1 24 35 RESET 25 36 SMPSFI LT1 26 37 SMPSFI LT2 27 38 VDD1V2 28 39 DIO13 29 41 DIO12 30 42 FTEST 31 43 DIO11 32 44 DIO15 - 20 DIO16 - 19 DIO17 - 17 UM2071 - Rev 14 LEDs Micro Buttons Pressure sensor JTAG CN1 CN2 CN3 CN4 pin 10 (SCL) SCL pin 4 (IO3) pin 4 (AD3) DL3 RESET RESET RESET pin 3 (NRST) pin 8 (IO7) pin 3 (AD2) PUSH1 pin 1 (AD0) INT1 RXD (PA3) pin 1 (RX) pin 3 (IO2) pin 2 (AD1) page 9/92 UM2071 Power supply Pin no. Pin name Board function QFN3 2(1) QFN4 8(2) DIO18 - 12 DIO19 - 11 DIO20 - 10 DIO21 - 6 DIO22 - 3 DIO23 - 2 DIO24 - 1 VBAT4 - 8/22 DIO25 - 48 LEDs Micro Buttons Pressure sensor 3D accelerometer and gyroscope JTAG CN1 CN2 CN3 CN4 1. QFN32 package on STEVAL-IDB007Vx and STEVAL-IDB008Vx kits. 2. QFN48 package on STEVAL-IDB009Vx kits. The board section labeled respectively BlueNRG-1, BlueNRG-2 (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region B) includes the following main components: • • • • • • 3.3 BlueNRG-1/BlueNRG-2 low power system on chip (in a QFN32 package for STEVAL-IDB007Vx, STEVALIDB008Vx, QFN48 package for STEVAL-IDB009Vx) ) BlueNRG-M2SA certified module based on the BlueNRG-2 Bluetooth LE SoC on STEVAL-IDB008V1M High frequency 16 MHz crystal on STEVAL-IDB007Vx and 32 MHz crystal on STEVAL-IDB008Vx, STEVALIDB009Vx Low frequency 32 kHz crystal for the lowest power consumption Integrated balun which integrates a matching network and harmonics filter SMA connector (not available on STEVAL-IDB007V1M/8V1M) Power supply Green LED DL4 (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region G) signals the board is being powered, either via: • • • micro USB connector CN5 (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region C) two AAA batteries (region F) an external DC power supply plus micro USB connector The following table describes the power supply modes available on the STEVAL-IDB007V1, STEVAL-IDB008V1 boards and corresponding jumper settings. Table 3. STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx kit platform power supply modes Power supply mode UM2071 - Rev 14 JP1 JP2 Comment 1 - USB USB supply through connector CN5 (Figure 7. STEVAL-IDB007Vx Fitted: 1-2 Fitted: 2-3 board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region C) 2 - Battery Fitted: 2-3 Fitted: 1-2 The supply voltage must be provided through battery pins (region F). 3 - Combo Fitted: 1-2 Optional USB supply through connector CN5 for STM32L1; JP2 pin 2 external power for BlueNRG-1, BlueNRG-2 page 10/92 UM2071 Jumpers 3.4 Jumpers The available jumpers are listed in the table below. Table 4. STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx kit platform jumpers Jumper JP1 Description 1-2: to provide power from USB (JP2: 2-3) 2-3: to provide power from battery holder (JP2: 1-2) 1-2: to provide power from battery holder (JP1: 2-3) JP2 2-3: to provide power from USB (JP1: 1-2) JP2 pin 2 to VDD to provide external power supply to BlueNRG-1, BlueNRG-2 (JP1: 1-2) JP3 JP4 JP5 3.5 pin 1 and 2 UART RX and TX of MCU pin 3 GND Fitted: to provide VBLUE to BlueNRG-1, BlueNRG-2. It can be used also for current measurement. Fitted: TEST pin to VBLUE Not fitted: TEST pin to GND Sensors The following sensors are available on the platform: An LPS25HB (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board 1. components, Figure 9. STEVAL-IDB009V1 board components – region H) is a piezoresistive absolute pressure sensor which functions as a digital output barometer. The device comprises a sensing element and an IC interface which communicates through I²C from the sensing element to the application. 2. An LSM6DS3 3D (region I) digital accelerometer and 3D digital gyroscope with embedded temperature sensor which communicates via SPI interface. One line for interrupt is also connected. Note: 3.6 In battery operating mode, if R59, R60 and R62 resistors are mounted, you should remove them to make LSM6DS3 function correctly. Extension connector BlueNRG-1, BlueNRG-2 signal test points are shared on two Arduino-compliant connector rows: CN1, CN3 (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region J) and CN2, CN4 (region L). See Table 2. BlueNRG-1, BlueNRG-2 pins description with board functions. 3.7 Push-buttons The board has one user button to reset the microcontroller (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region M) and two further buttons for application purposes (region N). Note: The PUSH1 button is not connected on the STEVAL-IDB008V1M as DIO13 is not available on the BlueNRGM2SA module (PUSH1 is also not connected on STEVAL-IDB007V1M). 3.8 JTAG connector A JTAG connector (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – region O) allows BlueNRG-1, BlueNRG-2 microcontroller programming and debugging with an in-circuit debugger and programmer such as ST-LINK/V2. Note: UM2071 - Rev 14 Only SWD mode is supported page 11/92 UM2071 LEDs 3.9 LEDs LEDs DL1 (yellow), DL2 (red), DL3 (blue) and DL4 (green, power LED) are available on the board (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – regions G and P). 3.10 STM32L151CBU6 microcontroller The most important feature of the STM32L151CBU6 48-pin microcontroller (Figure 7. STEVAL-IDB007Vx board components, Figure 8. STEVAL-IDB008Vx board components, Figure 9. STEVAL-IDB009V1 board components – regions Q) is the USB to serial bridge providing an I/O channel with the BlueNRG-1, BlueNRG-2 device. The microcontroller is connected to the BlueNRG-1, BlueNRG-2 device through an ST2378E level translator (region R). Note: The STM32L microcontroller on the board is not intended to be programmed by users. ST provides a preprogrammed firmware image for the sole purpose of interfacing BlueNRG-1, BlueNRG-2 to a USB host device (e.g., a PC). 3.11 Integrated balun with matching network and harmonics filter BALF-NRG-01D3 and BALF-NRG-02D3 devices are ultra-miniature baluns which integrate matching network and harmonics filter on STEVAL-IDB007Vx and STEVAL-IDB008Vx. Discrete matching network is available on STEVAL-IDB009V1. 3.12 Current measurements To monitor the power consumption of the BlueNRG-1, BlueNRG-2 only, remove the jumper from JP4 and insert an ammeter between pins 1 and 2 of the connector (when the power is ON, remove the USB connection). Since power consumption of the BlueNRG-1, BlueNRG-2 are usually very low, an accurate instrument in the range of few micro amps is recommended. Note: Extra current consumption might originate from the pull-resistor state of IOs 9-10-11 during the device low power mode. To remove the extra current, all the pull-resistors of IOs 9-10-11 have to be disabled during low power mode. 3.13 Hardware setup 1. 2. 3. 4. UM2071 - Rev 14 Connect an antenna to the SMA connector Configure the board to USB power supply mode as per Table 3. STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx kit platform power supply modes Connect the board to a PC via USB cable (connector CN5) Verify the power indication LED DL4 is on. page 12/92 UM2071 BlueNRG-1, BlueNRG-2 Navigator 4 BlueNRG-1, BlueNRG-2 Navigator BlueNRG-1, BlueNRG-2 Navigator are user friendly GUI which lets you select and run demonstration applications easily, without requiring any extra hardware. With it, you can access the following DK software package components: • • • • • • BlueNRG-1, BlueNRG-2 Bluetooth low energy (BLE) demonstration applications BlueNRG-1, BlueNRG-2 peripheral driver examples BlueNRG-1, BlueNRG-2 2.4 GHz radio proprietary examples BlueNRG-1, BlueNRG-2 development kits release notes license files With BlueNRG-1, BlueNRG-2 DK Navigator, you can directly download and run the selected prebuilt application binary image (BLE examples or peripheral driver example) on the BlueNRG-1, BlueNRG-2 platform without a JTAG interface. The interface gives demo descriptions and access to board configurations and source code if needed. User can run the utility through the BlueNRG-1 and BlueNRG-2 Navigator icon under: Start → ST BlueNRG -1_2 DK X.X.X → BlueNRG-1 Navigator, BlueNRG-2 Navigator. Figure 10. BlueNRG-1 Navigator Note: BlueNRG-1 Navigator and BlueNRG-2 Navigator are two instances of the same application tailored for the specific selected device, in order to select the related available resources. Next sections focus on BlueNRG-1 Navigator, but same concepts are also valid for BlueNRG-2 Navigator. 4.1 BlueNRG-1 Navigator ‘Demonstration Applications’ You can navigate the menus for the reference/demo application you want to launch. For each application, the following information is provided: • • • Application settings (if applicable) Application description Application hardware related information (e.g., LED signals, jumper configurations, etc.) The following functions are also available for each application: • UM2071 - Rev 14 Flash: to automatically download and run the available prebuilt binary file to a BlueNRG-1 platform connected to a PC USB port. page 13/92 UM2071 BlueNRG-1 Navigator ‘Demonstration Applications’ • • Doc: to display application documentation (html format) Project: to open the project folder with application headers, source and project files. The figure below shows you how to run the BLE Beacon demo application; the other demos function similarly. Figure 11. BLE Beacon application When a BlueNRG-1 platform is connected to your PC USB port, you can press the “Flash & Run” tab on the selected application window to download and run the available prebuilt application binary image on the BlueNRG-1 platform. Figure 12. BLE Beacon Flash programming Selecting the “Doc” tab opens the relative html documentation. UM2071 - Rev 14 page 14/92 UM2071 BlueNRG-1 Navigator ‘Demonstration Applications’ Figure 13. BLE Beacon documentation 4.1.1 BlueNRG-1 Navigator ‘Basic examples’ This page lists some basic sample applications for the BlueNRG-1 device to verify that BlueNRG-1 device is alive as well as the device sleep and wakeup modes. Figure 14. Basic examples 4.1.2 BlueNRG-1 Navigator ‘BLE demonstration and test applications’ This page lists all the available Bluetooth low energy (BLE) demonstration applications in the DK software package. These applications provide usage examples of the BLE stack features for the BlueNRG-1 device. UM2071 - Rev 14 page 15/92 UM2071 BlueNRG-1 Navigator ‘Demonstration Applications’ Figure 15. BLE demonstration and test applications 4.1.3 BlueNRG-1 Navigator ‘Peripherals driver examples’ This page lists the available BlueNRG-1 peripherals and corresponding test applications to work with certain features specific to the selected BlueNRG-1 peripheral. Figure 16. Peripherals driver examples 4.1.4 BlueNRG-1 Navigator ‘2.4 GHz radio proprietary examples’ The Radio low level driver provides access to the BlueNRG-1 device radio to send and receive packets without using the Bluetooth link layer. UM2071 - Rev 14 page 16/92 UM2071 BlueNRG-1 Navigator ‘Development Kits’ The 2.4 GHz radio proprietary examples built on top of the Radio low level driver can be used as reference examples for building other applications which use the BlueNRG-1 Radio. Figure 17. 2.4 GHz radio proprietary examples 4.2 BlueNRG-1 Navigator ‘Development Kits’ This window displays the available BlueNRG-1 DK kit platforms and corresponding resources. When you hover the mouse pointer on a specific item, the related component is highlighted on the board. Figure 18. STEVAL-IDB007V2 kit components 4.2.1 BlueNRG-1 Navigator ‘Release Notes’ and ‘License’ As their name suggests, these pages display the DK SW package Release Notes (html format) and the DK software package license file, respectively. UM2071 - Rev 14 page 17/92 UM2071 BlueNRG-X Radio Init Parameters Wizard 5 BlueNRG-X Radio Init Parameters Wizard The BlueNRG-X Radio Parameters Wizard is a PC application which allows to define the proper values required for the correct BlueNRG-1, BlueNRG-2 BLE radio initialization, based on the specific user application scenario. As consequence of the user choices, a configuration header file (*_config.h) is generated: this file must be used on the user demonstration application folder. Note: The BlueNRG-X Radio Init Parameters Wizard is provided only on BlueNRG-1_2 DK SW package (STSWBLUENRG1-DK) supporting BLE stack v2.x family. 5.1 How to run User can run this utility by clicking on the BlueNRG-X Radio Init Parameters Wizard icon under: Start → ST BlueNRG -1_2 DK X.X.X Figure 19. BlueNRG-X Radio Init Parameters Wizard 5.2 Main user interface window In the left section of the BlueNRG-X Radio Init Parameters Wizard Utility, user can select the following topics allowing to define the specific radio initialization parameters based on the specific BLE application requirements: 1. General Configuration 2. Radio Configuration 3. Service Configuration 4. Connection Configuration 5. Security DataBase configuration 6. OTA configuration 7. Stack configuration 8. Overview 9. Output Refer to the BlueNRG-X Radio Init Parameters Wizard documentation available within BlueNRG-1_2 DK SW package for more details about each provided configuration section. UM2071 - Rev 14 page 18/92 UM2071 Programming with BlueNRG-1, BlueNRG-2 system on chip 6 Programming with BlueNRG-1, BlueNRG-2 system on chip The BlueNRG-1, BlueNRG-2 Bluetooth low energy (BLE) stack is provided as a binary library. A set of APIs control BLE functionality. Some callbacks are also provided for user applications to handle BLE stack events. You simply have to link this binary library to your application and use the relevant APIs to access BLE functions, and complete the stack event callbacks to manage responses according to application requirements. A set of software driver APIs is also included for accessing the BlueNRG-1, BlueNRG-2 SoC peripherals and resources (ADC, GPIO, I²C, MFTX, micro, RTC, SPI, SysTick, UART, and WDG). The development kit software includes sample code that demonstrates how to configure BlueNRG-1, BlueNRG-2. It uses the device peripherals, BLE APIs, and event callbacks. The documentation of BLE APIs, callbacks, and peripheral drivers is available separately. 6.1 Software directory structure The BlueNRG-1, BlueNRG-2 DK software packages files are organized in the following main directories: • • • • Application: containing BlueNRG-1, BlueNRG-2 Navigator and Radio Init Parameters Wizard PC applications. Doc: with doxygen BLE APIs and events, BlueNRG-1, BlueNRG-2 peripheral drivers, BLE demo applications, BlueNRG-1, BlueNRG-2 Peripheral examples, BlueNRG-1, BlueNRG-2 SDK and HAL driver documentation, DK release notes and license file. Firmware: with prebuilt binary BLE and peripheral driver sample applications. Library – • Bluetooth LE: Bluetooth low energy stack binary library and all the definitions of stack APIs, stack and events callbacks. BLE stack v2.1x or later configuration header and source files. – cryptolib: AES library. – BLE_Application: BLE application framework files (BLE stack layers define values, OTA FW upgrade, BLE utilities, master library). – BlueNRG1_Periph_Driver: BlueNRG-1, BlueNRG-2 drivers for device peripherals (ADC, clock, DMA, Flash, GPIO, I²C, timers, RTC, SPI, UART and watchdog). – CMSIS: BlueNRG-1, BlueNRG-2 CMSIS files. – SDK_Eval_BlueNRG1: SDK drivers providing an API interface to the BlueNRG-1, BlueNRG-2 platform hardware resources (LEDs, buttons, sensors, I/O channel). – HAL: Hardware abstraction level APIs for abstracting certain BlueNRG-1 hardware features (sleep modes, clock based on SysTick, etc.). – STM32L: BlueNRG-1, BlueNRG-2 network coprocessor framework example for an external microcontroller Project – • BLE_Examples: Bluetooth low energy demonstration application including headers, source files and EWARM, Keil and WiSE-Studio project files. – BlueNRG1_Periph_Examples: with sample applications for the BlueNRG-1, BlueNRG-2 peripherals and hardware resources, including Headers, source files and project files. – STM32L: BlueNRG-1, BlueNRG-2 network coprocessor demonstration application examples for an external microcontroller. Utility: contains some utilities Note: The selection between BlueNRG-1, BlueNRG-2 device is done at compile time using a specific define value BLUENRG2_DEVICE for selecting BlueNRG-2 device. Default configuration (no define value) selects BlueNRG-1 device. Note: BLE_Application folder is available only on BlueNRG-1_2 DK SW package v3.0.0 or later. Note: Starting from BlueNRG-1_2 DK SW package v3.2.2, all SW package folders Library, Project and Utility folders are located under C:\Users\{username}\ST\BlueNRG-1_2 DK x.x.x, in order to be able to directly compile projects even with Windows User Account Control activated. UM2071 - Rev 14 page 19/92 UM2071 BLE beacon demonstration application 7 BLE beacon demonstration application The BLE beacon demo is supported by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It demonstrates how to configure a BlueNRG-1 device to advertise specific manufacturing data and allow another BLE device to determine whether it is in BLE beacon device range. 7.1 BLE Beacon application setup This section describes how to configure a BLE device to act as a beacon device. 7.1.1 Initialization The BLE stack must be correctly initialized thus: aci_gatt_init(); aci_gap_init(GAP_PERIPHERAL_ROLE, 0, 0x08, &service_handle, &dev_name_char_handle, &appearance_char_handle); See the BLE stack documentation for more information on these and following commands. 7.1.2 Define advertising data The BLE Beacon application advertises the following manufacturing data: Table 5. BlueNRG-1 Beacon advertising manufacturing data Data field Description Notes Company identifier code SIG company identifier (1) Default is 0x0030 (STMicroelectronics) ID Beacon ID Fixed value Location UUID Beacons UUID Used to distinguish specific beacons from others Major number Identifier for a group of beacons Used to group a related set of beacons Minor number Identifier for a single beacon Used to identify a single beacon Tx Power 2's complement of the Tx power Used to establish how far you are from device 1. available at: https://www.bluetooth.org/en-us/specification/assigned-numbers/company-identifiers 7.1.3 Entering non-connectable mode The BLE Beacon device uses the GAP API command to enter non-connectable mode thus: aci_gap_set_discoverable(ADV_NONCONN_IND, 160, 160, PUBLIC_ADDR, NO_WHITE_LIST_USE,0, NULL, 0, NULL, 0, 0); To advertise the specific selected manufacturer data, the BLE Beacon application can use the following GAP APIs: /* Remove TX power level field from the advertising data: it is necessary to have enough space for the beacon manufacturing data */ aci_gap_delete_ad_type(AD_TYPE_TX_POWER_LEVEL); /* Define the beacon manufacturing payload */ uint8_t manuf_data[] = {26, AD_TYPE_MANUFACTURER_SPECIFIC_DATA, 0x30, 0x00, //Company identifier code (Default is 0x0030 - STMicroelectronics) 0x02,// ID 0x15,//Length of the remaining payload 0xE2, 0x0A, 0x39, 0xF4, 0x73, 0xF5, 0x4B, 0xC4, //Location UUID 0xA1, 0x2F, 0x17, 0xD1, 0xAD, 0x07, 0xA9, 0x61, 0x00, 0x02, // Major number 0x00, 0x02, // Minor number 0xC8//2's complement of the Tx power (-56dB)}; }; /* Set the beacon manufacturing data on the advertising packet */ aci_gap_update_adv_data(27, manuf_data); UM2071 - Rev 14 page 20/92 UM2071 BLE Beacon FreeRTOS example Note: BLE Beacon with Flash Management demonstration application is also available. It allows to configure a Beacon device as with the original Beacon demo application; it also shows how to properly handle Flash operations (Erase and Write) and preserve the BLE radio activities. This is achieved by synchronizing Flash operations with the scheduled BLE radio activities through the aci_hal_end_of_radio_activity_event() event callback timing information. 7.2 BLE Beacon FreeRTOS example A specific new Beacon project (BLE_Beacon_FreeRTOS) shows how to use FreeRTOS with ST BLE stack v2.x. The example configures a BLE device in advertising mode (non-connectable mode) with specific manufacturing data and the BTLE_StackTick() is called from a FreeRTOS task (BLETask). A task randomly changes the Minor number in the advertising data every 500 ms, sending a message through UART each time. Another task sends other messages through UART every 200 ms and generates a short pulse on LED3 (visible with a logic analyzer or oscilloscope). In this example, low priority has been assigned to the BLETask. Assigning high priority to a BLETask can give better latency; if some tasks require a lot of CPU time, it is recommended to assign them a lower priority than the BLETask to avoid BLE operations slowing down. Only for tasks that perform very short sporadic operations before waiting for an event, it is still reasonable to choose a priority higher than the BLETask. UM2071 - Rev 14 page 21/92 UM2071 BLE serial port demo application 8 BLE serial port demo application The BLE serial port demo (server and client roles) is supported on the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It implements simple twoway communication between two BLE devices, demonstrating point-to-point wireless communication using the BlueNRG-1 product. This demo application exposes a single serial port service with the following (20 byte max.) characteristic values: • • The TX characteristic, with which the client can enable notifications; when the server has data to be sent, it sends notifications with the value of the TX characteristic. The RX characteristic, is a writable characteristic; when the client has data to be sent to the server, it writes a value in this characteristic. There are two device roles which can be selected through the specific project workspace: • • The Server that exposes the serial port service (BLE peripheral device). The Client that uses the serial port service (BLE central device). The application requires two devices to be programmed with respective server and client roles. These must be connected to a PC via USB with an open serial terminal for each device, with the following configurations: Table 6. Serial port configuration Parameter Value Baudrate 115200 bit/s Data bits 8 Parity bits None Stop bits 1 The application listens for keys typed in one device terminal and sends them to the remote device when the return key is pressed; the remote device then outputs the received RF messages to the serial port. Therefore, anything typed in one terminal becomes visible in the other. 8.1 Peripheral and central device setup This section describes how two BLE serial port devices (server-peripheral and client-central) interact with each other to set up a point-to-point wireless serial port. BLE device must first be set up on both devices by sending a series of API commands to the processor. 8.1.1 Initialization The BLE stack must be correctly initialized before establishing a connection with another BLE device. This is done with aci_gatt_init() and aci_gap_init() APIs: aci_gatt_init(); BLE serial port server role: aci_gap_init(GAP_PERIPHERAL_ROLE, 0, 0x08, &service_handle, &dev_name_char_handle, &appearance_char_handle); BLE serial port client role: aci_gap_init(GAP_CENTRAL_ROLE, 0, 0x08, &service_handle, &dev_name_char_handle, &appearance_char_handle); Peripheral and central BLE roles must be specified in the aci_gap_init() command. See the BLE stack API documentation for more information on these and following commands. 8.1.2 Add service and characteristics The serial port service is added to the BLE serial port server device via: aci_gatt_add_service(UUID_TYPE_128, &service_uuid, PRIMARY_SERVICE, 7,&SerialPortServHandle); UM2071 - Rev 14 page 22/92 UM2071 Peripheral and central device setup Where service_uuid is the private service 128-bit UUID allocated for the serial port service (Primary service). The command returns the service handle in SerialPortServHandle. The TX characteristic is added using the following command on the BLE Serial port server device: aci_gatt_add_char(SerialPortServHandle, UUID_TYPE_128, &charUuidTX, 20, CHAR_PROP_NOTIFY, ATTR_PERMISSION_NONE, 0, 16, 1, &TXCharHandle); Where charUuidTX is the private characteristic 128-bit UUID allocated for the TX characteristic (notify property). The characteristic handle is returned on the TXCharHandle variable. The RX characteristic is added using the following command on the BLE Serial port server device: aci_gatt_add_char(SerialPortServHandle, UUID_TYPE_128, &charUuidRX, 20, CHAR_PROP_WRITE| CHAR_PROP_WRITE_WITHOUT_RESP, ATTR_PERMISSION_NONE, GATT_SERVER_ATTR_WRITE,16, 1, &RXCharHandle); Where charUuidRX is the private characteristic 128-bit UUID allocated for the RX characteristic (write property). The characteristic handle is returned on the RXCharHandle variable. See the BLE stack API documentation for more information on these and following commands. 8.1.3 Enter connectable mode The server device uses GAP API commands to enter the general discoverable mode: aci_gap_set_discoverable(ADV_IND, 0, 0, PUBLIC_ADDR, NO_WHITE_LIST_USE,8,local_name, 0, NULL, 0, 0); The local_name parameter contains the name presented in advertising data, as per Bluetooth core specification version 4.2, Vol. 3, Part C, Ch. 11. 8.1.4 Connection with central device Once the server device is discoverable by the BLE serial port client device, the client device uses aci_gap_create_connection()to connect with the BLE serial port server device: aci_gap_create_connection(0x4000, 0x4000, PUBLIC_ADDR, bdaddr, PUBLIC_ADDR, 40, 40, 0, 60, 2000 , 2000); Where bdaddr is the peer address of the client device. Once the two devices are connected, you can set up corresponding serial terminals and type messages in either of them. The typed characters are stored in two respective buffers and when the return key is pressed: • on the BLE serial port server device, the typed characters are sent to the BLE serial port client device by notifying the previously added TX characteristic (after notifications are enabled) with: aci_gatt_update_char_value(SerialPortServHandle,TXCharHandle,0,len, (uint8_t*)cmd+j); • on the BLE serial port client device, the typed characters are sent to the BLE serial port server device by writing the previously added RX characteristic with: aci_gatt_write_without_resp(connection_handle, rx_handle+1, len, (uint8_t *)cmd+j); Where connection_handle is the handle returned upon connection as a parameter of the connection complete event, rx_handle is the RX characteristic handle discovered by the client device. Once these API commands have been sent, the values of the TX and RX characteristics are displayed on the serial terminals. UM2071 - Rev 14 page 23/92 UM2071 Peripheral and central device setup Figure 20. BLE serial port client Figure 21. BLE serial port server UM2071 - Rev 14 page 24/92 UM2071 BLE serial port master and slave demo application 9 BLE serial port master and slave demo application The BLE serial port master and slave demo is supported on the BlueNRG-1, BlueNRG-2development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It demonstrates simple point-to-point wireless communication using a single application which configures the serial port client and server roles at runtime. The new serial port demo application configures a BLE device as central or peripheral using the API: aci_gap_init(GAP_CENTRAL_ROLE|GAP_PERIPHERAL_ROLE, 0, 0x07, &service_handle, &dev_name_char_handle, &appearance_char_handle); It then initiates a discovery procedure for another BLE device configured with the same serial port master and slave application image. If such a device is found within a random interval, it starts a connection procedure and waits until a connection is established. If the discovery procedure time expires without finding another serial port master and slave device, the device enters discovery mode and waits for another serial port master and slave device to discover and connect to it. When connection is established, the client and server roles are defined and the serial port communication channel can be used. This demo application exposes a single serial port service with the following (20 byte max.) characteristic values: • • The TX characteristic, with which the client can enable notifications; when the server has data to be sent, it sends notifications with the value of the TX characteristic. The RX characteristic, is a writable characteristic; when the client has data to be sent to the server, it writes a value in this characteristic. The application requires two devices to be programmed with the same application, with the server and client roles defined at runtime. Connect the two devices to a PC via USB and open a serial terminal on both with the same configuration as Table 6. Serial port configuration. The application listens for keys typed in one device terminal and sends them to the remote device when the return key is pressed; the remote device then outputs the received RF messages to the serial port. Therefore, anything typed in one terminal becomes visible in the other. 9.1 BLE serial port master and slave roles This section describes how two BLE serial port master and slave devices interact with each other in order to set up a point-to-point wireless serial port. The BLE stack must first be set up on both devices by sending a series of API commands to the processor. The serial port master and slave client and server roles are defined at runtime. 9.1.1 Initialization The BLE stack must be correctly initialized before establishing a connection with another BLE device. This is done with two commands: aci_gatt_init(); aci_gap_init(GAP_CENTRAL_ROLE|GAP_PERIPHERAL_ROLE, TRUE,0x07, &service_handle, &dev_name_char_handle, &appearance_char_handle); The BLE peripheral and central roles are specified in the aci_gap_init() command. See the BLE API documentation for more information on these and following commands. 9.1.2 Add service and characteristics Refer to Section 8.1.2 Add service and characteristics. 9.1.3 Start discovery procedure To find another BLE serial port master and slave device in discovery mode, a discovery procedure must be started via: aci_gap_start_general_discovery_proc(0x4000, 0x4000, 0x00, 0x00); UM2071 - Rev 14 page 25/92 UM2071 BLE serial port master and slave roles 9.1.4 Enter connectable mode The following GAP API command is used for entering general discoverable mode: aci_gap_set_discoverable(ADV_IND, 0x90, 0x90, PUBLIC_ADDR, NO_WHITE_LIST_USE, sizeof(local_name), local_name, 0, NULL, 0x6, 0x8); 9.1.5 Connection with serial port master and slave client device In the above mentioned discovery and mode assignment procedures, the two serial port master and slave applications assume respective client and server roles at runtime. During this initial configuration phase, when a serial port master and slave device is placed in discoverable mode and it is found by the other serial port master and slave device performing a discovery procedure, a Bluetooth low energy connection is created and the device roles are defined. The following GAP API command is used for connecting to the discovered device: aci_gap_create_connection(0x4000, 0x4000,device_found_address_type, device_found_address, PUBLIC_ADDR, 40, 40, 0, 60, 2000 , 2000); Where device_found_address_type is the address type of the discovered serial port master and slave and device_found_address is the peer address of the discovered serial port master and slave device. Once the two devices are connected, you can set up corresponding serial terminals and type messages in either of them. The typed characters are stored in two respective buffers and when the return key is pressed: On the BLE serial port master-and-slave server device, the typed characters are sent to the master-and-slave client device by notifying the previously added TX characteristic (after notifications have been enabled). This is done via: aci_gatt_update_char_value(SerialPortServHandle, TXCharHandle, 0, len, (uint8_t *)cmd+j); On the master-and-slave client device, the typed characters are sent to the master-and-slave server device, by writing the previously added RX characteristic. This is done via: aci_gatt_write_without_resp (connection_handle, rx_handle +1, len, (uint8_t *)cmd+j); Where connection_handle is the handle returned upon connection as a parameter of the connection complete event, rx_handle is the RX characteristic handle discovered by the client device. Once these API commands have been sent, the values of the TX and RX characteristics are displayed on the serial terminals. UM2071 - Rev 14 page 26/92 UM2071 BLE remote control demo application 10 BLE remote control demo application The BLE remote control application is supported on the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It demonstrates how to control a remote device (like an actuator) using a BlueNRG-1, BlueNRG-2 device. This application periodically broadcasts temperature values that can be read by any device. The data is encapsulated in a manufacturer-specific AD type and the content (besides the manufacturer ID, i.e., 0x0030 for STMicroelectronics) is as follows: Table 7. BLE remote advertising data Byte 0 Byte 1 App ID (0x05) Byte2 Temperature value (little-endian) The temperature value is given in tenths of degrees Celsius. The device is also connectable and exposes a characteristic used to control LEDs DL1 and DL3 on the BLE kit platform. The value of this characteristic is a bitmap of 1 byte. Each bit controls one of the LEDs: • • bit 0 is the status of LED DL1 bit 2 is the status of LED DL3. A remote device can therefore connect and write this byte to change or read the status of these LEDs (1 for LED ON, 0 for LED OFF). The peripheral disconnects after a timeout (DISCONNECT_TIMEOUT) to prevent a central device remaining connected to the device indefinitely. Security is not enabled by default, but this can be changed with ENABLE_SECURITY (refer to file BLE_RC_main.h). When security is enabled, the central device must be authenticated before reading or writing the device characteristic. To interact with a device configured as a BLE remote control, another BLE device (a BlueNRG-1, BlueNRG-2 or any Bluetooth® Low Energy device) can be used to detect and view broadcast data. To control one of the LEDs, the device has to connect to a BlueNRG-1 BLE remote control device and write in the exposed control point characteristic. The Service UUID is ed0ef62e-9b0d-11e4-89d3-123b93f75cba. The control point characteristic UUID is ed0efb1a-9b0d-11e4-89d3-123b93f75cba. 10.1 BLE remote control application setup This section describes how to configure a BlueNRG-1 device to acting as a remote control device. 10.1.1 Initialization The BLE stack must be correctly initialized before establishing a connection with another Bluetooth LE device. This is done with two commands: aci_gatt_init(); aci_gap_init(GAP_PERIPHERAL_ROLE, 0, 0x07, &service_handle, &dev_name_char_handle, &appearance_char_handle); See BLE stack API documentation for more information on these and following commands. 10.1.2 Define advertising data The BLE remote control application advertises certain manufacturing data as follows: /* Set advertising device name as Node */ const uint8_t scan_resp_data[] = {0x05,AD_TYPE_COMPLETE_LOCAL_NAME,'N','o','d','e'} /* Set scan response data */ hci_le_set_scan_response_data(sizeof(scan_resp_data),scan_resp_data); /* Set Undirected Connectable Mode */ aci_gap_set_discoverable(ADV_IND, (ADV_INTERVAL_MIN_MS*1000)/625, (ADV_INTERVAL_MAX_MS*1000)/625, PUBLIC_ADDR, NO_WHITE_LIST_USE, 0, NULL, 0, NULL, 0, 0); /* Set advertising data */ hci_le_set_advertising_data(sizeof(adv_data),adv_data); UM2071 - Rev 14 page 27/92 UM2071 BLE remote control application setup On the development platform, the temperature sensor value is set in the adv_data variable. 10.1.3 Add service and characteristics The BLE Remote Control service is added via: aci_gatt_add_service(UUID_TYPE_128, &service_uuid, PRIMARY_SERVICE, 7, &RCServHandle); Where service_uuid is the private service 128-bit UUID allocated for the BLE remote service (ed0ef62e-9b0d-11e4-89d3-123b93f75cba). The command returns the service handle in RCServHandle. The BLE remote control characteristic is added using the following command: #if ENABLE_SECURITY aci_gatt_add_char(RCServHandle, UUID_TYPE_128, &controlPointUuid, 1, CHAR_PROP_READ|CHAR_PROP_WRITE|CHAR_PROP_WRITE_WITHOUT_RESP|CH AR_PROP_SIGNED_WRITE, ATTR_PERMISSION_AUTHEN_READ|ATTR_PERMISSION_AUTHEN_WRITE, GATT_NOTIFY_ATTRIBUTE_WRITE,16,1,&controlPointHandle); #else aci_gatt_add_char(RCServHandle, UUID_TYPE_128, &controlPointUuid, 1, CHAR_PROP_READ|CHAR_PROP_WRITE|CHAR_PROP_WRITE_WITHOUT_RESP, ATTR_PERMISSION_NONE, GATT_NOTIFY_ATTRIBUTE_WRITE, 16, 1,&controlPointHandle); #endif Where controlPointUuid is the private characteristic 128-bit UUID allocated for BLE remote control characteristic (ed0efb1a-9b0d-11e4-89d3-123b93f75cba) and controlPointHandle is the BLE remote control characteristic handle. If security is enabled, the characteristic properties must be set accordingly to enable authentication on controlPointUuid characteristic read and write. 10.1.4 Connection with a BLE Central device When connected to a BLE central device (another BlueNRG-1, BlueNRG-2 device or any Bluetooth® Low Energy device), the controlPointUuid characteristic is used to control the BLE remote control platform LED. Each time a write operation is performed on controlPointUuid, the aci_gatt_attribute_modified_event() callback is raised and the selected LEDs are turned on or off. UM2071 - Rev 14 page 28/92 UM2071 BLE sensor profile demo 11 BLE sensor profile demo The BLE sensor profile demo is supported on the BlueNRG-1, BlueNRG-2 development platforms (STEVALIDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It implements a proprietary, Bluetooth low energy (BLE) sensor profile. This example helps to build new profiles and applications that use the BlueNRG-1, BlueNRG-2 SoCs. The GATT profile is not compliant with any existing specification as the purpose of this project is to demonstrate how to implement a given profile. This profile exposes the acceleration and environmental services. The acceleration service free fall characteristic cannot be read or written, but can be signaled. The application sends notification of this characteristic (with a value of 0x01) if a free fall condition is detected by the MEMS sensor (when the acceleration on the three axes is near zero for a certain amount of time). You can enable or disable the notifications by writing the configuration descriptor of the associated client characteristic. The other characteristic exposed by the service gives the current value of the acceleration measured by the accelerometer in six bytes. Each byte pair contains the acceleration on one of the three axes. The values are in mg. This characteristic is readable and can be notified if notifications are enabled. Another service is defined, which contains characteristics that expose data from some environmental sensors: temperature and pressure. Each characteristic data type is described in a format descriptor. All of the characteristics have read-only properties. The figure below shows the whole GATT database, including the GATT (0x1801) and GAP (0x1800) services that are automatically added by the stack. Figure 22. BLE sensor demo GATT database 11.1 BLE sensor profile demo: connection with a central device This section describes how to interact with a central device, while the BLE stack is acting as a peripheral. The central device may be another BlueNRG-1, BlueNRG-2 device acting as a Bluetooth LE master, or any other Bluetooth Low Energy device. UM2071 - Rev 14 page 29/92 UM2071 BLE sensor profile demo: connection with a central device The Sensor device central role demonstration application is able to interact as a Central device with ST Bluetooth LE Sensor Demo. This application searches for ST Bluetooth LE Sensor Demo Peripheral device services and characteristics and gets the related acceleration and temperature sensor values. The BLE stack must first be set up by sending a series of Bluetooth LE API commands to the processor. 11.1.1 Initialization The BLE stack must be correctly initialized before establishing a connection with another Bluetooth LE device. This is done via: aci_gatt_srv_init(); aci_gap_init(GAP_PERIPHERAL_ROLE, 0, 0x07, &service_handle, &dev_name_char_handle, &appearance_char_handle); See BLE stack API documentation for more information on these and following commands. 11.1.2 Add service and characteristics The BlueNRG-1, BlueNRG-2 BLE stack has both server and client capabilities. A characteristic is an element in the server database where data is exposed, while a service contains one or more characteristics. The acceleration service is added with the following command: aci_gatt_add_service(UUID_TYPE_128, &accServHandle); &service_uuid, PRIMARY_SERVICE, 7, The command returns the service handle on variable accServHandle. The free fall and acceleration characteristics must now be added to this service thus: aci_gatt_add_char(accServHandle, UUID_TYPE_128, &char_uuid, 1, CHAR_PROP_NOTIFY, ATTR_PERMISSION_NONE, 16, 0, &freeFallCharHandle); aci_gatt_add_char(accServHandle, UUID_TYPE_128, &char_uuid, 6, CHAR_PROP_NOTIFY| CHAR_PROP_READ, ATTR_PERMISSION_NONE, GATT_NOTIFY_READ_REQ_AND_WAIT_FOR_APPL_RESP, 16, 0, &accCharHandle); The free fall and acceleration characteristics handles are returned on freeFallCharHandle and accCharHandle variables respectively. Similar steps are followed for adding the environmental sensor and relative characteristics. 11.1.3 Enter connectable mode Use GAP API command to enter one of the discoverable and connectable modes: aci_gap_set_discoverable(ADV_IND, (ADV_INTERVAL_MIN_MS*1000)/625, ADV_INTERVAL_MAX_MS*1000)/625, STATIC_RANDOM_ADDR, NO_WHITE_LIST_USE sizeof(local_name), local_name, 0, NULL, 0, 0); Where local_name[] = {AD_TYPE_COMPLETE_LOCAL_NAME,'B','l','u','e','N','R','G'}; The local_name parameter contains the name presented in advertising data, as per Bluetooth core specification version, Vol. 3, Part C, Ch. 11. 11.1.4 Connection with central device Once the BLE stack is placed in discoverable mode, it can be detected by a central device. Any Bluetooth Low Energy device like a smartphone can connect to the BLE sensor profile demo. For example, the LightBlue application in Apple Store® connects iPhone® versions 4S/5 and above can connect to the sensor profile device. When you use the LightBlue application, detected devices appear on the screen with the BlueNRG name. By tapping on the box to connect to the device, a list of all the available services is shown on the screen; tapping a service shows the characteristics for that service. The acceleration characteristic can be notified using the following command: aci_gatt_update_char_value(accServHandle, accCharHandle, 0, 6, buff); Where buff is a variable containing the three axes acceleration values. Once this API command has been sent, the new value of the characteristic is displayed on the phone. UM2071 - Rev 14 page 30/92 UM2071 BLE sensor profile central demo 12 BLE sensor profile central demo The BLE sensor profile central demo is supported on the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It implements a basic version of the BLE sensor profile central role, which interacts as central with ST Bluetooth LE sensor demo devices. This application configures a BlueNRG-1, BlueNRG-2 device as a sensor device with a central role. This device can find, connect, and properly configure the free fall, acceleration, and environment sensors characteristics provided by a BLE development platform configured as a BLE sensor device with a peripheral role (refer to Section 11 BLE sensor profile demo). This application uses a new set of APIs that allows performing the following operations on a BlueNRG-1, BlueNRG-2 master/central device: • • • • • • • functions for master configuration functions for master device discovery functions for master device connection functions for master discovery services and characteristics functions for master data exchange functions for master security functions for master common services These APIs, provided through a binary library, are detailed in the available Doxygen documentation within the DK software package. The Library\BLE_Application\Profile_Central\library folder provides the following master/central binary libraries: libmaster_library_bluenrg1.a for IAR, Keil, and WiSE-Studio toolchains in the STSW-BLUENRG1DK software package. UM2071 - Rev 14 page 31/92 UM2071 BLE HID/HOGP demonstration application 13 BLE HID/HOGP demonstration application The BLE HID/HOGP demonstration applications are supported by the BlueNRG-1, BlueNRG-2development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). It demonstrates a BLE device using the standard HID/HOGP Bluetooth low energy application profile. Keyboard and mouse demo examples are provided. 13.1 BLE HID/HOGP mouse demonstration application The BLE HID mouse application implements a basic HID mouse with two buttons compliant with the standard HID/HOGP BLE application profile. The HID mouse device is named ‘STMouse’ in the central device list. The mouse movements are provided by the 3D accelerometer and 3D gyroscope on the BLE development platform. • • The left button is the ‘PUSH1’ button. The right button is the ‘PUSH2’ button If the HID mouse is not used for two minutes, it closes the connection and enters deep sleep mode. This idle connection timeout can be changed from the application. To exit deep sleep mode, press the left PUSH1 button or reset the platform. 13.2 BLE HID/HOGP keyboard demonstration application The BLE HID keyboard application implements a basic HID keyboard compliant with the standard HID/HOGP BLE application profile. The HID mouse device is named ‘STKeyboard’ in the central device list. To successfully complete the bonding and pairing procedure, insert the PIN: 123456. To use the HID keyboard: • • • • Connect the BLE development platform to a PC USB port Open a HyperTerminal window (115200, 8, N,1) Put the cursor focus on the HyperTerminal window The keys that are sent to the central device using the HID/HOGP BLE application profile are also shown on the HyperTerminal window If the HID keyboard is not used for two minutes, it closes the connection and enters deep sleep mode. This idle connection timeout can be changed from the application. To exit deep sleep mode, press the left PUSH1 button or reset the platform. UM2071 - Rev 14 page 32/92 UM2071 BLE throughput demonstration application 14 BLE throughput demonstration application The BLE throughput demonstration application provides some basic throughput demonstration applications to provide some reference figures regarding the achievable Bluetooth low energy data rate using the BlueNRG-1, BlueNRG-2 device. The throughput application scenarios provided are: 1. Unidirectional scenario: the server device sends characteristic notifications to a client device. 2. Bidirectional scenario: the server device sends characteristic notifications to a client device and client device sends write without response characteristics to the server device. The throughput application exposes one service with two (20 byte max.) characteristic values: • • The TX characteristic, with which the client can enable notifications; when the server has data to be sent, it sends notifications with the value of the TX characteristic. The RX characteristic, is a writable characteristic; when the client has data to be sent to the server, it writes a value in this characteristic. The device roles which can be selected are: 1. Server, which exposes the service with the TX, RX characteristics (BLE peripheral device) 2. Client, which uses the service TX, RX characteristics (BLE central device). Each device role has two instances for each throughput scenario (unidirectional, bidirectional). The BLE throughput demonstration applications are supported by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). 14.1 BLE unidirectional throughput scenario The unidirectional throughput scenario lets you perform a unidirectional throughput test where a server device sends notification to a client device. To run this scenario: • • • • • 14.2 Program the client unidirectional application on one BLE platform and reset it. The platform is seen on the PC as a virtual COM port. Open the port in a serial terminal emulator (the required serial port baudrate is 921600) Program the server unidirectional application on a second BLE platform and reset it. The two platforms try to establish a connection; if successful, the slave continuously sends notifications of TX characteristic (20 bytes) to the client. After every 500 packets, the measured application unidirectional throughput is displayed. BLE bidirectional throughput scenario The bidirectional throughput scenario lets you perform a bidirectional throughput test where the server device sends notifications to a client device and client device sends write without response characteristics to the server device. To run this scenario: • • • • • • Note: UM2071 - Rev 14 Program the client bidirectional application on one BLE platform and reset it. The platform is seen on the PC as a virtual COM port. Open the related port in a serial terminal emulator (the required serial port baudrate is 921600) Program the server bidirectional application on a second BLE platform and reset it. Open the related port in a serial terminal emulator (the required serial port baudrate is 921600) The two platforms try to establish a connection; if successful, the slave device continuously sends notifications of TX characteristic (20 bytes) to the client device and the client device continuously sends write without responses of the RX characteristic (20 bytes) to the server device. After every 500 packets, the measured application bidirectional throughput is displayed. For BlueNRG-2, BLE stack v2.1 or later, a further BLE throughput demonstration application (with data length extension up to 251 bytes) is provided. The application allows displaying the throughput data in a unidirectional flow (the server sends notifications to the client) or a bidirectional flow (the server sends notifications to the client and the client writes without response operations on the server). The server can perform an ATT_MTU exchange operation to increase the ATT_MTU size to 247 bytes. The user can also directly set the actual data length value up to 247 bytes. page 33/92 UM2071 BLE notification consumer demonstration application 15 BLE notification consumer demonstration application The BLE ANCS demonstration application configures a BlueNRG-1, BlueNRG-2 device as a BLE notification consumer, which facilitates Bluetooth accessory access to the many notifications generated on a notification provider. After reset, the demo places the Bluetooth LE device in advertising with device name "ANCSdemo" and sets the device authentication requirements to enable bonding. When the device is connected and bonded with a notification provider, the demo configures the BLE notification consumer device to discover the service and the characteristics of the notification provider. When the setup phase is complete, the Bluetooth LE device is configured as a notification consumer able to receive the notifications sent from the notification provider. The BLE notification consumer demonstration application is supported by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). UM2071 - Rev 14 page 34/92 UM2071 BLE security demonstration applications 16 BLE security demonstration applications The BLE Security demonstration applications are supported by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx). They provide some basic examples about how to configure, respectively, two BLE devices as a Central and Peripheral, and setup a secure connection by performing a BLE pairing procedure. Once paired the two devices are also bonded. The following pairing key generation methods are showed: • • • • PassKey entry with random pin PassKey entry with fixed pin Just works Numeric Comparison (new paring method supported only from BlueNRG-1, BlueNRG-2 BLE stack v2.x) For each pairing key generation method, a specific project security configuration is provided for both Central & Peripheral device as shown in the following Table 8. BLE security demonstration applications security configurations combinations. Each Central and Peripheral device must be loaded, respectively, with the application image targeting the proper security configuration, to correctly demonstrate the associated BLE security pairing functionality. Table 8. BLE security demonstration applications security configurations combinations Pairing key generation method 16.1 Central device security configuration Peripheral device security configuration PassKey entry with random pin Master_PassKey_Random Slave_PassKey_Random PassKey entry with fixed pin Master_PassKey_Fixed Slave_PassKey_Fixed Just works Master_JustWorks Slave_JustWorks Numeric Comparison Master_NumericComp Slave_NumericComp Peripheral device On reset, after initialization, the Peripheral device sets security IO capability and authentication requirements in order to address the selected pairing key generation method in combination with the related security settings of the Central device. After initialization phase, the Peripheral device also defines a custom service with 2 proprietary characteristics (UUID 128 bits): - TX characteristic: notification (CHAR_PROP_NOTIFY), - RX characteristic with properties: read (CHAR_PROP_READ, GATT_NOTIFY_READ_REQ_AND_WAIT_FOR_APPL_RES (application is notified when a read request of any type is received for this attribute). Based on the selected security configuration, the RX characteristic is defined with proper security permission (link must be "encrypted to read" on JustWorks method, link must be "encrypted to read and need authentication to read" on all other methods). The Peripheral device enters Discovery mode with local name SlaveSec_Ax (x= 0,1,2,3 depending on the selected security configuration). Table 9. Peripheral device advertising local name parameter value Peripheral device configuration Advertising local name Pairing method Slave_JustWorks SlaveSec_A0 Just works Slave_PassKey_Fixed SlaveSec_A1 PassKey entry with fixed pin Slave_PassKey_Random SlaveSec_A2 PassKey entry with random pin Slave_NumericComp SlaveSec_A3 Numeric Comparison When a Central device starts the discovery procedure and detects the Peripheral device, the two devices connect. UM2071 - Rev 14 page 35/92 UM2071 Central device After connection, the Peripheral device starts a slave security request to the Central device aci_gap_slave_security_req() and the Central device starts the pairing procedure. Based on the pairing key generation method, the user may be prompted to perform certain actions (i.e., confirm the numeric value if the numeric comparison configuration is selected, add the key, displayed on Peripheral device, on Central hyper terminal, if the passkey entry with random pin configuration is selected). After devices pair and are bonded, the Peripheral device displays the list of its bonded devices and adds the bonded Central device to its white list aci_gap_configure_white_and_resolving_list() API. The Central device starts the service discovery procedure to identify the Peripheral service and characteristics and then enables the TX characteristic notification. The Peripheral device starts TX characteristic notification to the Central device at periodic intervals and it provides the RX characteristic value to the Central device each time it reads it. When connected, if user presses the Bluetooth LE platform button PUSH1, the Peripheral device disconnects and enters undirected connectable mode with advertising filter enabled (WHITE_LIST_FOR_ALL: Process scan and connection requests only from devices in the white list). This implies that the Peripheral device accepts connection requests only from devices on its white list: the Central device is still be able to connect to the Peripheral device; any other device connection requests are not accepted by the Peripheral device. TX and RX characteristics length is 20 bytes and related values are defined as follow: - TX characteristic value: {'S','L','A','V','E','_','S','E','C','U','R','I','T','Y','_','T','X',' ',x1,x2}; where x1, x2 are counter values - RX characteristic value: {'S','L','A','V','E','_','S','E','C','U','R','I','T','Y','_','R','X',' ',x1,x2}; where x1, x2 are counter values 16.2 Central device On reset, after initialization, the Central device uses the Master_SecuritySet() API for setting the security IO capability and authentication requirements to address the specific selected paring method in combination with the related security settings of the Central device. The Central device application uses the Central/Master library APIs and callbacks to perform the Central device Bluetooth LE operations (device discovery, connection, etc.). The Central device starts a device discovery procedure (Master_DeviceDiscovery() API, looking for the associated Peripheral device SlaveSec_Ax (x= 0,1,2,3 : refer to Table 9. Peripheral device advertising local name parameter value). When found, the Central connects to the Peripheral device. In order to start the pairing, the Central device waits for the Peripheral device to send a slave security request. Once the security request is received, the Central device starts the pairing procedure. Based on the pairing key generation method, the user may be asked to perform some actions (i.e. confirm the numeric value if the numeric comparison configuration is selected, add the key displayed on Peripheral device on Central hyper terminal if the passkey entry with random pin configuration is selected). Once the pairing and bonding procedure has completed, the Central device starts the service discovery procedure to determine the Peripheral TX & RX characteristics. After Service Discovery, the Central device enables the TX characteristic notification. Then the Central device receives the TX characteristic notification value periodically from Peripheral device and reads the related RX characteristic value from the Peripheral device. When connected, if the Bluetooth LE platform PUSH1 button is pressed, the Central device disconnects and reconnects with the Peripheral device, which enters undirected connectable mode with advertising filter enabled. Once connected to the Peripheral device, it enters the TX characteristic notification/RX characteristic read cycle again. Note: UM2071 - Rev 14 When using a smart phone Central device that implements a random resolvable address, the Peripheral device is not able to accept connection or scan requests from it during the reconnection phase. This is due to the fact that, when disconnecting, the Peripheral device enters the undirected connectable mode with filtering enabled (ADV_WHITE_LIST_FOR_ALL: process scan and connection requests from the White List devices only). Therefore, it is only able to accept the smart phone scan or connection requests if the Privacy Controller is enabled on the Peripheral device. A possible simple alternative is to replace the WHITE_LIST_FOR_ALL advertising filter policy on the Peripheral device with NO_WHITE_LIST_USE: the Peripheral device does not enable device filtering after reconnection and is able to accept connection or scan requests from a smart phone by using resolvable random addresses. page 36/92 UM2071 BLE power consumption demo application 17 BLE power consumption demo application The BLE power consumption demo application allows putting the selected BLE device in discovery mode: you can choose from a test menu which advertising interval to use (100 ms or 1000 ms). To measure the BlueNRG-1, BlueNRG-2 current consumption, it is necessary to connect a DC power analyzer to the JP4 connector of the STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx kit platforms. Then, you can set a connection up with another device configured as a master and measure the related power consumption. The master role can be covered by another BlueNRG-1, BlueNRG-2 kit platform configured with the DTM FW application (DTM_UART.hex) and running a specific script through the BlueNRG GUI or Script launcher PC applications. In the BLE_Power_Consumption demo application project folder, two scripts are provided to configure the master device and create a connection with the BlueNRG-1, 2 kit platform under test. The two scripts allow establishing a connection with 100 ms and 1000 ms as connection intervals, respectively. The power consumption demo supports some test commands: • • • • Note: UM2071 - Rev 14 f: the device is in discoverable mode with a fast interval of 100 ms s: the device is in discoverable mode with a slow interval of 1000 ms r: to reset the BlueNRG-1 ?: to display the help menu This demo application is available only on BlueNRG-1_2 DK SW package (STSW-BLUENRG1-DK) supporting BLE stack v2.x family. page 37/92 UM2071 BLE master and slave multiple connection demonstration application 18 BLE master and slave multiple connection demonstration application This application provides a basic example of multiple connections scenario: a device configured as master and slave which uses a specific formula to calculate the proper advertising, scanning and connection parameters for handling, at same time, BLE connections with slave and master devices. It is supported by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx,STEVAL-IDB008Vx, STEVAL-IDB009Vx). 18.1 Application roles The demonstration application defines two device roles: 1. Master_Slave device role 2. Master device role The slave devices can be configured through the Slaves_Num_Slaves.py python script, provided in the application src folder, and using the BlueNRG Script Launcher utility available in the STSW-BNRGUI software package. 18.1.1 Master_Slave device role The Master_Slave device role allows testing a multiple connection scenario using the GET_Master_Slave_device_connection_parameters() formula provided in the ble_utils.c file. This role configures the Master_Slave device as Central and Peripheral with one service and one characteristic, and it simultaneously advertises and scans to connect to up to Num_Slaves BLE Peripheral/Slave devices Slave1, Slave2, ... (which have defined the same service and characteristic) and to up to Num_Masters Central/ Master devices, respectively. The Num_Slaves depends on the max. number of supported multiple connections (8) and the Num_Masters [0-2] of the selected Master devices, that is: Num_Slaves = 8 - Num_Masters. The user must define the expected number of slaves and master devices, by setting the pre-processor options: • MASTER_SLAVE_NUM_MASTERS • MASTER_SLAVE_NUM_SLAVES The user can also set the requested minimal scan window and additional sleep time, respectively, through the preprocessor options: Note: • MASTER_SLAVE_SCAN_WINDOW • MASTER_SLAVE_SLEEP_TIME The default configuration is: • Num_Masters = 1 • Num_Slaves = 6 • Slave_Scan_Window_Length = 20 • Slave_Sleep_time = 0 Once slaves and devices are connected, the BLE Master_Slave device receives characteristic notifications from Num_Slaves devices and it also notifies characteristics (as Peripheral) to the Num_Masters BLE Master devices (if any) which display the related received slave index value. Num_Slaves devices notified characteristic value is: , where slave_index is one byte in the range [1 - Num_Slaves] and counter_value is a two-byte counter starting from 0. 18.1.2 Master role The master device role simply configures a BlueNRG-1, BlueNRG-2 device as a Master device looking for the Master_Slave device in advertising with the advertising name of advscan. Once the Master device finds the advscan device, it establishes a connection to it and enables the characteristic notification. Notifications from Num_Slaves devices are notified to the Master device through the Master_Slave device. UM2071 - Rev 14 page 38/92 UM2071 BLE Controller Privacy demonstration application 19 BLE Controller Privacy demonstration application This application provides a basic example of Bluetooth low energy controller privacy feature with BLE master and slave devices. Controller Privacy requires 32 MHz high speed crystal on the selected platforms. It is supported by the BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVALIDB009Vx). 19.1 Application scenario The application scenario is based on two devices, master and slave, configured with aci_gap_init(privacy flag = 0x02), which should perform the following macro steps: 1. 2. 3. 4. 5. Note: UM2071 - Rev 14 Initially, master and slave devices have no info on their security database: the two devices should connect and make a paring and bonding (fixed key: 123456). Once the bonding is completed, the slave calls the aci_gap_configure_white_and_resolving_list() API to add its bonded device address to the controller's white list. The master device enables the slave characteristic notification. After the first connection and the pairing/ bonding phase, devices disconnect. The slave enters undirected connectable mode with white list = 0x03 as advertising filter policy (process scan and connection requests only from devices in the White List). The master device performs a direct connection to the detected slave device, which accepts the connection since the master address is on its white list: the two devices reconnect and the slave starts a notification cycle to the master. When the connection is established, if you press the BLE platform button PUSH1 on one of the two devices, it disconnects and the slave enters the undirected connectable mode with filtering enabled (WHITE_LIST_FOR_ALL). This implies that the slave device accepts connection requests only from devices on its white list: the master device is still able to connect to the slave device; any other device connection request is not accepted from the slave device. page 39/92 UM2071 BLE sync demo application 20 BLE sync demo application The BLE sync demo application targets a clock synchronization scenario between master and slave devices. It is supported by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx,STEVAL-IDB008Vx, STEVAL-IDB009Vx). 20.1 Application scenario This demo uses three steval boards: one master and two slaves. Once connected, peripheral and central devices generates some pulses (the synchronized signal) on DIO2, at almost the same instant, with an accuracy of around 2 microseconds. A software library is used to maintain a virtual common clock between the devices in the network. Upon connection, the master sends the value of the virtual clock to the peripheral. The synchronized signal is used to keep this clock always synchronized. To demonstrate that the virtual clocks are synchronized between devices, a pulse is generated on DIO3 every 125 ms, by polling the value of this clock. UM2071 - Rev 14 page 40/92 UM2071 BlueNRG-1, BlueNRG-2 peripheral driver examples 21 BlueNRG-1, BlueNRG-2 peripheral driver examples The BlueNRG-1, BlueNRG-2 peripheral driver examples applications are supported respectively by the BlueNRG-1, BlueNRG-2 development platforms (STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx). The kit contains a set of examples demonstrating how to use the BlueNRG-1, BlueNRG-2 device peripheral drivers ADC, GPIOs, I²C, RTC, SPI, Timers, UART and WDG. Note: 21.1 On all the following sub-sections, any reference to the BlueNRG-1 device and the related kit platform STEVALIDB007Vx (with x=1, 2) is also valid for the BlueNRG-2 device and the related kit platform STEVAL-IDB008Vx (with x=1, 2) and STEVAL-IDB009Vx (x =1). ADC examples ADC polling: conversion is managed through the polling of the status register. The systick timer is used to have a delay of 100 ms between two samples. Each sample from ADC is printed through UART (USB-to-SERIAL must be connected to the PC). The default input is the differential ADC1-ADC2. ADC DMA: conversion is managed through the ADC DMA channel. The systick timer is used to have a delay of 100 ms between two samples. Each sample from ADC is printed through UART (USB-to-SERIAL must be connected to the PC). ADC PDM: this example shows a PDM stream processor from a MEMS microphone (MP34DT01-M) to UART. The application also supports the MP34DT01-M MEMS microphone available on the X-NUCLEO-CCA02M1 evaluation board (refer to the related BlueNRG-1 DK software package ADC PDM doxygen documentation for hardware connection setup). You are requested to connect the BLE platform to a PC USB port and open PuTTY serial terminal [512000, 8-N-1-N], which has to be configured to store the captured data in a log file. After the data have been captured, the PC Audacity tool can be opened to import the streamed data, following these steps: • • • File/Import/Raw Data. Open the log data. Configure as follows: – – – – • Encoding: Signed 16-bit PCM. Byte order: Little-endian. Channels: 1 Channel (Mono). Sample rate: 8000 (default, 16 kbps is supported by changing the firmware symbol FS in ADC_PDM_main.c) – Press the button Import. Play the audio. Note: As the output data format is two-bytes (B1B2), the serial terminal might get, as first byte, half data (B2). Therefore, this first byte must be removed from the log file. 21.2 Flash example Data storage: demonstrates basic flash operations as erase, write and verification. 21.3 GPIO examples Input interrupt: demonstrates the use of GPIO input interrupts. • • The PUSH1 button (IO13) is configured to generate the interrupt event on both edges of the input signal. LED DL1 is toggled ON if the level is high and OFF if low. The PUSH2 button (IO5) is configured to generate the interrupt event on the rising edge of the input signal. LED DL2 is toggled ON/OFF at each rising edge event. IO toggle: demonstrates GPIO state changes by toggling LEDs DL1 and DL2 every 500 ms. IO wakeup: demonstrates device wakeup from standby mode using the GPIO interrupt. • UM2071 - Rev 14 The PUSH1 button (IO13) is configured to generate the interrupt event on both edges of the input signal. LED DL2 is toggled, the system becomes active and LED DL1 is toggled by the systick interrupt service routine every 500 ms. page 41/92 UM2071 I²C examples Once the device is in standby, you cannot open a connection with the debug tool or download new code as the clocks are down and the system voltages are at their minimum values. Therefore, it is necessary to wake the system up via the IO9 (SDW clock signal) wake-up event. In this case, any connection attempt from the debugger wakes the system up. 21.4 I²C examples In all the following examples, I²C is configured in master mode and its clock frequency is set to 10 kHz. Master polling: I²C communication is controlled by polling the I²C status register content. This example involves a master board with Master_Polling firmware code and a slave board with Slave_Polling firmware. The Master board has a small command line interface through UART (USB-to-SERIAL must be connected to the PC), which you can use to read and change the LED status of the slave board. I²C is used to transfer information and change the status of the LEDs on the slave board. Slave polling: I²C communication is controlled by polling the I²C status register content. This also involves a master and a slave board with respective Master_Polling and Slave_Polling firmware. The slave board receives read and change requests for the LEDs via I²C. Master sensor: I²C communication is controlled by polling of I²C status register content, interrupts or DMA (three different configurations). In this example, the LPS25HB environmental sensor is configured to provide output data at 1 Hz. The BlueNRG-1 polls the sensor status register and prints available pressure and temperature data via UART (USB-to-SERIAL must be connected to the PC). 21.5 Micro examples Hello world: example for the basic ‘BlueNRG-1 Hello World’ application. Connect the BlueNRG-1 platform to a PC USB port and open a specific PC tool/program (like Tera Term): the "Hello World: BlueNRG-1 is here!" message is displayed. Sleep test: this test provides an example for the following BlueNRG-1 sleep modes: • • SLEEPMODE_WAKETIMER places the BlueNRG-1 in deep sleep with the timer clock sources running. The wakeup sources type any character on the keyboard, the PUSH1 button or the sleep timer are configured with a timeout of 5 s. SLEEPMODE_NOTIMER places the BlueNRG-1 in deep sleep with the sleep timer clock sources turned off. Only the wakeup sources and the PUSH1 button type any character on the keyboard. The demo supports some user commands: • • • • • • • 21.6 s: SLEEPMODE_NOTIMER - wakes UART/PUSH1 on t: SLEEPMODE_WAKETIMER - wakes UART/timeout 5 s/PUSH1 on l: toggles LED DL1 p: prints the ‘Hello World’ message r: resets the BlueNRG-1 device ?: displays the help menu PUSH1: toggles LED DL1 Public Key Accelerator (PKA) demonstration application The BlueNRG-1 PKA demonstration application is supported by the BlueNRG-1, BlueNRG-2 development platforms. It provides a basic example on how to use the available PKA driver APIs to perform a basic PKA processing and check the results. The Public Key Accelerator (PKA) is a dedicated hardware block used for computation of cryptographic public key primitives related to ECC (Elliptic curve cryptography). Note: UM2071 - Rev 14 This peripheral is used by the BlueNRG-1, BlueNRG-2 Bluetooth low energy stack during the security pairing procedures, so the user application must not use it in the meantime. The PKA demonstration application performs the following steps: 1. Starting from the PKA known point on the ellipse PKS_SetData() with PKA_DATA_PCX, PKA_DATA_PCY and from a random generated keyA, it performs a PKA process which generates a new point A on the ellipse. 2. The same process is repeated from a new generated random keyB, leading to a new point B on the ellipse. 3. A new PKA process starts using the keyA with the point B coordinates. This generates a new point C which is still on the same ellipse. page 42/92 UM2071 2.4 GHz radio proprietary examples 21.7 2.4 GHz radio proprietary examples The radio low level driver provides access to the BlueNRG-1, 2 device 2.4 GHz radio to send and receive packets without using the Bluetooth link layer. The available 2.4 GHz radio proprietary examples are: • • • • • • • • • • • • • • 21.8 AutomaticChMgm, a TX only example where the ActionTag INC_CHAN is used to automatically change the channel. Beep, a TX only example where the device continuously sends a packet in three different channels. BeepMultiState, a TX only example with multi state functionality. Serial port, point-to-point over the air communication. SerialPort encryption, as the previous example, but with the encryption enabled. RemoteControl, a basic remote control scenario; by pressing the PUSH1 button on the device makes toggle the LED1 on the receiver device. Sleep, demonstrates point-to-point communication with sleep management. Sniffer, a sniffer application in a selected channel and a defined NetworkID. SnifferMultiState, a sniffer application with multi state functionality. StarNetwork, a star network example where a Master asks for packets to the slaves of the network. TxRx, point-to-point communication with computation of packet error rate (PER). TxRxDoublePacket, point-to-point communication where a payload greater than 32 bytes is exchanged. Throughput TX, RX, throughput test example (unidirectional with one TX and one RX device, and bidirectional with two TX devices and one RX device) OTA Client, Server, 2.4 GHz proprietary radio demonstration application showing the 2.4 GHz proprietary radio Over-the-Air FW upgrade support functionality (Client and Server configurations) RNG examples Terminal: shows how to use the RNG. It gets the RNG values and prints them on the terminal. 21.9 RTC examples Clock watch: implements both RTC timer and RTC clockwatch. The RTC timer generates the 500 ms interrupt interval. The LED DL1 state is toggled in the RTC interrupt handler to signal proper RTC timer operation. The RTC clockwatch is also enabled with the system time and date set to December 1st 2014, 23 h 59 m 31 s. The RTC clockwatch match registers are then set to December 2nd 2014, 0 h 0 m 1 s. As soon as the RTC clockwatch data register and match registers coincide (30 s after device power up), the RTC clockwatch match interrupt is generated and LED DL2 is toggled to signal the event. Time base: the RTC is configured in the periodic timer mode, the load register (RTC_TLR1) value is set and the RTC is enabled. Whenever the RTC timer reaches the value 0x00, it generates an interrupt event and the timer value is automatically reloaded from the RTC_TLR1 register, which is set to generate the interrupt every 1 s. The LED DL1 is toggled at each interrupt event. Time base pattern: periodic mode is used with a pattern configuration. The RTC is configured in the periodic timer mode and register RTC_TLR1 is set to generate a 1 s interval, while RTC_TLR2 is set to generate a 100 ms interval. The RTC is then enabled and, whenever the RTC timer reaches the value 0x00, it generates an interrupt and the timer value is automatically reloaded from register RTC_TLR1 or RTC_TLR2 register depending on the pattern register setting. The pattern is set to 0b11110010 and its size to 8 bits, so the RTC generates four intervals with the RTC_TLR1 value followed by two RTC_TLR2 value intervals. The pattern repeats itself and the RTC interrupt routine toggles LED DL1 (IO6). RTC virtual timer: it shows how to emulate an RTC using the virtual timer (working on sleeping mode). The virtual timer is used to wait for 30 seconds, then LED2 turns on and the application stops. Sleep mode is used. A wakeup handled by the BLE stack is generated every 10.24 seconds. 21.10 SPI examples The following SPI application examples are available: UM2071 - Rev 14 page 43/92 UM2071 SysTick examples Master polling: involves a master board with the Master_Polling firmware code and a slave board with the Slave_Polling firmware. The Master board has a small command line interface through UART (USB-to-SERIAL must be connected to the PC), which you can use to read and change the LED status of the slave board via SPI. The SPI is configured in master mode and the SPI clock set to 100 kHz. The data is transferred in the Motorola format with an 8-bit data frame, with clock low when inactive (CPOL=0) and data valid on clock trailing edge (CPHA = 1). Slave polling: SPI communication is controlled by polling the SPI status register content. This also involves a master and a slave board with respective Master_Polling and Slave_Polling firmware. The slave board receives read and change requests for the LEDs via SPI. The SPI is configured in slave mode and the SPI clock set to 100 kHz. The data is transferred in the Motorola format with an 8-bit data frame, with clock low when inactive (CPOL=0) and data valid on clock trailing edge (CPHA = 1). Master sensor: SPI communication is controlled by polling of the SPI status register content, interrupts or DMA (3 different configurations). SPI is used to communicate with the LSM6DS3 inertial sensor SPI interface. Whenever the sensor generates an IRQ, the accelerometer and gyroscope output data are read and printed through UART (USB-to-SERIAL must be connected to the PC). The SPI is configured in master mode and the SPI clock set to 100 kHz. The data is transferred in the Motorola format with an 8-bit data frame, with clock low when inactive (CPOL=0) and data valid on clock trailing edge (CPHA = 1). Master DMA: SPI communication is controlled by DMA of the SPI status register content. It involves a master board with the Master_Dma firmware code and a slave board with the Slave_Dma firmware. The Master board has a small command line interface through UART (USB-to-SERIAL must be connected to the PC), which you can use to read and change the LED status of the slave board via SPI. The SPI is configured in master mode and the SPI clock set to 100 kHz. The data is transferred in the Motorola format with an 8-bit data frame, with clock low when inactive (CPOL=0) and data valid on clock trailing edge (CPHA = 1). Slave DMA: SPI communication is controlled by DMA of the SPI status register content. It involves a master board with the Master_Dma firmware code and a slave board with the Slave_Dma firmware. The slave board receives read and change requests for the LEDs via SPI. The SPI is configured in slave mode and the SPI clock set to 100 kHz. The data is transferred in the Motorola format with an 8-bit data frame, with clock low when inactive (CPOL=0) and data valid on clock trailing edge (CPHA = 1). SPI 3 wires: demonstrates the SPI 3 wires communication for reading humidity and temperature data from the HTS221 humidity sensor. In this example, the evaluation board for HTS221, STEVAL-MKI141V2, is used. The SPI clock frequency is set to 100 kHz. The data is transferred in the Microwire format and the data frame size is 8 bits. 21.11 SysTick examples Time base: the interrupt service routine toggles the user LEDs at approximately 0.5 s intervals. 21.12 Timers examples Mode 1: Timer/Counter 1 (TnCNT1) functions as the time base for the PWM timer and counts down at the clock rate selected by the Timer/Counter 1 clock selector. When an underflow occurs, the timer register is reloaded alternately from the TnCRA (first reload) and TnCRB registers and count down begins from the loaded value. Timer/Counter 2 can be used as a simple system timer, an external-event counter, or a pulse-accumulate counter. Counter TnCNT2 counts down with the clock selected by the Timer/Counter 2 clock selector, and can be configured to generate an interrupt upon underflow. MFTX1 and MFTX2 use prescaled clock as Timer/Counter 1. The IO2 pin is configured as output, generating a signal with 250 ms positive level and 500 ms negative level via MFTX1. The IO3 pin is configured as output, generating a signal with 50 ms positive level and 100 ms negative level via MFTX2. Timer/Counter 1 interrupts upon reload are enabled for MFTX1 and MFTX2; interrupt routines toggle LED DL1 for MFTX1 and LED DL2 for MFTX2. Mode 1a (pulse-train mode): the Timer/Counter 1 functions as PWM timer and Timer/Counter 2 is used as a pulse counter that defines the number of pulses to be generated. In this example, MFTX2 is configured to generate 30 pulses with positive level of 500 ms and negative level of 250 ms. MFTX2 uses prescaled clock as Timer/Counter 1. The IO3 pin is configured as output generating the number of pulses configured. Interrupts TnA and TnB are enabled and toggle GPIO 8 and 10, while Interrupt TnD is enabled and sets GPIO 7. UM2071 - Rev 14 page 44/92 UM2071 UART examples A software start trigger or external rising or falling edge start trigger can be selected. This example uses a software trigger which is generated after system configuration. Timer/Counter 1 interrupts on reload are enabled for MFTX1. Interrupt routines toggle LED DL1 for MFTX2. Mode 2 (dual-input capture mode): Timer/Counter 1 counts down with the selected clock and TnA and TnB pins function as capture inputs. Transitions received on the TnA and TnB pins trigger a transfer of timer content to the TnCRA and TnCRB registers, respectively. Timer/Counter 2 counts down with selected clock and can generate an interrupt on underflow. In this example, MFTX1 is used. The CPU clock is selected as the clock signal for Timer/Counter 1 and a Prescaled clock is used as the clock source for Timer/Counter 2. Sensitivity to falling edge is selected for TnA and TnB inputs; counter preset to 0xFFFF is disabled for both inputs. The IO2 pin is internally connected to TnA input (MFTX1) and the IO3 pin is internally connected to TnB input (MFTX1). Interrupts TnA and TnB are enabled and triggered by transitions on pins TnA and TnB, respectively. The interrupt routine records the value of TnCRA or TnCRB and calculates the period of the input signal every second interrupt. Interrupt TnC is enabled and is triggered on each underflow of Timer/Counter1; it increments the underflow counter variables used to calculate the input signal period. LED DL1 is toggled ON if a frequency of about 1 kHz is detected on IO2, and LED DL2 is toggled ON if a frequency of about 10 kHz is detected on IO3. Mode 3 (dual independent timer/counter): the timer/counter is configured to operate as a dual independent system timer or dual external-event counter. Timer/Counter 1 can also generate a 50% duty cycle PWM signal on the TnA pin, while the TnB pin can be used as an external-event input or pulse-accumulate input, and serve as the clock source to either Timer/Counter 1 or Timer/Counter 2. Both counters can also be operated from the prescaled system clock. In this example MFTX1 is used. The CPU clock is selected as the clock signal for Timer/Counter 1, while Timer/ Counter 2 uses an external clock on TnB pin. Sensitivity to rising edge is selected for TnB input. Timer/Counter 1 is preset and reloaded to 5000, so the frequency of the output signal is 1 kHz. Timer/Counter 2 is preset and reloaded to 5. The IO3 pin is internally connected to TnA input (MFTX1), while the IO2 pin is configured as output and configured as the PWM output from Timer/Counter 1. The LED DL1 is toggled in the main program according to a variable which is changed in TnD interrupt routine. Interrupt TnA and TnD are enabled and are triggered on the underflow of Timer/Counter1 and Timer/Counter2 respectively. Mode 4 (input-capture plus timer): is a combination of mode 3 and mode 2, and makes it possible to operate Timer/Counter 2 as a single input-capture timer, while Timer/Counter 1 can be used as a system timer as described above. In this example, MFTX1 is used. The CPU clock is selected as the input clock for Timer/Counter 1 and Timer/ Counter 2. Automatic preset is enabled for Timer/Counter 2. The IO2 pin is internally connected to the TnB input (MFTX1), while the IO3 pin is configured as the output and configured as the PWM output from Timer/Counter 1. Interrupt TnA is enabled and triggered on the underflow of Timer/Counter1; it sets a new value in the TnCRA register. Interrupt TnB in enabled and triggered when a transition on TnB input (input capture) is detected; it saves the TnCRB value. Interrupt TnD in enabled and it triggered on the underflow of Timer/Counter2. MFT timers: this example shows how configure peripherals MFT1, MFT2 and SysTick to generate three timer interrupts at different rate: MFT1 at 500 ms, MFT2 at 250 ms and SysTick at 1 second. Software PWM signals: this example shows how three independent PWM signals can be generated driving GPIO pins inside MFT interrupt handlers. 21.13 UART examples DMA: IO8 and IO11 are configured as UART pins and DMA receive and transmit requests are enabled. Each byte received from UART is sent back through UART in an echo application (USB-to-SERIAL must be connected to the PC). Interrupt: IO8 and IO11 are configured as UART pins and receive and transmit interrupts are enabled. Each byte received from UART is sent back through UART in an echo application (USB-to-SERIAL must be connected to the PC). Polling: IO8 and IO11 are configured as UART pins. Each byte received from UART is sent back through UART in an echo application (USB-to-SERIAL must be connected to the PC). UM2071 - Rev 14 page 45/92 UM2071 WDG examples RXTimeout: it demonstrates the UART RX FIFO level and RX timeout functionality. The demo prints the data received if the RX timeout expires or if the data received are ≥ the RX FIFO threshold. 21.14 WDG examples Reset: demonstrates the watchdog functionality and using it to reboot the system when the watchdog interrupt is not serviced during the watchdog period (interrupt status flag is not cleared). The watchdog is configured to generate the interrupt with a 15 s interval, then it is enabled and monitors the state of the PUSH1 button (IO13 pin). Any change on this pin triggers the watchdog counter to reload and restart the 15 s interval measurement. If the IO13 pin state does not change during this interval, the watchdog generates an interrupt that is intentionally not cleared and therefore remains pending; the watchdog interrupt service routine is therefore called continuously and the system is stuck in the watchdog interrupt handler. The chip is reset as it can no longer execute user code. The second watchdog timeout triggers system reboot as a new watchdog interrupt is generated while the previous interrupt is still pending. The application then starts measuring the 15 s interval again. The three user LEDs are toggled at increasing frequencies until the board is reset or PUSH1 button is pressed, which restores the LEDs toggling frequency with the 15 s watchdog timer. Wakeup: The watchdog timer is a 32-bit down counter that divides the clock input (32.768 kHz) and produces an interrupt whenever the counter reaches zero. The counter is then reloaded with the content of the WDT_LR register. If the interrupt status flag is not cleared and a new interrupt is generated, then the watchdog may generate a system reset. This example demonstrates the use of the watchdog to periodically wake the system from standby mode using the watchdog interrupt. The watchdog is configured to generate the interrupt at 1 s intervals. The watchdog is then enabled and the system is switched to the standby mode. As soon as the watchdog interrupt is generated, the system wakes up, LED1 (IO6 pin) is toggled and the device returns to standby mode. The IO6 pin is therefore toggled every 1 s. UM2071 - Rev 14 page 46/92 Schematic diagrams UM2071 - Rev 14 22 UM2071 Schematic diagrams page 47/92 UM2071 - Rev 14 22.1 STEVAL-IDB007V1 schematic digrams Figure 23. STEVAL-IDB007V1 Arduino connectors R1 DIO4 DIO5 0_0402 VBLUE CN2 1 2 3 4 5 6 7 8 DIO0 R4 DIO3 0_0402 R5 0_0402 RESETN R9 DIO7 R10 DIO8 0_0402 NC CN4 1 2 3 0_0402 4 5 R21 6 0_0402 R19 DIO13 R17 DIO14 0_0402 0_0402 R25 R16 DIO12 TEST1 0_0402 R23 ADC1 ADC2 0_0402 R2 R3 VBLUE 0_0402 DIO2 R7 DIO1 0_0402 R8 R6 R11 0_0402 R12 RESETN DIO6 0_0402 0_0402 DIO0 R18 DIO11 R20 CN1 0_0402 R15 DIO3 R13 DIO2 0_0402 R14 0_0402 DIO8 R22 DIO11 R24 10 9 0_0402 8 7 6 5 0_0402 4 3 0_0402 2 1 NC CN3 8 7 0_04026 5 0_04024 3 0_04022 1 0_0402 NC NC UM2071 STEVAL-IDB007V1 schematic digrams page 48/92 UM2071 - Rev 14 Figure 24. STEVAL-IDB007V1 JTAG VBLUE JTAG Male Connector 2x10 HDR straight CN7 DIO0 JTMS-SWTDIO JTCK-SWTCK DIO1 RESETN 2 4 6 8 10 12 14 16 18 20 1 3 5 7 9 11 13 15 17 19 SWD RS 473-8282 ST Link: 3.0-3.6V, 5V tolerant IAR J-Link: 1.2-3.6V, 5V tolerant GND UM2071 STEVAL-IDB007V1 schematic digrams page 49/92 UM2071 - Rev 14 Figure 25. STEVAL-IDB007V1 BlueNRG-1 C1 C2 Solder a 10u_0805 between 2 1or a 0R0_0805 between 13 100n_0402 1u_0402 D1 1 C3 VBLUE1 3 2 C4 150n_0402 RESETN C6 C5 I2C2_DAT I2C2_CLK JTMS-SWTDIO JTCK-SWTCK DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 1 2 3 4 5 6 7 8 DIO10 DIO9 DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 DIO3 DIO2 DIO1 DIO0 ANATEST0/DIO14 ANATEST1 ADC1 ADC2 TXD DIO7 DIO6 JP4 1 2 2 BlueNRG-1 VBLUE1 DIO3 DIO2 DIO1 DIO0 DIO14 TEST1 ADC1 ADC2 Jumper 2 JP5 R55 100k_0402 1 1 2 2 33 VBAT1 U12 1 2 VBAT2 B1 B2 A1 A2 BALF-NRG-01D3 L3 TBD_0402 4 3 J2 C12 TBD_0402 C11 TBD_0402 SMA connector 100n_0402 1u_0402 L5 TBD_0402 VBLUE1 VBAT3 VBAT2 C18 15p_0402 XTAL_HS C19 100n_0402 C20 1u_0402 TEST1 C21 100n_0402 ADC1 ADC2 TEST1 ADC1 ADC2 UM2071 page 50/92 STEVAL-IDB007V1 schematic digrams C17 C15 C14 VBLUE1 VBAT1 1u_0402 24 23 22 21 20 19 18 17 15p_0402 VBLUE1 Jumper 2 VBLUE1 C16 XTAL_LS Q2 SPI_IN SPI_OUT SPI_CS SPI_CLK DIO14 TEST VBAT1 SXTAL0 SXTAL1 RF0 RF1 VBAT2 FXTAL0 FXTAL1 Q1 22p_0402 9 10 11 12 13 14 15 16 1 VBLUE GND DIO11 TEST DIO12 DIO13 VDD1V2 SMPSFILT2 SMPSFILT1 RESETN 32 DIO11 31 TEST 30 DIO12 29 DIO13 28 27 26 25 RESETN 22p_0402 U1 TBD_0402 L1 DIO12 DIO13 SPI_CS1/RXD 100p_0402 UM2071 - Rev 14 Figure 26. STEVAL-IDB007V1 power management, sensors Vinh Gnd Bypass 6 5 4 BATT Battery holder C23 U3 33n_0402 1 C24 2.2u_0402 Jumper 3 VBLUE 3 470_0402 3 2 VDD JP1 2 POWER MANAGEMENT JP2 Jumper 3 R28 SPI_OUT DL4 GREEN SPI_CS 7 1u_0402 Vin N.C. Vout SPI_CLK 1 2 3 C22 1 USB_5V Gnd LDS3985PU33R VBLUE C28 U6 I2C2_DAT VBLUE R36 SDA SCL CS SPI_IN 10K_0402 R35 0_0402 LSM6DS3 DIO12 R41 0_0402 1 2 SDO/SA0 3 SDx R42 4 SCx INT1 0_0402 NC OCS INT2 VDD VBLUE C32 100n_0402 11 10 9 8 VBLUE C31 100n_0402 UM2071 page 51/92 STEVAL-IDB007V1 schematic digrams VBLUE 0_0402 0_0402 VDDIO GND GND LPS25HB VBLUE C30 100n_0402 R39 R38 5 6 7 R34 10K_0402 INT_DRDY CS RES SDA SA0 0_0402 VDDIO SCL 7 6 3 4 5 R31 1 2 U7 VDD GND GND C29 100n_0402 0_0402 SENSORS 10 9 8 VBLUE I2C2_CLK R37 100n_0402 14 13 12 C27 4.7u_0603 UM2071 - Rev 14 Figure 27. STEVAL-IDB007V1 buttons and LEDs VBLUE R26 100k_0402 VBLUE RESETN R27 100k_0402 C25 DIO13 SW1 10n_0402 C26 SW2 PUSH1 10n_0402 RESET GND R29 100_0402 GND R30 100_0402 VBLUE R54 100k_0402 I2C2_DAT DIO6 R32 C44 SW3 NC 510_0402 PUSH2 DL1 YELLOW GND R40 DIO14 DIO7 680_0402 R33 DL3 BLUE 680_0402 DL2 RED UM2071 page 52/92 STEVAL-IDB007V1 schematic digrams R53 100_0402 OSC_IN OSC_OUT NRST VDDA 1 2 3 4 5 6 7 8 9 10 11 12 VLCD PC13 RTC_AF1-WKUP2 PC14-OSC32_IN PC15-OSC32_OUT PH0-OSC_IN PH1-OSC_OUT NRST VSSA VDDA PA0-WKUP1 PA1 PA2 49 OSC_OUT GND VDD_2 VSS_2 PA13 PA12 PA11 PA10 PA9 PA8 PB15 PB14 PB13 PB12 C43 36 35 34 33 32 31 30 29 28 27 26 25 20p_0402 VDD2 JTMS USBDP USBDM USART1_RX USART1_TX 1-2SEL 3-4SEL VDD DIO7 R47 OE 10K_0402 NRST 13 14 15 16 17 18 19 20 21 22 23 24 UFQFPN48 7x7 package 128 kbyte flash 16 kbyte RAM USART1_RX 1 VDD1 PB2 RXD SPI_CS1 SPI_CLK1 SPI_OUT1 SPI_IN1 STM32L151CBU6 JP3 2 USART C35 C36 100n_0402 VDD2 C37 100n_0402 VDD VDD VDD VDD3 VDDA C38 100n_0402 C39 1u_0402 C40 100n_0402 C41 1u_0402 page 53/92 UM2071 100n_0402 VDD1 3 RESETN VLCD VDD USART1_TX STEVAL-IDB007V1 schematic digrams VDD R51 1M_0402 X1 8MHz PA3 PA4 PA5 PA6 PA7 PB0 PB1 PB2 PB10 PB11 VSS_1 VDD_1 TXD1 VDD_3 VSS_3 PB9 PB8 BOOT0 PB7 PB6 PB5 PB4 PB3 PA15 PA14 VLCD OSC_IN 48 47 46 45 44 43 42 41 40 39 38 37 U8 C42 20p_0402 JTDO JTDI JTCK VDD3 UM2071 - Rev 14 Figure 28. STEVAL-IDB007V1 micro UM2071 - Rev 14 Figure 29. STEVAL-IDB007V1 USB, level translator, JTAG for micro VDD USB CN5 11 10 9 R43 NC USB_5V USBDP R44 0_0402 USBDM 1 2 R45 0_0402 3 U9 DM DP SOT23-6L I/O11 I/O12 GND VBUS I/O21 I/O22 6 DP 5 4 SPI_CS1/RXD DIO7 GND GND GND USB micro B JTAG FOR MICRO VDD U10 Vl I/OVl1 I/OVcc2 I/OVl3 I/OVcc4 I/OVl5 I/OVcc6 I/OVl7 I/OVcc8 Gnd Vcc I/OVcc1 I/OVl2 I/OVcc3 I/OVl4 I/OVcc5 I/OVl6 I/OVcc7 I/OVl8 OE ST2378E 20 19 18 17 16 15 14 13 12 11 VDD CN6 RXD TXD1 PB2 OE 2 4 6 8 10 1 3 5 7 9 CONN Male Connector 2x5 page 54/92 UM2071 R50 10k_0402 JTMS JTCK JTDO JTDI STEVAL-IDB007V1 schematic digrams 1 2 3 0_0402 4 5 R49 0_0402 6 7 R52 8 9 0_0402 10 R48 TXD Vcc DD+ ID GND 6 7 8 DM LEVEL TRANSLATOR VBLUE 1 2 3 4 5 C33 100n_0402 USBLC6-2SC6 GND GND GND 1-2SEL=3-4SEL=H => SPI CONNECTED TO THE BLUENRG-1 1-2SEL=3-4SEL=L => SPI NOT CONNECTED TO THE BLUENRG-1 0_0402 100n_0402 R64 10K_0402 SPI_CLK 16 15 14 13 1S2 Vcc 1-2SEL 2S1 R59 0_0402 STG3692 SPI_CLK1 SPI_IN1 R62 SPI_IN D1 1S1 4S2 D4 1 2 3 4 0_0402 4S1 GND 3-4SEL 3S2 D2 2S2 3S1 D3 1-2SEL C45 R58 10K_0402 SPI_CS1 U11 R46 10K_0402 VDD SPI_CS1/RXD R61 5 6 7 8 UM2071 - Rev 14 Figure 30. STEVAL-IDB007V1 switch 12 11 10 9 3-4SEL R57 10K_0402 R63 10K_0402 SPI_OUT1 SPI_OUT R60 0_0402 R56 10K_0402 TP1 GND TP2 GND TP3 GND V1 V2 V3 V4 UM2071 STEVAL-IDB007V1 schematic digrams page 55/92 STEVAL-IDB007V2 schematic digrams Figure 31. STEVAL-IDB007V2 - scheme 1 VBLUE JTAG C1 C2 1u_0402 Male Connector 2x10 HDR straight D1 2 2 4 6 8 10 150n_0402 SPI_CS1/RXD 100p_0402 14 TXD DIO7 DIO6 I2C2_DAT I2C2_CLK JTMS-SWTDIO JTCK-SWTCK DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 1 2 3 4 5 6 7 8 DIO10 DIO9 DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 JP4 2 BlueNRG-1 VBLUE1 DIO3 DIO2 DIO1 DIO0 DIO14 TEST1 ADC1 ADC2 Jumper 2 JP5 1 TEST 1 2 2 VBAT2 A1 A2 BALF-NRG-02D3 L3 TBD_0402 4 3 J2 C12 TBD_0402 SMA connector C11 TBD_0402 C15 15p_0402 33 SPI_IN SPI_OUT SPI_CS SPI_CLK DIO14 XTAL_HS L5 TBD_0402 VBLUE1 VBAT3 VBAT2 C17 C18 100n_0402 15p_0402 C14 VBLUE1 VBAT1 1u_0402 B1 B2 C19 1u_0402 100n_0402 C20 1u_0402 TEST1 C21 ADC1 100n_0402 ADC2 TEST1 ADC1 ADC2 ARDUINO CONNECTORS VBLUE CN2 NC RESETN R9 0_0402 DIO0 R4 DIO3 0_0402 DIO7 R10 DIO8 0_0402 R3 R2 VBLUE 0_0402 R6 DIO2 R7 DIO1 0_0402 R8 R110_0402 CN1 10 9 0_0402 8 7 6 5 0_0402 4 3 0_04022 1 CN4 1 2 3 0_0402 4 5 R21 6 NC NC 0_0402 R19 DIO13 R17 DIO14 0_0402 0_0402 R25 R16 DIO12 TEST1 0_0402 R23 ADC1 ADC2 0_0402 R12 RESETN DIO6 0_0402 0_0402 R15 DIO3 R13 DIO2 DIO0 R18 0_0402 R14 DIO11 R20 0_0402 DIO8 R22 DIO11 R24 CN3 8 7 0_04026 5 0_04024 3 0_04022 1 0_0402 NC UM2071 page 56/92 1 2 3 4 5 6 7 8 R1 DIO4 DIO5 0_0402 R5 0_0402 STEVAL-IDB007V2 schematic digrams VBLUE1 C16 U12 1 2 Q2 VBLUE1 Jumper 2 R55 100k_0402 24 23 22 21 20 19 18 17 VBAT1 SXTAL0 SXTAL1 RF0 RF1 VBAT2 FXTAL0 FXTAL1 9 10 11 12 13 14 15 16 2 XTAL_LS VBAT1 U1 Q1 GND 32 DIO11 31 TEST 30 DIO12 29 DIO13 28 27 26 25 RESETN GND DIO11 TEST DIO12 DIO13 VDD1V2 SMPSFILT2 SMPSFILT1 RESETN RS 473-8282 1 22p_0402 22p_0402 ST Link: 3.0-3.6V, 5V tolerant IAR J-Link: 1.2-3.6V, 5V tolerant 1 C6 C5 18 20 SWD VBLUE TBD_0402 L1 DIO3 DIO2 DIO1 DIO0 ANATEST0/DIO14 ANATEST1 ADC1 ADC2 DIO1 RESETN C4 DIO12 DIO13 1 3 5 7 9 1112 13 1516 17 19 VBLUE1 3 1 C3 CN7 DIO0 JTMS-SWTDIO JTCK-SWTCK Solder a 10u_0805 between 1-2 or a 0R0_0805 between 1-3 100n_0402 RESETN UM2071 - Rev 14 22.2 VDD3 49 NC R51 1M_0402 X1 8MHz USB_5V OSC_OUT VLCD OSC_IN OSC_OUT NRST VDDA GND VDD_2 VSS_2 PA13 PA12 PA11 PA10 PA9 PA8 PB15 PB14 PB13 PB12 VLCD PC13 RTC_AF1-WKUP2 PC14-OSC32_IN PC15-OSC32_OUT PH0-OSC_IN PH1-OSC_OUT NRST VSSA VDDA PA0-WKUP1 PA1 PA2 20p_0402 C43 36 35 34 33 32 31 30 29 28 27 26 25 0_0402 VDD2 USBDM JTMS USBDP USBDM USART1_RX USART1_TX 1-2SEL 3-4SEL 2 R45 3 0_0402 I/O11 I/O12 GND VBUS I/O21 I/O22 USBLC6-2SC6 1 2 3 4 5 DM DP SOT23-6L 6 DP 5 4 GND GND GND Vcc DD+ ID GND 6 7 8 DM C33 100n_0402 GND GND GND USB micro B VDD DIO7 R47 OE 10K_0402 JTAG FOR MICRO UFQFPN48 7x7 package 128 kbyte flash 16 kbyte RAM VDD CN6 VDD1 1 3 5 7 9 2 4 6 8 10 JTMS JTCK JTDO JTDI USART1_RX 1 PB2 1 U9 NRST 13 14 15 16 17 18 19 20 21 22 23 24 RXD SPI_CS1 SPI_CLK1 SPI_OUT1 SPI_IN1 STM32L151CBU6 R44 USBDP PA3 PA4 PA5 PA6 PA7 PB0 PB1 PB2 PB10 PB11 VSS_1 VDD_1 TXD1 1 2 3 4 5 6 7 8 9 10 11 12 CN5 11 10 9 R43 OSC_IN 48 47 46 45 44 43 42 41 40 39 38 37 U8 VDD USB C42 20p_0402 JTDO JTDI JTCK MICRO VDD_3 VSS_3 PB9 PB8 BOOT0 PB7 PB6 PB5 PB4 PB3 PA15 PA14 UM2071 - Rev 14 Figure 32. STEVAL-IDB007V2 - scheme 2 JP3 RESETN 2 100n_0402 3 VDD3 100n_0402 100n_0402 C39 1u_0402 C40 100n_0402 U11 R46 10K_0402 VDD 100n_0402 LEVEL TRANSLATOR TXD SPI_CS1/RXD DIO7 1 R48 2 3 0_0402 4 5 R490_0402 6 7 R52 8 9 0_0402 10 Vl I/OVl1 I/OVcc2 I/OVl3 I/OVcc4 I/OVl5 I/OVcc6 I/OVl7 I/OVcc8 Gnd Vcc I/OVcc1 I/OVl2 I/OVcc3 I/OVl4 I/OVcc5 I/OVl6 I/OVcc7 I/OVl8 OE ST2378E 20 19 18 17 16 15 14 13 12 11 R64 10K_0402 SPI_CLK VDD U10 1 2 3 4 1-2SEL C45 VBLUE 1S2 Vcc 1-2SEL 2S1 R590_0402 STG3692 SPI_CLK1 RXD TXD1 PB2 TP1 GND TP2 GND R5810K_0402 SPI_CS1 C41 1u_0402 TP3 GND 16 15 14 13 VDDA C38 SPI_CS1/RXD R61 0_0402 SPI_IN1 R62 SPI_IN D1 1S1 4S2 D4 100n_0402 VDD C37 C36 VDD VDD VDD2 1-2SEL=3-4SEL=H => SPI CONNECTED TO THE BLUENRG-1 1-2SEL=3-4SEL=L => SPI NOT CONNECTED TO THE BLUENRG-1 0_0402 4S1 GND 3-4SEL 3S2 D2 2S2 3S1 D3 C35 VDD VDD1 Male Connector 2x5 5 6 7 8 VDD VLCD CONN USART1_TX USART 12 11 10 9 55 3-4SEL R57 10K_0402 R63 10K_0402 SPI_OUT1 SPI_OUT R600_0402 R5610K_0402 V1V2 V3 V4 OE R50 10k_0402 UM2071 STEVAL-IDB007V2 schematic digrams page 57/92 POWER MANAGEMENT BUTTONS AND LEDS VBLUE LDS3985PU33R C22 7 1u_0402 Vin N.C. Vout Vinh Gnd Bypass U3 6 5 4 BATT Battery holder 33n_0402 1 C24 2.2u_0402 R26 100k_0402 C23 2 VDD JP1 VBLUE JP2 1 USB_5V 1 2 3 Gnd UM2071 - Rev 14 Figure 33. STEVAL-IDB007V2 - scheme 3 R27 100k_0402 Jumper 3 3 SW1 RESET DIO13 Jumper 3 R28 470_0402 C25 10n_0402 3 2 VBLUE RESETN GND C26 DL4 SW2 PUSH1 10n_0402 R29 100_0402 GREEN GND VBLUE R30 100_0402 R54 100k_0402 VBLUE I2C2_DAT C28 100n_0402 LPS25HB VBLUE I2C2_DAT PUSH2 VBLUE 510_0402 SPI_CS C30 100n_0402 SPI_CLK 7 6 DL1 GND YELLOW 10K_0402 R37 VBLUE R35 0_0402 R36 0_0402 R53 100_0402 U7 SPI_IN 0_0402 NC OCS INT2 VDD VBLUE C32 100n_0402 11 10 9 8 R33 DL3 BLUE 680_0402 DL2 RED LSM6DS3 SDO/SA0 SDx SCx INT1 DIO7 680_0402 5 6 7 0_0402 DIO14 0_0402 VBLUE C31 100n_0402 UM2071 page 58/92 STEVAL-IDB007V2 schematic digrams DIO12 R410_0402 1 2 3 R42 4 R40 R39 R38 14 13 12 R34 10K_0402 DIO6 INT_DRDY CS RES SDA SA0 0_0402 VDDIO SCL SW3 NC R32 3 4 5 R31 1 2 C44 SDA SCL CS C29 100n_0402 VDD GND GND U6 I2C2_CLK SENSORS 10 9 8 VBLUE VDDIO GND GND 4.7u_0603 SPI_OUT C27 UM2071 - Rev 14 22.3 STEVAL-IDB008V1 schematic digrams Figure 34. STEVAL-IDB008V1 circuit schematic - JTAG VBLUE Male Connector 2x10 HDR straight CN7 1 3 5 DIO0 7 JTMS-SWTDIO 9 JTCK-SWTCK 11 13 DIO1 15 RESETN 17 19 2 4 6 8 10 12 14 16 18 20 SWD RS 473-8282 ST Link: 3.0-3.6V, 5V tolerant IAR J-Link: 1.2-3.6V, 5V tolerant GND UM2071 STEVAL-IDB008V1 schematic digrams page 59/92 UM2071 - Rev 14 Figure 35. STEVAL-IDB008V1 circuit schematic - Arduino connectors R1 DIO4 DIO5 0_0402 VBLUE CN2 1 2 3 4 5 6 7 8 DIO0 R4 DIO3 0_0402 R5 0_0402 RESETN R9 DIO7 R10 DIO8 0_0402 0_0402 R3 VBLUE 0_0402 R2 DIO2 R7 DIO1 0_0402 R8 R6 R11 0_0402 R12 RESETN DIO6 0_0402 0_0402 CN1 10 9 0_0402 8 7 6 5 0_0402 4 3 0_04022 1 NC NC CN4 1 2 3 0_0402 4 5 R21 6 NC 0_0402 R19 DIO13 R17 DIO14 0_0402 0_0402 R25 R16 DIO12 TEST1 0_0402 R23 ADC1 ADC2 0_0402 R15 DIO3 R13 DIO2 0_0402 R14 DIO0 R18 DIO11 R20 0_0402 DIO8 R22 DIO11 R24 CN3 8 7 0_04026 5 0_04024 3 0_04022 1 0_0402 NC UM2071 STEVAL-IDB008V1 schematic digrams page 60/92 UM2071 - Rev 14 Figure 36. STEVAL-IDB008V1 circuit schematic - BlueNRG-2 Solder a 10u_0805 between 1-2 or a 0R0_0805 between 1-3 C1 C2 100n_0402 1u_0402 D1 1 C3 VBLUE1 3 2 C4 100p_0402 150n_0402 RESETN DIO13 DIO12 SPI_CS1/RXD C6 C5 22p_0402 JP4 1 1 BlueNRG-2 2 2 VBLUE1 24 23 22 21 20 19 18 17 Jumper 2 ADC2 ADC1 TEST1 DIO14 DIO0 DIO1 DIO2 DIO3 1 1 2 2 A1 A2 L3 4 3 TBD_0402 J2 C12 TBD_0402 C11 TBD_0402 SMA connector 100n_0402 15p_0402 XTAL_HS VBAT2 C18 1u_0402 TEST1 VBLUE1 VBAT3 C19 100n_0402 C20 1u_0402 L5 TBD_0402 C21 100n_0402 ADC1 ADC2 TEST1 ADC1 ADC2 UM2071 page 61/92 STEVAL-IDB008V1 schematic digrams VBLUE1 C17 C15 C14 VBAT1 C16 B1 B2 BALF-NRG-01D3 DIO14 SPI_CLK SPI_CS SPI_OUT SPI_IN VBLUE1 1u_0402 VBAT2 15p_0402 VBLUE1 Jumper 2 R55 100k_0402 U12 1 2 Q2 JP5 TEST XTAL_LS VBAT1 GND VBAT1 SXTAL0 SXTAL1 RF0 RF1 VBAT2 FXTAL0 FXTAL1 Q1 22p_0402 16 15 14 13 12 11 10 9 VBLUE DIO10 DIO9 DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 ADC2 ADC1 ANATEST1 ANATEST0/DIO14 DIO0 DIO1 DIO2 DIO3 I2C2_DAT I2C2_CLK 1 2 3 4 5 6 7 8 RESETN SMPSFILT1 SMPSFILT2 VDD1V2 DIO13 DIO12 TEST DIO11 TXD DIO7 DIO6 JTMS-SWTDIO JTCK-SWTCK DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 33 RESETN 25 26 27 28 DIO13 29 DIO12 30 TEST 31 DIO11 32 U1 TBD_0402 L1 UM2071 - Rev 14 Figure 37. STEVAL-IDB008V1 circuit schematic - buttons and LEDS VBLUE R26 100k_0402 VBLUE RESETN R27 100k_0402 C25 SW1 10n_0402 RESET DIO13 GND C26 SW2 PUSH1 10n_0402 R29 100_0402 GND VBLUE R30 100_0402 R54 100k_0402 I2C2_DAT C44 DIO6 SW3 NC R32 510_0402 DL1 PUSH2 GND R53 100_0402 YELLOW R40 DIO7 680_0402 R33 DL3 BLUE 680_0402 DL2 RED UM2071 page 62/92 STEVAL-IDB008V1 schematic digrams DIO14 C28 100n_0402 R34 10K_0402 U7 LPS25HB VBLUE I2C2_DAT LSM6DS3 SDA SCL CS INT_DRDY CS C30 100n_0402 SPI_IN DIO12 R41 0_0402 1 2 SDO/SA0 3 SDx R42 4 SCx INT1 0_0402 10K_0402 VBLUE R35 0_0402 0_0402 0_0402 NC OCS INT2 VDD 11 10 9 8 5 6 7 0_0402 VDDIO SCL R39 R38 VBLUE 7 6 RES SDA SA0 R31 1 2 3 4 5 I2C2_CLK VDD GND GND U6 C29 100n_0402 0_0402 10 9 8 VBLUE R37 14 13 12 4.7u_0603 VDDIO GND GND C27 SPI_CS VBLUE SPI_CLK SPI_OUT UM2071 - Rev 14 Figure 38. STEVAL-IDB008V1 circuit schematic - sensors VBLUE C31 100n_0402 VBLUE R36 C32 100n_0402 Figure 39. STEVAL-IDB008V1 circuit schematic - power management 1 2 3 C22 7 1u_0402 Vin N.C. Vout 6 Vinh 5 Gnd 4 Bypass U3 1 2.2u_0402 JP1 C23 33n_0402 3 Jumper 3 2 VDD VBLUE 3 2 JP2 470_0402 R28 DL4 UM2071 page 63/92 GREEN Jumper 3 STEVAL-IDB008V1 schematic digrams C24 BATT Battery holder 1 USB_5V Gnd LDS3985PU33R UM2071 - Rev 14 Figure 40. STEVAL-IDB008V1 circuit schematic - JTAG for MCU VDD CN6 JTMS JTCK JTDO JTDI 2 4 6 8 10 1 3 5 7 9 CONN Male Connector 2x5 Figure 41. STEVAL-IDB008V1 circuit schematic - USB VDD CN5 11 10 9 R43 NC USB_5V USBDP R44 0_0402 USBDM 1 2 R45 0_0402 3 U9 DM DP SOT23-6L I/O11 I/O12 GND VBUS I/O21 I/O22 USBLC6-2SC6 6 DP 5 4 1 2 3 4 5 6 7 8 DM C33 100n_0402 GND GND GND Vcc DD+ ID GND GND GND GND USB micro B Figure 42. STEVAL-IDB008V1 circuit schematic - test points TP2 GND TP3 GND V1 V2 V3 V4 UM2071 page 64/92 STEVAL-IDB008V1 schematic digrams TP1 GND UM2071 - Rev 14 Figure 43. STEVAL-IDB008V1 circuit schematic - switch 1-2SEL=3-4SEL=H => SPI CONNECTED TO THE BLUENRG-2 1-2SEL=3-4SEL=L => SPI NOT CONNECTED TO THE BLUENRG-2 SPI_CS1/RXD R61 0_0402 R58 10K_0402 100n_0402 R64 10K_0402 SPI_CLK 1S2 Vcc 1-2SEL 2S1 R59 0_0402 STG3692 SPI_CLK1 R62 SPI_IN 0_0402 4S1 GND 3-4SEL 3S2 D2 2S2 3S1 D3 1-2SEL C45 1 2 3 4 5 6 7 8 VDD SPI_IN1 D1 1S1 4S2 D4 U11 R46 10K_0402 16 15 14 13 SPI_CS1 12 11 10 9 3-4SEL R57 10K_0402 R63 10K_0402 SPI_OUT1 SPI_OUT R60 0_0402 R56 10K_0402 UM2071 STEVAL-IDB008V1 schematic digrams page 65/92 OSC_IN R51 1M_0402 X1 8MHz 49 48 47 46 45 44 43 42 41 40 39 38 37 U8 C42 20p_0402 JTDO JTDI JTCK VDD3 UM2071 - Rev 14 Figure 44. STEVAL-IDB008V1 circuit schematic - microcontroller VLCD OSC_IN OSC_OUT NRST VDDA VLCD PC13 RTC_AF1-WKUP2 PC14-OSC32_IN PC15-OSC32_OUT PH0-OSC_IN PH1-OSC_OUT NRST VSSA VDDA PA0-WKUP1 PA1 PA2 GND VDD_2 VSS_2 PA13 PA12 PA11 PA10 PA9 PA8 PB15 PB14 PB13 PB12 20p_0402 C43 36 35 34 33 32 31 30 29 28 27 26 25 VDD2 JTMS USBDP USBDM USART1_RX USART1_TX 1-2SEL 3-4SEL VDD DIO7 R47 OE 10K_0402 PA3 PA4 PA5 PA6 PA7 PB0 PB1 PB2 PB10 PB11 VSS_1 VDD_1 TXD1 1 2 3 4 5 6 7 8 9 10 11 12 VDD_3 VSS_3 PB9 PB8 BOOT0 PB7 PB6 PB5 PB4 PB3 PA15 PA14 OSC_OUT UFQFPN48 7x7 package 128 kbyte flash 16 kbyte RAM USART1_RX 1 VDD1 PB2 13 14 15 16 17 18 19 20 21 22 23 24 RXD SPI_CS1 SPI_CLK1 SPI_OUT1 SPI_IN1 STM32L151CBU6 NRST JP3 2 USART1_TX VLCD C35 100n_0402 VDD1 C36 100n_0402 VDD2 C37 100n_0402 RESETN VDD VDD VDD VDD VDD3 VDDA C38 100n_0402 C39 1u_0402 C40 100n_0402 C41 1u_0402 UM2071 page 66/92 STEVAL-IDB008V1 schematic digrams VDD 3 USART UM2071 - Rev 14 Figure 45. STEVAL-IDB008V1 circuit schematic - level translator VBLUE 1 2 3 0_0402 4 5 R49 0_0402 6 7 R52 8 9 0_0402 10 R48 TXD SPI_CS1/RXD DIO7 VDD U10 Vl I/OVl1 I/OVcc2 I/OVl3 I/OVcc4 I/OVl5 I/OVcc6 I/OVl7 I/OVcc8 Gnd Vcc I/OVcc1 I/OVl2 I/OVcc3 I/OVl4 I/OVcc5 I/OVl6 I/OVcc7 I/OVl8 OE ST2378E 20 19 18 17 16 15 14 13 12 11 RXD TXD1 PB2 OE R50 10k_0402 UM2071 STEVAL-IDB008V1 schematic digrams page 67/92 UM2071 - Rev 14 22.4 STEVAL-IDB008V2 schematic digrams Figure 46. STEVAL-IDB008V2 - JTAG VBLUE Male Connector 2x10 HDR straight CN7 1 3 5 DIO0 7 JTMS-SWTDIO 9 JTCK-SWTCK 11 13 DIO1 15 RESETN 17 19 2 4 6 8 10 12 14 16 18 20 SWD RS 473-8282 ST Link: 3.0-3.6V, 5V tolerant IAR J-Link: 1.2-3.6V, 5V tolerant GND UM2071 STEVAL-IDB008V2 schematic digrams page 68/92 UM2071 - Rev 14 Figure 47. STEVAL-IDB008V2 - Arduino connection R1 DIO4 DIO5 0_0402 VBLUE CN2 1 2 3 4 5 6 7 8 DIO0 R4 DIO3 0_0402 R5 0_0402 RESETN R9 DIO7 R10 DIO8 0_0402 0_0402 R3 VBLUE 0_0402 R2 DIO2 R7 DIO1 0_0402 R8 R6 R11 0_0402 R12 RESETN DIO6 0_0402 0_0402 CN1 10 9 0_0402 8 7 6 5 0_0402 4 3 0_04022 1 NC NC CN4 1 2 3 0_0402 4 5 R21 6 NC 0_0402 R19 DIO13 R17 DIO14 0_0402 0_0402 R25 R16 DIO12 TEST1 0_0402 R23 ADC1 ADC2 0_0402 R15 DIO3 R13 DIO2 R18 DIO0 R14 0_0402 DIO11 R20 0_0402 DIO8 R22 DIO11 R24 CN3 8 7 0_04026 5 0_04024 3 0_04022 1 0_0402 NC UM2071 STEVAL-IDB008V2 schematic digrams page 69/92 UM2071 - Rev 14 Figure 48. STEVAL-IDB008V2 circuit schematic Solder a 10u_0805 between 1- 2 or a 0R0_0805 between 1- 3 C1 C2 100n_0402 1u_0402 D1 1 C3 VBLUE1 3 2 C4 150n_0402 RESETN C6 C5 I2C2_DAT I2C2_CLK JTMS-SWTDIO JTCK-SWTCK DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 1 2 3 4 5 6 7 8 DIO10 DIO9 DIO8 DIO7 DIO6 VBAT3 DIO5 DIO4 DIO3 DIO2 DIO1 DIO0 ANATEST0/DIO14 ANATEST1 ADC1 ADC2 TXD DIO7 DIO6 JP4 1 2 2 BlueNRG-2 VBLUE1 DIO3 DIO2 DIO1 DIO0 DIO14 TEST1 ADC1 ADC2 Jumper 2 JP5 R55 100k_0402 1 1 2 2 33 VBAT1 VBAT2 B1 B2 A1 A2 BALF-NRG-02D3 L3 TBD_0402 4 3 J2 C12 TBD_0402 C11 TBD_0402 SMA connector C17 100n_0402 XTAL_HS 1u_0402 L5 TBD_0402 VBLUE1 VBAT3 VBAT2 C18 C15 15p_0402 C14 VBLUE1 VBAT1 1u_0402 U12 1 2 Q2 VBLUE1 Jumper 2 VBLUE1 C16 24 23 22 21 20 19 18 17 22p_0402 XTAL_LS 15p_0402 SPI_IN SPI_OUT SPI_CS SPI_CLK DIO14 TEST VBAT1 SXTAL0 SXTAL1 RF0 RF1 VBAT2 FXTAL0 FXTAL1 Q1 9 10 11 12 13 14 15 16 1 VBLUE GND DIO11 TEST DIO12 DIO13 VDD1V2 SMPSFILT2 SMPSFILT1 RESETN 32 DIO11 31 TEST 30 DIO12 29 DIO13 28 27 26 25 RESETN 22p_0402 U1 TBD_0402 L1 DIO12 DIO13 SPI_CS1/RXD 100p_0402 C19 100n_0402 C20 1u_0402 TEST1 C21 100n_0402 ADC1 ADC2 TEST1 ADC1 ADC2 UM2071 STEVAL-IDB008V2 schematic digrams page 70/92 LDS3985PU33R 1 2 3 C22 7 1u_0402 Vin N.C. Vout 6 Vinh 5 Gnd 4 Bypass U3 1 C24 2.2u_0402 JP1 BATT Battery holder C23 33n_0402 3 JP2 2 VDD VBLUE 3 2 Jumper 3 1 USB_5V Gnd UM2071 - Rev 14 Figure 49. STEVAL-IDB008V2 - power managements 470_0402 R28 Jumper 3 DL4 GREEN UM2071 STEVAL-IDB008V2 schematic digrams page 71/92 UM2071 - Rev 14 Figure 50. STEVAL-IDB008V2 - SENSORs VBLUE C27 C28 4.7u_0603 100n_0402 10 9 8 VBLUE VBLUE LPS25HB VBLUE I2C2_DAT SPI_CS C30 100n_0402 SPI_CLK 7 6 SPI_OUT R34 10K_0402 INT_DRDY CS R37 10K_0402 VBLUE R35 0_0402 R36 0_0402 0_0402 0_0402 LSM6DS3 SDA SCL CS U7 R39 R38 14 13 12 0_0402 VDDIO SCL RES SDA SA0 R31 1 2 3 4 5 I2C2_CLK VDD GND GND U6 C29 100n_0402 NC OCS INT2 VDD 5 6 7 DIO12 R41 0_0402 1 2 SDO/SA0 3 SDx R42 4 SCx INT1 0_0402 VDDIO GND GND SPI_IN 11 10 9 8 VBLUE C31 100n_0402 VBLUE C32 100n_0402 UM2071 STEVAL-IDB008V2 schematic digrams page 72/92 UM2071 - Rev 14 Figure 51. STEVAL-IDB008V2 - buttons and leds VBLUE R26 100k_0402 VBLUE RESETN R27 100k_0402 C25 SW1 10n_0402 RESET DIO13 GND C26 SW2 PUSH1 10n_0402 R29 100_0402 GND VBLUE R30 100_0402 R54 100k_0402 I2C2_DAT C44 DIO6 SW3 NC R32 DL1 510_0402 PUSH2 GND R40 DIO14 DIO7 680_0402 R33 DL3 BLUE 680_0402 DL2 RED UM2071 page 73/92 STEVAL-IDB008V2 schematic digrams R53 100_0402 YELLOW OSC_IN X1 8MHz 49 48 47 46 45 44 43 42 41 40 39 38 37 U8 C42 20p_0402 JTDO JTDI JTCK VDD3 UM2071 - Rev 14 Figure 52. STEVAL-IDB008V2 - micro R51 1M_0402 VLCD OSC_IN OSC_OUT NRST VDDA VLCD PC13 RTC_AF1-WKUP2 PC14-OSC32_IN PC15-OSC32_OUT PH0-OSC_IN PH1-OSC_OUT NRST VSSA VDDA PA0-WKUP1 PA1 PA2 GND VDD_2 VSS_2 PA13 PA12 PA11 PA10 PA9 PA8 PB15 PB14 PB13 PB12 C43 36 35 34 33 32 31 30 29 28 27 26 25 VDD2 JTMS USBDP USBDM USART1_RX USART1_TX 1-2SEL 3-4SEL VDD DIO7 R47 OE 10K_0402 PA3 PA4 PA5 PA6 PA7 PB0 PB1 PB2 PB10 PB11 VSS_1 VDD_1 TXD1 1 2 3 4 5 6 7 8 9 10 11 12 VDD_3 VSS_3 PB9 PB8 BOOT0 PB7 PB6 PB5 PB4 PB3 PA15 PA14 OSC_OUT 20p_0402 UFQFPN48 7x7 package 128 kbyte flash 16 kbyte RAM VDD1 USART1_RX 1 PB2 13 14 15 16 17 18 19 20 21 22 23 24 RXD SPI_CS1 SPI_CLK1 SPI_OUT1 SPI_IN1 STM32L151CBU6 NRST JP3 RESETN 2 VDD VLCD 100n_0402 C36 100n_0402 VDD2 C37 100n_0402 3 VDD VDD VDD3 VDDA C38 100n_0402 C39 1u_0402 C40 100n_0402 C41 1u_0402 UM2071 page 74/92 STEVAL-IDB008V2 schematic digrams C35 VDD1 USART VDD VDD USART1_TX UM2071 - Rev 14 Figure 53. STEVAL-IDB008V2 - USB VDD CN5 11 10 9 R43 NC USB_5V USBDP R44 0_0402 USBDM R45 0_0402 1 2 3 U9 DM DP SOT23-6L I/O11 I/O12 GND VBUS I/O21 I/O22 USBLC6-2SC6 6 DP 5 4 1 2 3 4 5 6 7 8 DM C33 100n_0402 GND GND GND Vcc DD+ ID GND GND GND GND USB micro B Figure 54. STEVAL-IDB008V2 - JTAG for micro VDD CN6 JTMS JTCK JTDO JTDI 1 3 5 7 9 2 4 6 8 10 CONN UM2071 page 75/92 STEVAL-IDB008V2 schematic digrams Male Connector 2x5 UM2071 - Rev 14 Figure 55. STEVAL-IDB008V2 - level translator VBLUE 1 2 3 0_0402 4 5 R49 0_0402 6 7 R52 8 9 0_0402 10 R48 TXD SPI_CS1/RXD DIO7 VDD U10 Vl I/OVl1 I/OVcc2 I/OVl3 I/OVcc4 I/OVl5 I/OVcc6 I/OVl7 I/OVcc8 Gnd Vcc I/OVcc1 I/OVl2 I/OVcc3 I/OVl4 I/OVcc5 I/OVl6 I/OVcc7 I/OVl8 OE 20 19 18 17 16 15 14 13 12 11 RXD TXD1 PB2 OE R50 10k_0402 ST2378E Figure 56. STEVAL-IDB008V2 - Switch 1-2SEL=3-4SEL=H => SPI CONNECTED TO THE BLUENRG-2 SPI_CS1/RXD R61 1-2SEL=3-4SEL=L => SPI NOT 0_0402 CONNECTED TO THE BLUENRG-2 R58 10K_0402 R64 10K_0402 SPI_CLK 1S2 Vcc 1-2SEL 2S1 R59 0_0402 STG3692 SPI_CLK1 R62 SPI_IN 0_0402 4S1 GND 3-4SEL 3S2 D2 2S2 3S1 D3 1-2SEL C45 100n_0402 1 2 3 4 5 6 7 8 VDD SPI_IN1 D1 1S1 4S2 D4 U11 R46 10K_0402 16 15 14 13 SPI_CS1 12 11 10 9 3-4SEL R57 10K_0402 SPI_OUT1 TP2 GND TP3 GND V1 V2 V3 V4 UM2071 page 76/92 STEVAL-IDB008V2 schematic digrams SPI_OUT R60 0_0402 R56 10K_0402 TP1 GND R63 10K_0402 UM2071 - Rev 14 22.5 STEVAL-IDB008V1M schematic digrams Figure 57. STEVAL-IBD008V1M circuit schematic (1 of 3) Arduino connectors VBLUE JTAG VBLUE Male Connector 2x10 HDR straight CN2 CN7 1 3 5 7 9 11 13 15 17 19 DIO0 JTMS-SWTDIO JTCK-SWTCK DIO1 RESETN 2 4 6 8 10 12 14 16 18 20 RESETN CN4 RS 473-8282 1 2 3 0_0402 4 5 R21 6 L3 0_0402 GND R160_0402 NC 22 DIO2 Vin DIO0 CN3 0_0402 R15 DIO3 R13 DIO2 DIO0 R18 0_0402 R14 DIO11 R20 0_0402 DIO8 R22 DIO11 R24 8 7 0_04026 5 0_04024 3 0_04022 1 0_0402 NC 20 DIO12 DIO12 19 RESETN RESETN 18 DIO1 SPI_CS N.C. R670_0402 17 R550_0402 16 15 DIO0 R650_0402 DIO3 SPI_IN DIO2 SPI_OUT SPI_CLK DIO10 ANATEST1 14 13 DIO9 DIO8 DIO11 R660_0402 N.C. 12 6 C2 100n_0402 ADC1 ADC2 R250_0402 R12 RESETN DIO6 0_0402 21 DIO3 DIO5 10 5 0_0402 BLUENRG-M2SA MODULE DIO4 11 4 DIO1 GND 3 DIO5 ADC1 DIO6 DIO4 RESETN 9 L1 I2C2_DAT 2 ADC2 DIO7/BOOT I2C2_CLK VBLUE1 1 C47 3pF_0402 8 ADC1 2.2u_0402 GND_RF 23 DIO12 Jumper 2 C1 GND_RF ANTENNA ADC2 VBLUE1 ANATEST0/DIO14 2 7 2 EXT_ANT BLE1 C46 3pF_0402 JP4 DIO12 TEST1 0_0402 R19 DIO13 R17 DIO14 R230_0402 0_0402 NC 1 10 9 0_0402 8 R20_0402R3 7 VBLUE 0_0402 6 5 0_0402 4 R6 DIO2 R7 3 DIO1 0_0402 2 R80_0402 1 R110_0402 DIO13 ST Link: 3.0-3.6V, 5V tolerant IAR J-Link: 1.2-3.6V, 5V tolerant 1 DIO7 R10 DIO8 R90_0402 CN1 0_0402 NC SWD VBLUE R1 DIO0 R4 DIO3 0_0402 R5 0_0402 1 2 3 4 5 6 7 8 DIO4 DIO5 DIO14 DIO14 DIO7 DIO7 TXD SPI_CS1/RXD DIO8 DIO11 JTCK-SWTCK JTMS-SWTDIO C48 3pF_0402 TEST1 ADC1 ADC2 TEST1 ADC1 ADC2 UM2071 page 77/92 STEVAL-IDB008V1M schematic digrams DIO6 DIO6 UM2071 - Rev 14 Figure 58. STEVAL-IBD008V1M circuit schematic (2 of 3) 7 1u_0402 Vin N.C. Vout Vinh Gnd Bypass U3 6 5 4 1 R26 100k_0402 JP2 VBLUE 2 VDD JP1 3 R27 100k_0402 TP(DIO13) available for user connection DIO13 Jumper 3 R28 470_0402 RESETN VBLUE 3 2 Jumper 3 VBLUE C23 33n_0402 C24 2.2u_0402 Buttons and LEDs BATT Battery holder 1 C22 Gnd LDS3985PU33R 1 2 3 C25 DIO13 DL4 Power management SW1 10n_0402 RESET GND R29 100_0402 C26 GREEN 10n_0402 SW2 PUSH1 GND VBLUE Sensors R30 100_0402 VBLUE R54 100k_0402 I2C2_DAT C28 C27 100n_0402 LPS25HB VBLUE I2C2_DAT NC R32 PUSH2 VBLUE 510_0402 SPI_CS C30 100n_0402 SPI_CLK 7 6 SPI_OUT R34 10K_0402 DIO6 INT_DRDY CS DL1 GND YELLOW 10K_0402 R37 VBLUE R35 0_0402 R36 0_0402 R53 100_0402 U7 SPI_IN 0_0402 DIO14 0_0402 0_0402 NC OCS INT2 VDD C32 100n_0402 680_0402 DL2 RED VBLUE C31 100n_0402 UM2071 page 78/92 STEVAL-IDB008V1M schematic digrams VBLUE 11 10 9 8 R33 DL3 BLUE LSM6DS3 SDO/SA0 SDx SCx INT1 DIO7 680_0402 5 6 7 DIO12 R410_0402 1 2 3 R42 4 R40 R39 R38 14 13 12 0_0402 VDDIO SCL SDA SCL CS R31 1 2 VDDIO GND GND C29 100n_0402 RES SDA SA0 I2C2_CLK VDD GND GND U6 SW3 C44 10 9 8 VBLUE 3 4 5 4.7u_0603 VDD3 U8 VDD USB C42 20p_0402 JTDO JTDI JTCK Microcontroller X1 49 8MHz NC R51 1M_0402 USB_5V OSC_IN OSC_OUT NRST VDDA VLCD PC13 RTC_AF1-WKUP2 PC14-OSC32_IN PC15-OSC32_OUT PH0-OSC_IN PH1-OSC_OUT NRST VSSA VDDA PA0-WKUP1 PA1 PA2 GND VDD_2 VSS_2 PA13 PA12 PA11 PA10 PA9 PA8 PB15 PB14 PB13 PB12 20p_0402 C43 36 35 34 33 32 31 30 29 28 27 26 25 0_0402 VDD2 USBDM JTMS USBDP USBDM USART1_RX USART1_TX 1-2SEL 3-4SEL 2 R45 3 0_0402 I/O11 I/O12 GND VBUS I/O21 I/O22 1 2 3 4 5 DM DP SOT23-6L 6 DP 5 4 USBLC6-2SC6 GND GND GND Vcc DD+ ID GND 6 7 8 DM C33 100n_0402 GND GND GND USB micro B VDD DIO7 R47 OE 10K_0402 JTAG for micro UFQFPN48 7x7 package 128 kbyte flash 16 kbyte RAM VDD CN6 VDD1 2 4 6 8 10 JTMS JTCK JTDO JTDI USART1_RX 1 PB2 1 U9 NRST 13 14 15 16 17 18 19 20 21 22 23 24 RXD SPI_CS1 SPI_CLK1 SPI_OUT1 SPI_IN1 STM32L151CBU6 R44 USBDP PA3 PA4 PA5 PA6 PA7 PB0 PB1 PB2 PB10 PB11 VSS_1 VDD_1 TXD1 1 2 3 4 5 6 7 8 9 10 11 12 VDD_3 VSS_3 PB9 PB8 BOOT0 PB7 PB6 PB5 PB4 PB3 PA15 PA14 OSC_OUT VLCD CN5 11 10 9 R43 OSC_IN 48 47 46 45 44 43 42 41 40 39 38 37 UM2071 - Rev 14 Figure 59. STEVAL-IBD008V1M circuit schematic (3 of 3) 1 3 5 7 9 JP3 USART1_TX RESETN 2 3 100n_0402 100n_0402 100n_0402 C39 1u_0402 C40 100n_0402 U11 R46 10K_0402 VDD 100n_0402 Level translator VBLUE TXD SPI_CS1/RXD DIO7 Vcc I/OVcc1 I/OVl2 I/OVcc3 I/OVl4 I/OVcc5 I/OVl6 I/OVcc7 I/OVl8 OE ST2378E 20 19 18 17 16 15 14 13 12 11 10K_0402 SPI_CLK VDD U10 Vl I/OVl1 I/OVcc2 I/OVl3 I/OVcc4 I/OVl5 I/OVcc6 I/OVl7 I/OVcc8 Gnd R64 1S2 Vcc 1-2SEL 2S1 R590_0402 STG3692SPI_CLK1 RXD TXD1 PB2 OE R50 10k_0402 TP1 GND TP2 GND TP3 GND SPI_IN1 R62 SPI_IN 0_0402 4S1 GND 3-4SEL 3S2 12 11 10 9 3-4SEL R57 10K_0402 SPI_OUT1 R63 10K_0402 SPI_OUT V1 V2 V3 V4 R600_0402 R5610K_0402 UM2071 page 79/92 STEVAL-IDB008V1M schematic digrams 1 2 3 0_0402 4 5 R490_0402 6 7 R52 8 9 0_0402 10 1 2 3 4 1-2SEL C45 R48 R5810K_0402 SPI_CS1 C41 1u_0402 16 15 14 13 C38 C37 D1 1S1 4S2 D4 100n_0402 VDD3 VDDA VDD2 VDD1 C36 SPI_CS1/RXD R61 0_0402 D2 2S2 3S1 D3 VLCD C35 VDD VDD VDD VDD Male Connector 2x5 1-2 SEL=3-4 SEL=H -> SPI CONNECTED TO THE BLUENRG-2 1-2 SEL=3-4 SEL=L -> SPI NOT CONNECTED TO THE BLUENRG-2 5 6 7 8 VDD CONN USART UM2071 - Rev 14 22.6 STEVAL-IDB009V1 schematic digrams Figure 60. STEVAL-IDB009V1 board schematic ARDUINO CONNECTORS VBLUE JTAG DIO15 0_0402 Male Connector 2x10 HDR straight C1 D1 1 DIO24 2 DIO23 3 DIO22 4 DIO8 5 DIO7 6 DIO21 7 DIO6 8 VBAT4 9 DIO5 DIO20 10 DIO19 11 DIO18 12 TXD DIO7 DIO6 I2C2_DAT DIO24 DIO23 DIO22 DIO8 DIO7/BOOT DIO21 DIO6 VBAT4 DIO5 DIO20 DIO19 DIO18 JP4 2 2 VBLUE1 BLUENRG-248 JP5 1 2 2 RES ETN 36 35 34 33 32 31 30 29 28 27 26 25 VBLUE1 VBAT1 C16 1u_0402 100n_0402 R11 0_0402 R12 RES ETN DIO6 0_0402 0_0402 0_0402 R19 DIO13 R17 DIO14 0_0402 0_0402 22p_0402 R15 DIO25 R13 DIO23 DIO0 R18 0_0402 R14 DIO11 R20 0_0402 DIO22 R22 DIO21 R24 R16 DIO12 DIO18 0_0402 R23 DIO19 DIO20 0_0402 NC 51p_0402 L2 XTAL_LS VBAT1 C7 2n4_0402 C8 0p9_0402 L3 2n7_0402 C9 1n_0402 C13 ADC2 ADC1 C10 L4 1p8_0402 VBAT2 C11 L6 1n6_0402 1p5_0402 12p_0402 1p1_0402 J2 C49 S MA conne ctor 0p3_0402 C12 Q2 0p4_0402 15p_0402 C15 15p_0402 C14 XTAL_HS TES T0 L5 TBD_0402 TES T1 ADC2 C18 1u_0402 VBLUE1 C19 100n_0402 C20 1u_0402 VBAT4 C21 100n_0402 8 7 0_04026 5 0_04024 3 0_04022 1 0_0402 22p_0402 Q1 VBAT5 VBAT3 VBAT2 CN3 NC VBLUE1 VBLUE1 NC C6 C47 C17 R6 DIO2 R7 DIO1 0_0402 R8 ADC1 J umpe r 2 VBLUE1 R3 R2 VBLUE 0_0402 10 9 0_0402 8 7 6 5 0_0402 4 3 0_04022 1 0_0402 R25 VBLUE1 I2C2_CLK S P I_IN S P I_OUT S P I_CS R55 100k_0402 1 DIO7 R10 DIO8 CN1 0_0402 C34 1u_0402 1u_0402 C46 100n_0402 C48 100n_0402 TES T0 TES T1 ADC1 ADC2 UM2071 page 80/92 STEVAL-IDB009V1 schematic digrams TES T RES ETN VBAT1 S XTAL0 S XTAL1 NC RF0 RF1 VBAT2 FXTAL0 FXTAL1 ADC2 ADC1 DIO4 DIO3 DIO2 DIO1 DIO17 DIO0 DIO16 DIO15 DIO14 VBAT5 TES T0 TES T1 J umpe r 2 R67 L1 TBD_0402 DIO14 1 S P I_CLK 1 VBLUE R66 1 2 3 0_0402 4 5 R21 6 C5 RES ETN 100p_0402 150n_0402 RES ETN 0_0402 DIO16 0_0402 DIO17 GND U1 C3 R9 CN4 49 GND DIO25 DIO9 DIO10 VBAT3 DIO11 TES T DIO12 DIO13 VBAT3 VDD1V2 S MP S FILT2 S MP S FILT1 RS 473-8282 ST Link: 3.0-3.6V, 5V tolerant IAR J-Link: 1.2-3.6V, 5V tolerant NC VBLUE1 3 48 DIO25 47 J TCK-S WTCK 46 J TMS -S WTDIO 45 VBAT3 44 DIO11 S P I_CS 1/RXD 43 TES T 42 DIO12 DIO12 41 DIO13 DIO13 40 VBAT3 39 VDD1V2 38 37 2 1 S WD VDD1V2 C4 C2 100n_0402 1u_0402 DIO4 DIO3 DIO2 DIO1 DIO17 DIO0 DIO16 DIO15 DIO14 VBAT4 ANATES T0 ANATES T1 DIO1 RES ETN 2 4 6 8 10 12 14 16 18 20 13 14 15 16 17 18 19 20 21 22 23 24 1 3 5 7 9 11 13 15 17 19 DIO24 R4 DIO3 0_0402 R5 0_0402 1 2 3 4 5 6 7 8 CN7 DIO0 J TMS -S WTDIO J TCK-S WTCK VBLUE R65 CN2 Solder a 10u_0805 between 1-2 or a 0R0_0805 between 1-3 R1 DIO4 DIO5 0_0402 LDS 3985P U33R C22 7 1u_0402 Vin N.C. Vout Vinh Gnd Bypa s s U3 1 R26 100k_0402 JP2 VBLUE 2 VDD JP1 R27 100k_0402 3 J umpe r 3 R28 470_0402 C25 S W1 10n_0402 RES ET DIO13 DL4 GND C26 POWER MANAGEMENT RES ETN VBLUE 3 2 J umpe r 3 VBLUE C23 33n_0402 C24 2.2u_0402 BUTTONs AND LEDs BATT Ba tte ry holde r 6 5 4 1 US B_5V 1 2 3 Gnd UM2071 - Rev 14 Figure 61. STEVAL-IDB009V1 board schematic (part 2) S W2 P US H1 10n_0402 GREEN R29 100_0402 GND VBLUE R30 100_0402 SENSORs R54 100k_0402 VBLUE I2C2_DAT C27 C28 100n_0402 C44 10 9 8 VBLUE 10K_0402 LP S 25HB C30 100n_0402 VBLUE 10K_0402 R37 VBLUE I2C2_DAT DL1 510_0402 S P I_CS R34 INT_DRDY CS S P I_CLK VDDIO S CL S W3 NC R32 P US H2 VBLUE S P I_OUT 0_0402 DIO6 7 6 GND R53 100_0402 YELLOW R35 0_0402 0_0402 R36 0_0402 BLUE NC OCS INT2 VDD 11 10 9 8 5 6 7 C32 100n_0402 680_0402 DL2 RED VBLUE C31 100n_0402 VBLUE R33 DL3 UM2071 page 81/92 STEVAL-IDB009V1 schematic digrams DIO12 R41 0_0402 1 2 S DO/S A0 3 S Dx R42 4 S Cx INT1 0_0402 DIO7 680_0402 LS M6DS 3 VDDIO GND GND S P I_IN DIO14 0_0402 S DA S CL CS U7 R40 R39 R38 14 13 12 R31 1 2 RES S DA S A0 I2C2_CLK C29 100n_0402 VDD GND GND U6 3 4 5 4.7u_0603 49 NC R51 1M_0402 X1 8MHz US B_5V OS C_IN OS C_OUT NRS T VDDA VDD_3 VS S _3 P B9 P B8 BOOT0 P B7 P B6 P B5 P B4 P B3 P A15 P A14 VLCD P C13 RTC_AF1-WKUP 2 P C14-OS C32_IN P C15-OS C32_OUT P H0-OS C_IN P H1-OS C_OUT NRS T VS S A VDDA P A0-WKUP 1 P A1 P A2 20p_0402 C43 36 35 34 33 32 31 30 29 28 27 26 25 VDD_2 VS S _2 P A13 P A12 P A11 P A10 P A9 P A8 P B15 P B14 P B13 P B12 0_0402 VDD2 US BDM J TMS US BDP US BDM US ART1_RX US ART1_TX 1-2S EL 3-4S EL 2 R45 3 0_0402 I/O11 I/O12 GND VBUS I/O21 I/O22 1 2 3 4 5 DM DP SOT23-6L 6 DP 5 4 US BLC6-2S C6 GND GND GND Vcc DD+ ID GND 6 7 8 DM C33 100n_0402 GND GND GND US B micro B VDD DIO7 R47 OE 10K_0402 JTAG FOR MICRO UFQFPN48 7x7 package 128 kbyte flash 16 kbyte RAM VDD CN6 VDD1 2 4 6 8 10 J TMS J TCK J TDO J TDI US ART1_RX 1 P B2 1 U9 NRS T 13 14 15 16 17 18 19 20 21 22 23 24 RXD S P I_CS 1 S P I_CLK1 S P I_OUT1 S P I_IN1 S TM32L151CBU6 R44 US BDP P A3 P A4 P A5 P A6 P A7 P B0 P B1 P B2 P B10 P B11 VS S _1 VDD_1 TXD1 1 2 3 4 5 6 7 8 9 10 11 12 GND OS C_OUT VLCD CN5 11 10 9 R43 OS C_IN 48 47 46 45 44 43 42 41 40 39 38 37 U8 VDD USB C42 20p_0402 J TDO J TDI J TCK MICRO VDD3 UM2071 - Rev 14 Figure 62. STEVAL-IDB009V1 board schematic (part 3) 1 3 5 7 9 JP3 RES ETN 2 100n_0402 100n_0402 C39 1u_0402 C40 100n_0402 U11 R46 10K_0402 VDD 1-2S EL C45 100n_0402 LEVEL TRANSLATOR VBLUE TXD S P I_CS 1/RXD DIO7 10K_0402 S P I_CLK VDD U10 Vl I/OVl1 I/OVcc2 I/OVl3 I/OVcc4 I/OVl5 I/OVcc6 I/OVl7 I/OVcc8 Gnd R64 Vcc I/OVcc1 I/OVl2 I/OVcc3 I/OVl4 I/OVcc5 I/OVl6 I/OVcc7 I/OVl8 OE S T2378E 20 19 18 17 16 15 14 13 12 11 1 2 3 4 1S 2 Vcc 1-2S EL 2S 1 R59 0_0402 S TG3692 S P I_CLK1 RXD TXD1 P B2 OE R50 10k_0402 TP 1 GND TP 2 GND TP 3 GND S P I_IN1 R62 S P I_IN 0_0402 4S 1 GND 3-4S EL 3S 2 12 11 10 9 3-4S EL R57 10K_0402 R63 10K_0402 S P I_OUT1 S P I_OUT V1 V2 V3 V4 R60 0_0402 R56 10K_0402 UM2071 page 82/92 STEVAL-IDB009V1 schematic digrams 1 2 3 0_0402 4 5 R49 0_0402 6 7 R52 8 9 0_0402 10 R48 R58 10K_0402 S P I_CS 1 C41 1u_0402 16 15 14 13 C37 100n_0402 VDD3 VDDA C38 S P I_CS 1/RXD R61 0_0402 D1 1S 1 4S 2 D4 100n_0402 3 VDD C36 VDD VDD VDD2 1-2SEL=3-4SEL=H => SPI CONNECTED TO THE BLUENRG-2 1-2SEL=3-4SEL=L => SPI NOT CONNECTED TO THE BLUENRG-2 D2 2S 2 3S 1 D3 C35 VDD VDD1 Male Connector 2x5 5 6 7 8 VDD VLCD CONN US ART1_TX US ART UM2071 Revision history Table 10. Document revision history Date Version Changes 06-Jun-2016 1 Initial release. 08-Nov-2016 2 Added Section 11: "BlueNRG-1 sensor profile central demo" and description for ADC DMA, PDM and MFT timers. 23-Dec-2016 3 Updated STEVAL-IDB007V1 development platform and STEVAL-IDB007V1 board components. 27-Jun-2017 4 Updated: Figure 10: "BLE demonstration and test applications", and Section 18.9: " SPI examples ". Added: Section 16: "BLE security demonstration applications", Section 17: "BLE power consumption demo application", Section 18.6: "Public Key Accelerator (PKA) demonstration application" and Section 18.7: "RNG examples". Added reference to BlueNRG-2 device and related SW components. Add reference to STEVAL-IDB008V1 kit and related schematics pictures. 17-Oct-2017 5 Added reference to BlueNRG-1-V1 DK SW package supporting BLE stack v1.x family. 17-Jan-2018 6 Added references to STEVAL-IDB007V2, STEVAL-IDB008V2 platforms and related schematics. 08-Jun-2018 7 Updated Figure 7. BlueNRG-1 Navigator, Figure 8. BLE Beacon application, Figure 9. BLE Beacon Flash programming, Figure 11. Basic examples, Figure 12. BLE demonstration and test applications, Figure 13. Peripherals driver examples, Figure 15. STEVAL-IDB007V2 kit components, Figure 16. BlueNRG-1 radio parameters wizard, Section 5.1 Software directory structure, Section 6.1.3 Entering non-connectable mode , Section 13.2 BLE bidirectional throughput scenario, Section 18.9 RTC examples , Section 18.13 UART examples and Section 19 Schematic diagrams. Added Section 2.11 Integrated balun with matching network and harmonics filter, Section 3.1.4 BlueNRG-1 Navigator ‘2.4 GHz radio proprietary examples’, Section 17 BLE master and slave multiple connection demonstration application, Section 17.1 Application roles, Section 17.1.1 Master_Slave device role and Section 18.7 2.4 GHz radio proprietary examples. Removed BlueNRG-1 Flasher utility section. Throughout document added references to the STEVAL-IDB009V1 platform (BlueNRG-2 QFN48 package). 20-Nov-2018 8 Added Section 1 Development platforms, Figure 57. STEVAL-IDB009V1 schematic (1 of 3), Figure 58. STEVAL-IDB009V1 schematic (2 of 3), Figure 59. STEVAL-IDB009V1 schematic (3 of 3), Section 19 BLE Controller Privacy demonstration application and Section 19.1 Application scenario. Updated Introduction, Section 2.1 Kit contents, Section 3.1 STEVAL-IDB007Vx/STEVALIDB008Vx/ STEVAL-IDB009Vx board overview, Section 3.2 BlueNRG-1, BlueNRG-2 SoC connections, Section 20.7 2.4 GHz radio proprietary examples and Section 20.12 Timers examples. 08-Jan-2019 9 20-Mar-2019 10 10-Mar-2020 11 Updated reference to Start menu folder. Updated Section 3.5 Sensors. Removed references to BlueNRG-1-V1 DK SW package. Updated Section 2.2 System requirements, Figure 9. BlueNRG-1 Navigator, Figure 13. Basic examples, Figure 16. 2.4 GHz radio proprietary examples, Section 5 BlueNRG-X Radio Init Parameters Wizard, Section 5.1 How to run, Section 5.2 Main user interface window and Section 6.1 Software directory structure. Added Section 7.2 BLE Beacon FreeRTOS example. Throughout document: 03-Jun-2020 12 - added content and references relating to the STEVAL-IDB008V1M platform - minor text edits 04-May-2021 13-Oct-2021 13 Updated Section 3.12 Current measurements. 14 Updated Section 6 Programming with BlueNRG-1, BlueNRG-2 system on chip, Section 11 BLE sensor profile demo, Section 12 BLE sensor profile central demo, Figure 13. BLE Beacon documentation, Figure 15. BLE demonstration and test applications, Figure 17. 2.4 GHz radio proprietary examples and Figure 19. BlueNRG-X Radio Init Parameters Wizard. Added Section 20 BLE sync demo application. Added references to WiSE-Studio GCC toolchain and removed references to Atollic True Studio. UM2071 - Rev 14 page 83/92 UM2071 Date Version Changes Renamed chat demonstration applications as serial port. UM2071 - Rev 14 page 84/92 UM2071 Contents Contents 1 Development platforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 2 Getting started . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5 3 4 2.1 Kit contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.2 System requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.3 BlueNRG-1_2 development kit setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Hardware description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 3.1 STEVAL-IDB007Vx/STEVAL-IDB008Vx/STEVAL-IDB009Vx board overview. . . . . . . . . . . . . 6 3.2 BlueNRG-1, BlueNRG-2 SoC connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 3.3 Power supply . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 3.4 Jumpers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 3.5 Sensors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 3.6 Extension connector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 3.7 Push-buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 3.8 JTAG connector. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 3.9 LEDs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 3.10 STM32L151CBU6 microcontroller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 3.11 Integrated balun with matching network and harmonics filter . . . . . . . . . . . . . . . . . . . . . . . . . 12 3.12 Current measurements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 3.13 Hardware setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 BlueNRG-1, BlueNRG-2 Navigator. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .13 4.1 4.2 BlueNRG-1 Navigator ‘Demonstration Applications’ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 4.1.1 BlueNRG-1 Navigator ‘Basic examples’ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 4.1.2 BlueNRG-1 Navigator ‘BLE demonstration and test applications’ . . . . . . . . . . . . . . . . . . . 15 4.1.3 BlueNRG-1 Navigator ‘Peripherals driver examples’ . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 4.1.4 BlueNRG-1 Navigator ‘2.4 GHz radio proprietary examples’ . . . . . . . . . . . . . . . . . . . . . . 16 BlueNRG-1 Navigator ‘Development Kits’ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 4.2.1 5 6 BlueNRG-X Radio Init Parameters Wizard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .18 5.1 How to run . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 5.2 Main user interface window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 Programming with BlueNRG-1, BlueNRG-2 system on chip . . . . . . . . . . . . . . . . . . . . . . . .19 6.1 7 BlueNRG-1 Navigator ‘Release Notes’ and ‘License’ . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 Software directory structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 BLE beacon demonstration application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .20 7.1 UM2071 - Rev 14 BLE Beacon application setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 page 85/92 UM2071 Contents 7.2 8 Define advertising data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 7.1.3 Entering non-connectable mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 BLE Beacon FreeRTOS example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 Peripheral and central device setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 8.1.1 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 8.1.2 Add service and characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 8.1.3 Enter connectable mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 8.1.4 Connection with central device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 BLE serial port master and slave roles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 9.1.1 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 9.1.2 Add service and characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 9.1.3 Start discovery procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 9.1.4 Enter connectable mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 9.1.5 Connection with serial port master and slave client device . . . . . . . . . . . . . . . . . . . . . . . . 26 BLE remote control demo application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .27 10.1 11 7.1.2 BLE serial port master and slave demo application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25 9.1 10 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 BLE serial port demo application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .22 8.1 9 7.1.1 BLE remote control application setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 10.1.1 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 10.1.2 Define advertising data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 10.1.3 Add service and characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 10.1.4 Connection with a BLE Central device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 BLE sensor profile demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29 11.1 BLE sensor profile demo: connection with a central device. . . . . . . . . . . . . . . . . . . . . . . . . . . 29 11.1.1 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 11.1.2 Add service and characteristics. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 11.1.3 Enter connectable mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 11.1.4 Connection with central device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 12 BLE sensor profile central demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .31 13 BLE HID/HOGP demonstration application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .32 14 13.1 BLE HID/HOGP mouse demonstration application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 13.2 BLE HID/HOGP keyboard demonstration application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 BLE throughput demonstration application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .33 14.1 BLE unidirectional throughput scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 14.2 BLE bidirectional throughput scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 UM2071 - Rev 14 page 86/92 UM2071 Contents 15 BLE notification consumer demonstration application. . . . . . . . . . . . . . . . . . . . . . . . . . . . .34 16 BLE security demonstration applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .35 16.1 Peripheral device. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 16.2 Central device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 17 BLE power consumption demo application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37 18 BLE master and slave multiple connection demonstration application . . . . . . . . . . . . .38 18.1 19 Master_Slave device role . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 18.1.2 Master role . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 Application scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 BLE sync demo application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .40 20.1 21 18.1.1 BLE Controller Privacy demonstration application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .39 19.1 20 Application roles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 Application scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 BlueNRG-1, BlueNRG-2 peripheral driver examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .41 21.1 ADC examples. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 21.2 Flash example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 21.3 GPIO examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 21.4 I²C examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 21.5 Micro examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 21.6 Public Key Accelerator (PKA) demonstration application. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 21.7 2.4 GHz radio proprietary examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 21.8 RNG examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 21.9 RTC examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 21.10 SPI examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 21.11 SysTick examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 21.12 Timers examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 21.13 UART examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 21.14 WDG examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 22 Schematic diagrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .47 22.1 STEVAL-IDB007V1 schematic digrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 22.2 STEVAL-IDB007V2 schematic digrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 22.3 STEVAL-IDB008V1 schematic digrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 22.4 STEVAL-IDB008V2 schematic digrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 22.5 STEVAL-IDB008V1M schematic digrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 22.6 STEVAL-IDB009V1 schematic digrams . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80 UM2071 - Rev 14 page 87/92 UM2071 Contents Revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .83 UM2071 - Rev 14 page 88/92 UM2071 List of figures List of figures Figure 1. Figure 2. Figure 3. Figure 4. Figure 5. Figure 6. Figure 7. Figure 8. Figure 9. Figure 10. Figure 11. Figure 12. Figure 13. Figure 14. Figure 15. Figure 16. Figure 17. Figure 18. Figure 19. Figure 20. Figure 21. Figure 22. Figure 23. Figure 24. Figure 25. Figure 26. Figure 27. Figure 28. Figure 29. Figure 30. Figure 31. Figure 32. Figure 33. Figure 34. Figure 35. Figure 36. Figure 37. Figure 38. Figure 39. Figure 40. Figure 41. Figure 42. Figure 43. Figure 44. Figure 45. Figure 46. Figure 47. Figure 48. Figure 49. Figure 50. Figure 51. Figure 52. Figure 53. UM2071 - Rev 14 STEVAL-IDB007V1 development platform . . . . . . . . . . . . STEVAL-IDB007V2 development platform . . . . . . . . . . . . STEVAL-IDB008V1 development platform . . . . . . . . . . . . STEVAL-IDB008V2 development platform . . . . . . . . . . . . STEVAL-IDB009V1 development platform . . . . . . . . . . . . STEVAL-IDB008V1M development platform . . . . . . . . . . . STEVAL-IDB007Vx board components . . . . . . . . . . . . . . STEVAL-IDB008Vx board components . . . . . . . . . . . . . . STEVAL-IDB009V1 board components . . . . . . . . . . . . . . BlueNRG-1 Navigator . . . . . . . . . . . . . . . . . . . . . . . . . . BLE Beacon application. . . . . . . . . . . . . . . . . . . . . . . . . BLE Beacon Flash programming. . . . . . . . . . . . . . . . . . . BLE Beacon documentation . . . . . . . . . . . . . . . . . . . . . . Basic examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . BLE demonstration and test applications . . . . . . . . . . . . . Peripherals driver examples . . . . . . . . . . . . . . . . . . . . . . 2.4 GHz radio proprietary examples . . . . . . . . . . . . . . . . STEVAL-IDB007V2 kit components. . . . . . . . . . . . . . . . . BlueNRG-X Radio Init Parameters Wizard . . . . . . . . . . . . BLE serial port client . . . . . . . . . . . . . . . . . . . . . . . . . . . BLE serial port server . . . . . . . . . . . . . . . . . . . . . . . . . . BLE sensor demo GATT database . . . . . . . . . . . . . . . . . STEVAL-IDB007V1 Arduino connectors. . . . . . . . . . . . . . STEVAL-IDB007V1 JTAG . . . . . . . . . . . . . . . . . . . . . . . STEVAL-IDB007V1 BlueNRG-1 . . . . . . . . . . . . . . . . . . . STEVAL-IDB007V1 power management, sensors . . . . . . . STEVAL-IDB007V1 buttons and LEDs . . . . . . . . . . . . . . . STEVAL-IDB007V1 micro . . . . . . . . . . . . . . . . . . . . . . . STEVAL-IDB007V1 USB, level translator, JTAG for micro. . STEVAL-IDB007V1 switch . . . . . . . . . . . . . . . . . . . . . . . STEVAL-IDB007V2 - scheme 1 . . . . . . . . . . . . . . . . . . . STEVAL-IDB007V2 - scheme 2 . . . . . . . . . . . . . . . . . . . STEVAL-IDB007V2 - scheme 3 . . . . . . . . . . . . . . . . . . . STEVAL-IDB008V1 circuit schematic - JTAG . . . . . . . . . . STEVAL-IDB008V1 circuit schematic - Arduino connectors. STEVAL-IDB008V1 circuit schematic - BlueNRG-2 . . . . . . STEVAL-IDB008V1 circuit schematic - buttons and LEDS . STEVAL-IDB008V1 circuit schematic - sensors. . . . . . . . . STEVAL-IDB008V1 circuit schematic - power management STEVAL-IDB008V1 circuit schematic - JTAG for MCU . . . . STEVAL-IDB008V1 circuit schematic - USB . . . . . . . . . . . STEVAL-IDB008V1 circuit schematic - test points . . . . . . . STEVAL-IDB008V1 circuit schematic - switch . . . . . . . . . . STEVAL-IDB008V1 circuit schematic - microcontroller . . . . STEVAL-IDB008V1 circuit schematic - level translator . . . . STEVAL-IDB008V2 - JTAG . . . . . . . . . . . . . . . . . . . . . . STEVAL-IDB008V2 - Arduino connection . . . . . . . . . . . . STEVAL-IDB008V2 circuit schematic . . . . . . . . . . . . . . . STEVAL-IDB008V2 - power managements. . . . . . . . . . . . STEVAL-IDB008V2 - SENSORs . . . . . . . . . . . . . . . . . . . STEVAL-IDB008V2 - buttons and leds . . . . . . . . . . . . . . . STEVAL-IDB008V2 - micro . . . . . . . . . . . . . . . . . . . . . . STEVAL-IDB008V2 - USB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 . 2 . 2 . 3 . 3 . 4 . 6 . 7 . 7 13 14 14 15 15 16 16 17 17 18 24 24 29 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 63 64 64 64 65 66 67 68 69 70 71 72 73 74 75 page 89/92 UM2071 List of figures Figure 54. Figure 55. Figure 56. Figure 57. Figure 58. Figure 59. Figure 60. Figure 61. Figure 62. UM2071 - Rev 14 STEVAL-IDB008V2 - JTAG for micro . . . . . . . . STEVAL-IDB008V2 - level translator . . . . . . . . STEVAL-IDB008V2 - Switch . . . . . . . . . . . . . . STEVAL-IBD008V1M circuit schematic (1 of 3) . STEVAL-IBD008V1M circuit schematic (2 of 3) . STEVAL-IBD008V1M circuit schematic (3 of 3) . STEVAL-IDB009V1 board schematic . . . . . . . . STEVAL-IDB009V1 board schematic (part 2) . . STEVAL-IDB009V1 board schematic (part 3) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 76 76 77 78 79 80 81 82 page 90/92 UM2071 List of tables List of tables Table 1. Table 2. Table 3. Table 4. Table 5. Table 6. Table 7. Table 8. Table 9. Table 10. STEVAL-IDB007Vx/STEVAL-IDB008Vx/STEVAL-IDB009Vx board component descriptions . . BlueNRG-1, BlueNRG-2 pins description with board functions . . . . . . . . . . . . . . . . . . . . . . . STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx kit platform power supply modes STEVAL-IDB007Vx, STEVAL-IDB008Vx, STEVAL-IDB009Vx kit platform jumpers . . . . . . . . . BlueNRG-1 Beacon advertising manufacturing data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Serial port configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . BLE remote advertising data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . BLE security demonstration applications security configurations combinations . . . . . . . . . . . . Peripheral device advertising local name parameter value. . . . . . . . . . . . . . . . . . . . . . . . . . Document revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . UM2071 - Rev 14 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 . 8 10 11 20 22 27 35 35 83 page 91/92 UM2071 IMPORTANT NOTICE – PLEASE READ CAREFULLY STMicroelectronics NV and its subsidiaries (“ST”) reserve the right to make changes, corrections, enhancements, modifications, and improvements to ST products and/or to this document at any time without notice. Purchasers should obtain the latest relevant information on ST products before placing orders. ST products are sold pursuant to ST’s terms and conditions of sale in place at the time of order acknowledgement. Purchasers are solely responsible for the choice, selection, and use of ST products and ST assumes no liability for application assistance or the design of Purchasers’ products. No license, express or implied, to any intellectual property right is granted by ST herein. Resale of ST products with provisions different from the information set forth herein shall void any warranty granted by ST for such product. ST and the ST logo are trademarks of ST. For additional information about ST trademarks, please refer to www.st.com/trademarks. All other product or service names are the property of their respective owners. Information in this document supersedes and replaces information previously supplied in any prior versions of this document. © 2021 STMicroelectronics – All rights reserved UM2071 - Rev 14 page 92/92
STEVAL-IDB007V1 价格&库存

很抱歉,暂时无法提供与“STEVAL-IDB007V1”相匹配的价格&库存,您可以联系我们找货

免费人工找货