Giter Club home page Giter Club logo

Comments (10)

Cossid avatar Cossid commented on September 2, 2024 1

For unlisted devices, your best bet is installing ESPHome-Kickstart and using the upk2esphome plugin portion of LTChipTool to scan your kickstart device to see if it has device configuration in storage, the ltchiptool will generate a similar profile if the data is there. Otherwise you can use the included pinscan to test pins. There is not more specific advice we can give.

If a relay is backwards, you need to invert the pin.

from upk2esphome.

alecsandes avatar alecsandes commented on September 2, 2024

I used the 3 gang version, and in relay 1, toggling on nothing happens, toggling off, the relay activates and the toggle as well.
When flashing via tuya cloud cutter, I have chosen the profile:
devices/lonsonho-x801a-1-gang-switch.json instead of Tuya generic ATS01L-US 1 Gang Touch Switch

from upk2esphome.

alecsandes avatar alecsandes commented on September 2, 2024

Wow! I am so surprised to have the reply so quick!

For me it is unclear, if I start the tuya-cloudcutter program and choose a device by chip type and fw version (like I did (choose in the begining devices/lonsonho-x801a-1-gang-switch in the list, but then choosen the ESPHomeKickstarter, won't it be having the configuration of what I have chosen when flashing?

Now, I am back on ESPHome kickstart fw. will try now the LTChiptool.

I have other questions as well:

  1. is there a way to go back to tuya fw?
  2. once flashed with ESPHome, I cannot dump anymore the tuya configiuration via serial?
  3. If I have an untouched device, can i use the LTChipTool to read the tuya configuration only by soldering TX/RX pins or I need to remove some chip like in case of FW update via serial?
  4. I have seen that the status lights with the Tuya Generic ATS01L-US 1 gang Touch switch are fading on interaction, which was not before, how can I do replicate it by yaml code building in LTChipTool?

TIA!

from upk2esphome.

kuba2k2 avatar kuba2k2 commented on September 2, 2024

For me it is unclear, if I start the tuya-cloudcutter program and choose a device by chip type and fw version (like I did (choose in the begining devices/lonsonho-x801a-1-gang-switch in the list, but then choosen the ESPHomeKickstarter, won't it be having the configuration of what I have chosen when flashing?

tuya-cloudcutter allows you to flash custom firmware, like ESPHome. It doesn't change any GPIO/pin configuration. What it does though, is change the device's secret keys, so that you cannot connect it back to Tuya Cloud.


Now, I am back on ESPHome kickstart fw. will try now the LTChiptool.

That is the correct way to go. ltchiptool will allow you to pull device config from the switch on runtime (as long as Kickstart is installed) and will generate a (mostly) ready-to-use ESPHome YAML with correct pin config (as long as it's possible - should be).


  1. No, unless you have dumped the firmware (via serial) before using tuya-cloudcutter. If you have, you can simply reflash the dumped firmware via serial again.
  2. You can. Tuya-cloudcutter doesn't overwrite the configuration (apart from device secrets). However, dumping via serial will give you exactly the same result as via ltchiptool+UPK2ESPHome.
  3. I don't know what chip you had to remove, I don't see any removed chip on the photo. "Tuya configuration" is stored in flash, same as firmware. So the same steps apply here like in case of FW update via serial.
  4. They shouldn't be fading, the YAML you have is probably wrong. Generate YAML with UPK2ESPHome and try again.

from upk2esphome.

alecsandes avatar alecsandes commented on September 2, 2024

Hi @kuba2k2 thank you very much for your work and the reply!

  1. I managed, I did like this the other day for a miniswitch, I don't know why I lost time yday, maybe I was tired and overthought

  2. I meant that in many Bekken flashing videos requiring serial communication, a chip or a single wire was removed. e.g.
    image

  3. The status LED (wifi led) is blinking and it is annoying, if I don't want it, I just delete the line?

  4. Are there any other manipulations I can do with these LEDs or buttons (like if pressed for 5s do stuff) in YAML?

from upk2esphome.

kuba2k2 avatar kuba2k2 commented on September 2, 2024

You can do everything that ESPHome allows - browse their documentation at esphome.io to learn more.

I meant that in many Bekken flashing videos requiring serial communication, a chip or a single wire was removed. e.g.

In this one, the chip is most likely not using RX/TX actively, but one of these lines is connected. Usually there are 0 Ohm resistors somewhere - they are easier to remove than the entire chip.

The status LED (wifi led) is blinking and it is annoying, if I don't want it, I just delete the line?

If it's blinking in regular intervals, it means that ESPHome is not connected to Home Assistant. The status LED component is meant to indicate just that.

from upk2esphome.

alecsandes avatar alecsandes commented on September 2, 2024

I come back with feedback, the kickstarter is great! It made the yaml just right reading from device.
The challenge is to find the right profile when flashing the device.

Well, almost everything is great except:

  1. Multigang switches
    Multigang switches after flashing show only on button led, I don't know why, I guess I need to go back to Kickstarter and try the pins myself.
    In yaml I have the following which I believe are the button leds:
output:
  - platform: libretiny_pwm
    id: output_led_1
    pin:
      number: P14
      inverted: true
  - platform: libretiny_pwm
    id: output_led_2
    pin:
      number: P26
      inverted: true
  - platform: libretiny_pwm
    id: output_led_3
    pin:
      number: P11
      inverted: true
light:
  - platform: monochromatic
    id: light_switch_1
    output: output_led_1
  - platform: monochromatic
    id: light_switch_2
    output: output_led_2
  - platform: monochromatic
    id: light_switch_3
    output: output_led_3
  1. Kickstarter ESP turns off light switches after a period of time when the device is not connected to home assistant. How can I disable this?_

from upk2esphome.

Cossid avatar Cossid commented on September 2, 2024

monochromatic & libretiny_pwm may not work for all LEDs, you may want to try binary & gpio instead.

from upk2esphome.

alecsandes avatar alecsandes commented on September 2, 2024

Super! Thank you @Cossid!
Do you know why the switch is turning off after a while if not connected to wifi/home assistant instance by chance?
How can I prevent this?

from upk2esphome.

Cossid avatar Cossid commented on September 2, 2024

Yes, ESPHome will reboot if HA hasn't connected for 15 minutes. You can disable it by changing the value of reboot_timeout on the api component: https://esphome.io/components/api.html?highlight=reboot_timeout

from upk2esphome.

Related Issues (8)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.