Seit dem letzten Update läuft bei mir Proplanta nicht mehr:
2015.06.02 06:53:18 0: Time::HiRes::nanosleep(): unimplemented in this platform at ./FHEM/59_PROPLANTA.pm line 36
BEGIN failed--compilation aborted at ./FHEM/59_PROPLANTA.pm line 36, <$fh> line 953.
Ich musste den Workaround auskommentieren, damit das Modul wieder geladen wird:
#use Time::HiRes qw(usleep nanosleep);
.
.
# Wait 1ms to reduce CPU load and hence blocking of FHEM by it (workaround until a better solution is available)
#usleep (1000);
Zitat
# perl -v
This is perl, v5.10.0 built for arm-none-linux-gnueabi
Die unschöne Verschlimmbesserung ist leider immer noch drin.
Könnte man nicht eine Fallunterscheidung einbauen: "Ist die Funktion verfügbar, ja/nein"?
Nach dem Update muss ich wieder Hand anlegen.
Oder ich schließe diesem Modul von Update aus ...
Eine Lösung wäre auch, das Modul in die Plattform zu implementieren.
Eine Alternative wäre es in einem eval zu prüfen:
eval { use Time::HiRes qw(usleep nanosleep); };
if(!$@)
{
# Wait 1ms to reduce CPU load and hence blocking of FHEM by it (workaround until a better solution is available)
usleep (1000);
}
oder per select warten
select(undef,undef,undef,0.001);
gruß
andre