<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title><![CDATA[Smart Home Automation Forum - MT4]]></title>
		<link>https://www.kincony.com/forum/</link>
		<description><![CDATA[Smart Home Automation Forum - https://www.kincony.com/forum]]></description>
		<pubDate>Mon, 27 Jul 2026 08:18:59 +0000</pubDate>
		<generator>MyBB</generator>
		<item>
			<title><![CDATA[[arduino code examples for MT4]-06 IR receiver decode]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9614</link>
			<pubDate>Sat, 11 Jul 2026 10:21:10 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9614</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * SimpleReceiver.cpp<br />
 *<br />
 * Demonstrates receiving ONLY NEC protocol IR codes with IRremote<br />
 * If no protocol is defined, all protocols (except Bang&amp;Olufsen) are active.<br />
 *<br />
 *  This file is part of Arduino-IRremote https://github.com/Arduino-IRremote/Arduino-IRremote.<br />
 *<br />
 ************************************************************************************<br />
 * MIT License<br />
 *<br />
 * Copyright (c) 2020-2025 Armin Joachimsmeyer<br />
 *<br />
 * Permission is hereby granted, free of charge, to any person obtaining a copy<br />
 * of this software and associated documentation files (the "Software"), to deal<br />
 * in the Software without restriction, including without limitation the rights<br />
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell<br />
 * copies of the Software, and to permit persons to whom the Software is furnished<br />
 * to do so, subject to the following conditions:<br />
 *<br />
 * The above copyright notice and this permission notice shall be included in all<br />
 * copies or substantial portions of the Software.<br />
 *<br />
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,<br />
 * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A<br />
 * PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT<br />
 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF<br />
 * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE<br />
 * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.<br />
 *<br />
 ************************************************************************************<br />
 */<br />
<br />
#include &lt;Arduino.h&gt;<br />
#include &lt;IRremote.hpp&gt; // include the library<br />
<br />
uint8_t sender_pins[] = {47, 48};<br />
uint8_t receiver_pin = 15;<br />
<br />
int sender_pin_num = sizeof(sender_pins) / sizeof(sender_pins[0]);<br />
uint8_t sender_pin_idx = 0;<br />
uint8_t receive_cnt = 0;<br />
uint8_t sCommand = 0x34;<br />
uint8_t sRepeats = 0;<br />
<br />
void setup() {<br />
    Serial.begin(115200);<br />
    IrReceiver.begin(receiver_pin, false);<br />
    IrSender.begin(sender_pins[0]);<br />
<br />
    xTaskCreate(<br />
      sendIr,    // Function that should be called<br />
      "Send IR", &nbsp;&nbsp;// Name of the task (for debugging)<br />
      4096,            // Stack size (bytes)<br />
      NULL,            // Parameter to pass<br />
      1,             &nbsp;&nbsp;// Task priority<br />
      NULL           &nbsp;&nbsp;// Task handle<br />
  );<br />
}<br />
<br />
void sendIr(void * parameter) {<br />
  <br />
  delay(2000);<br />
  IrSender.setSendPin(47);<br />
  IrSender.sendNEC(0x00, sCommand, sRepeats);<br />
  Serial.printf("send by pin: %d&#92;n", 47);<br />
  delay(2000);<br />
<br />
  IrSender.setSendPin(48);<br />
  IrSender.sendNEC(0x00, sCommand, sRepeats);<br />
  Serial.printf("send by pin: %d&#92;n", 48);<br />
<br />
  delay(2000);<br />
  vTaskDelete(NULL);<br />
}<br />
<br />
void loop() {<br />
  if (IrReceiver.decode()) {<br />
      Serial.println("recv data");<br />
      if (IrReceiver.decodedIRData.protocol == UNKNOWN) {<br />
          Serial.println(F("Received noise or an unknown (or not yet enabled) protocol"));<br />
          // We have an unknown protocol here, print extended info<br />
          IrReceiver.printIRResultRawFormatted(&amp;Serial, true);<br />
<br />
          IrReceiver.resume(); // Do it here, to preserve raw data for printing with printIRResultRawFormatted()<br />
      } else {<br />
          IrReceiver.resume(); // Early enable receiving of the next IR frame<br />
<br />
          IrReceiver.printIRResultShort(&amp;Serial);<br />
          IrReceiver.printIRSendUsage(&amp;Serial);<br />
      }<br />
  } else {<br />
    // Serial.println("no data");<br />
  }<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10200" target="_blank" title="">SimpleSendReceiver.zip</a> (Size: 1.62 KB / Downloads: 53)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10201" target="_blank" title="">SimpleSendReceiver.ino.merged.zip</a> (Size: 194.06 KB / Downloads: 51)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * SimpleReceiver.cpp<br />
 *<br />
 * Demonstrates receiving ONLY NEC protocol IR codes with IRremote<br />
 * If no protocol is defined, all protocols (except Bang&amp;Olufsen) are active.<br />
 *<br />
 *  This file is part of Arduino-IRremote https://github.com/Arduino-IRremote/Arduino-IRremote.<br />
 *<br />
 ************************************************************************************<br />
 * MIT License<br />
 *<br />
 * Copyright (c) 2020-2025 Armin Joachimsmeyer<br />
 *<br />
 * Permission is hereby granted, free of charge, to any person obtaining a copy<br />
 * of this software and associated documentation files (the "Software"), to deal<br />
 * in the Software without restriction, including without limitation the rights<br />
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell<br />
 * copies of the Software, and to permit persons to whom the Software is furnished<br />
 * to do so, subject to the following conditions:<br />
 *<br />
 * The above copyright notice and this permission notice shall be included in all<br />
 * copies or substantial portions of the Software.<br />
 *<br />
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,<br />
 * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A<br />
 * PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT<br />
 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF<br />
 * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE<br />
 * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.<br />
 *<br />
 ************************************************************************************<br />
 */<br />
<br />
#include &lt;Arduino.h&gt;<br />
#include &lt;IRremote.hpp&gt; // include the library<br />
<br />
uint8_t sender_pins[] = {47, 48};<br />
uint8_t receiver_pin = 15;<br />
<br />
int sender_pin_num = sizeof(sender_pins) / sizeof(sender_pins[0]);<br />
uint8_t sender_pin_idx = 0;<br />
uint8_t receive_cnt = 0;<br />
uint8_t sCommand = 0x34;<br />
uint8_t sRepeats = 0;<br />
<br />
void setup() {<br />
    Serial.begin(115200);<br />
    IrReceiver.begin(receiver_pin, false);<br />
    IrSender.begin(sender_pins[0]);<br />
<br />
    xTaskCreate(<br />
      sendIr,    // Function that should be called<br />
      "Send IR", &nbsp;&nbsp;// Name of the task (for debugging)<br />
      4096,            // Stack size (bytes)<br />
      NULL,            // Parameter to pass<br />
      1,             &nbsp;&nbsp;// Task priority<br />
      NULL           &nbsp;&nbsp;// Task handle<br />
  );<br />
}<br />
<br />
void sendIr(void * parameter) {<br />
  <br />
  delay(2000);<br />
  IrSender.setSendPin(47);<br />
  IrSender.sendNEC(0x00, sCommand, sRepeats);<br />
  Serial.printf("send by pin: %d&#92;n", 47);<br />
  delay(2000);<br />
<br />
  IrSender.setSendPin(48);<br />
  IrSender.sendNEC(0x00, sCommand, sRepeats);<br />
  Serial.printf("send by pin: %d&#92;n", 48);<br />
<br />
  delay(2000);<br />
  vTaskDelete(NULL);<br />
}<br />
<br />
void loop() {<br />
  if (IrReceiver.decode()) {<br />
      Serial.println("recv data");<br />
      if (IrReceiver.decodedIRData.protocol == UNKNOWN) {<br />
          Serial.println(F("Received noise or an unknown (or not yet enabled) protocol"));<br />
          // We have an unknown protocol here, print extended info<br />
          IrReceiver.printIRResultRawFormatted(&amp;Serial, true);<br />
<br />
          IrReceiver.resume(); // Do it here, to preserve raw data for printing with printIRResultRawFormatted()<br />
      } else {<br />
          IrReceiver.resume(); // Early enable receiving of the next IR frame<br />
<br />
          IrReceiver.printIRResultShort(&amp;Serial);<br />
          IrReceiver.printIRSendUsage(&amp;Serial);<br />
      }<br />
  } else {<br />
    // Serial.println("no data");<br />
  }<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10200" target="_blank" title="">SimpleSendReceiver.zip</a> (Size: 1.62 KB / Downloads: 53)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10201" target="_blank" title="">SimpleSendReceiver.ino.merged.zip</a> (Size: 194.06 KB / Downloads: 51)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[[arduino code examples for MT4]-05 RS485 communication test]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9613</link>
			<pubDate>Sat, 11 Jul 2026 10:19:54 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9613</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * Made by KinCony IoT: https://www.kincony.com<br />
 *<br />
 * RS485 Communication Test<br />
 *<br />
 * This program is a simple test for RS485 communication using ESP32-S3.<br />
 * It will send a message over RS485 and then read incoming messages.<br />
 * The TXD pin is defined as GPIO 16 and RXD pin is defined as GPIO 17.<br />
 */<br />
<br />
#include &lt;HardwareSerial.h&gt;<br />
<br />
// Define RS485 pins<br />
#define RS485_RXD 7<br />
#define RS485_TXD 6<br />
<br />
// Create a hardware serial object<br />
HardwareSerial rs485Serial(1);<br />
<br />
void setup() {<br />
  // Start serial communication for debugging<br />
  Serial.begin(115200);<br />
  while (!Serial);<br />
<br />
  // Initialize RS485 Serial communication<br />
  rs485Serial.begin(9600, SERIAL_8N1, RS485_RXD, RS485_TXD);<br />
  <br />
  Serial.println("RS485 Test Start");<br />
}<br />
<br />
void loop() {<br />
  // Send a test message<br />
  rs485Serial.println("Hello from KinCony");<br />
<br />
  // Wait for a short period<br />
  delay(1000);<br />
<br />
  // Check if data is available to read<br />
  if (rs485Serial.available()) {<br />
    String receivedMessage = "";<br />
    while (rs485Serial.available()) {<br />
      char c = rs485Serial.read();<br />
      receivedMessage += c;<br />
    }<br />
    // Print the received message<br />
    Serial.print("Received: ");<br />
    Serial.println(receivedMessage);<br />
  }<br />
<br />
  // Wait before sending the next message<br />
  delay(2000);<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10198" target="_blank" title="">RS485-Test.zip</a> (Size: 754 bytes / Downloads: 71)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10199" target="_blank" title="">RS485-Test.ino.merged.zip</a> (Size: 185.84 KB / Downloads: 71)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * Made by KinCony IoT: https://www.kincony.com<br />
 *<br />
 * RS485 Communication Test<br />
 *<br />
 * This program is a simple test for RS485 communication using ESP32-S3.<br />
 * It will send a message over RS485 and then read incoming messages.<br />
 * The TXD pin is defined as GPIO 16 and RXD pin is defined as GPIO 17.<br />
 */<br />
<br />
#include &lt;HardwareSerial.h&gt;<br />
<br />
// Define RS485 pins<br />
#define RS485_RXD 7<br />
#define RS485_TXD 6<br />
<br />
// Create a hardware serial object<br />
HardwareSerial rs485Serial(1);<br />
<br />
void setup() {<br />
  // Start serial communication for debugging<br />
  Serial.begin(115200);<br />
  while (!Serial);<br />
<br />
  // Initialize RS485 Serial communication<br />
  rs485Serial.begin(9600, SERIAL_8N1, RS485_RXD, RS485_TXD);<br />
  <br />
  Serial.println("RS485 Test Start");<br />
}<br />
<br />
void loop() {<br />
  // Send a test message<br />
  rs485Serial.println("Hello from KinCony");<br />
<br />
  // Wait for a short period<br />
  delay(1000);<br />
<br />
  // Check if data is available to read<br />
  if (rs485Serial.available()) {<br />
    String receivedMessage = "";<br />
    while (rs485Serial.available()) {<br />
      char c = rs485Serial.read();<br />
      receivedMessage += c;<br />
    }<br />
    // Print the received message<br />
    Serial.print("Received: ");<br />
    Serial.println(receivedMessage);<br />
  }<br />
<br />
  // Wait before sending the next message<br />
  delay(2000);<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10198" target="_blank" title="">RS485-Test.zip</a> (Size: 754 bytes / Downloads: 71)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10199" target="_blank" title="">RS485-Test.ino.merged.zip</a> (Size: 185.84 KB / Downloads: 71)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[[arduino code examples for MT4]-04 DC motor control by L298N driver chip]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9612</link>
			<pubDate>Sat, 11 Jul 2026 10:18:25 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9612</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * Language: English | Русский: ../RU/DIR_DIR_PWM/ | Қазақ: ../KZ/DIR_DIR_PWM/<br />
 *<br />
 * This code demonstrates motor control using the AlashMotorControlLite library.<br />
 * It sets different rotation speeds for the motor with delays between them.<br />
 * Code written for Alash engineering.<br />
 */<br />
#include "AlashMotorControlLite.h"<br />
// Create motor object with DIR_DIR_PWM mode and pins inA = 4, inB = 5, PWM = 6<br />
AlashMotorControlLite motor(DIR_DIR_PWM, 39, 46, 9);<br />
void setup() {<br />
}<br />
void loop() {<br />
  motor.setSpeed(100); // Set forward rotation speed<br />
  delay(3000); // Delay 3 seconds<br />
<br />
  motor.setSpeed(0); // Stop motor<br />
  delay(3000); // Delay 3 seconds<br />
<br />
  motor.setSpeed(-100); // Set reverse rotation speed<br />
  delay(3000); // Delay 3 seconds<br />
<br />
  motor.setSpeed(0); // Stop motor<br />
  delay(3000); // Delay 3 seconds<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10196" target="_blank" title="">motor.zip</a> (Size: 560 bytes / Downloads: 82)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10197" target="_blank" title="">motor.ino.merged.zip</a> (Size: 184.36 KB / Downloads: 46)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * Language: English | Русский: ../RU/DIR_DIR_PWM/ | Қазақ: ../KZ/DIR_DIR_PWM/<br />
 *<br />
 * This code demonstrates motor control using the AlashMotorControlLite library.<br />
 * It sets different rotation speeds for the motor with delays between them.<br />
 * Code written for Alash engineering.<br />
 */<br />
#include "AlashMotorControlLite.h"<br />
// Create motor object with DIR_DIR_PWM mode and pins inA = 4, inB = 5, PWM = 6<br />
AlashMotorControlLite motor(DIR_DIR_PWM, 39, 46, 9);<br />
void setup() {<br />
}<br />
void loop() {<br />
  motor.setSpeed(100); // Set forward rotation speed<br />
  delay(3000); // Delay 3 seconds<br />
<br />
  motor.setSpeed(0); // Stop motor<br />
  delay(3000); // Delay 3 seconds<br />
<br />
  motor.setSpeed(-100); // Set reverse rotation speed<br />
  delay(3000); // Delay 3 seconds<br />
<br />
  motor.setSpeed(0); // Stop motor<br />
  delay(3000); // Delay 3 seconds<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10196" target="_blank" title="">motor.zip</a> (Size: 560 bytes / Downloads: 82)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10197" target="_blank" title="">motor.ino.merged.zip</a> (Size: 184.36 KB / Downloads: 46)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[[arduino code examples for MT4]-03 Read free GPIO state]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9611</link>
			<pubDate>Sat, 11 Jul 2026 10:16:56 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9611</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
  Made by KinCony IoT: https://www.kincony.com<br />
<br />
  Monitor GPIO0, GPIO18, GPIO8<br />
  Print to Serial when state changes<br />
*/<br />
<br />
#define PIN_0 &nbsp;&nbsp;0<br />
#define PIN_18  18<br />
#define PIN_8 &nbsp;&nbsp;8<br />
<br />
int lastState0;<br />
int lastState18;<br />
int lastState8;<br />
<br />
void setup() {<br />
  Serial.begin(115200);<br />
<br />
  pinMode(PIN_0, INPUT_PULLUP);<br />
  pinMode(PIN_18, INPUT_PULLUP);<br />
  pinMode(PIN_8, INPUT_PULLUP);<br />
<br />
  lastState0  = digitalRead(PIN_0);<br />
  lastState18 = digitalRead(PIN_18);<br />
  lastState8  = digitalRead(PIN_8);<br />
<br />
  Serial.println("GPIO Monitor Started");<br />
}<br />
<br />
void loop() {<br />
<br />
  int state0 = digitalRead(PIN_0);<br />
  if (state0 != lastState0) {<br />
    Serial.print("GPIO0 changed to: ");<br />
    Serial.println(state0);<br />
    lastState0 = state0;<br />
  }<br />
<br />
  int state18 = digitalRead(PIN_18);<br />
  if (state18 != lastState18) {<br />
    Serial.print("GPIO18 changed to: ");<br />
    Serial.println(state18);<br />
    lastState18 = state18;<br />
  }<br />
<br />
  int state8 = digitalRead(PIN_8);<br />
  if (state8 != lastState8) {<br />
    Serial.print("GPIO8 changed to: ");<br />
    Serial.println(state8);<br />
    lastState8 = state8;<br />
  }<br />
<br />
  delay(10);<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10194" target="_blank" title="">Free-GPIO.zip</a> (Size: 539 bytes / Downloads: 54)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10195" target="_blank" title="">Free-GPIO.ino.merged.zip</a> (Size: 180.26 KB / Downloads: 64)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
  Made by KinCony IoT: https://www.kincony.com<br />
<br />
  Monitor GPIO0, GPIO18, GPIO8<br />
  Print to Serial when state changes<br />
*/<br />
<br />
#define PIN_0 &nbsp;&nbsp;0<br />
#define PIN_18  18<br />
#define PIN_8 &nbsp;&nbsp;8<br />
<br />
int lastState0;<br />
int lastState18;<br />
int lastState8;<br />
<br />
void setup() {<br />
  Serial.begin(115200);<br />
<br />
  pinMode(PIN_0, INPUT_PULLUP);<br />
  pinMode(PIN_18, INPUT_PULLUP);<br />
  pinMode(PIN_8, INPUT_PULLUP);<br />
<br />
  lastState0  = digitalRead(PIN_0);<br />
  lastState18 = digitalRead(PIN_18);<br />
  lastState8  = digitalRead(PIN_8);<br />
<br />
  Serial.println("GPIO Monitor Started");<br />
}<br />
<br />
void loop() {<br />
<br />
  int state0 = digitalRead(PIN_0);<br />
  if (state0 != lastState0) {<br />
    Serial.print("GPIO0 changed to: ");<br />
    Serial.println(state0);<br />
    lastState0 = state0;<br />
  }<br />
<br />
  int state18 = digitalRead(PIN_18);<br />
  if (state18 != lastState18) {<br />
    Serial.print("GPIO18 changed to: ");<br />
    Serial.println(state18);<br />
    lastState18 = state18;<br />
  }<br />
<br />
  int state8 = digitalRead(PIN_8);<br />
  if (state8 != lastState8) {<br />
    Serial.print("GPIO8 changed to: ");<br />
    Serial.println(state8);<br />
    lastState8 = state8;<br />
  }<br />
<br />
  delay(10);<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10194" target="_blank" title="">Free-GPIO.zip</a> (Size: 539 bytes / Downloads: 54)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10195" target="_blank" title="">Free-GPIO.ino.merged.zip</a> (Size: 180.26 KB / Downloads: 64)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[[arduino code examples for MT4]-02 Ethernet W5500 chip work with TCP Server mode]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9610</link>
			<pubDate>Sat, 11 Jul 2026 10:15:26 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9610</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * Made by KinCony IoT: https://www.kincony.com<br />
 *<br />
 * This Arduino program sets up an ESP32-S3 with a W5500 Ethernet module<br />
 * as a TCP server. It listens on port 4196 and echoes back any string <br />
 * received from a client.<br />
 *<br />
 * Hardware connections:<br />
 * - CLK: GPIO42<br />
 * - MOSI: GPIO43<br />
 * - MISO: GPIO44<br />
 * - CS: GPIO41<br />
 * - RST: GPIO1<br />
 * - INT: GPIO2<br />
 *<br />
 * Static IP address: 192.168.3.55<br />
 * Subnet Mask: 255.255.255.0<br />
 * Gateway: 192.168.3.1<br />
 * DNS: 192.168.3.1<br />
 */<br />
<br />
#include &lt;SPI.h&gt;<br />
#include &lt;Ethernet.h&gt;<br />
<br />
// Define the W5500 Ethernet module pins<br />
#define W5500_CS_PIN  41<br />
#define W5500_RST_PIN 1<br />
#define W5500_INT_PIN 2<br />
#define W5500_CLK_PIN 42<br />
#define W5500_MOSI_PIN 43<br />
#define W5500_MISO_PIN 44<br />
<br />
// MAC address for your Ethernet shield (must be unique on your network)<br />
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };<br />
<br />
// Static IP address configuration<br />
IPAddress ip(192, 168, 3, 55);     &nbsp;&nbsp;// Static IP address<br />
IPAddress subnet(255, 255, 255, 0); &nbsp;&nbsp;// Subnet mask<br />
IPAddress gateway(192, 168, 3, 1);    // Default gateway<br />
IPAddress dns(192, 168, 3, 1);        // DNS server address<br />
<br />
// Create an EthernetServer object to handle TCP connections<br />
EthernetServer server(4196);<br />
<br />
void setup() {<br />
  // Initialize serial communication<br />
  Serial.begin(115200);<br />
  while (!Serial) {<br />
    ; // Wait for serial port to connect<br />
  }<br />
<br />
  // Initialize the W5500 module<br />
  pinMode(W5500_RST_PIN, OUTPUT);<br />
  pinMode(W5500_INT_PIN, INPUT);<br />
  digitalWrite(W5500_RST_PIN, LOW);  // Reset the W5500 module<br />
  delay(100);                     &nbsp;&nbsp;// Wait for reset to complete<br />
  digitalWrite(W5500_RST_PIN, HIGH); // Release reset<br />
<br />
  // Initialize SPI with the correct pin definitions<br />
  SPI.begin(W5500_CLK_PIN, W5500_MISO_PIN, W5500_MOSI_PIN);<br />
<br />
  // Set up the Ethernet library with W5500-specific pins<br />
  Ethernet.init(W5500_CS_PIN);<br />
<br />
  // Start the Ethernet connection with static IP configuration<br />
  Ethernet.begin(mac, ip, dns, gateway, subnet);<br />
<br />
  // Print the IP address to the serial monitor<br />
  Serial.print("IP Address: ");<br />
  Serial.println(Ethernet.localIP());<br />
<br />
  // Start listening for incoming TCP connections<br />
  server.begin();<br />
}<br />
<br />
void loop() {<br />
  // Check for incoming client connections<br />
  EthernetClient client = server.available();<br />
  if (client) {<br />
    Serial.println("New client connected");<br />
<br />
    // Read data from the client and echo it back<br />
    while (client.connected()) {<br />
      if (client.available()) {<br />
        char c = client.read();<br />
        server.write(c);<br />
      }<br />
    }<br />
<br />
    // Close the connection when done<br />
    client.stop();<br />
    Serial.println("Client disconnected");<br />
  }<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10192" target="_blank" title="">Ethernet-W5500.zip</a> (Size: 1.23 KB / Downloads: 50)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10193" target="_blank" title="">Ethernet-W5500.ino.merged.zip</a> (Size: 189.86 KB / Downloads: 55)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
 * Made by KinCony IoT: https://www.kincony.com<br />
 *<br />
 * This Arduino program sets up an ESP32-S3 with a W5500 Ethernet module<br />
 * as a TCP server. It listens on port 4196 and echoes back any string <br />
 * received from a client.<br />
 *<br />
 * Hardware connections:<br />
 * - CLK: GPIO42<br />
 * - MOSI: GPIO43<br />
 * - MISO: GPIO44<br />
 * - CS: GPIO41<br />
 * - RST: GPIO1<br />
 * - INT: GPIO2<br />
 *<br />
 * Static IP address: 192.168.3.55<br />
 * Subnet Mask: 255.255.255.0<br />
 * Gateway: 192.168.3.1<br />
 * DNS: 192.168.3.1<br />
 */<br />
<br />
#include &lt;SPI.h&gt;<br />
#include &lt;Ethernet.h&gt;<br />
<br />
// Define the W5500 Ethernet module pins<br />
#define W5500_CS_PIN  41<br />
#define W5500_RST_PIN 1<br />
#define W5500_INT_PIN 2<br />
#define W5500_CLK_PIN 42<br />
#define W5500_MOSI_PIN 43<br />
#define W5500_MISO_PIN 44<br />
<br />
// MAC address for your Ethernet shield (must be unique on your network)<br />
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };<br />
<br />
// Static IP address configuration<br />
IPAddress ip(192, 168, 3, 55);     &nbsp;&nbsp;// Static IP address<br />
IPAddress subnet(255, 255, 255, 0); &nbsp;&nbsp;// Subnet mask<br />
IPAddress gateway(192, 168, 3, 1);    // Default gateway<br />
IPAddress dns(192, 168, 3, 1);        // DNS server address<br />
<br />
// Create an EthernetServer object to handle TCP connections<br />
EthernetServer server(4196);<br />
<br />
void setup() {<br />
  // Initialize serial communication<br />
  Serial.begin(115200);<br />
  while (!Serial) {<br />
    ; // Wait for serial port to connect<br />
  }<br />
<br />
  // Initialize the W5500 module<br />
  pinMode(W5500_RST_PIN, OUTPUT);<br />
  pinMode(W5500_INT_PIN, INPUT);<br />
  digitalWrite(W5500_RST_PIN, LOW);  // Reset the W5500 module<br />
  delay(100);                     &nbsp;&nbsp;// Wait for reset to complete<br />
  digitalWrite(W5500_RST_PIN, HIGH); // Release reset<br />
<br />
  // Initialize SPI with the correct pin definitions<br />
  SPI.begin(W5500_CLK_PIN, W5500_MISO_PIN, W5500_MOSI_PIN);<br />
<br />
  // Set up the Ethernet library with W5500-specific pins<br />
  Ethernet.init(W5500_CS_PIN);<br />
<br />
  // Start the Ethernet connection with static IP configuration<br />
  Ethernet.begin(mac, ip, dns, gateway, subnet);<br />
<br />
  // Print the IP address to the serial monitor<br />
  Serial.print("IP Address: ");<br />
  Serial.println(Ethernet.localIP());<br />
<br />
  // Start listening for incoming TCP connections<br />
  server.begin();<br />
}<br />
<br />
void loop() {<br />
  // Check for incoming client connections<br />
  EthernetClient client = server.available();<br />
  if (client) {<br />
    Serial.println("New client connected");<br />
<br />
    // Read data from the client and echo it back<br />
    while (client.connected()) {<br />
      if (client.available()) {<br />
        char c = client.read();<br />
        server.write(c);<br />
      }<br />
    }<br />
<br />
    // Close the connection when done<br />
    client.stop();<br />
    Serial.println("Client disconnected");<br />
  }<br />
}</code></div></div> arduino ino file download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10192" target="_blank" title="">Ethernet-W5500.zip</a> (Size: 1.23 KB / Downloads: 50)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download:  <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10193" target="_blank" title="">Ethernet-W5500.ino.merged.zip</a> (Size: 189.86 KB / Downloads: 55)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[[arduino code examples for MT4]-01 433MHz RF receiver]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9609</link>
			<pubDate>Sat, 11 Jul 2026 10:13:37 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9609</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
  Simple example for receiving<br />
  <br />
  https://github.com/sui77/rc-switch/<br />
*/<br />
<br />
#include &lt;RCSwitch.h&gt;<br />
<br />
RCSwitch mySwitch = RCSwitch();<br />
<br />
void setup() {<br />
  Serial.begin(9600);<br />
  mySwitch.enableReceive(digitalPinToInterrupt(38)); <br />
  Serial.print("begin test");<br />
}<br />
<br />
void loop() {<br />
  if (mySwitch.available()) {<br />
    <br />
    Serial.print("Received ");<br />
    Serial.print( mySwitch.getReceivedValue() );<br />
    Serial.print(" / ");<br />
    Serial.print( mySwitch.getReceivedBitlength() );<br />
    Serial.print("bit ");<br />
    Serial.print("Protocol: ");<br />
    Serial.println( mySwitch.getReceivedProtocol() );<br />
<br />
    mySwitch.resetAvailable();<br />
  }<br />
}</code></div></div><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10189" target="_blank" title="">arduino.png</a> (Size: 131.43 KB / Downloads: 53)
<!-- end: postbit_attachments_attachment --><br />
arduino ino file download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10191" target="_blank" title="">433-decode.zip</a> (Size: 451 bytes / Downloads: 69)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10190" target="_blank" title="">433-decode.ino.merged.zip</a> (Size: 181.95 KB / Downloads: 48)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>/*<br />
  Simple example for receiving<br />
  <br />
  https://github.com/sui77/rc-switch/<br />
*/<br />
<br />
#include &lt;RCSwitch.h&gt;<br />
<br />
RCSwitch mySwitch = RCSwitch();<br />
<br />
void setup() {<br />
  Serial.begin(9600);<br />
  mySwitch.enableReceive(digitalPinToInterrupt(38)); <br />
  Serial.print("begin test");<br />
}<br />
<br />
void loop() {<br />
  if (mySwitch.available()) {<br />
    <br />
    Serial.print("Received ");<br />
    Serial.print( mySwitch.getReceivedValue() );<br />
    Serial.print(" / ");<br />
    Serial.print( mySwitch.getReceivedBitlength() );<br />
    Serial.print("bit ");<br />
    Serial.print("Protocol: ");<br />
    Serial.println( mySwitch.getReceivedProtocol() );<br />
<br />
    mySwitch.resetAvailable();<br />
  }<br />
}</code></div></div><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10189" target="_blank" title="">arduino.png</a> (Size: 131.43 KB / Downloads: 53)
<!-- end: postbit_attachments_attachment --><br />
arduino ino file download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10191" target="_blank" title="">433-decode.zip</a> (Size: 451 bytes / Downloads: 69)
<!-- end: postbit_attachments_attachment --><br />
BIN file (you can use esp32 download tool download to ESP32-S3 with address 0x0 then directly to use) download: <br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10190" target="_blank" title="">433-decode.ino.merged.zip</a> (Size: 181.95 KB / Downloads: 48)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[MT4 ESPHome yaml for home assistant without tuya]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9608</link>
			<pubDate>Sat, 11 Jul 2026 10:10:41 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9608</guid>
			<description><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>esphome:<br />
  name: mt4<br />
  friendly_name: MT4<br />
<br />
esp32:<br />
  board: esp32-s3-devkitc-1<br />
  framework:<br />
    type: esp-idf<br />
<br />
logger:<br />
<br />
api:<br />
<br />
ethernet:<br />
  type: W5500<br />
  clk_pin: GPIO42<br />
  mosi_pin: GPIO43<br />
  miso_pin: GPIO44<br />
  cs_pin: GPIO41<br />
  interrupt_pin: GPIO2<br />
  reset_pin: GPIO1<br />
<br />
web_server:<br />
  port: 80<br />
<br />
globals:<br />
  - id: motor1_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor1_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
  - id: motor2_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor2_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
  - id: motor3_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor3_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
  - id: motor4_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor4_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
output:<br />
  # Motor 1<br />
  - platform: gpio<br />
    id: motor1_in1<br />
    pin: GPIO39<br />
<br />
  - platform: gpio<br />
    id: motor1_in2<br />
    pin: GPIO46<br />
<br />
  - platform: ledc<br />
    id: motor1_pwm<br />
    pin: GPIO9<br />
    frequency: 1000Hz<br />
<br />
  # Motor 2<br />
  - platform: gpio<br />
    id: motor2_in1<br />
    pin: GPIO11<br />
<br />
  - platform: gpio<br />
    id: motor2_in2<br />
    pin: GPIO10<br />
<br />
  - platform: ledc<br />
    id: motor2_pwm<br />
    pin: GPIO12<br />
    frequency: 1000Hz<br />
<br />
  # Motor 3<br />
  - platform: gpio<br />
    id: motor3_in1<br />
    pin: GPIO13<br />
<br />
  - platform: gpio<br />
    id: motor3_in2<br />
    pin: GPIO47<br />
<br />
  - platform: ledc<br />
    id: motor3_pwm<br />
    pin: GPIO14<br />
    frequency: 1000Hz<br />
<br />
  # Motor 4<br />
  - platform: gpio<br />
    id: motor4_in1<br />
    pin: GPIO48<br />
<br />
  - platform: gpio<br />
    id: motor4_in2<br />
    pin: GPIO45<br />
<br />
  - platform: ledc<br />
    id: motor4_pwm<br />
    pin: GPIO21<br />
    frequency: 1000Hz<br />
<br />
script:<br />
  # Motor 1<br />
  - id: motor1_forward<br />
    then:<br />
      - output.turn_on: motor1_in1<br />
      - output.turn_off: motor1_in2<br />
      - output.set_level:<br />
          id: motor1_pwm<br />
          level: !lambda "return id(motor1_speed_value);"<br />
<br />
  - id: motor1_reverse<br />
    then:<br />
      - output.turn_off: motor1_in1<br />
      - output.turn_on: motor1_in2<br />
      - output.set_level:<br />
          id: motor1_pwm<br />
          level: !lambda "return id(motor1_speed_value);"<br />
<br />
  - id: motor1_stop<br />
    then:<br />
      - output.turn_off: motor1_in1<br />
      - output.turn_off: motor1_in2<br />
      - output.set_level:<br />
          id: motor1_pwm<br />
          level: 0%<br />
<br />
  # Motor 2<br />
  - id: motor2_forward<br />
    then:<br />
      - output.turn_on: motor2_in1<br />
      - output.turn_off: motor2_in2<br />
      - output.set_level:<br />
          id: motor2_pwm<br />
          level: !lambda "return id(motor2_speed_value);"<br />
<br />
  - id: motor2_reverse<br />
    then:<br />
      - output.turn_off: motor2_in1<br />
      - output.turn_on: motor2_in2<br />
      - output.set_level:<br />
          id: motor2_pwm<br />
          level: !lambda "return id(motor2_speed_value);"<br />
<br />
  - id: motor2_stop<br />
    then:<br />
      - output.turn_off: motor2_in1<br />
      - output.turn_off: motor2_in2<br />
      - output.set_level:<br />
          id: motor2_pwm<br />
          level: 0%<br />
<br />
  # Motor 3<br />
  - id: motor3_forward<br />
    then:<br />
      - output.turn_on: motor3_in1<br />
      - output.turn_off: motor3_in2<br />
      - output.set_level:<br />
          id: motor3_pwm<br />
          level: !lambda "return id(motor3_speed_value);"<br />
<br />
  - id: motor3_reverse<br />
    then:<br />
      - output.turn_off: motor3_in1<br />
      - output.turn_on: motor3_in2<br />
      - output.set_level:<br />
          id: motor3_pwm<br />
          level: !lambda "return id(motor3_speed_value);"<br />
<br />
  - id: motor3_stop<br />
    then:<br />
      - output.turn_off: motor3_in1<br />
      - output.turn_off: motor3_in2<br />
      - output.set_level:<br />
          id: motor3_pwm<br />
          level: 0%<br />
<br />
  # Motor 4<br />
  - id: motor4_forward<br />
    then:<br />
      - output.turn_on: motor4_in1<br />
      - output.turn_off: motor4_in2<br />
      - output.set_level:<br />
          id: motor4_pwm<br />
          level: !lambda "return id(motor4_speed_value);"<br />
<br />
  - id: motor4_reverse<br />
    then:<br />
      - output.turn_off: motor4_in1<br />
      - output.turn_on: motor4_in2<br />
      - output.set_level:<br />
          id: motor4_pwm<br />
          level: !lambda "return id(motor4_speed_value);"<br />
<br />
  - id: motor4_stop<br />
    then:<br />
      - output.turn_off: motor4_in1<br />
      - output.turn_off: motor4_in2<br />
      - output.set_level:<br />
          id: motor4_pwm<br />
          level: 0%<br />
<br />
button:<br />
  - platform: template<br />
    name: "Motor1 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor1_direction<br />
          value: '1'<br />
      - script.execute: motor1_forward<br />
<br />
  - platform: template<br />
    name: "Motor1 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor1_direction<br />
          value: '-1'<br />
      - script.execute: motor1_reverse<br />
<br />
  - platform: template<br />
    name: "Motor1 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor1_direction<br />
          value: '0'<br />
      - script.execute: motor1_stop<br />
<br />
  - platform: template<br />
    name: "Motor2 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor2_direction<br />
          value: '1'<br />
      - script.execute: motor2_forward<br />
<br />
  - platform: template<br />
    name: "Motor2 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor2_direction<br />
          value: '-1'<br />
      - script.execute: motor2_reverse<br />
<br />
  - platform: template<br />
    name: "Motor2 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor2_direction<br />
          value: '0'<br />
      - script.execute: motor2_stop<br />
<br />
  - platform: template<br />
    name: "Motor3 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor3_direction<br />
          value: '1'<br />
      - script.execute: motor3_forward<br />
<br />
  - platform: template<br />
    name: "Motor3 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor3_direction<br />
          value: '-1'<br />
      - script.execute: motor3_reverse<br />
<br />
  - platform: template<br />
    name: "Motor3 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor3_direction<br />
          value: '0'<br />
      - script.execute: motor3_stop<br />
<br />
  - platform: template<br />
    name: "Motor4 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor4_direction<br />
          value: '1'<br />
      - script.execute: motor4_forward<br />
<br />
  - platform: template<br />
    name: "Motor4 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor4_direction<br />
          value: '-1'<br />
      - script.execute: motor4_reverse<br />
<br />
  - platform: template<br />
    name: "Motor4 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor4_direction<br />
          value: '0'<br />
      - script.execute: motor4_stop<br />
<br />
number:<br />
  - platform: template<br />
    name: "Motor1 Speed"<br />
    id: motor1_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor1_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor1_direction) == 1;"<br />
          then:<br />
            - script.execute: motor1_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor1_direction) == -1;"<br />
          then:<br />
            - script.execute: motor1_reverse<br />
<br />
  - platform: template<br />
    name: "Motor2 Speed"<br />
    id: motor2_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor2_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor2_direction) == 1;"<br />
          then:<br />
            - script.execute: motor2_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor2_direction) == -1;"<br />
          then:<br />
            - script.execute: motor2_reverse<br />
<br />
  - platform: template<br />
    name: "Motor3 Speed"<br />
    id: motor3_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor3_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor3_direction) == 1;"<br />
          then:<br />
            - script.execute: motor3_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor3_direction) == -1;"<br />
          then:<br />
            - script.execute: motor3_reverse<br />
<br />
  - platform: template<br />
    name: "Motor4 Speed"<br />
    id: motor4_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor4_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor4_direction) == 1;"<br />
          then:<br />
            - script.execute: motor4_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor4_direction) == -1;"<br />
          then:<br />
            - script.execute: motor4_reverse</code></div></div><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10186" target="_blank" title="">HA_MT4.png</a> (Size: 91.68 KB / Downloads: 47)
<!-- end: postbit_attachments_attachment --><br />
yaml file download:<br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/txt.png" title="Text Document" border="0" alt=".txt" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10187" target="_blank" title="">HA_4_motor.txt</a> (Size: 9 KB / Downloads: 36)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[<div class="codeblock"><div class="title">Code:</div><div class="body" dir="ltr"><code>esphome:<br />
  name: mt4<br />
  friendly_name: MT4<br />
<br />
esp32:<br />
  board: esp32-s3-devkitc-1<br />
  framework:<br />
    type: esp-idf<br />
<br />
logger:<br />
<br />
api:<br />
<br />
ethernet:<br />
  type: W5500<br />
  clk_pin: GPIO42<br />
  mosi_pin: GPIO43<br />
  miso_pin: GPIO44<br />
  cs_pin: GPIO41<br />
  interrupt_pin: GPIO2<br />
  reset_pin: GPIO1<br />
<br />
web_server:<br />
  port: 80<br />
<br />
globals:<br />
  - id: motor1_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor1_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
  - id: motor2_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor2_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
  - id: motor3_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor3_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
  - id: motor4_direction<br />
    type: int<br />
    restore_value: true<br />
    initial_value: '0'<br />
  - id: motor4_speed_value<br />
    type: float<br />
    restore_value: true<br />
    initial_value: '0.5'<br />
<br />
output:<br />
  # Motor 1<br />
  - platform: gpio<br />
    id: motor1_in1<br />
    pin: GPIO39<br />
<br />
  - platform: gpio<br />
    id: motor1_in2<br />
    pin: GPIO46<br />
<br />
  - platform: ledc<br />
    id: motor1_pwm<br />
    pin: GPIO9<br />
    frequency: 1000Hz<br />
<br />
  # Motor 2<br />
  - platform: gpio<br />
    id: motor2_in1<br />
    pin: GPIO11<br />
<br />
  - platform: gpio<br />
    id: motor2_in2<br />
    pin: GPIO10<br />
<br />
  - platform: ledc<br />
    id: motor2_pwm<br />
    pin: GPIO12<br />
    frequency: 1000Hz<br />
<br />
  # Motor 3<br />
  - platform: gpio<br />
    id: motor3_in1<br />
    pin: GPIO13<br />
<br />
  - platform: gpio<br />
    id: motor3_in2<br />
    pin: GPIO47<br />
<br />
  - platform: ledc<br />
    id: motor3_pwm<br />
    pin: GPIO14<br />
    frequency: 1000Hz<br />
<br />
  # Motor 4<br />
  - platform: gpio<br />
    id: motor4_in1<br />
    pin: GPIO48<br />
<br />
  - platform: gpio<br />
    id: motor4_in2<br />
    pin: GPIO45<br />
<br />
  - platform: ledc<br />
    id: motor4_pwm<br />
    pin: GPIO21<br />
    frequency: 1000Hz<br />
<br />
script:<br />
  # Motor 1<br />
  - id: motor1_forward<br />
    then:<br />
      - output.turn_on: motor1_in1<br />
      - output.turn_off: motor1_in2<br />
      - output.set_level:<br />
          id: motor1_pwm<br />
          level: !lambda "return id(motor1_speed_value);"<br />
<br />
  - id: motor1_reverse<br />
    then:<br />
      - output.turn_off: motor1_in1<br />
      - output.turn_on: motor1_in2<br />
      - output.set_level:<br />
          id: motor1_pwm<br />
          level: !lambda "return id(motor1_speed_value);"<br />
<br />
  - id: motor1_stop<br />
    then:<br />
      - output.turn_off: motor1_in1<br />
      - output.turn_off: motor1_in2<br />
      - output.set_level:<br />
          id: motor1_pwm<br />
          level: 0%<br />
<br />
  # Motor 2<br />
  - id: motor2_forward<br />
    then:<br />
      - output.turn_on: motor2_in1<br />
      - output.turn_off: motor2_in2<br />
      - output.set_level:<br />
          id: motor2_pwm<br />
          level: !lambda "return id(motor2_speed_value);"<br />
<br />
  - id: motor2_reverse<br />
    then:<br />
      - output.turn_off: motor2_in1<br />
      - output.turn_on: motor2_in2<br />
      - output.set_level:<br />
          id: motor2_pwm<br />
          level: !lambda "return id(motor2_speed_value);"<br />
<br />
  - id: motor2_stop<br />
    then:<br />
      - output.turn_off: motor2_in1<br />
      - output.turn_off: motor2_in2<br />
      - output.set_level:<br />
          id: motor2_pwm<br />
          level: 0%<br />
<br />
  # Motor 3<br />
  - id: motor3_forward<br />
    then:<br />
      - output.turn_on: motor3_in1<br />
      - output.turn_off: motor3_in2<br />
      - output.set_level:<br />
          id: motor3_pwm<br />
          level: !lambda "return id(motor3_speed_value);"<br />
<br />
  - id: motor3_reverse<br />
    then:<br />
      - output.turn_off: motor3_in1<br />
      - output.turn_on: motor3_in2<br />
      - output.set_level:<br />
          id: motor3_pwm<br />
          level: !lambda "return id(motor3_speed_value);"<br />
<br />
  - id: motor3_stop<br />
    then:<br />
      - output.turn_off: motor3_in1<br />
      - output.turn_off: motor3_in2<br />
      - output.set_level:<br />
          id: motor3_pwm<br />
          level: 0%<br />
<br />
  # Motor 4<br />
  - id: motor4_forward<br />
    then:<br />
      - output.turn_on: motor4_in1<br />
      - output.turn_off: motor4_in2<br />
      - output.set_level:<br />
          id: motor4_pwm<br />
          level: !lambda "return id(motor4_speed_value);"<br />
<br />
  - id: motor4_reverse<br />
    then:<br />
      - output.turn_off: motor4_in1<br />
      - output.turn_on: motor4_in2<br />
      - output.set_level:<br />
          id: motor4_pwm<br />
          level: !lambda "return id(motor4_speed_value);"<br />
<br />
  - id: motor4_stop<br />
    then:<br />
      - output.turn_off: motor4_in1<br />
      - output.turn_off: motor4_in2<br />
      - output.set_level:<br />
          id: motor4_pwm<br />
          level: 0%<br />
<br />
button:<br />
  - platform: template<br />
    name: "Motor1 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor1_direction<br />
          value: '1'<br />
      - script.execute: motor1_forward<br />
<br />
  - platform: template<br />
    name: "Motor1 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor1_direction<br />
          value: '-1'<br />
      - script.execute: motor1_reverse<br />
<br />
  - platform: template<br />
    name: "Motor1 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor1_direction<br />
          value: '0'<br />
      - script.execute: motor1_stop<br />
<br />
  - platform: template<br />
    name: "Motor2 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor2_direction<br />
          value: '1'<br />
      - script.execute: motor2_forward<br />
<br />
  - platform: template<br />
    name: "Motor2 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor2_direction<br />
          value: '-1'<br />
      - script.execute: motor2_reverse<br />
<br />
  - platform: template<br />
    name: "Motor2 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor2_direction<br />
          value: '0'<br />
      - script.execute: motor2_stop<br />
<br />
  - platform: template<br />
    name: "Motor3 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor3_direction<br />
          value: '1'<br />
      - script.execute: motor3_forward<br />
<br />
  - platform: template<br />
    name: "Motor3 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor3_direction<br />
          value: '-1'<br />
      - script.execute: motor3_reverse<br />
<br />
  - platform: template<br />
    name: "Motor3 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor3_direction<br />
          value: '0'<br />
      - script.execute: motor3_stop<br />
<br />
  - platform: template<br />
    name: "Motor4 Forward"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor4_direction<br />
          value: '1'<br />
      - script.execute: motor4_forward<br />
<br />
  - platform: template<br />
    name: "Motor4 Reverse"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor4_direction<br />
          value: '-1'<br />
      - script.execute: motor4_reverse<br />
<br />
  - platform: template<br />
    name: "Motor4 Stop"<br />
    on_press:<br />
      - globals.set:<br />
          id: motor4_direction<br />
          value: '0'<br />
      - script.execute: motor4_stop<br />
<br />
number:<br />
  - platform: template<br />
    name: "Motor1 Speed"<br />
    id: motor1_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor1_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor1_direction) == 1;"<br />
          then:<br />
            - script.execute: motor1_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor1_direction) == -1;"<br />
          then:<br />
            - script.execute: motor1_reverse<br />
<br />
  - platform: template<br />
    name: "Motor2 Speed"<br />
    id: motor2_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor2_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor2_direction) == 1;"<br />
          then:<br />
            - script.execute: motor2_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor2_direction) == -1;"<br />
          then:<br />
            - script.execute: motor2_reverse<br />
<br />
  - platform: template<br />
    name: "Motor3 Speed"<br />
    id: motor3_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor3_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor3_direction) == 1;"<br />
          then:<br />
            - script.execute: motor3_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor3_direction) == -1;"<br />
          then:<br />
            - script.execute: motor3_reverse<br />
<br />
  - platform: template<br />
    name: "Motor4 Speed"<br />
    id: motor4_speed<br />
    min_value: 0<br />
    max_value: 100<br />
    step: 1<br />
    optimistic: true<br />
    restore_value: true<br />
    initial_value: 50<br />
    set_action:<br />
      - globals.set:<br />
          id: motor4_speed_value<br />
          value: !lambda "return x / 100.0;"<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor4_direction) == 1;"<br />
          then:<br />
            - script.execute: motor4_forward<br />
      - if:<br />
          condition:<br />
            lambda: "return id(motor4_direction) == -1;"<br />
          then:<br />
            - script.execute: motor4_reverse</code></div></div><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10186" target="_blank" title="">HA_MT4.png</a> (Size: 91.68 KB / Downloads: 47)
<!-- end: postbit_attachments_attachment --><br />
yaml file download:<br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/txt.png" title="Text Document" border="0" alt=".txt" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10187" target="_blank" title="">HA_4_motor.txt</a> (Size: 9 KB / Downloads: 36)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[MT4 ESP32-S3 IO pins define]]></title>
			<link>https://www.kincony.com/forum/showthread.php?tid=9607</link>
			<pubDate>Sat, 11 Jul 2026 10:09:15 +0800</pubDate>
			<dc:creator><![CDATA[<a href="https://www.kincony.com/forum/member.php?action=profile&uid=1">admin</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.kincony.com/forum/showthread.php?tid=9607</guid>
			<description><![CDATA[IIC Bus:<br />
<br />
SDA:GPIO5<br />
SCL:GPIO4<br />
<br />
24C02 EPROM i2c address: 0x50<br />
<br />
-----------------<br />
<br />
Ethernet (W5500) I/O define:<br />
<br />
clk_pin: GPIO42<br />
mosi_pin: GPIO43<br />
miso_pin: GPIO44<br />
cs_pin: GPIO41<br />
<br />
interrupt_pin: GPIO2<br />
reset_pin: GPIO1<br />
<br />
--------------------<br />
RS485: <br />
RXD:GPIO7<br />
TXD:GPIO6<br />
<br />
Tuya module:<br />
RXD:GPIO17<br />
TXD:GPIO16<br />
<br />
Tuya network button: Tuya module's P28<br />
Tuya network LED: Tuya module's P16<br />
--------------------<br />
1-Wire-TEP1:GPIO18<br />
1-Wire-TEP2:GPIO8<br />
<br />
--------------------<br />
<br />
433MHz RF receiver: GPIO38<br />
IR receiver: GPIO15<br />
<br />
DL(download) button: GPIO0<br />
---------------------<br />
Motor1:<br />
IN1-1: GPIO39<br />
IN1-2: GPIO46<br />
PWM1: GPIO9<br />
<br />
Motor2:<br />
IN2-1: GPIO11<br />
IN2-2: GPIO10<br />
PWM2: GPIO12<br />
<br />
Motor3:<br />
IN3-1: GPIO13<br />
IN3-2: GPIO47<br />
PWM3: GPIO14<br />
<br />
Motor4:<br />
IN4-1: GPIO48<br />
IN4-2: GPIO45<br />
PWM4: GPIO21<br />
<br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10188" target="_blank" title="">KinCony-MT4-smart-controller-diagram.png</a> (Size: 1.44 MB / Downloads: 77)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[IIC Bus:<br />
<br />
SDA:GPIO5<br />
SCL:GPIO4<br />
<br />
24C02 EPROM i2c address: 0x50<br />
<br />
-----------------<br />
<br />
Ethernet (W5500) I/O define:<br />
<br />
clk_pin: GPIO42<br />
mosi_pin: GPIO43<br />
miso_pin: GPIO44<br />
cs_pin: GPIO41<br />
<br />
interrupt_pin: GPIO2<br />
reset_pin: GPIO1<br />
<br />
--------------------<br />
RS485: <br />
RXD:GPIO7<br />
TXD:GPIO6<br />
<br />
Tuya module:<br />
RXD:GPIO17<br />
TXD:GPIO16<br />
<br />
Tuya network button: Tuya module's P28<br />
Tuya network LED: Tuya module's P16<br />
--------------------<br />
1-Wire-TEP1:GPIO18<br />
1-Wire-TEP2:GPIO8<br />
<br />
--------------------<br />
<br />
433MHz RF receiver: GPIO38<br />
IR receiver: GPIO15<br />
<br />
DL(download) button: GPIO0<br />
---------------------<br />
Motor1:<br />
IN1-1: GPIO39<br />
IN1-2: GPIO46<br />
PWM1: GPIO9<br />
<br />
Motor2:<br />
IN2-1: GPIO11<br />
IN2-2: GPIO10<br />
PWM2: GPIO12<br />
<br />
Motor3:<br />
IN3-1: GPIO13<br />
IN3-2: GPIO47<br />
PWM3: GPIO14<br />
<br />
Motor4:<br />
IN4-1: GPIO48<br />
IN4-2: GPIO45<br />
PWM4: GPIO21<br />
<br />
<!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.kincony.com/forum/images/attachtypes/image.png" title="PNG Image" border="0" alt=".png" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=10188" target="_blank" title="">KinCony-MT4-smart-controller-diagram.png</a> (Size: 1.44 MB / Downloads: 77)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
	</channel>
</rss>