Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 10,554
» Latest member: mm88io
» Forum threads: 4,339
» Forum posts: 21,351

Full Statistics

Online Users
There are currently 521 online users.
» 0 Member(s) | 504 Guest(s)
AhrefsBot, Applebot, Baidu, Bing, Bytespider, Crawl, Google, PetalBot, bot

Latest Threads
HAv2 + ESPHome - Avoiding...
Forum: KC868-HA /HA v2
Last Post: phrfpeixoto
1 hour ago
» Replies: 3
» Views: 11
KCS debounce option for K...
Forum: KC868-A16
Last Post: admin
3 hours ago
» Replies: 1
» Views: 38
Does KCS v3 on CO16 opera...
Forum: CO16
Last Post: admin
3 hours ago
» Replies: 1
» Views: 2
[arduino code examples fo...
Forum: F32
Last Post: admin
Yesterday, 04:27 AM
» Replies: 0
» Views: 22
[arduino code examples fo...
Forum: F32
Last Post: admin
Yesterday, 04:25 AM
» Replies: 0
» Views: 20
KC868-A16 wiring diagram
Forum: KC868-A16
Last Post: admin
11-17-2026, 09:31 PM
» Replies: 24
» Views: 22,091
N20 energy
Forum: N20
Last Post: admin
11-17-2026, 09:29 PM
» Replies: 1
» Views: 27
Automatic Modbus Sensor p...
Forum: "KCS" v3 firmware
Last Post: admin
11-17-2026, 09:27 PM
» Replies: 4
» Views: 125
[arduino code examples fo...
Forum: CO16
Last Post: admin
11-17-2026, 04:33 AM
» Replies: 0
» Views: 30
KC868-A8 PCB V1.7 - Maxim...
Forum: KC868-A8
Last Post: admin
11-16-2026, 09:29 AM
» Replies: 1
» Views: 65

  AIO Hybrid ESPHome yaml for home assistant with tuya
Posted by: admin - 09-15-2025, 01:18 AM - Forum: AIO Hybrid - No Replies

Code:
esphome:
  name: aio-hybrid
  friendly_name: AIO-hybrid
  platformio_options:
    board_build.extra_flags:
      # WIFI_CONTROL_SELF_MODE = 0
      # WIFI_CONTROL_SELF_MODE = 1
      - "-DWIFI_CONTROL_SELF_MODE=1"

esp32:
  board: esp32-s3-devkitc-1
  framework:
    type: arduino

# Enable logging
#logger:
#  hardware_uart: USB_SERIAL_JTAG

external_components:
  - source:
      type: git
      url: https://github.com/hzkincony/esphome-tuya-wifi-mcu
      ref: v1.1.0


# Enable Home Assistant API
api:

uart:
#  - id: uart_zsu
#    baud_rate: 115200
#    debug:
#      direction: BOTH
#      dummy_receiver: true
#      after:
#        timeout: 10ms
#      sequence:
#        - lambda: UARTDebug::log_string(direction, bytes);
#    tx_pin: 15
#3    rx_pin: 48

  - id: tuya_mcu_uart
    tx_pin: GPIO39
    rx_pin: GPIO38
    baud_rate: 9600

tuya_wifi_mcu:
  # tuya mcu product id
  product_id: 0x9gs3fuzgggwhi1
  uart_id: tuya_mcu_uart
  wifi_reset_pin: 28
  wifi_led_pin: 16

ethernet:
  type: W5500
  clk_pin: GPIO42
  mosi_pin: GPIO43
  miso_pin: GPIO44
  cs_pin: GPIO41
  interrupt_pin: GPIO2
  reset_pin: GPIO1

i2c:
   - id: bus_a
     sda: 8
     scl: 18
     scan: true
     frequency: 400kHz

pcf8574:
  - id: 'pcf8574_hub_output_1'  # for output channel 5
    i2c_id: bus_a
    address: 0x26

  - id: 'pcf8574_hub_input_1'  # for input channel 1-12
    i2c_id: bus_a
    address: 0x24
    pcf8575: true


switch:

#  - platform: uart
#    uart_id: uart_zsu
#    name: "UART zigbee"
#    data: [0x55, 0xaa, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x01, 0x00, 0x04] # ZSU zigbee module 

  - platform: gpio
    name: "AIO_hybrid-output01"
    id: "AIO_hybrid_output01"
    pin:
      pcf8574: pcf8574_hub_output_1
      number: 3
      mode: OUTPUT
      inverted: true
  - platform: tuya_wifi_mcu
    name: AIO_hybrid-output1-tuya
    dp_id: 1
    # hide from homeassistant ui
    internal: true
    # bind other switch, sync state
    bind_switch_id: "AIO_hybrid_output01"


  - platform: gpio
    name: "AIO_hybrid-output02"
    id: "AIO_hybrid_output02"
    pin:
      pcf8574: pcf8574_hub_output_1
      number: 4
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-output03"
    id: "AIO_hybrid_output03"
    pin:
      pcf8574: pcf8574_hub_output_1
      number: 5
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-output04"
    id: "AIO_hybrid_output04"
    pin:
      pcf8574: pcf8574_hub_output_1
      number: 6
      mode: OUTPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-output05"
    id: "AIO_hybrid_output05"
    pin:
      pcf8574: pcf8574_hub_output_1
      number: 7
      mode: OUTPUT
      inverted: true

  - platform: template
    name: IR-Send1
    turn_on_action:
      - remote_transmitter.transmit_pronto:
          transmitter_id: ir1
          data: "0000 006C 0022 0002 015B 00AD 0016 0041 0016 0016 0016 0041 0016 0016 0016 0016 0016 0041 0016 0041 0016 0041 0016 0041 0016 0041 0016 0041 0016 0016 0016 0016 0016 0016 0016 0016 0016 0041 0016 0041 0016 0041 0016 0041 0016 0016 0016 0016 0016 0016 0016 0016 0016 0016 0016 0016 0016 0041 0016 0041 0016 0041 0016 0041 0016 0041 0016 0041 0016 0041 0016 0575 015B 0057 0016 0E6C"

binary_sensor:
  - platform: gpio
    name: "AIO_hybrid-input01"
    id: "AIO_hybrid_input01"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 0
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input02"
    id: "AIO_hybrid_input02"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 1
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input03"
    id: "AIO_hybrid_input03"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 2
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input04"
    id: "AIO_hybrid_input04"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 3
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input05"
    id: "AIO_hybrid_input05"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 4
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input06"
    id: "AIO_hybrid_input06"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 5
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input07"
    id: "AIO_hybrid_input07"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 6
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input08"
    id: "AIO_hybrid_input08"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 7
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input09"
    id: "AIO_hybrid_input09"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 8
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input10"
    id: "AIO_hybrid_input10"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 9
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input11"
    id: "AIO_hybrid_input11"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 10
      mode: INPUT
      inverted: true

  - platform: gpio
    name: "AIO_hybrid-input12"
    id: "AIO_hybrid_input12"
    pin:
      pcf8574: pcf8574_hub_input_1
      number: 11
      mode: INPUT
      inverted: true

## without resistance on PCB
  - platform: gpio
    name: "AIO_hybrid-433M"
    pin:
      number: 40
      inverted:  false

  - platform: gpio
    name: "AIO_hybrid-io0"
    pin:
      number: 0
      inverted:  false

mcp4728:
  - id: dac_output

output:
- platform: mcp4728
  id: dimmer1
  mcp4728_id: dac_output
  channel: A
  vref: vdd
  power_down: normal # default

- platform: mcp4728
  id: dimmer2
  mcp4728_id: dac_output
  channel: B
  vref: vdd
  power_down: normal # default

- platform: mcp4728
  id: dimmer3
  mcp4728_id: dac_output
  channel: C
  vref: vdd
  power_down: normal # default

- platform: mcp4728
  id: dimmer4
  mcp4728_id: dac_output
  channel: D
  vref: vdd
  power_down: normal # default

light:
  - platform: monochromatic
    name: "dimmer-1"
    output: dimmer1
    gamma_correct: 1.0

  - platform: monochromatic
    name: "dimmer-2"
    output: dimmer2
    gamma_correct: 1.0

  - platform: monochromatic
    name: "dimmer-3"
    output: dimmer3
    gamma_correct: 1.0

  - platform: monochromatic
    name: "dimmer-4"
    output: dimmer4
    gamma_correct: 1.0



font:
  - file: "gfonts://Roboto"
    id: roboto
    size: 20

display:
  - platform: ssd1306_i2c
    i2c_id: bus_a
    model: "SSD1306 128x64"
    address: 0x3C
    lambda: |-
      it.printf(0, 0, id(roboto), "AIO-hybrid");

sensor:
  - platform: adc
    pin: 5
    name: "AIO_hybrid A1 Voltage"
    update_interval: 55s
    attenuation: 11db
    filters:
      - lambda:
          if (x >= 3.11) {
            return x * 1.60256;
          } else if (x <= 0.15) {
            return 0;
          } else {
            return x * 1.51;
          }
  - platform: adc
    pin: 7
    name: "AIO_hybrid A2 Voltage"
    update_interval: 55s
    attenuation: 11db
    filters:
      # - multiply: 1.51515
      - lambda:
          if (x >= 3.11) {
            return x * 1.60256;
          } else if (x <= 0.15) {
            return 0;
          } else {
            return x * 1.51;
          }
  - platform: adc
    pin: 6
    name: "AIO_hybrid A3 Current"
    update_interval: 55s
    unit_of_measurement: mA
    attenuation: 11db
    filters:
      - multiply: 6.66666666
  - platform: adc
    pin: 4
    name: "AIO_hybrid A4 Current"
    update_interval: 55s
    unit_of_measurement: mA
    attenuation: 11db
    filters:
      - multiply: 6.66666666

remote_receiver:
  pin: 17
  dump: all

remote_transmitter:
  - id: ir1
    pin: 14
    carrier_duty_percent: 50%



web_server:
  port: 80
download yaml file:

.txt   AIO-hybrid_pin_define-HA-with-Tuya.txt (Size: 8.12 KB / Downloads: 409)

Print this item

  AIO Hybrid ESP32-S3 IO pins define
Posted by: admin - 09-15-2025, 01:16 AM - Forum: AIO Hybrid - Replies (5)

ANALOG_A1(0-5v)    GPIO5
ANALOG_A2(0-5v)    GPIO7
ANALOG_A3(4-20mA)  GPIO6
ANALOG_A4(4-20mA)  GPIO4

IIC SDA:GPIO8
IIC SCL:GPIO18

PCF8575:  i2c address:0x24

PCF8575->P0 (DI1)
PCF8575->P1 (DI2)
PCF8575->P2 (DI3)
PCF8575->P3 (DI4)
PCF8575->P4 (DI5)
PCF8575->P5 (DI6)
PCF8575->P6 (DI7)
PCF8575->P7 (DI8)
PCF8575->P8 (DI9)
PCF8575->P9 (DI10)
PCF8575->P10 (DI11)
PCF8575->P11 (DI12)

PCF8574:  i2c address:0x26
PCF8574->P3 (RELAY1)
PCF8574->P4 (RELAY2)
PCF8574->P5 (RELAY3)
PCF8574->P6 (RELAY4)
PCF8574->P7 (RELAY5)

IR Sender: GPIO14
IR Receiver: GPIO17
RF433MHz wireless receiver: GPIO40
------------------------

Ethernet (W5500) I/O define:

clk_pin: GPIO42
mosi_pin: GPIO43
miso_pin: GPIO44
cs_pin: GPIO41

interrupt_pin: GPIO2
reset_pin: GPIO1

--------------------
RS485:
RXD:GPIO47
TXD:GPIO3
--------------------
Tuya wifi module:
RXD:GPIO38
TXD:GPIO39

Tuya network button: Toya module's P28
Tuya network LED: Tuya module's P16

--------------------

Tuya Zigbee module:
RXD: GPIO48
TXD: GPIO15

------------------------
SD Card:
SPI-MOSI:GPIO10
SPI-SCK:GPIO11
SPI-MISO:GPIO12
SPI-CS:GPIO9
SPI-CD:GPIO13
------------------------
24C02 EPROM i2c address: 0x50
SSD1306 display: i2c address:0x3c
DS3231 RTC i2c address: 0x68
MCP4728 DAC: i2c address:0x60

Print this item

Exclamation Change PIN define
Posted by: JuDie07 - 09-14-2025, 02:54 PM - Forum: KC868-A series and Uair Smart Controller - Replies (1)

KC868-a8v3
Great, I have spent a whole afternoon looking for a bug!
And then, we quietly changed the PIN Define file without saying anythingAngry

ESP32 I/O pin define: https://www.kincony.com/forum/showthread.php?tid=7970

Huh Is it so difficult to issue a short INFO?



Attached Files Thumbnail(s)
   
Print this item

  Board recommendation ?
Posted by: Lory - 09-14-2025, 01:53 PM - Forum: DIY Project - Replies (3)

Hello,

I have 8 wooden doors and I want to install a 12v electric lock in each one and also a NFC card reader in each one.

To power the electric locks I can use a kincony board with 8 relays, but each card reader needs to be connected via SPI or with I2C

Is there a kincony board that can resolve this needs?

Edit:
problem is that the card readers might have the same I2C address, probably I do need a I2C multiplexor TCA9548A?

Also, if I want to use Kincony F series I see that the I2C port is utilized by a LCD screen… how can I overcome this difficulty?

Thanks

Print this item

  M30 - Inrush power recording
Posted by: dwarloch - 09-14-2025, 11:00 AM - Forum: KC868-M16 / M1 / MB / M30 - Replies (1)

Will it be possible to you can add in official FW support for recording the peak voltage, current, power and expose that through modbus registers? Plus add "clear peak values" modbus register where we can write a "1" to clear out the peak values. It would be great to monitor the spikes that can cause the breakers trigger. Also a great thing that implement for this type of devices would be support for LXI protocol so it could be used with software like this one: https://github.com/lxi-tools/lxi-tools

The peak values I think is most important here as it will be beneficial many users. The LXI support I will implement on my own but having it also out of the box would be beneficial. 

Question regarding the ARM with modbus server, does it read the values from BL09010 in the loop or does it read for each request from modbus?

Print this item

  switch dimensions
Posted by: swisstmack25 - 09-13-2025, 11:26 AM - Forum: KC868-HA /HA v2 - Replies (5)

please can you publish the dimensions of the switch https://shop.kincony.com/products/moment...5651591333
would be a good idea to have a technical drawing of the dimensions on your website.

is it the same for all gang variants, I want to understand if it will fit in a Swiss in wall housing (which is slightly smaller than that of the EU

60mm approx in diameter with 49mm depth
My wish is th use the keypad with the HAv2 module

Thanks!

Print this item

  T16M Output after reset
Posted by: Steen - 09-12-2025, 01:15 PM - Forum: T16M - Replies (8)

Just received myT16M in the mail this morning and I'm performing some test.

I installed the KCS 3.12 firmware and the servers webgui etc came up as expected.

Under the tab System there is this option: "Keep Output After Restart"
With this enabled I expected the outputs to com up in the last known state before restart or powertoggle, but all outputs comes up in a off state

Br Steen from Denmark

Print this item

  Suitable Hardware Selection for Automating a 10 000 sqr feet greenhouse
Posted by: nikhuge - 09-12-2025, 07:58 AM - Forum: DIY Project - Replies (4)

I am expecting to automate Climate Controlling,Irrigation,Fertigation,Shading in my Greenhouse of 10 000 square feet using kincony Hardwares and Home assistant.Can any one Suggest me What kind of Selections of Kincony Controllers I can use for above Project.(all the crops are grow in grow bags).I have a 20 000. Sqare feet greenhouse too.If this is success I am going to automate that one too.

Print this item

  Operating WLAN and Ethernet together
Posted by: JuDie07 - 09-10-2025, 07:53 AM - Forum: Getting Started with ESPHome and Home Assistant - Replies (2)

Confused  When I enter WLAN and Ethernet together in ESPHome, I get the following error message:

Can you please provide a code example?



Attached Files Image(s)
   
Print this item

  Getting started with KC-868AG Pro for blinds control with ESPHome/Home Assistant
Posted by: Parallax Abstraction - 09-09-2025, 10:54 PM - Forum: KC868-AG / AG Pro / AG8 / Z1 - Replies (15)

Hey everyone.

First off, a lot of what I'm asking will be novice questions here, but I'm a quick learner.

I have a set of automated blinds that are controlled with a remote on 433.92Mhz. I purchased a KC-868AG Pro in order to be able to automate them using Home Assistant. I did check out some material on the device before I bought it, but it seems a lot of it assumed some basic setup had been done before hand and I'm struggling with that. I am a technical person and work in IT, but haven't done much with these kinds of devices. Clear documentation and firmware is not easy to find on KinCony's web site and after spending quite some time, I'm not sure I'm going down the right path.

I have downloaded and installed the CH431SER driver on Windows 11 and the device does get detected when plugged in with USB. From what I understand, the next step is to install the ESPHome firmware for this device. However, I cannot find it. Every page about firmware on this forum I can find doesn't list one for this model and I can't find anything for it on the main web site. As I understand it, I can't join the device to my wi-fi or start programming it without this, so I'm hoping someone can point me in the right direction. In addition, is USB power all this device needs for what I want to do or will I need a separate power adapter? Since it powers on and it reachable over USB alone, I'm assuming that's all I need for my use case but again, it's unclear. I understand that I also need a default YAML file for ESPHome for Home Assistant to recognize the device. Is this the case and if so, is there somewhere I can grab that as well?

Once I get the basics done, I think I can figure things out from there. I'm just at a loss on these beginning steps.

Thanks for your help, I appreciate it!

Print this item