Open gfanini opened 6 months ago
What DPS values did you get from it when you ran the wizard (python -m tinytuya wizard
)? I recommend looking at each of those and use the iot.tuya.com portal to investigate them. You can then manipulate those values with tinytuya's set_value(index, value, nowait)
function.
I registered on iot.tuya.com portal as individual developer, is it free of charge ?
what should I use here, I tried to put the key from python -m tinytuya scan
"devices": [
{
"id": "bfb63ee0a1bff588ee0uw9",
"ip": "192.168.1.74",
"active": 2,
"encrypt": true,
"productKey": "rsyse6okboceueag",
"name": "",
"key": "",
"mac": "",
"ability": 0,
"token": "",
"wf_cfg": "",
"dev_type": "default",
"origin": "broadcast",
"ver": "3.3"
}
binary@ECLLAP12:/mnt/c/Users/gfanini$ python3 -m tinytuya wizard TinyTuya Setup Wizard [1.13.1]
Enter API Key from tuya.com: rsyse6okboceueag
Enter API Secret from tuya.com:
what would be the "api secret" ? also here there seems to be a method to enumerate the "DP" is it data points https://www.zigbee2mqtt.io/advanced/support-new-devices/03_find_tuya_data_points.html
When you set up your free trial account, they will give you an API key and secrete. Follow the instructions here: https://github.com/jasonacox/tinytuya#setup-wizard---getting-local-keys
A PDF version is here, which might help: https://github.com/jasonacox/tinytuya/files/12836816/Tuya.IoT.API.Setup.v2.pdf
I enclose what DPs it extracted, there seem to be numbers 1-18 but no clue anything to reset the device somehow ... Polling local devices... [Netbot S15 ] 192.168.1.74 - [Off] - DPS: {'1': False, '4': 'foward', '5': '0', '6': 50, '16': 0, '17': 0, '18': 0, '101': 'low_step'} devices.json
possibly there would be "hidden" debug/development ones ? https://github.com/rospogrigio/localtuya/issues/1188
this is the list from the iot website
how could I read or set a value in this DP
Code:water_step Function Name:Scrub mode Data Transfer Type:Send & report Data Type:Enum Remarks:water_step
Here is a small code sample of how you would set DP values:
# Connect to Device
d = tinytuya.OutletDevice(DEVICEID, DEVICEIP, DEVICEKEY)
d.set_version(3.3)
# Show status of device
data = d.status()
print('\nCurrent Status: %r' % data)
# Change DPS 18 as example
d.set_value(18, 1)
# Show status of device
data = d.status()
print('\nCurrent Status: %r' % data)
could it be possibly to issue reset to cleaner robot with tuya protocol 3.3 ? it is ikohs S15 :
snapshot.json
thank you for possible clues for say "factory reset" that it's acting strangely.