Closed berkinet closed 2 years ago
Device details: indigo.devices[1411198383] # "LinkTap Asparagus"
I need the log output from the "print device details" context (right click) menu.
Sorry. Too much wine with dinner (I'm in France)...
Embedded script executor host2 started
Script address : 064ED91D004B1200_2
allowOnStateChange : False
allowSensorValueChange : False
batteryLevel : 100
buttonGroupCount : 0
configured : True
description :
deviceTypeId : shimOnOffSensor
displayStateId : curEnergyLevel
displayStateImageSel : PowerOff
displayStateValRaw : 0.0
displayStateValUi : 0.0 W
enabled : True
energyAccumBaseTime : 2022-10-24 20:22:03
energyAccumTimeDelta : 0
energyAccumTotal : 0.0
energyCurLevel : 0.0
errorState :
folderId : 625929587
globalProps : MetaProps : (dict)
com.flyingdiver.indigoplugin.shims : (dict)
SupportsBatteryLevel : true (bool)
SupportsEnergyMeter : true (bool)
SupportsEnergyMeterCurPower : true (bool)
SupportsOnState : false (bool)
SupportsSensorValue : false (bool)
SupportsStatusRequest : false (bool)
address : 064ED91D004B1200_2 (string)
battery_payload_key : dev_stat.battery (string)
brokerID : 1807946172 (string)
energy_payload_key : dev_stat.speed (string)
message_type : ##LinkTap2## (string)
power_payload_key : dev_stat.volume (string)
shimSensorSubtype : Power (string)
state_dict_payload_key : . (string)
state_location : payload (string)
state_location_payload_key : dev_stat.is_watering (string)
state_location_payload_type : json (string)
state_location_topic_field : 0 (string)
state_on_value : (string)
states_list : (list)
Item : cmd (string)
Item : gw_id (string)
Item : dev_stat (string)
status_action_payload : (string)
status_action_template : (string)
uid_location : topic (string)
uid_location_payload_key : (string)
uid_location_topic_field : 3 (string)
id : 1411198383
lastChanged : 2022-10-24 20:22:03
lastSuccessfulComm : 2022-10-24 20:22:03
model : MQTT On/Off Sensor Device
name : LinkTap Asparagus
onState : None
ownerProps : com.flyingdiver.indigoplugin.shims : (dict)
SupportsBatteryLevel : true (bool)
SupportsEnergyMeter : true (bool)
SupportsEnergyMeterCurPower : true (bool)
SupportsOnState : false (bool)
SupportsSensorValue : false (bool)
SupportsStatusRequest : false (bool)
address : 064ED91D004B1200_2 (string)
battery_payload_key : dev_stat.battery (string)
brokerID : 1807946172 (string)
energy_payload_key : dev_stat.speed (string)
message_type : ##LinkTap2## (string)
power_payload_key : dev_stat.volume (string)
shimSensorSubtype : Power (string)
state_dict_payload_key : . (string)
state_location : payload (string)
state_location_payload_key : dev_stat.is_watering (string)
state_location_payload_type : json (string)
state_location_topic_field : 0 (string)
state_on_value : (string)
states_list : (list)
Item : cmd (string)
Item : gw_id (string)
Item : dev_stat (string)
status_action_payload : (string)
status_action_template : (string)
uid_location : topic (string)
uid_location_payload_key : (string)
uid_location_topic_field : 3 (string)
pluginId : com.flyingdiver.indigoplugin.shims
pluginProps : emptyDict : (dict)
protocol : Plugin
remoteDisplay : True
sensorValue : None
sharedProps : com.indigodomo.indigoserver : (dict)
states : States : (dict)
accumEnergyTimeDelta : 0 (integer)
accumEnergyTimeDelta.ui : 0 seconds (string)
accumEnergyTotal : 0 (real)
accumEnergyTotal.ui : 0.0 kWh (string)
batteryLevel : 100 (integer)
batteryLevel.ui : 100% (string)
cmd : 3 (integer)
curEnergyLevel : 0 (real)
curEnergyLevel.ui : 0.0 W (string)
dev_stat : {"dev_id": "064ED91D004B1200_2", "plan_mode": 5, "plan_sn": 281531291, "is_rf_linked": true, "is_flm_plugin": true, "is_fall": false, "is_broken": false, "is_cutoff": false, "is_leak": false, "is_clog": false, "signal": 83, "battery": 100, "child_lock": 0, "is_manual_mode": false, "is_watering": false, "is_final": true, "total_duration": 30, "remain_duration": 0, "speed": 0.0, "volume": 0.0, "volume_limit": 0.0, "failsafe_duration": 0} (string)
gw_id : 5150D91D004B1200 (string)
subModel :
subType :
supportsAllLightsOnOff : False
supportsAllOff : False
supportsOnState : False
supportsSensorValue : False
supportsStatusRequest : False
version : None
Interesting. The device shows SupportsOnState : false (bool)
Which is wrong.
Did you originally create this as some other kind of device then change it?
I noticed that. I’m not sure what I cold do to change that. OTOH, I was playing around and at one point had the plugin define the states. So, maybe that could have done it?
On 24 Oct 2022, at 20:43, Joe Keenan @.***> wrote:
Interesting. The device shows SupportsOnState : false (bool) Which is wrong.
Did you originally create this as some other kind of device then change it?
— Reply to this email directly, view it on GitHub https://github.com/FlyingDiver/Indigo-Shims/issues/25#issuecomment-1289446213, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAZLU4MGIGROQURK4XDBR6TWE3KFZANCNFSM6AAAAAARNCXF4M. You are receiving this because you authored the thread.
What does "had the plugin define the states" mean?
You could take that template definition from your first post, put it in a new file either in the Templates folder in the plugin itself, or in a folder named "MQTT Shim Templates" in the Indigo install folder, then create a new device based on the template. Then see if that new device has the same problem.
On 24 Oct 2022, at 20:51, Joe Keenan @.***> wrote: What does "had the plugin define the states" mean?
On Generic JSON Device, I entered the key for the dict with the device states.
You could take that template definition from your first post, put it in a new file either in the Templates folder in the plugin itself, or in a folder named "MQTT Shim Templates" in the Indigo install folder, then create a new device based on the template. Then see if that new device has the same problem.
Ok, I added it in the plugin as Server Plugin/Templates/LinkTap.yaml But, where should I see or reference that?
Use the plugin menu command "create device from template".
Ok, That works. It took me a second to find the new device with the "shimOnOffSensor " prefix
Yeah, I think that might have started as a Generic sensor then gotten changed to an onOffSensor. That doesn't work right. I think I later figured out what I need to do to make it work, but haven't done the changes to old code yet.
So, this works, though the error wasn't a show stopper. Since I was mostly playing with the plugins, my first ever try at MQTT, I probably tried every option just to see what they did. So, a little hard to remember what I actually did... But, my guess is something got set in some mode, and didn't get reset when I changed modes.
Indigo 2022.1.2 Device template:
Logged error: