mikemucc / screenlogic-api

API to control a pentair Screenlogic. Built on top of parnic's screenlogic-node library.
Apache License 2.0
9 stars 2 forks source link

Intellichem not present? #6

Closed etdebruin closed 3 years ago

etdebruin commented 4 years ago

When firing up docker container I get the following:

% docker run -e SL_IP_ADDRESS=192.168.1.15 -it pent
Connecting to ScreenLogic at 192.168.1.15 on port 80...
Got Screenlogic IP address and Port from the Environment.
Pool data update interval is 5 seconds.
Express server listening on port 3000
/usr/src/app/server.js:324
        poolSpaInfo.controllerConfig.equipPresent.intellichem;
                                                  ^

TypeError: Cannot read property 'intellichem' of undefined
    at UnitConnection.<anonymous> (/usr/src/app/server.js:324:51)
    at UnitConnection.emit (events.js:315:20)
    at UnitConnection.onClientMessage (/usr/src/app/node_modules/node-screenlogic/index.js:279:14)
    at Socket.<anonymous> (/usr/src/app/node_modules/node-screenlogic/index.js:148:15)
    at Socket.emit (events.js:315:20)
    at addChunk (_stream_readable.js:295:12)
    at readableAddChunk (_stream_readable.js:271:9)
    at Socket.Readable.push (_stream_readable.js:212:10)
    at TCP.onStreamRead (internal/stream_base_commons.js:186:23)
mikemucc commented 4 years ago

Hey, thanks for opening this issue. I'll need some more info:

mikemucc commented 4 years ago

Ok, master branch has an update that hopefully will fix your issue. Looks like I was calling the wrong method to get intellichem presence info. You can re-pull the docker image or git pull master branch from the repo.

Will you please test and let me know if this fixed it?