Search Results

by superninja
Tue Aug 24, 2021 7:42 am
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

Yes, I upgraded it as indicated previously by mparadis.
Firmware Version 1.0.53

I really don't understand why I'm getting different results than both of you :(
by superninja
Wed Aug 18, 2021 3:24 pm
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

Not sure how it worked before but it went back to giving the same error before, maybe a race condition? Thanks Patrick, I doubled checked I was registering the state event before opening and indeed I am. Also, the code pasted by mparadis has the same behaviour. I tested with a VoltageInput, and I ge...
by superninja
Wed Aug 18, 2021 8:38 am
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

I just tested again - I still don't get an event on startup, but I can successfully call the getState() function immediately after the open function, and I don't get the 'Unknown or Invalid Value' error anymore, it gives me the correct state. I will check the voltage and the sensitivity screw to see...
by superninja
Wed Aug 18, 2021 3:59 am
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

the phidget22 libs version for nodejs is 2.7.4 (installed with npm install)
by superninja
Wed Aug 18, 2021 3:26 am
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

I'm using a wireless VINT hub (HUB5000_0), sorry I didn't mention. I upgraded the firmware to version 1.0.53 and ran your code. I only get a state update when I put my finger in the sensor, no initial state update event is sent :( If this is working as expected with the HUB0000, thats great because ...
by superninja
Mon Aug 16, 2021 3:29 pm
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

The onStateChange handler is never called until I interact with the Beam break sensor. So, if there is an object in the sensor when I start the application, meaning the state should be reported as 'false', this is never the case. Nothing is reported until the state changes. I checked, and indeed onc...
by superninja
Thu Aug 12, 2021 9:23 am
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

I'm getting an error such as: name: 'PhidgetError', errorCode: 51, message: 'Unknown or Invalid Value' Maybe the issue is in what I'm trying to do - I'm using a Beam break sensor, and after connecting to the hub and opening the digital input, I want to know the value of the sensor before running oth...
by superninja
Tue Aug 10, 2021 4:02 pm
Forum: Javascript
Topic: Unhandled Promise Rejection
Replies: 16
Views: 59535

Re: Unhandled Promise Rejection

Hi, I am getting this error on some API calls, for example the DigitalInput getState() function. In fact, the sample code for this function, in the API documentation, also gives this error.
Is this some error in the libs? Or in the sample code (and mine)?
Thanks.