Giter VIP home page Giter VIP logo

Comments (18)

argoyle avatar argoyle commented on July 19, 2024 1

So either Ferroamp didn't actually enable the MQTT-broker (if there is actually anything for them to enable, could be that it's always enabled, not sure about that) or your network is acting up somehow. I know that the ip-address you used is the same as you had in the router-sensor but try to make sure that that is actually the adress of the Energy hub.

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024 1

Hi and thanks for the very good follow-up :), MQTT had to be turned on in the local ferroamp from the supplier. Everything now seems to work.

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

If you have Mosquitto installed as a supervised addon you need to add the following to your config:

customize:
  active: true
  folder: mosquitto

That requires a folder named mosquitto under /share and in there I have added a file called energyhub.conf with the following content (change accordingly for your setup):

connection energyhub
address <your energyhub ip-address>
remote_username <username from Ferroamp>
remote_password <password from Ferroamp>
topic extapi/# both

Restart mosquitto and make sure it says it's connecting to your EnergyHub.

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

Hi, thanks for the suggestion. After some exploration of being able to insert the right file in the right folder, it seems to play, but I get an error message:
-------------------------------------log------------------------
[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] mosquitto.sh: executing...
[00:09:02] INFO: Certificates found: SSL is available
[cont-init.d] mosquitto.sh: exited 0.
[cont-init.d] nginx.sh: executing...
[cont-init.d] nginx.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[00:09:03] INFO: Starting NGINX for authentication handling...
[00:09:03] INFO: Starting mosquitto MQTT broker...
1630534143: Loading config file /share/mosquitto/energyhub.conf
1630534143: mosquitto version 1.6.12 starting
1630534143: |-- *** auth-plug: startup
1630534143: Config loaded from /etc/mosquitto/mosquitto.conf.
1630534143: Loading plugin: /usr/share/mosquitto/auth-plug.so
1630534143: ├── Username/password checking enabled.
1630534143: ├── TLS-PSK checking enabled.
1630534143: └── Extended authentication not enabled.
1630534143: Opening ipv4 listen socket on port 1883.
1630534143: Opening ipv6 listen socket on port 1883.
1630534143: Opening websockets listen socket on port 1884.
1630534144: Opening ipv4 listen socket on port 8883.
1630534144: Opening ipv6 listen socket on port 8883.
1630534144: Opening websockets listen socket on port 8884.
1630534144: Warning: Mosquitto should not be run as root/administrator.
1630534144: Connecting bridge energyhub (192.168.0.2:1883)
1630534144: mosquitto version 1.6.12 running
1630534144: New connection from 127.0.0.1 on port 1883.
1630534144: Socket error on client local.core-mosquitto.energyhub, disconnecting.
1630534144: Socket error on client , disconnecting.

Any suggestions on where to look for the error?

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

I've got lots of 1630559603: Socket error on client <unknown>, disconnecting. in my logs as well but nothing regarding the energyhub. Do you get information from Ferroamp into the system? In that case I would probably ignore the socket errors. 😊

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

Hi, this is what I got when I installed the solution (before your setup), and it's the same I find now.
Skjermbilde 2021-09-02 205321

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

Control Status and Extapi Version are our sensors but the rest is probably from some router or something like that. Looking at the information on control status I assume that the MQTT-configuration you have is to the mosquitto-server (rather than directly to ENergyHub) and that the bridge is not working since you would have quite a lot of sensors otherwise. Not sure what we can do to help you investigate though.

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

Now see that those sensors come from the UniFi router.
Should the sensors appeared on the list in Mosquitto broker integration if everything was working correct ?
The only unit i have here now is one tasmota socket
Skjermbilde 2021-09-02 221421

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

No, they should be under the Ferroamp integration. Did you use HACS to install the integration? I would recommend to remove your current configuration of the integration and re-add it and see if that makes any difference. If it doesn't I guess the bridge is not working correctly and no actual information is making it's way into mosquitto.

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

This is how it looks in my integration-page
image

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

OK, I did uninstall, and tryed to install a new one, but getting following message:
Skjermbilde 2021-09-02 225224

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

Correct. The latest version requires the latest version of Home Assistant. Either upgrade your installation or choose version 1.2.1 of Ferroamp in the drop down.

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

Hi, then I have updated and reinstalled ferroamp, but unfortunately there are no more sensors. Attach some pictures of my setup in case you can see that there is something here I have misunderstood
config file
Mosquitto broker
config bilde

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

Everything looks correct to me. You run the same version of mosquitto as I do and everything seems to be correctly setup. What happens if you subscribe to extapi/# if you click configure on the MQTT integration? If the bridge is working you should get one message per second from the EnergyHub. My feeling is that there is something acting up in your network. Could you install a MQTT client and connect it directly to the EnergyHub with the same config as in the bridge-config perhaps.

from ha-ferroamp.

TurboJonte avatar TurboJonte commented on July 19, 2024

I can recommend MQTT Explorer for testing of your Mosquitto configuration.

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

Thanks, I see that I get data from the test setup for mosquitto (pictures 1 and 2)
1
2
and from the setup for my home assistant (pictures 3 and 4),
3
4
but get an error message with connection to ferroamp (picture 5)
5

from ha-ferroamp.

bopbrev avatar bopbrev commented on July 19, 2024

Could there be any missing setup in the local Ferroamp?

from ha-ferroamp.

argoyle avatar argoyle commented on July 19, 2024

Nice to hear. 😊

from ha-ferroamp.

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.