Page 36 of 37
Re: Nefit Easy™
Posted: Sunday 22 September 2019 22:05
by Stormryder
If you are still wondering. I had the same problem and the following thread seems to help me.
Could it be that you first installed Node.js V4 and afterwards tried with V6 or V8?
After deleting all Node.js packages and giving some commands from the tread below, it seems to be working now.
https://github.com/robertklep/nefit-eas ... /issues/38
Re: Nefit Easy™
Posted: Thursday 09 January 2020 22:45
by Wanderer
Hi all, just installed Domoticz on my new RPi4, first thing i tried to do is adding my nefit easy to the devices. So i installed the easy-server using the wiki:
https://www.domoticz.com/wiki/NefitEasy But i installed the lateds node.js 13.x instead of the mentioned 10.x version.
When i use pm2 list or pm2 show the server is online, so i added the hardware in domoticz, but the domoticz logs show this error. 2020-01-09 21:45:04.628 Error: NefitEasy: Error getting http data!
when is query the status with this url:
http://127.0.0.1:3000/bridge/ecus/rrc/uiStatus i get this error:
Code: Select all
TypeError [ERR_INVALID_CHAR]: Invalid character in statusMessage
at ServerResponse.writeHead (_http_server.js:285:11)
at ServerResponse.writeHead (/usr/lib/node_modules/nefit-easy-http-server/node_modules/on-headers/index.js:44:26)
at ServerResponse._implicitHeader (_http_server.js:237:8)
at write_ (_http_outgoing.js:659:9)
at ServerResponse.end (_http_outgoing.js:776:5)
at ServerResponse.send (/usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/response.js:221:10)
at /usr/lib/node_modules/nefit-easy-http-server/lib/cli/server.js:46:18
at Layer.handle_error (/usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/router/layer.js:71:5)
at trim_prefix (/usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/router/index.js:315:13)
at /usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/router/index.js:284:7
at Function.process_params (/usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/router/index.js:335:12)
at Immediate.next (/usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/router/index.js:275:10)
at Immediate._onImmediate (/usr/lib/node_modules/nefit-easy-http-server/node_modules/express/lib/router/index.js:635:15)
at processImmediate (internal/timers.js:458:21)
Anyone got an idea how to fix this.
Re: Nefit Easy™
Posted: Sunday 26 January 2020 10:45
by tranzzy
I've been at it all night without success,
I tried to follow these instructions.
https://eye-vision.homeip.net/domoticz-configureren/
I have a fully updated raspberry pi 4 running Ubitquiti contoller / Pi-Hole and Domoticz.
I manage to get the script to run and go online. But i think there the Easy-server is not attached to port 3000.
I added the Nefit hardware to Domoticz but there is no data coming in because of it.
I tried rolling back the things i installed but i must admin that my Linux knowledge ends here to really understand what i'm doing.
This is where i'm at at the moment.
Code: Select all
pi@raspberrypi4:~ $ curl http://127.0.0.1:3000/bridge/ecus/rrc/uiStatus
curl: (7) Failed to connect to 127.0.0.1 port 3000: Connection refused
pi@raspberrypi4:~ $ pm2 list
┌─────┬────────────────────────┬─────────────┬─────────┬─────────┬──────────┬────────┬──────┬───────────┬──────────┬──────────┬──────────┬──────────┐
│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │
├─────┼────────────────────────┼─────────────┼─────────┼─────────┼──────────┼────────┼──────┼───────────┼──────────┼──────────┼──────────┼──────────┤
│ 0 │ nefiteasyhttpserver │ default │ N/A │ fork │ 8652 │ 0s │ 161… │ online │ 0% │ 2.5mb │ pi │ disabled │
└─────┴────────────────────────┴─────────────┴─────────┴─────────┴──────────┴────────┴──────┴───────────┴──────────┴──────────┴──────────┴─────────
pi@raspberrypi4:~ $ pm2 show nefiteasyhttpserver
Describing process with id 0 - name nefiteasyhttpserver
┌───────────────────┬──────────────────────────────────────────────────┐
│ status │ online │
│ name │ nefiteasyhttpserver │
│ namespace │ default │
│ version │ N/A │
│ restarts │ 16772 │
│ uptime │ 0s │
│ script path │ /etc/init.d/nefiteasyhttpserver.sh │
│ script args │ N/A │
│ error log path │ /home/pi/.pm2/logs/nefiteasyhttpserver-error.log │
│ out log path │ /home/pi/.pm2/logs/nefiteasyhttpserver-out.log │
│ pid path │ /home/pi/.pm2/pids/nefiteasyhttpserver-0.pid │
│ interpreter │ bash │
│ interpreter args │ N/A │
│ script id │ 0 │
│ exec cwd │ /home/pi/nefit-easy-http-server │
│ exec mode │ fork_mode │
│ node.js version │ N/A │
│ node env │ N/A │
│ watch & reload │ ✘ │
│ unstable restarts │ 0 │
│ created at │ 2020-01-26T00:24:05.657Z │
└───────────────────┴──────────────────────────────────────────────────┘
Divergent env variables from local env
┌────────────────┬──────────────────────────────────────┐
│ PWD │ /home/pi/nefit-easy-http-server │
│ SSH_CONNECTION │ 192.168.1.138 53224 192.168.1.200 22 │
│ XDG_SESSION_ID │ c4 │
│ SSH_CLIENT │ 192.168.1.138 53224 22
Re: Nefit Easy™
Posted: Sunday 26 January 2020 21:46
by Geitje
OK, I can try to help, but I do not have that much knowledge myself, so someone else may jump in...
It seems it cannot connect to port 3000. Is that one already used? Try
and please check wether 3000 is already used?
Re: Nefit Easy™
Posted: Sunday 26 January 2020 22:22
by tranzzy
Thanks bud.
I ran that already (forgot to mention). No port 3000 in use.
I also got a an "authtication failed" error in the log file. But it's not failing against my Nefit controller. I know that for sure.
For now gave up and restored an automatic img file of the day before to a different SD so i could try again with a clean start. I tried so many things that it became a mess today.
Re: Nefit Easy™
Posted: Tuesday 25 February 2020 20:18
by frankwijers
I'm running in some issues with this. I have installed everything and I'm trying to get it running.
Everytime I try to start the server I get the message "XMPP authentication failure" while I'm sure that serial, access code and password are correct.
I start it in this format:
easy-server --serial=serialnumber --access-key=mykey --password=mypassword
Any suggestions to what point I should start searching?
EDIT: something with a serial should have 9 digits, only had 8. Keep using arrow up for last commands .....
HTTP server listening on
http://127.0.0.1:3000
curl
http://127.0.0.1:3000/bridge/ecus/rrc/uiStatus
Already got it in Domoticz.
Re: Nefit Easy™
Posted: Saturday 29 February 2020 11:00
by Geitje
I think you can do this if you follow this tutorial:
https://www.domoticz.com/wiki/NefitEasy
Re: Nefit Easy™
Posted: Saturday 29 February 2020 20:50
by Geitje
Re: Nefit Easy™
Posted: Monday 02 March 2020 8:57
by Geitje
I see you already asked on Github, and was answered... I never tried myself.
Re: Nefit Easy™
Posted: Tuesday 26 May 2020 19:09
by xyntec
I changed from PI to windows server this week, but I can't seem to get the easy communication working, I installed Node JS on the server, and installed the nefit easy server too, and on the server itself I can read evrything from the easy, and also change temperature etc. Of course I can only do this with a command including all customer data (serial/accesscode/password), I know in the PI, I had to give the export commands after starting the server, and after that everything is available in domoticz. I have no idea what the export command does (I just followed the instructions to get it running), but I suppose it saves the data to some configuration file that domoticz uses?
Because with the windows installation I only get error could not get http data, I suppose because the user data is missing. I have no idea however to use this export command in node JS? It is not recognized as is.
Anybody knows how to solve this? How and where do I put the user data, so that domoticz can get/set values from/to the easy?
Re: Nefit Easy™
Posted: Wednesday 11 November 2020 19:51
by King1987
Hi All,
I have running on my Synology Domoticz (2020.2 build 12626) and in Docker I have running the Nefit Easy Server (the pre-made one, from balk77).
Filled in the serialnumber/password/acceskey and that works perfectly. Standard 127.0.0.1 and port 3000.
I fill in Domoticz the information for the server (see screenshot) but I don't see (also not after a few minutes) the nefit pear in Devices.
What do I wrong in your opinion?
Re: Nefit Easy™
Posted: Wednesday 11 November 2020 20:02
by FireWizard
Hi, @King1987
What is the real IP Address of your Synology Domoticz and the real IP Address of your Docker container with the Nefit Easy Server?
As long as they are different, you cannot use the local loop-back address 127.0.0.1, but you should use the real IP Address of your Docker container with the Nefit Easy Server.
Regards
Re: Nefit Easy™
Posted: Tuesday 24 November 2020 19:32
by King1987
FireWizard wrote: ↑Wednesday 11 November 2020 20:02
Hi, @King1987
What is the
real IP Address of your Synology Domoticz and the
real IP Address of your Docker container with the Nefit Easy Server?
As long as they are different, you cannot use the local loop-back address 127.0.0.1, but you should use the
real IP Address of your Docker container with the Nefit Easy Server.
Regards
Sorry, very late reply, but busy times.
You mean that I need to put a ip adres in the range of my Docker? The Docker container is running also on my Synology, so Domoticz and Docker are on the same system.
My IP range is different then 127.0.0.1 (it is in the 192.168 range). Or is the not what you mean?
Re: Nefit Easy™
Posted: Wednesday 25 November 2020 16:26
by FireWizard
Hi, @King1987,
You wrote:
You mean that I need to put a ip adres in the range of my Docker? The Docker container is running also on my Synology, so Domoticz and Docker are on the same system.
Yes, use the IP address and not 127.0.0.1. Your docker container is not on the same network as the host (Synology).
This means that, even if they are physically on the same hardware Domoticz (and the Synology NAS) and Docker are on different networks.
See:
https://docs.docker.com/config/containe ... etworking/
Regards
Re: Nefit Easy™
Posted: Sunday 27 December 2020 3:02
by TheFons
I have installed the Nefit easy-server, following all the steps in the wiki. working with Pi4.
Easy-server did not start.
I did update all parts of the installation and also the OS
assured the ssl security was adjusted.
the PM2 start proces stops the process after to many restarts.
I started the easy-server on the commandline with all nessecary items (access-key, password and serial )
Like: easy-server --serial='xxx xxx xxx' --access-key='xxxx xxxx xxxx xxxx' --password=6932 (serial and access-key use single quotes, password uses none as there are no spaces in my password.
result: XMPP authentication failure
The mobile app uses the excact same items , access-key, password and serial , and that works
I have used ALL available options,
if I use the option -v I get 5.0.3, so the version option (together with all the other options) still works.
So what are my options?
One thing the was different is the directory easy-server resides in: /usr/local/bin/ and not in the directory the wiki states /usr/bin/, but this was ok according the programmer of easy-server.
If i change one of the options like the quotes around the serial number, ik get another responce: Usage: easy-server [options]
Anyone some advice?
Re: Nefit Easy™
Posted: Sunday 27 December 2020 14:11
by waltervl
Did you check the ownership of the .PM2 folder in home?
see
https://www.domoticz.com/wiki/Talk:NefitEasy
I think it depends if you used sudo or not when installing the prerequisites.
Re: Nefit Easy™
Posted: Sunday 27 December 2020 16:46
by TheFons
I am one step further: PM2 now only starts up the nefithttpserver once (as it should, no more restarts), and in the logs there are no more errors, only that Easy-server is online. so it looks like this part is ok.
I have disabled IPv6, and I edited the Hosts file where i removed the IPv6 entries
I have tested it with SUDO as wel as with normal Pi user, Both work,BUT
netstat does not show ANY port 3000 open.
Dominicz device nefit still gives : Error: NefitEasy: Error getting http data
I am out of thoughts. why is there no netstat port 3000 in de lists?
Why is NefitEasy in Domoticz not getting http data?
Re: Nefit Easy™
Posted: Sunday 27 December 2020 21:24
by waltervl
Please also check the github issues of nefit ease server. Did you check the openssl setting of your RPi?
https://github.com/robertklep/nefit-eas ... -510818042
Re: Nefit Easy™
Posted: Tuesday 29 December 2020 1:31
by TheFons
hi Walter, Thanx for your reply,
Ik have made a new issue :
https://github.com/robertklep/nefit-eas ... /issues/47
It was the proposed setting in OpenSSL that prevented the pm2 nefiteasyhttpserver to connect in the first place.
so I changed them. But in both cases the Nefit easy http plugin refuses to load the http data (see my issue on github)
I still can not see my Nefit in Domoticz, waiting for Robert to have a look at it???
Re: Nefit Easy™
Posted: Wednesday 13 January 2021 0:27
by TheFons
Solved:
The Wiki pages nowhere state that the Access-key and the serial-Number should NOT use the spaces that you can see in the Android Nefit App, or on the underside of the Nefit Thermostate.
When I Copied the Number and Key from the App into the startupline in the NefitEasyHTTPserver.sh I got nowhere,
It looks like it was online in de "PM2 list" commandline, en viewing the PM2 logs, you could see a lot of activity and the the server just restarting.
It had all to do with authentication: If the Access_key and/or the Serial_Number contain spaces, just delete then, so the Access_key has 9 numbers and the Access_Key just 16 letters/numbers, This Solved my problems.
Grtz Fons