Esp-homekit-devices: Template Help

Created on 15 Nov 2019  路  23Comments  路  Source: RavenSystem/esp-homekit-devices

Hi,

Thanks everyone so much for the hard work on this!

I have managed to flash this firmware on some Tuya Sockets using Tuya-Convert but now I need some help with a template.

Not sure if it will help but this is the Tasmota template for the same socket.

Hopefully someone can point me in the right direction!

Thanks again!

HAA

Most helpful comment

Hi @RavenSystem, would you like your firmware bundled with tuya-convert? I'm sure there are others who would appreciate your HomeKit integration, thanks @tonysprenk for the tip off

All 23 comments

For anyone that's interested I can do a small write up of how I got esp-homekit-devices flashed OTA (!!!) onto a Tuya device.

This is amazing! Yes, please, write it.

Have you tried this template?
https://github.com/RavenSystem/esp-homekit-devices/wiki/HAA-Templates#tuya-swa1-with-esp8266-smart-plug

For those curious: I changed the flash mode of rboot.bin and combined it with the other 2 binaries offered by this repository. I was then able to flash the Tuya device using Tuya-convert. Pretty simple in the end!

@RavenSystem the template works in all aspects accept for it doesn鈥檛 turn the relay on. The physical button changes the color of the led and the state in home app and vis verse the same with the button in the home app but the relay isn鈥檛 switched on or off. What should I change?

Sent with GitHawk

GPIO 5 is not the relay. It seems to be only status LED. We must find GPIO relay. Maybe an Internet search helps.

@tonysprenk Nice !

Could you please share the details on how to combine the 3 files into one?

Update : found details here : https://github.com/ct-Open-Source/tuya-convert/issues/389

@tonysprenk Please, can you share tuya-firmware version using otaboot.bin? I could include it in the repo.

@tonysprenk What is your device? Here there is GPIO info about Tuya devices: https://github.com/ct-Open-Source/tuya-convert/wiki/Compatible-devices-(HTTP-firmware)

Hi @RavenSystem, would you like your firmware bundled with tuya-convert? I'm sure there are others who would appreciate your HomeKit integration, thanks @tonysprenk for the tip off

@RavenSystem @kueblc

its the moeshouse I think relay should be GPIO12.

We should look into building some safeties into the HK firmware because it鈥檚 designed to be flashed by wire of anything goes wrong the device is bricked and there is no return. Like the wrong WiFi password. Or I for example uploaded a wrong template and now one of the devices is bricked as I can鈥檛 put it in setup mode anymore. @RavenSystem is this correct?

@tonysprenk

I'm very interested in flashing HAA on a Blitzwolf BW-LT11 (a very cheap but nice color led strip RGBW).

Which firmware did you use to flash? I saw on reddit page you gave a link for a thirdparty firmware bin file, is this HAA?
After flashing do you have OTA functionality for getting HAA/Ravencore updates?
After flashing, are you able to use same method to get back to original firmware?

Thanks & Regards

Yes the binary I linked is a modified version of HAA. It includes the 3 binaries offered in this repository. After flashing every thing is done OTA. There is no return to original firmware after flashing. Make sure you know the different GPIO pins for R, B, G and W and any other buttons or anything your device might have so you can make a working HAA template. Let us know your results!

This is the command to backup your original firmware:
esptool.py -p com4 -b 115200 read_flash 0 0x200000 c:/firmware.bin

This is the command to backup your original firmware:
esptool.py -p com4 -b 115200 read_flash 0 0x200000 c:/firmware.bin

thanks! but I wouldn't be able to use same method to go back right? I would probably need to solder wires directly to the chip.

I don鈥檛 know which method will you use and need you solder the cables. Sonoff basic,th no need to solder , magic home led controller need to solder. I don鈥檛 know your chip.

Soldering or not, it looks that going back via OTA or TuyaConnect is not possible once you flash a different firmware. But thanks for the command to save the original firmware. It will be handy.

Tuya-Convert also backs up the original firmware and gives you a chance to put it back (undo) before you do the final flash.

@kueblc Yes, I think installing HomeKit firmware using Tuya-Convert is a good idea for those compatible devices. But I think the best choice is using otaboot.bin to allow then to update it through OTA.
https://github.com/RavenSystem/esp-homekit-devices/wiki/Installation#installation-with-ota

@tonysprenk Try this:

{"c":{"b":[{"g":13,"t":5}]},"a":[{"t":2,"0":{"r":[{"g":5},{"g":12}]},"1":{"r":[{"g":5,"v":1},{"g":12,"v":1}]},"b":[{"g":13}]}]}

@RavenSystem thanks! I will try this out. Like I said in my previous comment I have one plug that doesn鈥檛 work anymore. The led is red and flashes once every 30 seconds. I think in the previous template I tried the button sequence to put it into setup mode was 5: hold indefinitely but no matter how long I hold the button nothing happens. I also have one plug that is in setup mode, when I connect to the AP and put in al the credentials it seems to never install the HAA firmware and just keeps putting out the AP. Any ideas?

@tonysprenk Did you installed otaboot.bin or directly HAA main.bin?

otaboot.bin as part f the tuya_convert flash and main.bin once the AP is created.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

fluppie picture fluppie  路  5Comments

i3laze picture i3laze  路  3Comments

noobydp picture noobydp  路  5Comments

Codi878 picture Codi878  路  3Comments

macjl picture macjl  路  5Comments