ECMD serielle Schnittstelle überwachen

Begonnen von NeuFehm, 13 August 2014, 22:45:53

Vorheriges Thema - Nächstes Thema

NeuFehm

Rasp und fhem hängen per /ttyAMA0 an einem rs485-Bus.
Mit Hilfe von ECMD und ECMD-Device kann ich die Geräte steuern und erhalte auch entsprechende Rückmeldungen.
Nun sollen die Schalter im Bus fhem steuern, also ich möchte erreichen, dass die Events im Event-Monitor von fhem sichtbar werden.

Meiner Meinung nach benötige ich ein Prozess, der dauerhaft am Bus lauscht.
Habt Ihr Handlungsideen?

PS.: Ich habe keinerlei Funk-Kram ;)
Raspberry Pi B+
RS 485 Schnittstellen: DIGITUS DA-70157, LINKSPTITE RS485/GPIO Shield for Raspberry Pi
RS485 Geräte: Ultraschallsensor für Zisternenfüllstand (Eigenbau), 4x8 Relais-M-Mastermodule (Eigenbau), 6 T-Module (Schalter und 3 analoge Eingänge) (Eigenbau)
sonstige Hardware: 2 Relay Modul

NeuFehm

Evtl. brauch ich auch einen Systemprozess, der aktiv nach fhem meldet, wenn auf der Schnittstelle die Post abgeht. ;)
Hat noch jemand einen Denkansatz?
Raspberry Pi B+
RS 485 Schnittstellen: DIGITUS DA-70157, LINKSPTITE RS485/GPIO Shield for Raspberry Pi
RS485 Geräte: Ultraschallsensor für Zisternenfüllstand (Eigenbau), 4x8 Relais-M-Mastermodule (Eigenbau), 6 T-Module (Schalter und 3 analoge Eingänge) (Eigenbau)
sonstige Hardware: 2 Relay Modul

Carsten

Ich habs noch nicht ausprobiert, aber eigentlich lauscht das ECMD doch schon permanent am Bus.

Auszug aus der CommandRef:

reading <reading> match "<regex>"

Declares a new reading named <reading>. A spontaneous data transmission from the physical device that matches the Perl regular expression <regex> is evaluated to become the value of the named reading. All ECMDDevice devices belonging to the ECMD device with readings with matching regular expressions will receive an update of the said readings.

reading <reading> postproc { <perl special> }

Declares a postprocessor for the reading <reading>. The data received for the named reading is processed by the Perl code <perl command>. This works analogously to the postproc spec for set and get commands.


Ich glaub, das hat Boris Neubert Anfang des Jahres hinzugefügt.