Code Monkey home page Code Monkey logo

Comments (4)

tjblevins avatar tjblevins commented on June 3, 2024 1

Sorry... I am such an idiot. It was the event. I must have been drunk when I was typing that and even missed it again after you pointed it out earlier. Sorry... works like a champ now.
image

from node-screenlogic.

parnic avatar parnic commented on June 3, 2024

Several things jump out at me, but it's hard to say what exactly your problem is based on the partial code you've provided.

The main, most likely, issue is that the event is named getPumpStatus, not pumpStatus. However, the code you provided doesn't ever appear to be calling getPumpStatus() anywhere except in response to a pumpStatus event, which won't ever get hit. If you'd like to provide a full gist of or link to your code, I'd be happy to help further, but right now it looks like you've just got the wrong event name.

By the way, if you set the environment variable DEBUG to sl:*, you can see behind-the-scenes of what the library is doing. It's likely that it's emitting logs of some kind about the event that's firing, but since you never capture the event, your calling code seems to hang, waiting for an event that will never come.

from node-screenlogic.

tjblevins avatar tjblevins commented on June 3, 2024

Sorry you are correct I messed up when I adding the call to getPumpStatus(), thanks for pointing that out. I fixed that
Screen Shot 2020-10-06 at 1 11 49 PM
Screen Shot 2020-10-06 at 1 12 45 PM

I am getting an error now...

from node-screenlogic.

parnic avatar parnic commented on June 3, 2024

Does that error happen immediately or after some delay? You're still not hooking the correct event name (getPumpStatus), so an ECONNRESET would indicate that the connection is resetting due to, perhaps, a timeout.

from node-screenlogic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.