-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Add a smart water heater switch with touch function of model TS0601_b… #10373
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -20407,4 +20407,40 @@ export const definitions: DefinitionWithExtend[] = [ | |||||
| ], | ||||||
| }, | ||||||
| }, | ||||||
| { | ||||||
| fingerprint: tuya.fingerprint("TS0601", ["_TZE284_udaucpdi"]), | ||||||
| model: "TS0601_boiler_6", | ||||||
| vendor: "AVATTO", | ||||||
| description: "Smart boiler switch", | ||||||
| extend: [tuya.modernExtend.tuyaBase({dp: true, forceTimeUpdates: true})], | ||||||
| exposes: [ | ||||||
| e.switch(), | ||||||
| e.enum("level", ea.STATE_SET, ["T0", "T30", "T60", "T90", "T120", "TON"]).withDescription("LEVEL"), | ||||||
| e.numeric("countdown", ea.STATE_SET).withValueMin(0).withValueMax(7200).withUnit("s").withDescription("countdown"), | ||||||
| e.numeric("cur_current", ea.STATE).withUnit("mA").withDescription("Current"), | ||||||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Use, |
||||||
| e.numeric("cur_power", ea.STATE).withUnit("W").withDescription("Current Power"), | ||||||
| e.numeric("cur_voltage", ea.STATE).withUnit("V").withDescription("Current Voltage"), | ||||||
| ], | ||||||
| meta: { | ||||||
| tuyaDatapoints: [ | ||||||
| [1, "switch_1", tuya.valueConverter.onOff], | ||||||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
Otherwise I don't expect it works |
||||||
| [21, "cur_current", tuya.valueConverterBasic.scale(0, 30000, 0, 30000)], | ||||||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. please remove the |
||||||
| [22, "cur_power", tuya.valueConverter.divideBy10], | ||||||
| [23, "cur_voltage", tuya.valueConverter.divideBy10], | ||||||
| [ | ||||||
| 102, | ||||||
| "level", | ||||||
| tuya.valueConverterBasic.lookup({ | ||||||
| T0: tuya.enum(0), | ||||||
| T30: tuya.enum(1), | ||||||
| T60: tuya.enum(2), | ||||||
| T90: tuya.enum(3), | ||||||
| T120: tuya.enum(4), | ||||||
| TON: tuya.enum(5), | ||||||
| }), | ||||||
| ], | ||||||
| [103, "countdown", tuya.valueConverter.raw], | ||||||
| ], | ||||||
| }, | ||||||
| }, | ||||||
| ]; | ||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not quite clear to me what this does, could you extend the description?