Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


Question

Posted

Hi2Uall!

 

I configured a (working) Raspberry Pi 3 Raspbian with Node-Red and MQTT (see this excellent YouTube

Please login or register to see this link.

for explanation). Now on working, and learning (a lot) how to implement this. So far it is very useful to connect several IoT services.

 

Did anyone have an idea how to connect the HC2 to an MQTT server?

 

18 answers to this question

Recommended Posts

  • 0
Posted

The topic has been moved from "

Please login or register to see this link.

" to "

Please login or register to see this link.

".

 

Temat został przeniesiony z "

Please login or register to see this link.

" do "

Please login or register to see this link.

".

  • 0
Posted

Dear,

 

you can configure a web service in node-red and use these from lua, HC2.

 

Brgds,

  • 0
  • Inquirer
  • Posted

    Thanks for responding Marc.

     

    I was wondering if it could be done directly from lua, without the need of setting up a (extra) webservice. Or is there a function-block in node red I overlooked?

    • 0
    Posted

    mqtt directly from HC2 lua, i'l don't think it's possible. However,  If you can install,

    Please login or register to see this link.

    on HC2 then !?  

    • 0
    Posted
    1 hour ago, marc.calis said:

    mqtt directly from HC2 lua, i'l don't think it's possible. However,  If you can install,

    Please login or register to see this link.

    on HC2 then !?  

    If you do not need support that would be very easy.

    • 0
  • Inquirer
  • Posted

    Hmm. But as you know not every user has root access....I do though. Thanks for your suggestion @marc.calis!

     

    @robmac, do you have a short how to?

    • 0
    Posted
    On 4/3/2017 at 3:22 AM, Lambik said:

    Hi2Uall!

     

    I configured a (working) Raspberry Pi 3 Raspbian with Node-Red and MQTT (see this excellent YouTube

    Please login or register to see this link.

    for explanation). Now on working, and learning (a lot) how to implement this. So far it is very useful to connect several IoT services.

     

    Did anyone have an idea how to connect the HC2 to an MQTT server?

     

     

    Hi @LambikChecked out that vid, what a great platform. Interested to hear @robmac's reply

    • 0
  • Inquirer
  • Posted
    9 minutes ago, Jamie mccrostie said:

     

    Hi @LambikChecked out that vid, what a great platform. Interested to hear @robmac's reply

    FYI, I just started to explore the node-red/Mqtt platform and realised things, in a short time, what the HC2 will never able to do. Now I'm trying to find a (simple) solution to communicate with the HC2.

    • 0
    Posted
    Just now, Lambik said:

    FYI, I just started to explore the node-red/Mqtt platform and realised things, in a short time, what the HC2 will never able to do. Now I'm trying to find a (simple) solution to communicate with the HC2.

     

    RE hc2 node surely similar to how homebridge plugin is set up?

    • 0
  • Inquirer
  • Posted

    I don't know Homebridge.... :oops:

    • 0
    Posted (edited)

    @Lambik Have a quick read of hombridge posts , i could be miles away here but similar json file exchange between HC2 and pi

    Edited by Jamie mccrostie
    • 0
    Posted

    @Lambik

    Q: Now I'm trying to find a (simple) solution to communicate with the HC2?

     

    A: I made a quick and dirty example with node-red, hope this help?

    Needed: HC2, Node-red, Mosquito (MQTT) broker, change my settings (IP, MQTT broker according to you system)

    How it's working: Sends a deviceID & command from (HC2, browser, ...) to node-red http-server, node-red send & receive MQTT via broker & send result to HC2 (device turnoff)  

     

    Included: (file, node-red flow included, copy, import in node-red)  change parameters for your setup, HC2 IP, Name, Password, (Broker) or use a public broker

     

    ps: this simple test looks stupid but it work for me, feedback & more idea's welcome

     

    Please login or register to see this attachment.

    • 0
  • Inquirer
  • Posted

    Thank you Marc, I have something similar right now :-D! Like you way of thinking! :mrgreen:

     

    But with this solution you have to 'ask' the HC2 what the status is of a device every time. I'm trying to setup a, sort of, a local webhook.

     

    I'm looking for a solution where the HC2 'talks' to the mqtt-broker, for example, to use in a scene. To be more specific, to use send the content of a global variable on content change.

    • 0
    Posted

    good thinking, but confusing for me.

     

    I presume you would like something like

    Please login or register to see this link.

      or

    Please login or register to see this link.

    or both?

     

    The normal MQTT binding (use in a scene is easy), the persistence binding is a pain in the ... , i simply don't know how to solve this, maybe someone else has a brilliant idea !?

     

    • 0
  • Inquirer
  • Posted

    Mqtt binding should be enough for the time being. I don't know MQTT very well (just started) and you say it could be easy. What are you thinking about?

     

     

    • 0
    Posted
    8 minutes ago, Lambik said:

     

    Mqtt binding should be enough for the time being

     

     

    @marc.calis

    @Lambik

     

    I would also be interested :-D

    My PV panels have data exposed via an MQTT API and I'd like to be able to pull this into my HC2

    • 0
  • Inquirer
  • Posted
    On 5-4-2017 at 9:20 PM, Jamie mccrostie said:

    @Lambik Have a quick read of hombridge posts , i could be miles away here but similar json file exchange between HC2 and pi

    I'm right if homebridge is intended for the use of Apple Homekit products?

    Do you have an URL to check?

    • 0
    Posted (edited)
    6 hours ago, Lambik said:

    I'm right if homebridge is intended for the use of Apple Homekit products?

    Do you have an URL to check?

     

    IOS SIRI control of HC2 thru Pi search home bridge posts on this forum

    Edited by Jamie mccrostie

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Answer this question...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    ×
    ×
    • Create New...