Comments (13)
The underlying library (https://github.com/thomasmunduchira/myq-api) is relying on state.light_state property to control lights. based on your log, your linked light is using state.lamp_state instead. not sure whether it's a general change in apis or there are different devices (eg light and lamp). so the non-breaking way of introducing the support for "lamp" would be to fork myq-api and make the change there as well. I can try to make this change but would not be able to test as I don't have such devices at home.
from node-red-contrib-myq.
I've pushed new version 0.0.3 with support for "lamp" object. so you can use "lamp_on" and "lamp_off" for them. Please try as I cannot test it myself.
from node-red-contrib-myq.
I missed the subtle difference between light and lamp. I will update and verify the added lamp support.
Greatly appreciate your fast update. Will report back
from node-red-contrib-myq.
FYI, Installing 0.0.3 does not install the dependent myq-api module as 0.0.2 did: -
16 Aug 11:37:54 - [info] Installed module: node-red-contrib-myq
16 Aug 11:37:54 - [info] Added node types:
16 Aug 11:37:54 - [info] - node-red-contrib-myq:myq-device-node : Error: Cannot find module 'myq-api'
Require stack:
- /data/node_modules/node-red-contrib-myq/myq.js
- /usr/src/node-red/node_modules/@node-red/registry/lib/loader.js
- /usr/src/node-red/node_modules/@node-red/registry/lib/index.js
- /usr/src/node-red/node_modules/@node-red/runtime/lib/nodes/index.js
- /usr/src/node-red/node_modules/@node-red/runtime/lib/index.js
- /usr/src/node-red/node_modules/node-red/lib/red.js
- /usr/src/node-red/node_modules/node-red/red.js
16 Aug 11:57:36 - [info] Stopping modified nodes
16 Aug 11:57:36 - [info] Stopped modified nodes
16 Aug 11:57:36 - [info] Waiting for missing types to be registered:
16 Aug 11:57:36 - [info] - myq-device-node```
from node-red-contrib-myq.
I have no issues on brand new node-red (via docker). The 0.0.3 is using my own fork of myq-api which is @dre2901/myq-api:
"dependencies": { "@dre2901/myq-api": "2.0.5" },
Maybe some clean up is needed on your environment. Try to uninstall and install node-red-contrib-myq
from node-red-contrib-myq.
Manually installed the myq-api npm and the Lamp Node correctly shows the lamp state underneath it
Maybe I am misunderstanding something (I'm not a developer)
I send a payload with lamp_on and receive this from the api
TypeError: api.setLampState is not a function
Using payload with string on I get the previous error about it not being a light as expected.
Will check I installed your version of myq-api
from node-red-contrib-myq.
Also running in Docker and did try removing > Restart container > Install myq > restart container - same issue - missing node
This Instance was rebuilt from new using NR 2.x over the weekend and importing my flows.
Just spun up a test NR 2.0.5 and just installed node-red-contrib-myq and same result.
from node-red-contrib-myq.
yep, my fault - forgot to update reference to the new fork in one require
statement, so it was still looking for the old myq-api.
I have updated the node to 0.0.4. Install works without issues now.
There is only weird behaviour of Palette Manager which does not show the latest version 0.0.4 but it does show up on web using https://flows.nodered.org/search?term=node-red-contrib-myq
So for my tests I had to install it manually npm i node-red-contrib-myq
and restart node red
from node-red-contrib-myq.
Working in the test NR container and much closer to working. Install all good via the Palette Manager, but when I send a payload
with lamp_on
I get the following: -
Error message: Invalid action parameter 'Symbol(turnOn)' specified for a lamp; valid actions are MyQ.actions.lamp.TURN_ON and MyQ.actions.lamp.TURN_OFF.
Node shows correctly the status of the lamp, which it did not in version 0.0.2. If I turn it on manually and request status, its shows correctly under the node.
The lamp_on is hitting your forked myq-api but seems to be running into an issue. Or am I using the wrong payload?
Again, thank you
from node-red-contrib-myq.
debug in darkness :) fixed in 0.0.5. now if I am sending lamp_on
for my garage door it properly returns that it is not a lamp. try it for your lamp
from node-red-contrib-myq.
Debugging in the dark works like a charm!
Confirmed - Status poll works and sets label under node.
lamp_on
turns on the lamp and returns status OK
lamp_off
turns the lamp off and returns a status OK.
open
, close
, on
and off
all return I am not a door or a light as expected
Everything else returns detailed status
Many Thanks -- One more automation moved over into Node Red with your help.
from node-red-contrib-myq.
from node-red-contrib-myq.
Yes, V5 API is down. New oAuth login has to be implemented for V6. It is tracked here thomasmunduchira/myq-api#34
from node-red-contrib-myq.
Related Issues (15)
- Node-Red Setup HOT 1
- While opening or closing garage door, getting errors HOT 1
- Newest version generating: ERR_REQUIRE_ESM HOT 15
- Receiving errors with v0.0.9 HOT 31
- Receiving errors with v0.0.15 HOT 2
- Update broke the working version 1
- New errors with v0.0.15 HOT 1
- Won't Install HOT 2
- Where do I find serial number? HOT 3
- v6 support? HOT 4
- Getting error with v0.6 HOT 6
- Garage Door Light Question HOT 1
- I'm getting an error Syntax Error Unexpected Token * (line: 2) running Node red 1.0.3. Is my node red just too old? HOT 1
- This node stopped working for me HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from node-red-contrib-myq.