โมดูลบลูทูธ JDY-31 SPP Bluetooth Serial Module HC-06 Compatible
Shopee

โมดูลบลูทูธ JDY-31 SPP Bluetooth Serial Module HC-06 Compatible

4.8
ขายแล้ว 1 ชิ้น 0 ครั้ง
฿85
General4_Group
แบรนด์: NoBrand
ซื้อที่ Shopee

คุณจะถูกนำไปยัง Shopee

รายละเอียดสินค้า

โมดูลบลูทูธ JDY-31 SPP Bluetooth Serial Module HC-06 Compatible

โมดูลบลูทูธ JDY-31 ขาการเชื่อมต่อจะเหมือนกับ HC-06 แต่มีข้อดีที่เหนือกว่า HC-06 ที่ใช้งานง่ายขึ้น และราคาถูกกว่า HC-06

โมดูลบลูทูธ JDY-31 เป็นโมดูล Bluetooth 3.0 SPP รองรับการใช้งานกับอุปกรณ์ Windows, Linux, Andriod สามารถรับส่งข้อมูลได้ไกลสูงสุด 30 เมตร สามารถตั้งค่าต่างๆ เช่น เปลี่ยนชื่ออุปกรณ์, ตั้งค่า baud rate หรืออื่นๆได้จาก AT Command โมดูลบลูทูธตัวนี้จะไม่รองรับการเชื่อมต่อกับอุปกรณ์ Apple ครับ

การใช้งาน JDY-31 นี้จะคล้ายกับ HC-06 ที่ไม่สามารถเป็น Master ได้เท่านั้น โมดูล JDY-31 จะเป็น AT mode โดย default เมื่อต่อไฟเข้าและไม่ได้เชื่อมต่อ Bluetooth
รายละเอียดขาของโมดูลบลูทูธ JDY-31
JDY-31 Pins Pin
Name
คำอธิบาย

1
STATE
Connection status pin (not connected low level,
output high level after connection)

2
RXD
Receiver pin, this pin must connect to TX pin of next device.

3
TXD
Transmitter pin, this pin must connect to RX pin of next device.

4
GND
GND

5
VCC
Power Supply (1.8-3.6V, 3.3v recommended)

6
EN
Enable or disable the module. When this pin is held high, the
module is enabled and begins transmitting and receiving data.



คำสั่ง AT Command Set สำหรับ JDY-31
Command
Function
Default

AT+VERSION
Version Number
JDY-31-V1.2

AT+RESET
Soft reset

AT+DISC
Disconnect (valid when connected)

AT+LADDR
Query the MAC address of the module

AT+PIN
Set or query connection password
1234

AT+BAUD
Set or query baud rate
9600

AT+NAME
Set or query broadcast name
JDY-31-SPP

AT+DEFAULT
Factory reset

AT+ENLOG
Serial port status output
1


ตัวอย่างโค้ตสำหรับโมดูลบลูทูธ JDY-31 เพื่อส่ง AT command ผ่าน Arduino IDE Serial Monitor

// Basic Bluetooth sketch HC-06_01
// Connect the Hc-06 module and communicate using the serial monitor
//
// The HC-06 defaults to AT mode when first powered on.
// The default baud rate is 9600
// The Hc-06 requires all AT commands to be in uppercase. NL+CR should not be added to the command string
//


#include
SoftwareSerial BTserial(2, 3); // RX | TX
// Connect the HC-06 TX to the Arduino RX on pin 2.
// Connect the HC-06 RX to the Arduino TX on pin 3 through a voltage divider.
//


void setup()
{
Serial.begin(9600);
Serial.println("Enter AT commands:");

// HC-06 default serial speed is 9600
BTserial.begin(9600);
}

void loop()
{
// Keep reading from HC-06 and send to Arduino Serial Monitor
if (BTserial.available())
{
Serial.write(BTserial.read());
}
// Keep reading from Arduino Serial Monitor and send to HC-06
if (Serial.available())
{
BTserial.write(Serial.read());
}
}

สินค้าที่เกี่ยวข้อง