How can I add a PIN authorization code to a HID bluetooth device?

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

cross mob
alli_264371
Level 4
Level 4
25 replies posted 10 replies posted 10 questions asked

I want to make an access control device based on the automatic Bluetooth connection of a smartphone. I used the example project CY8CKIT-142 HID keyboard, the device connects to the smartphone without asking for a password. How do I add one-time authorization to a smartphone using a user-entered password?


I cannot confirm email and add messages due to a bug on your site, the email section is not active
0 Likes
1 Solution
Yugandhar
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 5 likes given

Hello,

Please refer to the Day015_Bonding Code example from the GitHub. You can add this code in your project. In this example, the BLE Component requires the peer device to enter a passkey for establishing a connection for the first time. Once the connection is established, this passkey and identity information is stored and device is said to be bonded.
Once bonded, no passkey is required upon reconnection, until the bonding data is removed manually by the user.

Thanks,
P Yugandhar.

View solution in original post

0 Likes
2 Replies
Yugandhar
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 5 likes given

Hello,

Please refer to the Day015_Bonding Code example from the GitHub. You can add this code in your project. In this example, the BLE Component requires the peer device to enter a passkey for establishing a connection for the first time. Once the connection is established, this passkey and identity information is stored and device is said to be bonded.
Once bonded, no passkey is required upon reconnection, until the bonding data is removed manually by the user.

Thanks,
P Yugandhar.

0 Likes
Thanks, it looks like this is exactly what I need

I cannot confirm email and add messages due to a bug on your site, the email section is not active
0 Likes