I have followed this tutorial from this link but cannot get it work.
Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
do
{
int i;
char buf[42];
for (i = 0; i < 3; i++) {
snprintf(buf,42, "A%dBBCCDDEEAABBCCDDEEAABBCCDDEEAABBCCDDXX", i);
// puts string into buffer
printf("%s\n", buf); // outputs so you can see it
APP_TIMER_DEF(buf);
app_timer_create(&buf,APP_TIMER_MODE_REPEATED, uart_event_handle);
app_timer_start(buf, APP_TIMER_TICKS(1000), NULL);
uint16_t length2 = sizeof(buf);
err_code = ble_nus_data_send(&m_nus,buf, &length2, m_conn_handle);
I have 3 loop. For the first loop of sending data it will have a delay about 1s and until 2 finish. But there is no delay and it does not work.