18 lines
457 B
Plaintext
Executable File
18 lines
457 B
Plaintext
Executable File
commandArray = {}
|
|
|
|
print("Debut pingVolumio2")
|
|
ping_success=os.execute('ping -c1 volumio')
|
|
if ping_success then
|
|
if ( otherdevices['Volumio2'] == 'Off') then
|
|
print("pingVolumio2 success")
|
|
commandArray['Volumio2']='On'
|
|
end
|
|
else
|
|
if (otherdevices['Volumio2'] == 'On') then
|
|
print("pingVolumio2 fail")
|
|
commandArray['Volumio2']='Off'
|
|
end
|
|
end
|
|
print("fin pingVolumio2")
|
|
return commandArray
|