diff --git a/station_broadcast.lua b/station_broadcast.lua index eae687e..18c8471 100644 --- a/station_broadcast.lua +++ b/station_broadcast.lua @@ -1,6 +1,6 @@ -- 1. Configuration & Constants -local APP_VERSION_TEXT = "v1.0.51" +local APP_VERSION_TEXT = "v1.0.52" local CONFIG = { CLOUD_URL = "ws://stabadmin.fse-media.group", @@ -2626,6 +2626,16 @@ function Main.loop() cleanupTimestampMap(State.announcedAlerts, now, tonumber(CONFIG.ALERT_COOLDOWN_MS) or 300000) for i, stop in ipairs(data.TrainStops) do + -- [DEBUG] Dump first stop to file for inspection + if i == 1 and not State.dumpedStop then + State.dumpedStop = true + local f = fs.open("stop_dump.json", "w") + if f then + f.write(textutils.serializeJSON(stop)) + f.close() + Utils.log("DEBUG", "Dumped stop structure to stop_dump.json") + end + end local st = stop.Station if st then local trainName = st.TrainName or "Unknown"