Impossible to pair Apple Wireless Keyboard (A1016) after update to Monterey 12.0.1
I have trouble pairing again my white Apple Wireless Keyboard (2003) (S/N M9270LL/A or A1016) to my 15-inch 2016 MacBook Pro after update to Monterey 12.0.1. Here is how the problem unfolds:
- Device turned on and in 'Discovery' mode, it appears in the 'Bluetooth' panel in 'System Preferences', in the list of unpaired devices.
- By clicking on 'Connect' button, nothing happens until 'Return' key is pressed.
- Then, the panel indicating the 6-digit 'Passkey' appears and then immediately disappears.
- If no key is pressed though, the panel never appears and pairing simply fails; then the Connect button is clickable again within approximately 20 seconds.
- Device status in BT panel then indicates 'Passkey doesn't match' (as I was unable to enter the passkey anyway).
I have tried turning Bluetooth off and on, rebooting Mac and reseting SMC+PRAM countless times, as well as replacing the batteries. Since I own two of these I tried with both and the problem is exactly the same. The two worked seamlessly on that computer before the update. I haven't got another computer to test them on unfortunately. My other BT peripherals connect fine to that same computer.
Please note that I was unable to reset the Bluetooth module or delete all devices since these options don't seem to be present anymore by opening Bluetooth menu in Menu Bar while pressing alt+shift after update to Monterey, sadly.
I also tried pairing using blueutil in Terminal however it's the same problem: nothing happens until I press return. As soon as I press return, pairing immediately fails without giving me the opportunity to enter the passcode. If I try to enter the 6-digit code then return, it does the same as it doesn't recognize the passcode I entered. Here is the error messages:
alexis@macbook-pro ~ % blueutil --pair 00-0a-95-45-9b-58 123123
Input pin 123123 on "Apple Wireless Keyboard" (00-0a-95-45-9b-58)
2021-10-31 08:44:43.900 blueutil[2637:220491] IOBluetoothDevicePair BluetoothHCIPINCodeRequestReply - 0
2021-10-31 08:44:44.466 blueutil[2637:220493] -[IOBluetoothDevicePair peerPairingCompleted:withError:]: Calling connectionComplete on IOBluetoothDevicePair. Status: 31
2021-10-31 08:44:44.470 blueutil[2637:220493] -[IOBluetoothDevicePair peerPairingCompleted:withError:]: Calling connectionComplete on IOBluetoothDevicePair. Status: 31
Failed to pair "00-0a-95-45-9b-58" with error 0x1f (Unspecified Error)
Note that the phrase "Input pin 123123 on "Apple Wireless Keyboard" doesn't appear UNTIL I press Return on the external keyboard, the terminal stays blank. If I try to enter a passcode and then press Return, it makes no difference, the passkey isn't registered. I also tried with different 6-digit codes with no result.
So to me it doesn't seem to be a problem with the UI but rather with the IOBluetooth API handling the pairing internally. I reported what seems to be a bug to Apple using the provided tool. Please help, I would like to avoid having to downgrade to Big Sur to get my external keyboard to work if possible.
Kind regards,