Jdy40 Arduino Example - Best

void setup() Serial.begin(9600); // For debugging (optional) jdy.begin(9600);

/* * JDY-40 Simple Serial Bridge * This sketch forwards data between the JDY-40 and the Serial Monitor. * No AT commands are used – the module acts as a transparent wireless UART. */

While the HC‑05 remains one of the most popular Bluetooth modules for Arduino, the JDY‑40 offers several distinct advantages:

void setup() Serial.begin(9600); // JDY-40 default baud rate dht.begin(); jdy40 arduino example best

void loop() if (jdy.available()) String msg = jdy.readString(); Serial.print("Received: "); Serial.println(msg);

Note: Both modules must have the exact same RFID string to talk to each other. AT+DVID5566 Note: Both modules must share the same DVID. Reset Module: AT+RESET Part 2: Best Two-Way Transparent Communication Example

void loop() if (bluetooth.available() > 0) char data = bluetooth.read(); Serial.print("Received: "); Serial.println(data); void setup() Serial

Note: After configuring both modules with identical settings, remove the SET-to-GND connection, then power cycle the modules to return to communication mode. 5. Troubleshooting & Pro-Tips

Unlike traditional Bluetooth modules that require pairing protocols, the JDY-40 allows devices to communicate immediately as long as they share the same channel and device ID. Hardware Connection: JDY-40 to Arduino

This approach gives you a flexible, low‑cost wireless network for up to 999 nodes (IDs 001–999). Keep in mind that all nodes must share the same RF channel; only the ID distinguishes them. AT+DVID5566 Note: Both modules must share the same DVID

But in practice, many people connect directly and it works fine. For this tutorial, I’ll show the direct method with a warning.

After setting AT+RFNETID , the modules automatically pair. No need for AT+LINK or address targeting. This is transparent broadcasting — anything one sends, all receive.

Supports transparent serial transmission, IO switching, and remote control

21 Total Ratings with 5.00/5 possible Rating Points. Unblock UK Telly