Hello Team Dialog,
I have written a program based on the ble_central project, which finds BLE devices with a special name or MAC address.
If a device is found, I connect to it and then I write into a characteristic.
My problem is:
Every time I try to write to the peripheral, the status is 3 (ATT_ERROR_WRITE_NOT_PERMITTED) at the Write-Completed-Event.
When I try to do it with my mobile phone via nRF Connect App, I can read and write without any problems.
Tried out as a peripheral a Raspberry Pi, my mobile phone and also a Dialog 14680.
Every time the status is 3.
printf("start write\r\n"); uint16_t * mtu = 0; ble_gattc_get_mtu(evt->conn_idx, mtu); printf("MTU Rate: %u\r\n", *mtu); uint8_t test = 0x00; printf("uuid: %s\r\n",format_uuid(&charact[0].uuid)); printf("write\r\n"); ble_gattc_write(evt->conn_idx, charact[0].handle ,false , sizeof(test) ,&test);
charact[0] contains the handler from the Characteristic.
Many thanks for the effort in advance.
Best Regards
HDR
我在DA14683的开发板上运行ble_central demo, 并且设置好了目标地址,但是没有任何反应。手机或PC的蓝牙可以连接目标外设。