Dear all.
Is it possible to read the connected peer address in ReadAttrCB?
Regards.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Dear all.
Is it possible to read the connected peer address in ReadAttrCB?
Regards.
Hi Joao,
I am forwarding this question to an expert now. In the meantime, I would recommend reviewing the SimpleLink Academy Section on custom profile, as well as the API reference.
SLA Custom Profile - dev.ti.com/.../node
Best,
Nate
Hi Nathan
Thank for your awnser.
Normally I use below line of code inside read callback function but stop the application.
linkDBItem_t *link = linkDB_Find(connHandle);
Regards.
Hi Joao,
Generally speaking, the function linkDB_GetInfo can achieve what you want. Please review our examples (simple_peripheral and simple_central for details on it usage). However, I am not use you can call this function in a _ReadAttrCB callback context.
One alternative option, could be to locally store the address of all the peers and use this instead.
I hope this will help,
Best regards,
Hi Clement.
I try to explain my application more.
In my application in cc2652 it will only connect with cell phones, but it can connect with one or more cell phones. The device uses the limit. In my application there are two types of user, admin users and normal users.
Admin users will be able to read and write to some resources, but normal users will not. So I need to check if that user is admin. I save the admin users address in memory and I want to check their address when I get a read request. You suggest something to implement this feature. Is it possible to implement a serial port with ble?
Is it possible to implement this with resources with authorization permission? If yes, can you explain how?
Regards
Hi Joao
Sorry for late respond, could you show me the error occurred when you try to use linkDB_GetInfo?
Did you follow project_zero (ti.com) when you configure that?