Just sharing this code I wrote, when motion armed is tripped, I wanted my cameras to upload image to dropbox (using the awesome app) but not just 1 photo, I wanted to upload a photo every 5 seconds, for up to 50 seconds.
Here is my code that I added to my scene, mind you this is my first code so any comments will be welcomed!
UploadPhoto(“10”)
function UploadPhoto(timesToCall)
luup.call_action(“urn:milliesoft-com:serviceId:WebcamDropboxUploader1”,“SendAllSnapshots”, “”,115)
local ttcNum = tonumber(timesToCall)
if ttcNum > 0 then
local nextTimesToCall = tostring(ttcNum - 1)
luup.call_delay(“UploadPhoto”, 5, nextTimesToCall)
end
end