 Hands-on, pairing over poskey entry with keyboard only. In this hands-on we will do very similar thing like in the previous one. Only this time the WB will indicate that it supports keyboard only. So the mobile phone will display a six-digit number that we as a users are supposed to input on the WB side over the keyboard. In the CUBEmix the only change is to set the IO capability to keyboard only. We already have UART connection to display some application traces and we can use that also to input some values. So in the upper BLE.C we will process the event generated by BLE stack. This is the same one like we've seen before the PASCy request. And then we will wait on the UART for the user to enter the six-digit decimal number. And then we will pass it back to the BLE stack through the ACI gap PASCy response command. So in the vPan middleware we set the IO capabilities to keyboard only. That's the only change we can regenerate the project and make the small adjustment in the upper BLE.C. And here online 504 we will modify the event handler for the PASCy request which is generated by BLE stack on every pairing. First we will define an array of six integers, six unsigned integers. One for each character that we will receive over UART. So then we call HAL UART receive. We will use polling mode for simplicity. So the first parameter is the pointer to the UART structure. Next is the pointer to the data array. Then it's the number of characters that we wish to receive and a timeout in milliseconds. So let's set it to 10,000 so we have 10 seconds to enter the value. The characters are ASCII encoded so we need to convert it back into decimal by subtracting 30 in hex. And we have to do this for each character. Then we need to concatenate these numbers into single unsigned integer of size 32 bit. So I will call this variable PASCy. The first element in the array is the most significant digit. So it will be multiplied by 100,000 and the next by 10,000 etc. And then we will pass this variable via value to the PASCy response. So the C compiler doesn't usually like the definition of a variable just after label, which we can fix by adding a semicolon here. And the next thing we need to do is to define an extern variable for this UART structure. So let's put it online 227 and let's define an external variable, which is of the type UART handle type def. The variable is called UART1. So now if I compile the code I get still some errors because I misspelled extern and I get zero errors. So we can load it and make the test. So the device is now advertising. I will connect to it through STBLE toolbox and I will try to read the characteristic. A pairing message pops out and Android generates a 6 digit decimal. I will enter it and the pairing succeeds and the value is red. And this is the end of the hands-on.