Phone Alert Status Service Cy_BLE_PASSS_GetCharacteristicValue

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
pime_2449811
Level 1
Level 1
First question asked First reply posted

Hi,

I am using "Phone Alert Status Service" for BLE communication for my PSoC6 project.  I am trying to write 2 bytes of data to characteristic: "Ringer Control Point".  The following is the code:

uint8_t test[2]={0};

/* Read the input from the GATT database */

cy_en_ble_api_result_t m_result=Cy_BLE_PASSS_GetCharacteristicValue(CY_BLE_PASS_CP, 2, test);

if(m_result==CY_BLE_SUCCESS){

  //turn LED on

    cyhal_gpio_write((cyhal_gpio_t)CYBSP_USER_LED2, CYBSP_LED_STATE_ON);

}

If I input two bytes: e.g. 0x01 0x02 writing is not successful;  When I input one byte: e.g. 0x01, it works.  I do not understand why "Cy_BLE_PASSS_GetCharacteristicValue" fails with writing more than one byte and I'd appreciated if some one can provide a solution.

0 Likes
1 Solution
lock attach
Attachments are accessible only for community members.
Yugandhar
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 5 likes given

Hello,

Ringer control point characteristic has only one byte of data length as shown in attached image. Writing more than one byte is not possible.
Please let me know if you have any questions.

Thanks,
P Yugandhar.

View solution in original post

0 Likes
1 Reply
lock attach
Attachments are accessible only for community members.
Yugandhar
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 5 likes given

Hello,

Ringer control point characteristic has only one byte of data length as shown in attached image. Writing more than one byte is not possible.
Please let me know if you have any questions.

Thanks,
P Yugandhar.

0 Likes