กลับไปหน้ารวมไฟล์
hc-05-bluetooth-module-with-arduino-via-at-command-mode-03154c-en.md

Firmware Manipulation: HC-05 AT Command Mode

Usually, you just plug an HC-05 module into 5V and connect to it using "0000" or "1234". However, if you are building a fleet of 10 robots, you cannot have 10 identical Bluetooth modules named "HC-05"; they will cross-connect and destroy each other! The HC-05 AT Command Mode project forces you to actually hack the firmware of the Bluetooth chip itself, completely bypassing standard C++ code and dumping raw DOS-like "AT" system configurations straight into the silicon!

bluetooth_hc05_wiring_macro_1772682001936.png

The Hardware Boot-Loader Trap

You cannot send AT system commands while the module is communicating. You must "Jailbreak" its boot sequence!

  1. The EN/Key Pin Validation: When wiring the HC-05 (RX/TX) to the Arduino's SoftwareSerial pins, you also take a jumper wire from the HC-05's EN (Enable) pin and plug it directly into the 5V line.
  2. Holding that En wire HIGH WHILE plugging the Arduino into USB power forces the HC-05 chip to violently boot up in "AT COMMAND MODE." The tiny LED will blink slowly instead of rapidly!

Executing the AT String Payload

An HC-05 running in AT mode speaks a terrible speed: 38400 baud ONLY.

  • It requires the serial string entirely formatted in carriage returns.
  • Using the laptop's Arduino IDE Serial Monitor, you type raw ASCII Strings directly into the console!
  • Type: AT -> The module replies OK! (You are in!).
  • Type: AT+NAME=BattleBot_Alpha -> It completely re-programs the radio broadcast SSID!
  • Type: AT+PSWD="7788" -> The module deletes its old password and locks itself out to any smartphone not having the secure key!
  • Master/Slave Configuration: Most HC-05s are "Slaves" (Wait for a phone). You can type AT+ROLE=1 to transform it instantly into a "Master," instructing it to violently seek out and connect to other HC-05s autonomously!

Essential Radio Diagnostic Configuration

  • Arduino Uno/Nano (Any board supporting SoftwareSerial logic!).
  • HC-05 Bluetooth Module (It must be an HC-05. The deeply restricted HC-06 requires completely different pin-wiring and cannot become a Master!).
  • Standard Breadboard Jumpers (For the critical sequence of holding the EN pin high during system bootup!).

ข้อมูล Frontmatter ดั้งเดิม

title: "HC-05 Bluetooth Module with Arduino via AT Command Mode"
description: "Low-level system infiltration! Subvert standard Bluetooth radio protocols by wiring the Uno's Serial lines directly into the HC-05's core chip, deploying hardcore AT ASCII commands to manually reprogram MAC addresses and pin codes."
category: "Wireless & IoT"
difficulty: "Advanced"