0
0
mirror of https://github.com/Doodle3D/doodle3d-firmware.git synced 2024-12-22 11:03:48 +01:00

Wait 1 second manually for the network association to finish

This commit is contained in:
peteruithoven 2014-01-08 14:50:44 +01:00
parent cdcd76654a
commit 491e6021e9
2 changed files with 8 additions and 1 deletions

View File

@ -369,6 +369,13 @@ function M.associateSsid(ssid, passphrase, recreate)
return nil,msg
end
log:info(" waiting for network configuration to finish")
local waitTime = 1
local endTime = os.time() + waitTime
while os.time() <= endTime do
-- waiting...
end
M.setStatus(M.CONNECTED,"Connected");
-- signin to connect.doodle3d.com

View File

@ -145,7 +145,7 @@ end
-- @treturn string Output of the command that was run.
-- @todo: this function has been duplicated from rest/api/api_system.lua
function M.captureCommandOutput(cmd)
local f = assert(io.popen(cmd, 'r'))
local f = assert(io.popen(cmd..' 2>&1', 'r'))
local output = assert(f:read('*all'))
f:close()
return output