Zeige doch bitte mal, was in der devices.csv bzw. in der MyConfig.php stehen sollte. Ich kann das dann mal von Hand anlegen und sehen, ob die Kommunikation mit den Geräten funktioniert.
Zur Info hier die /var/log/apache2/error.log nachdem ich den neuen Code installiert hatte:
Code
[Tue Jan 16 17:09:31.897835 2018] [:error] [pid 766] [client 192.168.178.22:60498] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.68', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.68')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:09:53.180193 2018] [:error] [pid 1300] [client 192.168.178.22:60534] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.65', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.65')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:11:04.822564 2018] [:error] [pid 766] [client 192.168.178.22:60626] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.65', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.65')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:11:38.332772 2018] [:error] [pid 1214] [client 192.168.178.22:60686] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.68', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.68')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:12:37.555508 2018] [:error] [pid 765] [client 192.168.178.22:60756] PHP Notice: Undefined index: ota_server_ip in /var/www/html/pages/site_config.php on line 27, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:12:52.281326 2018] [:error] [pid 1319] [client 192.168.178.22:60780] PHP Notice: Undefined index: ota_server_ip in /var/www/html/pages/site_config.php on line 27, referer: http://192.168.178.23/index.php?page=site_config
[Tue Jan 16 17:13:45.231110 2018] [:error] [pid 1211] [client 192.168.178.22:60860] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.64', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.64')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:13:59.418781 2018] [:error] [pid 766] [client 192.168.178.22:60894] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.68', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.68')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add&lang=en
[Tue Jan 16 17:14:06.458729 2018] [:error] [pid 1319] [client 192.168.178.22:60910] PHP Notice: Undefined index: ota_server_ip in /var/www/html/pages/site_config.php on line 27, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:14:11.283821 2018] [:error] [pid 1297] [client 192.168.178.22:60916] PHP Notice: Undefined index: ota_server_ip in /var/www/html/pages/site_config.php on line 27, referer: http://192.168.178.23/index.php?page=site_config
[Tue Jan 16 17:18:04.526332 2018] [:error] [pid 764] [client 192.168.178.22:32926] PHP Fatal error: Uncaught Error: Call to undefined function curl_init() in /var/www/html/includes/Sonoff.php:81\nStack trace:\n#0 /var/www/html/includes/Sonoff.php(19): Sonoff->doRequest('192.168.178.65', 'Status 0')\n#1 /var/www/html/pages/device_action.php(61): Sonoff->getAllStatus('192.168.178.65')\n#2 /var/www/html/index.php(89): include_once('/var/www/html/p...')\n#3 {main}\n thrown in /var/www/html/includes/Sonoff.php on line 81, referer: http://192.168.178.23/index.php?page=device_action&action=add
[Tue Jan 16 17:17:21.732247 2018] [mpm_prefork:notice] [pid 732] AH00163: Apache/2.4.10 (Raspbian) configured -- resuming normal operations
[Tue Jan 16 17:17:21.753858 2018] [core:notice] [pid 732] AH00094: Command line: '/usr/sbin/apache2'
Alles anzeigen
Zur Erklärung der IPs:
.22 ist das System von dem ich per SSH auf den Raspberry zugreife. Der Raspi hat IP .23. Die IPs .64, .65 und .68 sind Sonoffs.
Gruß
Jörg