SATEL MODBUS controller with fhem: high cpu while polling modbus

Begonnen von claudio, 27 Juni 2021, 17:31:09

Vorheriges Thema - Nächstes Thema

claudio

Hi folks

I just recently bought an alarm system made by SATEL (I actually bought only their wireless system, the controller is the ACU-220 with some pir/mw detectors and remotes). I have choosen this device because it have proper documentation and it can be interfaced with RS-485 Modbus. With this, you can make your OWN alarm system, and obviously, connect it to FHEM in order to retrieve PIR sensors status, sensors tamper, remote keyfobs infos and so much more. You can also drive the ACU-220 controller via modbus. The possibilities is exceptionnal for peoples like us, I personnally avoid anything requiring the cloud or online services to work.

The wireless controller is a slave, meaning that you have to query it to get it's infos. Thats where I'm starting to have issues. I managed to set it up properly under fhem and get different registers via modbus polling. Now, fhem seems to have difficulties to retrieve data from the controller at a rate of 0.5s to 1s. It works but the cpu usage seems higher than I though, it goes from 0.3%/3% cpu usage (without polling started) to 15%/35% with a polling of 1 per seconds.

The same polling with the program "modpoll" under the same machine consume only 0.3% cpu... I'm worried because I could not lose "any" sensor detection. Is there anything I could do to improve cpu usage with modbus polling ??

claudio

Anyone pls ??

Could there be any specific reason WHY fhem is so slow dealing with modbus ??
fhem as a modbus master querying slave device every seconds eat between 20 ~ 25 % CPU !
same problem when fhem as slave receiving data from an arduino master.

This is really driving me nuts. Could there be anything to do to improve it ?

I though about a modbus to mqtt bridge running on the pi which send and receive data to / from fhem but the (few) that's exists are not really usable or active projects and I'm not sure it would resolve the fact that fhem is slow as hell