Hi, DLG,
I've got the problem when connecting the peripheral(DA14580) to the Android platform (Xiaomi, MI note 3) using the 'all in one' example, the peripheral(DA14580) sometimes gets reset a few seconds after when I make the 'connetion' action on the phone. Then I've tried on the IOS platform, but it seemed no problem at all.
In the example of 'all in one', what I have made the modifications are listed as below:
1. Suit the GPIO to my board:
1.1 One Led at P02, activated at High level.
1.2 One button at P11, input High when pushed.
1.3 One PWM at P10.
1.4 Disable the I2C function in the orignial example.
2. At bottom of the 'user_app_init', power down the flash with the code: ( As such, when the device gets reset, it can be stuck at booting routine )
spi_flash_enable(SPI_EN_GPIO_PORT, SPI_EN_GPIO_PIN);
spi_flash_power_down ();
spi_release();
Then, I tried to sniff the packets over the air using sniffer: ( Continuously connect or disconnect the device through App 'nrf connect' from the phone(Xiaomi, MI note 3) )
3. The failure occured once in 5 or 6 attempts.
4. And the most of the time of the failure, when I started to connect the device from the phone, the sniffer can still and only catch the ADV_IND and SCAN_REQ/SCAN_RSP PDUs and last for over 10 seconds, then the device stuck.
5. Sometimes in these failures, the sniffer gets the CONNECT_REQ PDUs, and then the 'Feature exchange' and 'Version exchange' procedures. After that the master of the phone immediately sends out a 'LL_TERMINATE_IND' PDU with the error code 'Remote User Terminated Connection(0x13)', and later on the ADV_IND/SCAN_REQ/SCAN_RSP similar to the point 4 as described above. The packets snifferred are listed in the attachment.
Hope your help.
Description fixes:
1. In addition to the original post behind 'In the example of 'all in one', what I have made the modifications are listed as below', add 'The duration time of the Advertising is changed from 10 seconds to 120 seconds'
2. I had only make the 'connection' atcion and then the situation occurred according the description of point 5 of the original post.
嗨文究,
There are a few reasons that your device resets, so I will refer the most possible and common reasons in order to debug this.
Thanks, PM_Dialog