Closed LTrainExpress closed 4 years ago
As far as I can see there is no code to actually communicate with the pool controller yet.
You need to run this: https://github.com/tagyoureit/nodejs-poolController
Yes, but there's nothing in the webClient that queries the pool controller for data.
The code is there... Make sure you pulled the latest code for both the main app and webClient. Try to delete the poolConfig.json
and poolState.json
in the data directory of the main app and restart the program. I fixed a bug not too long ago that the bodies weren't being created properly.
I have the latest versions of the main app from the next branch and the webClient from the main branch. I can query the main app using curl and it logs the GET call, however the webClient does not issue any calls to the main app. I have tried http, https, and SSDP with the same results. I did notice that line 80 of Server.ts is commented out, but uncommenting it results in an ERR_HTTP_HEADERS_SENT error.
Server.ts doesn't talk to the nodejs-poolController app. The web page talks directly to the nodejs-poolController.
Likely the app isn't able to find the controller. Maybe because you don't have SSDP enabled on the controller. Or maybe you have a router blocking the routing/protocol? If you open up the hamburger menu (in the upper right of the webpage) you can turn on/off SSDP and input a manual IP address. I'd try to set a manual address and see if you can get the web pages talking to the app.
Both the controller and the webClient are on the same machine. I've tried setting the IP manually to localhost, 127.0.0.1, the IP address of the host to no avail. The webClient finds the IP address when SSDP is enabled on the controller but it still doesn't communicate. Not sure what else to do at this point. Is there any way to turn logging on in the webClient (at the moment all I get are the GET messages issued from the browser.)
There are 2 places to see logging for the webclient.
The latter will probably be more instructive.
You can also attach your poolConfig.json and poolState.json here and I'll see if I can replicate the issue.
Ok, I see the problem. Even though the webClient is running on the same host, the http requests are coming from where ever the browser is. Since the browser machine is different from the controller/webClient host, I had to configure the controller http to start on the actual IP address of the host (rather than 127.0.0.1) and set the webClient host to use this IP address. Note that I had to restart the webClient to get it to work. Thanks!
Glad you got it working. That's a good distinction and I'll note it in the readme.
When I press the edit button for the pump for the first time, it pops up a window that says Adjust Pump Configuration and below that it says "Loading..." and never actually loads.