Smart Home Automation Forum
ESPHome GPIO - Printable Version

+- Smart Home Automation Forum (https://www.kincony.com/forum)
+-- Forum: Technical Support (https://www.kincony.com/forum/forumdisplay.php?fid=20)
+--- Forum: KC868-A16 (https://www.kincony.com/forum/forumdisplay.php?fid=25)
+--- Thread: ESPHome GPIO (/showthread.php?tid=2387)



ESPHome GPIO - lautarosrur - 11-04-2022

How can I reference the GPIO and analog pins in ESPHome? Can you provide some example? Thanks.


RE: ESPHome GPIO - admin - 11-05-2022

sure, all our boards support ESPHome. Here is demo config:

# Example configuration entry
sensor:
- platform: adc
pin: 36
name: "analog-1"
update_interval: 10s
attenuation: 11db

- platform: adc
pin: 34
name: "analog-2"
update_interval: 10s
attenuation: 11db

- platform: adc
pin: 35
name: "analog-3"
update_interval: 10s
attenuation: 11db

- platform: adc
pin: 39
name: "analog-4"
update_interval: 10s
attenuation: 11db


RE: ESPHome GPIO - lautarosrur - 11-05-2022

Thank you admin! The board also has 3 GPIO pins, what number are they? Can I use any of them for PWM output?


RE: ESPHome GPIO - admin - 11-05-2022

here is all GPIO define: https://www.kincony.com/forum/showthread.php?tid=1666
sorry, PWM already have used by Ethernet pins.


RE: ESPHome GPIO - Andrew Adventure - 10-04-2024

Hi,

Is it possible to integrate Gpio's (HT1, HT2, HT3) in esphome?

I'm using kc868-a16 and would like to integrate ds18b20.


Thanks in advance


RE: ESPHome GPIO - admin - 10-05-2024

sure, it's ok.


RE: ESPHome GPIO - Andrew Adventure - 10-05-2024

(10-05-2024, 12:00 AM)admin Wrote: sure, it's ok.

Hi, could you support me with setup?

My curent ymal in esp :

Code:
- platform: adc
    pin: 32
    name: "KC868-A16-HT1"
    update_interval: 10s
   
  - platform: adc
    pin: 33
    name: "KC868-A16-HT2"
    update_interval: 10s
 

  - platform: adc
    pin: 36
    name: "KC868-A16-A1"
    update_interval: 10s
    attenuation: 11db

  - platform: adc
    pin: 34
    name: "KC868-A16-A2"
    update_interval: 10s
    attenuation: 11db

  - platform: adc
    pin: 35
    name: "KC868-A16-A3"
    update_interval: 10s
    attenuation: 11db

  - platform: adc
    pin: 39
    name: "KC868-A16-A4"
    update_interval: 10s
    attenuation: 11db

Is that ok?

Thanks in advance.... Smile


RE: ESPHome GPIO - admin - 10-06-2024

no, GPIO pins use for 1-wire sensor, such as DS18B20,DHT11,DHT22 sensor.
A1,A2,A3,A4 is analog input port, use for ADC.