Sonos Say last time a sensor as been trip

Sonos cannot says last time a sensor as been trip, instead it give a billion number.
How can i convert that number to time it as been trip?

[code]local SONOS_ID = 194
local SONOS_SID = “urn:micasaverde-com:serviceId:Sonos1”
local SONOS_ZONES=“Cuisine”

local time = luup.variable_get(“urn:micasaverde-com:serviceId:SecuritySensor1”,“LastTrip”, 183)

local greeting=“personne ,es venu ici depuis le,”

luup.call_action(SONOS_SID, “Say”,
{Text= " Le syst?me de surveillance vous di, "…greeting … time , Language=“fr-CA”, GroupZones=SONOS_ZONES,
Volume=volume, SameVolumeForAll=“true”},
SONOS_ID)[/code]

The time value you are getting returned is in Unix style seconds since a specific date. You have to feed it to the os.time function and specify the format you want it as. See Programming in Lua : 22.1 for more info on that.

It look like a good reference but, i m not very good in programming + english reading (mean more difficult).
i just want Sonos to say something like: March 25 2017 at 22:17. (last time sensor been trip)
Thanks if somebody can help with that.

[code]…
local time = luup.variable_get(“urn:micasaverde-com:serviceId:SecuritySensor1”,“LastTrip”, 183)
local timeString = os.date(" %B %d %Y at %X", time)

local greeting=“personne ,es venu ici depuis le,”

luup.call_action(SONOS_SID, “Say”,
{Text= " Le syst?me de surveillance vous di, "…greeting … timeString, Language=“fr-CA”, GroupZones=SONOS_ZONES,
Volume=volume, SameVolumeForAll=“true”},
SONOS_ID)
[/code]

It Works !!!
Something weird it say the number in french and say the month in english…
But it is ok for now.

Thank you very much Jswim788

[code]…
local time = luup.variable_get(“urn:micasaverde-com:serviceId:SecuritySensor1”,“LastTrip”, 183)
local timeString = os.date(" %d %Y a %X", time)
local month = tonumber(os.date(“%m”,time))
local frMonth = { “janvier”, “fevrier”, “mars”, “avril”, “mai”, “juin”, “juillet”,“aout”,“septembre”,“octobre”,“novembre”,“decembre”}

timeString = frMonth[month] … timeString

local greeting="personne ,es venu ici depuis le, "

luup.call_action(SONOS_SID, “Say”,
{Text= " Le syst?me de surveillance vous di, "…greeting … timeString, Language=“fr-CA”, GroupZones=SONOS_ZONES,
Volume=volume, SameVolumeForAll=“true”},
SONOS_ID)
[/code]
I don’t know how to get the special characters into the text, but maybe the above will work? I bet @amg0 can do better for translation…

Thanks again jswim788 .