Component guide · Intermediate · 5 min read
Ai-Thinker Ai-WB2 (BL602) Wi-Fi and BLE Modules

AT Commands and SDK
By Geekobot Learning Team · Updated 29 Oct 2026
On this page
The Ai-WB2 series uses Bouffalo Lab's BL602, a 192 MHz RISC-V chip with 2.4 GHz Wi-Fi and BLE 5. Ai-Thinker built the modules in familiar footprints: Ai-WB2-01S matches ESP-01S, Ai-WB2-12F matches ESP-12F and Ai-WB2-32S matches ESP-32S. They ship with AT firmware, so an Arduino or STM32 can add Wi-Fi over UART, or you can program them with Ai-Thinker's SDK.
Key specs at a glance
- Chip
- Bouffalo BL602, RISC-V 192 MHz, 276 KB SRAM
- Wireless
- Wi-Fi 802.11 b/g/n 2.4 GHz, BLE 5.0
- Flash
- 2 or 4 MB
- Supply
- 3.3 V
- Footprints
- 01S/01M (ESP-01 style), 07S, 12F/12S, 13/13U, 32S, M1
- Firmware
- AT commands by default
Models in this guide
These are alternatives. Pick the one that fits your project; you only need one.
Option 1AI-Thinker Ai-WB2-12F Wi-Fi & BLE 5.0 Module w/ BL602 SoC₹229
Option 2AI-Thinker Ai-WB2-12S Wi-Fi & BLE 5.0 Module₹146
Option 3AI-Thinker Ai-WB2-01S Wi-Fi & BLE 5.0 Module (BL602)₹129
Option 4AI-Thinker Ai-WB2-01M Wi-Fi & BLE 5.0 Module₹146
Option 5AI-Thinker Ai-WB2-07S Wi-Fi & BLE 5.0 Module w/ IPEX Connector₹165
Option 6AI-Thinker Ai-WB2-13 Wi-Fi & BLE 5.0 Module w/ BL602 SoC₹122
What the Ai-Thinker Ai-WB2 BL602 module is
The Ai-WB2 modules put Bouffalo Lab's BL602 RISC-V Wi-Fi and BLE chip into the same footprints as the ESP-01S, ESP-12F and ESP-32S.
The pin-compatible footprints make the Ai-WB2 a drop-in on many ESP8266 boards, but the firmware and SDK are different: Arduino ESP8266 code does not run on it. AT commands follow Ai-Thinker's own set, close to Espressif's for common tasks such as AT+WJAP (join) and socket commands.
Programming your own firmware uses Ai-Thinker's Ai-Thinker-WB2 SDK (FreeRTOS based) and a UART flasher with the BOOT pin held high.
Ai-Thinker Ai-WB2 BL602 module pinout
The pins on the Ai-Thinker Ai-WB2 BL602 module and what each one does.
| Pin | Function |
|---|---|
| VCC / GND | 3.3 V supply |
| TXD / RXD | UART0 for AT commands and flashing |
| EN | Enable, pull high |
| IO8 / BOOT | High at reset to enter download mode |
| GPIO | PWM, ADC and I2C on larger modules |
- VCC / GND
- 3.3 V supply
- TXD / RXD
- UART0 for AT commands and flashing
- EN
- Enable, pull high
- IO8 / BOOT
- High at reset to enter download mode
- GPIO
- PWM, ADC and I2C on larger modules
Wiring the Ai-Thinker Ai-WB2 BL602 module
The module is 3.3 V only; use a divider or level shifter from a 5 V Uno and a separate 3.3 V regulator.
| Ai-Thinker Ai-WB2 BL602 module pin | Arduino Uno | ESP32 |
|---|---|---|
| VCC | 3.3V from a 500 mA regulator | 3V3 |
| GND | GND | GND |
| TXD | D2 (SoftwareSerial RX) | GPIO 16 |
| RXD | D3 via divider | GPIO 17 |
| EN | 3.3V | 3V3 |
- VCC
- Arduino Uno:
- 3.3V from a 500 mA regulator
- ESP32:
- 3V3
- GND
- Arduino Uno:
- GND
- ESP32:
- GND
- TXD
- Arduino Uno:
- D2 (SoftwareSerial RX)
- ESP32:
- GPIO 16
- RXD
- Arduino Uno:
- D3 via divider
- ESP32:
- GPIO 17
- EN
- Arduino Uno:
- 3.3V
- ESP32:
- 3V3
Example code
Command names come from Ai-Thinker's Ai-WB2 AT manual; check it for TCP and MQTT commands on your firmware version.
HardwareSerial wb2(2);
void at(const char* c, int w = 1000) { wb2.println(c); delay(w); while (wb2.available()) Serial.write(wb2.read()); }
void setup() {
Serial.begin(115200);
wb2.begin(115200, SERIAL_8N1, 16, 17);
at("AT");
at("AT+GMR"); // firmware version
at("AT+WJAP=\"YOUR_WIFI\",\"YOUR_PASSWORD\"", 8000);
at("AT+WJAP?"); // connection status
}
void loop() {}Setup and tuning
supply 3.3 V that can deliver 300 mA or more, with a capacitor at the module for Wi-Fi bursts.
send AT commands at 115200 baud from an Arduino or USB-serial adapter to test Wi-Fi before custom code.
hold the boot pin high (IO8 on most modules) during reset to flash new firmware with Bouffalo's tools.
the module is 3.3 V only; use a divider on the RX line from a 5 V Arduino.
for your own firmware use the Ai-Thinker or Bouffalo SDK; it is not the ESP-IDF and Arduino support is limited.
What you need
Shop this list17 of 18 found in our store · ₹3,316
AI-Thinker Ai-WB2-12F Wi-Fi & BLE 5.0 Module w/ BL602 SoC: the part this guide coversAI-Thinker Ai-WB2-12F Wi-Fi & BLE 5.0 Module w/ BL602 SoC₹229
AI-Thinker Ai-WB2-12S Wi-Fi & BLE 5.0 Module: another version this guide coversAI-Thinker Ai-WB2-12S Wi-Fi & BLE 5.0 Module₹146
AI-Thinker Ai-WB2-01S Wi-Fi & BLE 5.0 Module (BL602): another version this guide coversAI-Thinker Ai-WB2-01S Wi-Fi & BLE 5.0 Module (BL602)₹129
AI-Thinker Ai-WB2-01M Wi-Fi & BLE 5.0 Module: another version this guide coversAI-Thinker Ai-WB2-01M Wi-Fi & BLE 5.0 Module₹146
AI-Thinker Ai-WB2-07S Wi-Fi & BLE 5.0 Module w/ IPEX Connector: another version this guide coversAI-Thinker Ai-WB2-07S Wi-Fi & BLE 5.0 Module w/ IPEX Connector₹165
AI-Thinker Ai-WB2-13 Wi-Fi & BLE 5.0 Module w/ BL602 SoC: another version this guide coversAI-Thinker Ai-WB2-13 Wi-Fi & BLE 5.0 Module w/ BL602 SoC₹122
AI-Thinker Ai-WB2-13 Wi-Fi & BLE Development Kit: another version this guide coversAI-Thinker Ai-WB2-13 Wi-Fi & BLE Development Kit₹379
AI-Thinker Ai-WB2-13U Wi-Fi & BLE 5.0 Module w/ IPEX: another version this guide coversAI-Thinker Ai-WB2-13U Wi-Fi & BLE 5.0 Module w/ IPEX₹184
AI-Thinker Ai-WB2-32S Wi-Fi & BLE 5.0 Dev Kit: another version this guide coversAI-Thinker Ai-WB2-32S Wi-Fi & BLE 5.0 Dev Kit₹409
AI-Thinker Ai-WB2-M1 Wi-Fi & BLE 5.0 Module: another version this guide coversAI-Thinker Ai-WB2-M1 Wi-Fi & BLE 5.0 Module₹116
AI-Thinker Ai-WB2-M1-I Wi-Fi & BLE Module: another version this guide coversAI-Thinker Ai-WB2-M1-I Wi-Fi & BLE Module₹110
Ai-WB2-32S Wi-Fi & BLE 5.0 Module: another version this guide coversAi-WB2-32S Wi-Fi & BLE 5.0 Module₹197
Ai-WB2-32S-Kit BL602 Wi-Fi & BT5 Module w/ 4MB Flash: another version this guide coversAi-WB2-32S-Kit BL602 Wi-Fi & BT5 Module w/ 4MB Flash₹419
USB to TTL serial converter: to talk to the module from a PCUSB to TTL Serial Converter (CH340G / CP2102 / FT232RL / PL2303)₹85Closest match, check the specs- Uno R3 development board: the controller used in the wiring tableFind this part
4-channel logic level converter (BSS138): to connect 5 V and 3.3 V signals safely4-Channel Logic Level Converter (BSS138)₹20
Breadboard power supply module 3.3V/5V: a 3.3 V supply for bare modulesBreadboard Power Supply Module (3.3V / 5V)₹71
ESP32-WROOM-32 38-pin development board: a host board with spare UARTsESP32-WROOM-32 38-Pin Development Board₹389
Alternatives and when to choose them
- BL602 and RTL8720 modules: the wider family.
- ESP-01 ESP8266: the module the 01S footprint copies.
- ESP-12F: the module the 12F footprint copies.
Common mistakes to avoid
- Expecting ESP8266 Arduino sketches to run on it.
- Powering it from an Arduino 3.3 V pin that cannot supply Wi-Fi current.
- Sending 5 V serial straight into its RX pin.
- Forgetting to hold the boot pin when flashing.
Frequently asked questions
Is the Ai-WB2 compatible with ESP8266 code?
No. It shares the footprint but not the chip, so ESP8266 and ESP32 firmware will not run on it.
Can I program it with the Arduino IDE?
Arduino support is limited. Most users use the AT firmware or the Bouffalo and Ai-Thinker SDKs.
Does it support Bluetooth?
Yes. The BL602 has BLE 5.0 as well as 2.4 GHz Wi-Fi.
Why does the module keep resetting?
Usually the 3.3 V supply sags during Wi-Fi transmit. Use a stronger regulator and a capacitor at the module.
Why choose it over an ESP-01?
It is low-cost with BLE added, but the ESP modules have far more tutorials and libraries.
Parts for this guide
Keep learning
Sources
Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.

