cancel
Showing results for 
Search instead for 
Did you mean: 

BlueNRG-2 IRQ problem

CBras
Associate

Hi,

I have a custom PCB based on STM32L4R9 with a SPI interface to BlueNRG-2 flashed with DTM SPI (2.1f stack). I use X-CUBE-BLE2.

I'm able to communicate with the module such as retrieve firmware details, start and stop tones. The problem I'm seeing is that the IRQ line often stays high after sending a command. The command is executed and later commands is also executed with success.

After the following code flow is excuted the IRQ is low as expected.

hci_init(NULL, NULL);
 
/* Sw reset of the device */
hci_reset();
 
aci_hal_get_firmware_details(&DTM_version_major, &DTM_version_minor, &DTM_version_patch, &DTM_variant, &DTM_Build_Number, &BTLE_Stack_version_major, &BTLE_Stack_version_minor, &BTLE_Stack_version_patch, &BTLE_Stack_development, &BTLE_Stack_variant, &BTLE_Stack_Build_Number);
 
 
aci_hal_tone_start(0, 0); // 2.402 GHz (no offset)

If I send aci_hal_tone_stop(); afterwards IRQ stays high again.

Things i noticed:

  • Inside HCI_TL_SPI_Receive, 20% of times the waiting time for IRQ to go low before raising CS ends in timeout. Why does this occur?
  • The IRQ interrupt configured to rising edge is triggered ~60 times for those few commands, I would assume 1 interrupt for 1 command send.
  • Many of the respones is a vendor specific HCI event packet with reason code 5 which from my understanding is "Reset caused by watchdog" Is this correct?

0 REPLIES 0