vinodsr / node-red-contrib-tuya-smart-device

a node-red module for managing tuya smart devices
https://flows.nodered.org/node/node-red-contrib-tuya-smart-device
MIT License
43 stars 15 forks source link

TypeError: ID and IP are missing from device #50

Closed antonio1000homens closed 3 years ago

antonio1000homens commented 3 years ago

I'm using the generic node to pass on the device details via parameters however I keep getting this message TypeError: ID and IP are missing from device

image

Am I doing anything silly?

vinodsr commented 3 years ago

Don't pass ID and IP at once. Pass either one of it at a time.

On Wed, 7 Apr, 2021, 9:12 pm antonio1000homens, @.***> wrote:

I'm using the generic node to pass on the device name via parameters however I keep getting this message TypeError: ID and IP are missing from device

[image: image] https://user-images.githubusercontent.com/36929120/113894652-20847a00-97c0-11eb-9183-2c693b2a324b.png

Am I doing anything silly?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/vinodsr/node-red-contrib-tuya-smart-device/issues/50, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADQ6OGDPLMDM7ATTRHEBWLTHR4PZANCNFSM42RBKOZQ .

antonio1000homens commented 3 years ago

Yes Tried that also using one or another.. Are you using this node without errors?

vinodsr commented 3 years ago

Can you please confirm the version?

Is it possible for you tot share the logs ?

On Fri, 9 Apr, 2021, 1:47 pm antonio1000homens, @.***> wrote:

Yes Tried that also using one or another.. Are you using this node without errors?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/vinodsr/node-red-contrib-tuya-smart-device/issues/50#issuecomment-816508099, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADQ6OBNVB6AJRXJWTRQ6B3TH2Z27ANCNFSM42RBKOZQ .

antonio1000homens commented 3 years ago

Ok my bad, if this can help anyone the "payload" is actually nested inside another payload.. so where I configured { "deviceID":"..." "payload": {"dps":"1"...} }

should have been

{ "payload":{ "deviceID":"..." "payload": {"dps":"1"...} } }

So yeah was doing something Silly! Thanks for the help!