cancel
Showing results for 
Search instead for 
Did you mean: 

BlueNRG-2 IO6 mode selection

DrJRM
Associate

Hello ST Community,

I have the STEVAL-IDB008V1M boards to evaluate BlueNRG-2, and am working with the BLE_Sync example program contained in the BlueNRG-2 DK SW package. Would someone be kind enough to help me to understand the meaning of the signal that IO6 is being connected to in the following lines which can be found in BlueNRG-1_2 DK 3.2.3\Project\BLE_Examples\BLE_Sync\src\sync.c :

 

  // Enable Blue controller signal on GPIO6
  uint8_t i = 6;
  uint8_t mode = 3;
  MODIFY_REG(GPIO->MODE0, (0xF<<(i*4)), (mode << (i*4)) );

 

I'm puzzled firstly because the BlueNRG-2 Datasheet appears to say that each four bits of the mode register should be set to binary 0000, 0001, 0100, or 0101 which would be decimal 0, 1, 4 or 5. So I don't know what mode = 3 would do.  (I do know it isn't equivalent to 0001 because I already tried that and the example program stopped working).

DrJRM_1-1700836425248.png

And I'm puzzled secondly because I haven't figured out how any of the possible signals listed in the datasheet would be meaningful to this example.

DrJRM_0-1700835899494.png

Options appear to be UART_RTS, I2C2_CLK, or PDM_DATA.  The source code comment describes it as a "Blue controller signal" but I don't see how any of those could be described as such.

All help gratefully received!

0 REPLIES 0