Hi to all,
i am developing a device with nrf51822 soc, i want to read some data from flash storage of nrf51822 then forward it on ble, i implemented a code for this job but i can not receive the data with specified connection interval, the connection parameters configured as below:
gap_conn_params.min_conn_interval = MSEC_TO_UNITS(25, UNIT_1_25_MS); gap_conn_params.max_conn_interval = MSEC_TO_UNITS(25, UNIT_1_25_MS); gap_conn_params.slave_latency = SLAVE_LATENCY; gap_conn_params.conn_sup_timeout = MSEC_TO_UNITS(1000, UNIT_1_25_MS);
as you can see the connection interval was set to 25ms, but i am receiving the data on central device with 1 packet per 50ms rate. the process is in this manner that at first i send a packet(20 byte) on notification char, and then i send next 20 byte when i received the BLE_EVT_TX_COMPLETE event. each time i receive BLE_EVT_TX_COMPLETE i try to open a record from flash storage, then i read 20 Byte from flash and then i try to close the record. and also i am using the notification charactristic to transfer data. and also when i change the connection interval to 50ms, the speed of data transfer change to one packet per 100ms.
now any can give me a advice to read 20 byte data from flash and then forward it on bluetooth on each connection interval.
thanks.