关于HM10软串口BLE特性、UUID/GATT配置及硬件串口对接的技术咨询
Hey there! Let’s break down your questions clearly—since you’re new to BLE and HM10, I’ll keep things straightforward and actionable.
First off: Yes, the HM10 fully supports BLE features even when connected via software serial—the module itself is a BLE peripheral, so as long as your software serial connection is stable (correct baud rate, 3.3V level matching, no heavy CPU load), it will work normally.
To adjust UUIDs and GATT configurations, you’ll use AT commands directly over the serial link. Here’s a step-by-step guide:
- Enter AT mode: Most HM10 modules require holding the
KEYpin high during power-up, or sending a specific trigger (check your module’s datasheet if holding KEY doesn’t work). Once in mode, sendATfollowed by a carriage return—you’ll get anOKresponse if it worked. - Modify Service UUID: Use the
AT+UUID=<your-UUID>command. For example:
The module will returnAT+UUID=0000FFE0-0000-1000-8000-00805F9B34FBOKif the change is accepted. - Modify Characteristic UUID: Use
AT+CHAR=<your-characteristic-UUID>to set the UUID for the data transfer characteristic:AT+CHAR=0000FFE1-0000-1000-8000-00805F9B34FB - Save changes: Don’t forget to send
AT+SAVEto store the configuration permanently—otherwise, it’ll reset to defaults on power loss. - Pro tip: Send
AT+HELPto get a full list of supported commands, since firmware versions can vary slightly in syntax.
Bidirectional Data Transfer & BLE Mode Setup
Since you’ve been working on this for weeks, let’s simplify the workflow:
- Confirm your HM10 is in BLE mode (default for most modules, but you can force it with
AT+ROLE0to set it as a peripheral). - Enable notifications for the data characteristic with
AT+NOTI1—this lets the module push incoming serial data to your phone automatically. - Use a BLE testing app like nRF Connect on your phone: connect to the HM10’s broadcast name, find your configured characteristic, and you can send data to the module (it’ll appear on the serial port) and receive data from the serial port via notifications.
Using Hardware RX-TX Instead of Software Serial
Absolutely—this is actually highly recommended! Hardware serial (UART) is handled by dedicated hardware on your microcontroller, so it’s far more stable than software serial (which relies on CPU interrupts and can drop data under load).
To set it up:
- Connect HM10’s
TXpin to your microcontroller’sRXpin, and HM10’sRXpin to your microcontroller’sTXpin. - Critical note: HM10 uses 3.3V logic—if your microcontroller is 5V, add a level shifter between the pins to avoid damaging the module.
- Match the baud rate (default is usually 9600 or 115200; check with
AT+BAUD?if unsure).
The rest of the setup (AT commands, BLE configuration) works exactly the same as with software serial—you’ll just get more reliable data transfer.
A few quick beginner tips to save you time:
- Always test AT commands with a USB-to-serial adapter first before connecting to your microcontroller—this helps rule out wiring issues.
- Make sure your HM10 has a stable 3.3V power supply (at least 50mA current draw)—unstable power causes weird BLE connection drops.
内容的提问来源于stack exchange,提问作者Chakradhar Nakka

