The verbose dump shows that the HM10 and Pi have different ideas about the security settings. I've borrowed an HM10 module and these procedures work. There are two connection options here - No security (dead easy) and PIN code security, and then instructions for exchanging data.
NO SECURITY
Before connection. From PC UART terminal to the HM10This restores default settings which are peripheral and no security. (AT+ROLE0, AT+TYPE0)
From btferretPIN CODE SECURITY
Before connection. Over PC UARTFrom btferretREAD/WRITE data
NO SECURITY
Before connection. From PC UART terminal to the HM10
Code:
AT+RENEWAT+RESET
From btferret
Code:
b - Scan for LE devicesc - Connect - select HM10 device Enable security options = 1 Yes BONDING 0 = No PAIRING and SECURITY = 0 Do not pair CONNECTION COMPLETE TIME = 750 (but 0 seems to work)Should show: Connect OK as LE client - see READ/WRITE data
Before connection. Over PC UART
Code:
AT+RENEWAT+RESETAT+TYPE2AT+PASS123456
Code:
b - Scan for LE devicesc - Connect - select HM10 device Enable security options = 1 Yes BONDING 0 = No PAIRING and SECURITY = 2 Pair - Fixed passkey PASSKEY CHOSEN BY = 1 Remote server Fixed 6-digit passkey = 123456 CONNECTION COMPLETE TIME = 2000 PAIRING COMPLETE TIME = 2000 Should show: Connect OK as LE client
Code:
v - Read services. It should show FFE1 UUID characteristicw - Write LE characteristic - select HM10 Input ctic index = index of FFE1 UUID Input data bytes = 61 62 63 0D 0A (abc + cr/lf) abc will appear on the PC terminalj - Enable notifications - select HM10 Input ctic index = index of FFE1 UUID 1 = EnableR - Read notifications Input time out in s = 30 seconds From PC UART terminal send hello FFE1 UUID notify = 68 65 6C 6C 6F appears on Pi
Statistics: Posted by petzval — Fri Mar 28, 2025 3:22 pm