Hello friends, I hope you all are doing great. Today, I am going to share the new HM-10 Bluetooth LE Library for Proteus Simulation. The HM-10 is the classic Bluetooth 4.0 Low Energy serial module: a small board around a CC2541 chip that turns a UART into a wireless link. It talks to the outside world with simple AT commands - its name, its address, its role, scanning and connecting - and once two modules are connected it becomes a transparent serial cable. With this library you can run a full Proteus simulation of HM-10 modules: the AT commands and their answers, the peripheral and central roles, scanning, connecting and the data flowing between two boards.
HM-10 Bluetooth LE Library for Proteus
Latest version: V1.0 (November 2026, this tutorial)
Other wireless modules: RYLR998 LoRa · E220 LoRa · SX1278 LoRa
Helping Tools
- Serial Monitor Advance: a serial terminal window for the UART of your board
- Serial Monitor Expert: the serial monitor with extra debugging tools
- LCD Library for Proteus V3.0: 16x2, 20x4 and I2C LCDs to show your readings
Two modules on one sheet hear each other through the simulation's shared air. The demo is a Bluetooth remote: one Arduino makes its HM-10 a central, finds the lamp, connects and sends it commands; the other Arduino switches an LED and answers.
NOTICE: Our team has put a lot of effort into these small parts: the bodies, the animation and the pop-ups are all our own design, and you get them free. Your feedback is the fuel that keeps us going, so please tell us what you think in the comments below or in the Bluetooth LE board of our forum. And if our free libraries help you, you can buy us a coffee. So, let's get started with the HM-10 Bluetooth LE Library for Proteus Simulation:
What Is the HM-10 Bluetooth LE Module?
The HM-10 is a Bluetooth 4.0 Low Energy module built on the TI CC2541. On the common breakout it sits on a carrier board with a 3.3 V regulator, a status LED and a six-pin header: STATE, VCC, GND, TXD, RXD and BRK. Its firmware offers a serial service: bytes written to RXD go out over the radio, and bytes received come out of TXD. Unlike the older HC-05, which uses classic Bluetooth, the HM-10 speaks Bluetooth Low Energy - the kind phones, watches and sensors use today.
| HM-10 Bluetooth LE module | |
|---|---|
| Radio | Bluetooth 4.0 Low Energy, 2.4 GHz (CC2541) |
| Interface | UART, 9600 8N1 from the factory |
| Roles | peripheral (the factory) or central (AT+ROLE1) |
| Commands | AT commands, no line ending needed |
| Pins | STATE, VCC, GND, TXD, RXD, BRK |
| Uses | phone control, wireless sensors, links between two boards |
Peripheral and Central
Bluetooth LE has two roles. A peripheral advertises - it announces itself and waits. A central scans, picks a peripheral and connects to it. A phone is usually the central; an HM-10 leaves the factory as a peripheral. To link two HM-10s, one of them must become a central with AT+ROLE1. With AT+IMME1 the central waits for your commands instead of connecting on its own, so your sketch decides when to scan (AT+DISC?) and whom to connect to (AT+CON followed by the twelve-digit address).
AT Commands Without Line Endings
The HM-10's commands are short and need no carriage return: write "AT+NAME?" and after a moment the module answers "OK+NAME:HMSoft" - also without a line ending. That is why a sketch reads until the module goes quiet rather than until a newline. Answers can run together: a scan gives OK+DISCS, OK+DIS0:<address> for each device found and OK+DISCE in one stream, and a connection gives OK+CONNA (accepted) followed by OK+CONN (linked). With AT+NOTI1 the module also reports link changes to its board with OK+CONN and OK+LOST.
The Transparent Link and STATE
Once connected, the module stops listening for commands: everything the board writes comes out of the other module, both ways - except "AT" on its own, which cuts the link. The STATE pin shows the link at a glance: it blinks 500 ms on and 500 ms off while the module waits, and stays high while it is connected. Wire it to an input and your sketch always knows whether the other side is there.
Two Modules, One Sheet
A Proteus sheet has no radio, so the library gives its modules a shared air of their own. Every HM-10 placed on the sheet joins it: a peripheral that has finished starting up becomes visible to scans, a central that connects is paired with exactly one peripheral, and from then on the bytes written to one module come out of the other after the next connection interval. The rules are the module's own - a peripheral cannot scan, a connected module is not offered in a scan, a reset or a power cut ends the link - so a sketch that works here follows the same steps it needs on real hardware. Each module also gets its own address, either from the ADDRESS property or made from its part reference, so a scan always finds the same address.
Features of the HM-10 Bluetooth LE Library for Proteus Simulation
- A real-looking module: the 37 x 16 mm breakout at its real size, the green HM-10 core with its shield can and meander antenna, the STATE LED and the six-pin header.
- The real commands: AT, AT+NAME, AT+ADDR?, AT+ROLE, AT+IMME, AT+NOTI, AT+DISC?, AT+CON, AT+CONNL, AT+BAUD, AT+RESET, AT+RENEW, AT+VERS? and more, answered as the firmware does.
- Real links: peripherals advertise, centrals scan and connect; the link carries data both ways in packets of up to 20 bytes.
- STATE and BRK: the STATE pin and LED blink while waiting and stay high when connected; BRK held low cuts the link.
- A pop-up: the link with both modules and the AT log, the role, the state, the peer, the UART, the AT commands, the data over the air and the packets - graphs, an event log and a check page.
- A complete package: about 2.0 MB with the library, our Arduino UNO V4.0 and the two-board demo, without the source code of the model.
The HM-10 in Proteus
The device is HM10BLETEP in TEPHM10.LIB, under Modules > Bluetooth, with the prefix U and the model TEPHM10.DLL. Search HM-10 or Bluetooth in Pick Devices. Six pins on the left: STATE, VCC, GND, TXD, RXD and BRK. Three properties: BLENAME is the name it advertises at power-on, ADDRESS its twelve-digit address (blank makes one from the part reference), and BAUD its UART rate.
Download HM-10 Bluetooth LE Library for Proteus Simulation
Click the button below to download HM-10-Bluetooth-LE-Library-for-Proteus-v1.0.zip (about 2.0 MB, without the source code of the models):
HM-10 Bluetooth LE Library for Proteus V1.0- README.txt: installation, the demo, the wiring, troubleshooting and the limits of the simulation.
- Proteus Library Files:
TEPHM10.LIB,TEPLED5MM.LIB,TEPRESISTOR.LIBandArduinoV4TEP.LIB. - Proteus Model Files:
TEPHM10.DLL,TEPLED5MM.DLL,TEPRESISTOR.DLLandTEPARDUINO.DLL. - Arduino Code: the remote and lamp sketches (no Bluetooth library).
- Proteus Simulation: the demo project, its two HEX files and copies of the DLLs.
No Proteus yet? Read How to Download and Install Proteus 7 and 8. New to libraries? Follow How to Install a New Library in Proteus.
How to Install HM-10 Bluetooth LE Library for Proteus Simulation
- Close Proteus and extract the whole zip file, for example to your Desktop.
- Copy the files from Proteus Library Files into the LIBRARY folder of Proteus.
- Copy the files from Proteus Model Files into the MODELS folder.
- Delete
TEPHM10.IDXfrom the LIBRARY folder if it is there. - Start Proteus, press P and search for HM-10.
Proteus Simulation of a Bluetooth Remote
The demo uses an A3 sheet with two of our Arduino UNO Library for Proteus V4.0 boards. On the left, ARD1 is the remote with U1 (BLENAME TEPREMOTE); on the right, ARD2 is the lamp with U2 (BLENAME TEPLAMP) and an LED on D5. On both boards the module's TXD goes to D8 and RXD to D9 (AltSoftSerial), and STATE to D4. Each Arduino has its own built-in monitor, the same window as our TEP Serial Monitor Advance for Proteus. Open HM10-Remote-Lamp-ArduinoUnoV4.pdsprj.
The Sketches
Because the answers have no line ending, the remote reads until the module has been quiet for 60 ms:
if (s.length() && millis() - last > 60) break;
Then it turns its module into a central that waits for commands and reports link changes, and restarts it:
at("AT+ROLE1"); at("AT+IMME1"); at("AT+NOTI1");
A scan returns every address after "OK+DIS0:"; the sketch takes the twelve characters that follow:
const String addr = r.substring(i + 8, i + 20);
Connecting is AT+CON with that address. The sketch waits for the whole answer - OK+CONNA, then OK+CONN - because OK+CONN alone is also the start of OK+CONNA:
r = readUntil("OK+CONNAOK+CONN", 3000); // OK+CONNA (accepted), then OK+CONN (linked)
From then on, sending is just printing to the serial port:
ble.println(lamp ? F("LAMP ON") : F("LAMP OFF"));
The lamp's sketch reads lines and switches its LED; it also spots the module's own OK+CONN report, which arrives without a line ending:
if (!strcmp(s, "LAMP ON")) { digitalWrite(PIN_LAMP, HIGH); ble.println(F("LAMP IS ON")); Serial.println(F("The lamp is ON")); }
HM-10 Simulation Results
Open the project and press Run. The demo runs 12.0 simulated seconds and took about three minutes on our PC with the pop-ups open and the pictures being taken. Click either module for its pop-up. Every number below comes from one simulation run, the demo exactly as it ships.
The Start
Both modules power up as peripherals - the factory setting - and start advertising at 0.30 s, their STATE LEDs blinking. The remote's sketch then works through its commands, and each answer appears on its monitor: AT gives OK, AT+NAME? gives OK+NAME:TEPREMOTE (the BLENAME property), AT+ADDR? the module's address A4C138F2F613, and AT+ROLE1, AT+IMME1 and AT+NOTI1 each give OK+Set:1. AT+RESET answers OK+RESET; 0.3 s later the module is back, now as a central waiting for commands.
Scanning and Connecting
At 1.73 s the remote sends AT+DISC?. The module answers OK+DISCS at once and scans for 1.5 s; then come OK+DIS0:A4C138F2F7A6 - the lamp's module - and OK+DISCE, all in one run of text without line endings. The sketch finds the address after "OK+DIS0:" and sends AT+CONA4C138F2F7A6 at 3.30 s. OK+CONNA follows immediately, and at 3.70 s OK+CONN: the link is up. On the lamp's side the module tells its board OK+CONN, because the lamp's sketch turned AT+NOTI1 on, and both STATE LEDs stop blinking and stay lit.
The Link at Work
From now on the two modules are a cable. The remote sends a temperature line every second and LAMP ON or LAMP OFF every three seconds; the lamp's sketch reads them line by line, switches the LED on D5 and answers LAMP IS ON or LAMP IS OFF, which the remote prints as "The lamp says: ...". The LED comes on at 3.7 s, goes off at 6.7 s and on again at 9.7 s. The data travels in packets of up to 20 bytes, one every 20 ms - the pop-up counts them.
Later in the Run
At 12.0 s the remote's module has sent 100 bytes and received 37 over the air: twelve lines and lamp commands out, three answers in. It handled 9 AT commands, made 1 link and lost none. The lamp's pop-up shows the same link from the other side: a peripheral, connected to A4C138F2F613.
The Graphs, the Event Log and the Check Page
The Graphs page plots the bytes from and to the board, the link and the STATE pin. The Event log keeps the start, the role change, the reset, the scan and the connection. The Check page sums up the run: VCC 5.00 V, the UART at 9600 baud 8N1 with no framing error, 9 AT commands and none unknown, the central role with IMME1 and NOTI1, the link connected to A4C138F2F7A6 with 1 link and 0 cut, and the data - 100 bytes sent and 37 received, with no byte left with nowhere to go. Every line is green.
The remote's monitor shows its side: every command and answer, the lamp found, the link and the lamp's replies.
Bluetooth LE or LoRa?
Bluetooth LE is made for short distances - a room or a house - with phones and watches in mind, and it moves data quickly. For kilometres, look at our RYLR998 LoRa Module Library for Proteus: LoRa sends small messages much farther, much more slowly. Both modules turn a serial port into a wireless link, so the same sketches - write a line, read a line - fit either one.
Try It Yourself
- Change U2's BLENAME and ask it with AT+NAME? from the lamp's sketch.
- Leave out AT+ROLE1: the scan returns OK+DISCE at once - a peripheral cannot scan.
- Send "AT" from the remote after the link is up: the link is cut, and both sides print OK+LOST.
- Power the lamp down during the run: the remote loses the link and STATE starts blinking again.
- Use AT+CONNL after a reset to reconnect to the last module without scanning.
Ideas to Extend the Demo
- A remote with real buttons: one per lamp command.
- A sensor node that sends a reading only when the STATE pin says the link is up.
- Three lamps: the central scans, lists them and connects to the one you choose.
Your Own Sketches
The demo sketch is in the zip file, and you can change it in the Arduino IDE. New to Arduino? Start with our Arduino Tutorial for Beginners. Export the compiled binary, and set the UNO's PROGRAM property to the new file. Our guide on How to get the HEX file from Arduino shows you where the file ends up.
Things to Know Before Using a Real HM-10
- Logic levels: the module's RXD is 3.3 V logic - divide the 5 V from an UNO's TX.
- Clones: many cheap boards (CC41-A, MLT-BT05) answer differently - check yours with AT+VERS?.
- Phones: a phone app talks to the HM-10 through its service FFE0 and characteristic FFE1.
- Settings stick: the name, role and baud rate are stored; AT+RENEW brings back the factory settings.
- Range: about ten metres indoors - walls and bodies absorb 2.4 GHz.
Troubleshooting
- No answer to AT: TXD and RXD crossed wrong, the baud rate differs, or the module is connected (then AT cuts the link).
- AT+DISC? finds nothing: the other module is not a peripheral, already connected, or not powered.
- Data goes nowhere: the modules are not connected yet - wait for OK+CONN or a steady STATE.
- Answers look glued together: they have no line endings - read until the module is quiet, and look for whole answers.
- The part is not simulated:
TEPHM10.DLLis missing from MODELS and from the project folder.
Limitations of the Simulation
- The UART, the AT commands, the roles, scanning, connecting, the transparent link, STATE and BRK follow the module's firmware; the breakout is our own drawing.
- Our own choices: the shared air (only HM-10s on the same sheet hear each other), a 1.5 s scan, a 0.4 s connection, 20-byte packets every 20 ms and the address made from the part reference.
- Not modelled: phones and other Bluetooth devices, iBeacon, the PIO commands, the sleep modes and the signal strength.
- Arduino is a name of Arduino; this library is not made or endorsed by Arduino, Labcenter or the module's maker.
- Tested in Proteus 8.5 in November 2026 (the demo as shipped). Proteus 7 is not supported.
So, that was all about the HM-10 Bluetooth LE Library for Proteus Simulation. I hope it helps you get your roles, your commands and your link right before the first modules arrive - so that your lamp switches in the simulation before it switches from across the room. If you have any questions, ask in the comments and I will help you out. Till the next tutorial, take care and have fun!