Skip to content
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

Node RED crash on some commands #6

Open
8666 opened this issue Oct 14, 2018 · 4 comments
Open

Node RED crash on some commands #6

8666 opened this issue Oct 14, 2018 · 4 comments

Comments

@8666
Copy link

8666 commented Oct 14, 2018

TypeError: _this6.GetLogicalAddresses(...).includes is not a function
at /root/.node-red/node_modules/node-red-contrib-cec/node_modules/@damoclark/cec-monitor/lib/cec-monitor.js:918:40
at Array.forEach (native)
at null._onTimeout (/root/.node-red/node_modules/node-red-contrib-cec/node_modules/@damoclark/cec-monitor/lib/cec-monit or.js:915:11)
at Timer.listOnTimeout (timers.js:89:15)

Will try to find the exact reason

@8666
Copy link
Author

8666 commented Oct 16, 2018

When I power on or off the TV with remote I get the same message. Also If I send power ON command from Node RED using:

{"source":null,"target":0,"opcode":"IMAGE_VIEW_ON"}

@damoclark
Copy link
Owner

Hi @8666

What I have come to learn is that many vendors don't implement the CEC specification correctly and so reliability varies depending on the equipment you use. I was only really able to test with the devices I had - Panasonic and Sony.

And unfortunately I don't have time at present to work on issues relating to this module.

I will however gladly accept PRs and merge them into the codebase if fixes are provided. :)

Damo.

@8666
Copy link
Author

8666 commented Oct 17, 2018

I have Philips. I used my own software based on libcec but wanted to move to something more up-to-date and maintained by others as I could not do it myself but ended with the same problem here :)

It is true that many TVs do not behave as expected on some commands. I will try to take a look at your code. Thanks for your node red contribution.

@8666
Copy link
Author

8666 commented Oct 17, 2018

I replaced

  if (this.GetLogicalAddresses().includes(t) || phys === null) {
    return
  }

with

return

only

at https://github.com/damoclark/cec-monitor/blob/master/src/cec-monitor.js

It is not crashing anymore, still able to get the powerstatus of the TV..not sure what should not work :)

I see there are differnces from https://github.com/senzil/cec-monitor/blob/master/src/cec-monitor.js

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants