Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Arduino IDE demo source code for KC868-AI]--#06-KC868-AI_RS485_code
#1
[Arduino IDE demo source code for KC868-AI]--#06-KC868-AI_RS485_code

Code:
void setup() {
  // put your setup code here, to run once:
Serial2.begin(9600);
}

void loop() {
  // put your main code here, to run repeatedly:
Serial2.println("KinCony");
delay(500);
}


Attached Files
.zip   RS485.zip (Size: 420 bytes / Downloads: 269)
Reply
#2
(07-06-2022, 01:07 AM)KinCony Support Wrote: [Arduino IDE demo source code for KC868-AI]--#06-KC868-AI_RS485_code

Code:
void setup() {
  // put your setup code here, to run once:
Serial2.begin(9600);
}

void loop() {
  // put your main code here, to run repeatedly:
Serial2.println("KinCony");
delay(500);
}

the module does not work for sending via rs485 protocol. how is zero applied to the RE and DE pins MAX13487? there must be either a connection to the DI pin or control of a separate esp32 pin.


Attached Files Image(s)
   
Reply
#3
DE/RE not need to use, MAX13487 will auto control the signal direction. for ESP32 just use RXD,TXD pins is ok.
DE/RE pin just connect together with 10k resistance to Vcc is ok.
do you have define the Serial2 pin in your arduino config fle firstly?
Reply
#4
[Image: attachment.php?aid=1924]
RS485:
RXD:GPIO16
TXD:GPIO14

just replace these pin number in your config file. Because I uploaded the image is KC868-A6's RS485 pin of ESP32.
Reply
#5
(02-23-2023, 12:02 PM)admin Wrote: RS485:
RXD:GPIO16
TXD:GPIO14

just replace these pin number in your config file. Because I uploaded the image is KC868-A6's RS485 pin of ESP32.

Thank you. it works
Reply
#6
ok, good.
Reply


Forum Jump:


Users browsing this thread: