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


Recommended Posts

Posted
17 minutes ago, FSE said:

how to pass a json from VD to nodered?

I do not know why you trying to pass logic and data from VD to Node-red, cuz we can just pass some states from VD to node-red via flags (values) but your workaround is OK.

as far as I can remember we asking Fibaro developers add userdata to VD for easy using but Fibaro developer is busy-bee. 

Posted

v0.0.79

 

a topic for HC2 device eq "queryState" initiates immediate get the current status of the device.

also now you can pass a msg.payload integer as device Id for  "queryState". HC2 device must be configured with deviceId = 0.

 

typical flow:

you load HTML page. on HTML page you show the current state of the door with id 431/ id 313 / etc

you get an empty state on the load page because the device(s) is not sent to HC2 own state yet

it's not good.

ok.

in HTML page we provide code

Please login or register to see this code.

NODE-RED

Please login or register to see this code.

 

html page - F5 (refresh)

voila

Please login or register to see this image.

 

  • 2 weeks later...
Posted (edited)

Hi,

if a want to trig when my universal sensor change it's status (maybe only shortly like 1 second)

Can I use following function? Does it buffer a change or is it a risk that I will miss the short change (false-true-false)?

 

Please login or register to see this attachment.

Edited by petrho
Posted

As l know Fibaro announce all triggered events so you can not to worry about this

@petrho

Posted
2 hours ago, 10der said:

As l know Fibaro announce all triggered events so you can not to worry about this

@petrho

So even if the change is between the 10 seconds - it will be buffered so I don't miss it.

Example

0 sec .                                       5 sec .                                       7 sec                                                                   10 sec .  

check status                            universal sensor true            universal sensor false                                      check status

 

what will the status be at 10 seconds?

Posted (edited)

@petrho all events without doesn't make any difference stored in fibaro core and I can catch it via fibaro API.

fibaro api function "refresh" always return all event since the last calling. so if you setup node with 1 minute (sic) interval you will get all (SPAM ;) ) events what occurred at this minute... 

 

sorry, maybe I was unclear

Edited by 10der
  • Thanks 1
Posted (edited)
21 hours ago, 10der said:

@petrho all events without doesn't make any difference stored in fibaro core and I can catch it via fibaro API.

fibaro api function "refresh" always return all event since the last calling. so if you setup node with 1 minute (sic) interval you will get all (SPAM ;) ) events what occurred at this minute... 

 

sorry, maybe I was unclear

 It seems to work fine! Thanks!

Edited by petrho
  • 1 month later...
Posted

greetings,

it seems that fibaro device module can not query devices on pressing magnifier icon. I use 0.80 .

Posted

Oopps. :( will do... at evening. 

  • 2 weeks later...
Posted

Just another question - does your great solution also work with a Fibaro Home Center Lite?

Posted

IMHO yes

  • 1 month later...
Posted

greetings!

A silly question: can I change from node-red the value of a label directly or should I need to send to globalVar and grab the change on fibaro?

I like to have globarVar entries only for variables that are used on more than one vd/scenes, so that is the reason of my request.

Any helpful, simple example is welcome :)

 

Posted (edited)
3 hours ago, FSE said:

greetings!

A silly question: can I change from node-red the value of a label directly or should I need to send to globalVar and grab the change on fibaro?

I like to have globarVar entries only for variables that are used on more than one vd/scenes, so that is the reason of my request.

Any helpful, simple example is welcome :)

 

 

Please login or register to see this link.

Edited by 10der
Posted (edited)
9 hours ago, 10der said:

 

Please login or register to see this link.

Dear @10der ,

example was very helpfull for VD that have buttons. I just like to edit only the text on a label from node-red .

I have only some values from ble device ( battery level/signal strength, etc) that are connected via node-red and I like to display these values on a VD of fibaro. 

 

here is what I have on my setup but it did not worked

 

Please login or register to see this code.

 

Edited by FSE
Posted

Sir. here is lits of all commands for Hc2


 

Please login or register to see this code.

Take care 

  • Thanks 2
  • 6 months later...
Posted

Hi... I'm trying to implement MQTT in HC2 and I'm using the scene shared here but I receive the message "connection reset by peer".

MQTT broker is regularly working in raspberry and tested with mqtt tester.

Do you have any idea or suggestion?

Thanks

Posted

By any chance are you using the same ClientID for two different connections to MQTT - if so you can't do that and the broker will kick you off.

Posted

Thank you xAPPO.. actually i have HC2, raspberry with MQTT broker and node red with MQTT client. Should I have to change client ID in node red or HC2? Honestly I cannot find the clientID in both hc2 and mode red. Do you have a lua scene as example? Thank you very much

Posted

Wow wow guys, how you can establish connection from HC2 to Mqqtt server?! LUA function for connection to mqtt server still disabled 

Posted

You can't .. unfortunately but I had thought possibly NodeRED and something else (not HC2) were connecting to the MQTTbroker. What else might it be @10der ?

Join the conversation

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

Guest
Reply to this topic...

×   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...