[APP][Pro] Modbus - Connect every Modbus devices

Question, what is the minimum time required between two commands in single connection mode at Modbus? Or does that also depend on the connected hardware?

It depends on the Modbus device (or Modbus TCP bridge).

In normal cases you could request registers every second. But I don’t know how this is on Homey side with several Flows every 1 sec :thinking:

I can confirm, homey kill flows that trigger every 1sec after sometime.
(was trying to poll state of pir sensors to use as triggers)

Flows that check every 10sec seems okey :smiley: (Polling Energy Meters every 10sec here)

10 seconds sounds great to let my PV inverter ride the power consumption in the house.

@RonnyW Once again many thanks for this really useful app. I’m using it for my heat pump and two inverters and it’s such a great help!

As I do quite some intensive control of those devices, I would like to reduce the number of actual write operation. At least for some devices it has been reported, that too many write operation might degrade their flash memory.

The most obvious solution would be a read-compare-write-if-changed, but this would need three flow cards for every write operation, which would make many flows a bit messy (more than they already are).

So would it be possible to get a separate flow card that does the above? Just like the normal write-flow card, but it first reads the value and only actually writes it, if it needs to be changed? Or alternatively add a third mode e.g. called “update” to your write flow card that does that.

New test version 0.12.0:

  • Added device setting to prevent register writing if unchanged.

@CaptainVoni FYI and test. Thanks for the suggestion. Even if (good) Modbus devices normally are operating in RAM and are writing only real changes to memory, it can make sense if yre not sure how the device is operating.
I decided to add this option as device setting, because you will use this logic per device and not per flow card. I hope it’s working wight :crossed_fingers: :grin:

You’re the best!!! Will start testing in the next days - today I need to test the export limitation of my inverter and I don’t want to change too much on my system while doing so.

Thank you again for this great app!

Just to report back: I have switched to the test version and changed the relevant setting. Everything seems to be working fine at first glance. Writing is significantly slower when the value changes (about factor 3-5 on the heat pump and around factor 2 on the inverters), but that is as expected. Will keep an eye on it in the next days and report back if something unexpected happens.

Once again, many thanks @RonnyW !

Final feedback: Everything works with the new setting after a few days of testing. No unexpected behaviour.

Thanks again!

Hi @RonnyW, first many thanks for all your hard work on this integration.

I am running into the same experience with v0.11 on my Homey 2019, reported earlier here (without the migration). Only those three cards available at flow creation. Did not solve by re-installing the app.

Flow creation directly from the device does offer all flowcards, but only this way. Also, the exposure of tag {{Numeric Value}} is not being registered, and I suspect more underlaying issues.

Any tips to get the app going on H2019, properly? Thanks!

I thought this was a great idea - since two minutes ago, when I realized, that one register on my main inverter needs to be written even if the value is unchanged, because it resets an internal timer. :roll_eyes:
I have to change the setting back for my main inverter.

That are the flow cards available in Standard Flow.

You need Advanded Flow to use the other one, because only Advanced Flow offfers the possibility to “chain” cards and use output tokens from Modbus reading.

But thsi does not mean that every writing by the app directly writes to memory. A “good” device is caching internally and only writing real changes. So let’s hope :crossed_fingers:

Sorry, but I didn’t get that. What do you mean?

In the mean time I changed the setting for the main inverter back; now everything works again. It’s just that one register that actually needs to be written even if the value is unchanged.

Modbus is designed for instant updates. A device should hoold the data in RAM and should only write to Flash memory if a register really changes.

Understood, thanks for the clarification.

Hey Ronny, I had to chage my Router so the Fronius now has a new IP address. I can access the fronius UI via my web browser but I can’t get the Modbus App to accept the new IP Address.

Any hints?

In case it helped I did create a diagnostic report: d1422df6-e2bb-48fe-a15d-401c24e416ca

Hi,

can’t you change the IP in settings (not updated) or is is not working with the new IP?

I only see connection timeouts for http://192.168.0.233:502/ in the log.