cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 4 MCU

Contributor II

I have a BLE service that's used for debug and I don't want it to show up in release builds.  Is there a way of either disabling it for debug builds or for programmatically getting rid of it before I start advertising?

I can't find anything like that in the documentation, but I'm hoping I'm just missing something.

0 Likes
Reply
1 Solution
Employee

Hello,

Can you have a look at the function CyBle_GattsDisableAttribute().

This function disables the attribute entry for service or characteristic logical group in the GATT database registered

in the BLE Stack.

Thanks,

Hima

View solution in original post

0 Likes
Reply
3 Replies
Employee

Hello,

Can you have a look at the function CyBle_GattsDisableAttribute().

This function disables the attribute entry for service or characteristic logical group in the GATT database registered

in the BLE Stack.

Thanks,

Hima

View solution in original post

0 Likes
Reply
Contributor II

HimaM_31

This works almost perfectly.  I'm calling CyBle_GattsDisableAttribute() with the handle of the secondary service I want to disable.  When I discover services, the characteristics from the secondary service are gone, but the service is still there.  I can work with that, but it would be even better if the service itself was no longer visible.  Is there any way to accomplish that?

Thanks.

0 Likes
Reply
Employee

Hello,

There is a GATT "Service Changed" indication which can be sent. Can you please try using the same.

Thanks,

Hima

0 Likes
Reply