Henry_Du
3c25040a84
chore(client): 优化日志输出并清理测试代码
...
1. 引入全局 `CONFIG.DEBUG` 配置项(默认为 `false`),将所有 `Utils.log(DEBUG, ...)` 的大量扫描和推算日志默认隐藏,避免刷屏 CC 终端,需要时可通过配置文件开启。
2. 移除了排查 NBT 结构时添加的 `stop_dump.json` 导出逻辑,保持主机系统文件整洁。
2026-08-03 12:27:37 +08:00
Henry_Du
fdbcfa3b9b
fix(client): 优化停站时间获取,并在列车停站时禁用进站预告
...
1. 修复 `Utils.getStopTime` 和 `Utils.getNextStation` 会误匹配“非车站指令”(如修改最高速度等指令)中的文本的问题,现在仅在 `instruction.id == create:station`
或 `create:destination` 的条目中扫描,保证了 CC 电脑从 `create:track_station`
获取到的时刻表信息(包括计算出的停站时间)100% 准确。
2. 修复显示器(Display Board / NBT)在列车停站后依然显示“离站倒计时 ETA”,导致触发 `train_approaching` 的问题:如果当前列车已经在站内(`State.currentTrain` 存在且匹配),将强制忽略该列车的 `train_approaching` 触发逻辑,彻底解决列车停站时倒秒导致的重复播报。
2026-08-03 12:20:54 +08:00
Henry_Du
87fda31485
fix(client): 在 NBT 分支中也应用非车站指令过滤
...
将 `isStationDestination` 的过滤逻辑同时应用于 Block Reader(读取车站方块 NBT)的分支,
确保无论是通过显示屏还是 NBT 读取,都不会把“设置最高速度”等非停站指令当作列车进站播报。
同时已包含 `etaSeconds > 0` 修复,解决完全停站后重复播报的问题。
2026-08-03 12:09:08 +08:00
Henry_Du
f846004091
fix(client): 过滤非车站指令并修复列车停站后重复播报进站预告的问题
...
1. 新增 `isStationDestination` 过滤器,在通过显示屏(Create Target)读取时刻表时,
自动忽略包含“速度”、“重命名”、“时刻表”、“等待”、“卸载”等关键字的非车站指令,
防止将这些指令当作车站并错误触发进站预告。
2. 修复显示屏读取到的负数 ETA 被错误解析为正数的问题(增加可选负号匹配)。
3. 将触发进站预告的条件从 `etaSeconds >= 0` 修改为 `etaSeconds > 0`。
这样当列车完全停站(ETA=0或负数)时,将不再触发进站预告,彻底解决停站时间
超过冷却期后导致的重复播报“进站预告”的问题。
2026-08-03 12:04:13 +08:00
Henry_Du
439ed9ea3c
chore(client): 增加调试日志以导出 NBT stop 结构
...
用于排查非停站指令(如设置最高速度、新建时刻表区段)的 NBT 结构,
以便后续在代码中精准过滤这些非车站指令。
2026-08-03 11:28:32 +08:00
Henry_Du
eb018dbae9
fix(client): 修复多个同名同目的地的列车互相清除 pending 状态的问题
...
当存在多个列车(如无名列车 ??? 开往同一目的地)时:
- 第二个 ETA 较远的列车会因为 `etaSeconds > 45` 走进 `else` 分支
- 原逻辑在 `else` 分支会直接清空该 key 的 pending 状态
- 导致排在前面的列车永远无法积累 5 秒的稳定期
修改:
1. 移除 `else` 分支,统一交由末尾的清理循环处理
2. 使用 `if not seenApproachKeys[announceKey]` 确保同一个 tick 只有 ETA 最近(排最前)的列车更新状态
2026-08-03 11:14:40 +08:00
Henry_Du
619d4e9a20
杂项(station_broadcast): 更新版本至v1.0.50并添加列车ETA调试日志
...
该调试日志会打印列车名称、ETA秒数、计时tick数及服务器tick率,仅在列车ETA不超过60秒且未触发过接近播报时输出,用于辅助排查列车接近播报的逻辑问题
2026-08-03 11:09:44 +08:00
Henry_Du
3c71d64f79
chore(station_broadcast): 升级版本至v1.0.49并调整ETA触发阈值
...
调整列车接近播报的ETA更新阈值,从3秒改为15秒以减少频繁触发
2026-08-03 10:40:12 +08:00
Henry_Du
a36b21cfaf
fix(server): 完善列车接近音频的处理与日志记录
...
新增列车接近音频入队和构建失败的日志输出
调整音频任务优先级为1,中断模式改为ifLower
修复音频构建为空时的静默失败问题
2026-08-03 10:22:04 +08:00
Henry_Du
101d392840
fix(CloudServer/server): 修复列车接近处理的ch序列遗漏的站台编号参数
2026-08-03 09:59:58 +08:00
Henry_Du
c8681417a8
refactor(音频模块): 重构wav音频播放与解码逻辑
...
移除冗余的流式wav解码工具函数,复用现有decodeWavChunkToSamples
简化playChunkOnSpeakers实现,移除固定帧拆分逻辑与无用常量
优化音频日志与错误处理,解码失败时回退至HQ播放路径
调整应用版本号从v1.0.50回退至v1.0.47
2026-08-03 09:51:33 +08:00
Henry_Du
bf1895ebc5
perf(audio): 优化音频播放帧处理逻辑,升级版本至v1.0.50
...
- 为test.lua添加标准文件头部注释
- 将station_broadcast.lua版本从v1.0.49更新至v1.0.50
- 新增NATIVE_AUDIO_FRAME_SAMPLES常量,将音频处理拆分为128样本每帧
- 修复空音频样本输入的边界异常问题
- 优化原生扬声器播放的循环逻辑,提升兼容性与执行效率
2026-08-03 09:49:01 +08:00
Henry_Du
394f81b9fa
1
2026-08-03 09:39:00 +08:00
Henry_Du
5fb81e3998
feat(audio): 实现流式WAV解码器并优化音频播放逻辑
...
将应用版本更新至v1.0.48;新增WAV头部解析与流式解码逻辑,替换原有的单块解码方案;添加扬声器speakWav兼容性检测,无支持设备时输出错误日志;优化WAV解码错误处理与日志输出,仅首次打印音频格式信息。
2026-08-03 09:37:00 +08:00
Henry_Du
e89b82a8b4
1
2026-08-03 09:27:51 +08:00
Henry_Du
5dbd3d667f
fix: restore speaker peripheral detection
...
Re-add speaker discovery during peripheral init so installed speakers are available for playback and log the detected count at startup.
2026-08-03 09:24:58 +08:00
Henry_Du
6964e7a47d
refactor(station_broadcast): 清理冗余代码与注释,移除无用文件并更新gitignore
...
- 清理station_broadcast.lua中的冗余注释、废弃代码块,移除无用的节分隔注释
- 删除不再使用的austream.lua文件
- 更新.gitignore,新增临时文件与转储文件的忽略规则
2026-08-02 22:03:06 +08:00
Henry_Du
59865138c7
11
2026-08-02 21:26:41 +08:00
Henry_Du
b2888c6c88
chore(安装脚本与文档): 修改安装脚本下载源并新增教程视频
...
将install_station_broadcast.lua中的旧下载地址替换为gitea仓库的https新源,同时新增FSE铁路广播系统教程视频文件
2026-08-02 21:24:57 +08:00
Henry_Du
aef63ca444
fix: install updater alongside startup script
...
Download the update helper during install and expose it from the cloud server so new hosts can run manual updates immediately.
2026-08-02 21:20:28 +08:00
Henry_Du
10d15dfddc
feat: add station auto update publishing
...
Publish the latest station script from the console so online hosts download and reboot immediately while offline hosts update on their next load.
2026-08-02 20:04:55 +08:00
Henry_Du
52a643a868
tune: shorten delay alert confirmation to 15 seconds
2026-08-02 19:48:01 +08:00
Henry_Du
e29cc0c2ba
tune: trigger approaching announcement earlier
2026-08-02 19:34:27 +08:00
Henry_Du
73f0ba8e69
tune: trigger stable approaching announcement at 45 seconds
2026-08-02 19:29:26 +08:00
Henry_Du
22ea43c1c1
tune: stabilize approaching trigger and show precise ETA
2026-08-02 19:25:57 +08:00
Henry_Du
fb1256fbcc
tune: add delay confirmation and approaching cooldown
2026-08-02 19:22:01 +08:00
Henry_Du
04591fc0c8
fix: dedupe delay alerts to reduce music stutter
2026-08-02 19:19:00 +08:00
Henry_Du
906594008a
fix: remove ch-min from delay announcement
2026-08-02 19:06:20 +08:00
Henry_Du
126aaaf02f
fix: trigger delay alerts from displayed CRN delay
2026-08-02 19:04:10 +08:00
Henry_Du
278de7de6b
feat: announce delay alerts as soon as they appear
2026-08-02 18:58:54 +08:00
Henry_Du
ea22c79008
fix: rename Japanese delay reason audio files
2026-08-02 18:52:43 +08:00
Henry_Du
39dc446958
功能(站点广播): 实现延误与停运列车的双语广播功能
...
添加所有中日文广播所需的音频资源文件
将应用版本更新至v1.0.37
修复列车状态原因映射逻辑,补充广播所需的缺失字段
实现根据延误、停运状态生成对应双语广播序列的逻辑
更新测试脚本以适配区块阅读器并正确解析CRN的NBT数据
添加示例NBT转储文件作为参考
2026-08-02 18:50:49 +08:00
Henry_Du
f922ace154
fix: trigger approaching broadcast under 30 seconds
2026-08-02 17:42:49 +08:00
Henry_Du
b7be4cd00d
fix: use NBT ETA and clean monitor debug output
2026-08-02 17:33:05 +08:00
Henry_Du
9060e79006
fix: use earlier realtime tick for arrival ETA
2026-08-02 17:14:51 +08:00
Henry_Du
426e55a7f0
fix: normalize upcoming ETA keys before text override
2026-08-02 17:11:31 +08:00
Henry_Du
db818209f2
debug: show raw create target line and eta fields
2026-08-02 17:08:59 +08:00
Henry_Du
a1db54b295
fix: parse CRN ETA as value plus unit
2026-08-02 17:05:53 +08:00
Henry_Du
96222ebf06
debug: expand text ETA parsing and show raw eta string
2026-08-02 17:03:43 +08:00
Henry_Du
9f2dc5bb3d
debug: compare text and NBT ETA keys on monitor
2026-08-02 17:00:24 +08:00
Henry_Du
4b95c86af6
fix: align NBT destination with CRN display stopovers
2026-08-02 16:55:15 +08:00
Henry_Du
432b82eae9
feat: prefer CRN display ETA text when available
2026-08-02 16:48:42 +08:00
Henry_Du
23196cd59d
fix: compute ETA using measured tick rate
2026-08-02 16:44:12 +08:00
Henry_Du
ea288b6572
feat: show delay reason/status from CRN NBT on monitor
2026-08-02 16:41:01 +08:00
Henry_Du
61576a7d9e
fix: detect advanced peripherals block reader by type or method
2026-08-02 16:33:50 +08:00
Henry_Du
b725c74e1d
debug: add upcoming trains data probe
2026-08-02 16:31:07 +08:00
Henry_Du
c13a0c9dcc
fix: avoid monitor log overlap and show upcoming status
2026-08-02 16:24:32 +08:00
Henry_Du
5134a4ebf0
fix: restore main loop block structure
2026-08-02 16:22:44 +08:00
Henry_Du
544179758e
fix: restore goto label required by earlier logic
2026-08-02 16:19:56 +08:00
Henry_Du
95e550441e
fix: ensure trailing newline at end of file
2026-08-02 16:17:33 +08:00
Henry_Du
8a431147ec
fix: remove unused goto continue label causing lint error
2026-08-02 16:15:23 +08:00
Henry_Du
d28b0eec30
fix: correctly assign State.upcomingTrains before display link fallback
2026-08-02 16:10:52 +08:00
Henry_Du
ad70f4adbc
feat: display upcoming trains and delay info on monitor
2026-08-02 16:07:48 +08:00
Henry_Du
e92348b4db
feat: add real-time ETA interpolation for block reader
2026-08-02 16:04:41 +08:00
Henry_Du
13dc054a01
feat: use block reader for accurate ETA and delay data
2026-08-02 15:57:14 +08:00
Henry_Du
c573260e5d
feat: Implement exact 45s pre-arrival broadcast by delaying 1min signal
2026-08-02 14:59:07 +08:00
Henry_Du
dbf259efe5
fix: Re-enable train pre-arrival broadcast on '1 min' to provide sufficient advance notice
2026-08-02 12:08:16 +08:00
Henry_Du
5c899b30bb
fix: Trigger train pre-arrival broadcast only on '现在' or '0' instead of '1 min'
2026-08-02 12:02:44 +08:00
Henry_Du
53b4d1b296
fix: Reduce train pre-arrival debounce timeout to 1 minute
2026-08-02 11:57:57 +08:00
Henry_Du
b52776fe09
fix: Reduce train pre-arrival debounce timeout to 2.5 minutes
2026-08-02 11:56:20 +08:00
Henry_Du
43a2a4deaf
fix: Increase train pre-arrival debounce timeout to 5 minutes to prevent multiple broadcasts for fuzzy ETA
2026-08-02 11:54:23 +08:00
Henry_Du
712d8bb84d
fix: Ensure platform is stripped of non-digit chars for audio file matching
2026-08-02 11:52:27 +08:00
Henry_Du
26003844b9
特性(音频与脚本): 添加8条语音音频文件与火车站点监测脚本
...
添加4条中文、4条日文语音音频文件,新增脚本用于ComputerCraft下的Create模组火车站点监测
2026-08-02 11:45:24 +08:00
Henry_Du
ef75671527
feat: Add train pre-arrival broadcast via CRN create_target
2026-08-02 11:37:41 +08:00
Henry_Du
805aba9f37
fix: remove 3.0 fallback and strictly apply AUDIO_VOLUME=100 directly to HQ speaker APIs
2026-08-02 09:07:12 +08:00
Henry_Du
faa25bbb3c
fix: safely apply CONFIG.AUDIO_VOLUME to all HQ speaker APIs (speakWavAll, speakHLS, etc.) with 3.0 fallback
2026-08-02 08:57:20 +08:00
Henry_Du
ac8405e300
fix: use pcall to uncapped AUDIO_VOLUME for HQ speakers while keeping 3.0 fallback for vanilla speakers
2026-08-02 08:53:49 +08:00
Henry_Du
832658ad58
feat: apply 5x volume boost to all FFmpeg audio processing (broadcast sequences, HLS, DFPWM) to maximize loudness
2026-08-02 08:50:28 +08:00
Henry_Du
8aec4c6a84
chore: set default AUDIO_VOLUME to 100 for maximum HQ speaker distance/volume (v1.0.19)
2026-08-02 08:42:13 +08:00
Henry_Du
fb49925a9b
chore(Audio/voice): 更新日语语音文件ja-zt.wav
2026-08-02 08:21:04 +08:00
Henry_Du
66ce214f51
Perf: fix audio playback stuttering by increasing pre-buffer to 5 chunks and optimizing multi-speaker synchronization without forced gaps
2026-08-01 23:19:37 +08:00
Henry_Du
944f00f521
Fix: correctly parse nextStation by checking both create:station and create:destination, and handle schedule loop
2026-08-01 23:10:06 +08:00
Henry_Du
90c108b1d7
Update: remove ja-xl and ch-line from train arrival broadcast sequence
2026-08-01 23:05:39 +08:00
Henry_Du
01b367fa8b
杂项(Audio/voice): 更新一批语音音频文件
2026-08-01 23:02:10 +08:00
Henry_Du
4b3bd91023
Fix: implement case-insensitive file matching for broadcast audio sequences to fix missing uppercase line and station names
2026-08-01 22:54:10 +08:00
Henry_Du
2fae7305f6
Fix: use filter_complex for sequence concatenation to fix sample rate mismatch causing speed up and noise
2026-08-01 22:46:23 +08:00
Henry_Du
e009f05a61
Fix: use wav-stream-live for train arrivals and departures to fix CC client audio playback
2026-08-01 22:34:29 +08:00
Henry_Du
81f58b58bb
Fix: Lua client config screen overwritten by logs, and fix temp broadcast preview URL
2026-08-01 22:15:59 +08:00
Henry_Du
5c78b20163
Fix: include audioLineDir and audioVoiceDir when building broadcast sequence
2026-08-01 22:09:40 +08:00
Henry_Du
1043d46fb8
Fix: correctly setup line audio directory, routing, and upload handling
2026-08-01 18:41:29 +08:00
Henry_Du
440a8366ca
Feat: CC client auto-detects and displays available departure beeps from server
2026-08-01 18:37:52 +08:00
Henry_Du
495b3cedb9
Fix: save line audio to voice directory instead of beep
2026-08-01 18:30:59 +08:00
Henry_Du
2741b2d321
Revert TTS generation to backend with fixed local proxy 127.0.0.1:7890
2026-08-01 18:25:50 +08:00
Henry_Du
c76538e4bd
feat: switch to client-side fetch for Fish Audio API to bypass server network restrictions
2026-08-01 17:58:20 +08:00
Henry_Du
a516976e35
Revert "feat: use pure direct connection to official api.fish.audio without any forced proxies"
...
This reverts commit 3ecae7b0bc .
2026-08-01 17:57:00 +08:00
Henry_Du
3ecae7b0bc
feat: use pure direct connection to official api.fish.audio without any forced proxies
2026-08-01 17:55:30 +08:00
Henry_Du
b8aee4d766
fix: revert to server proxy logic and add resilient fallback for win32 to prevent 500 errors
2026-08-01 17:51:08 +08:00
Henry_Du
038662c15e
Revert "feat: switch to client-side fetch for Fish Audio API to bypass server network restrictions"
...
This reverts commit dedb37e22b .
2026-08-01 17:49:57 +08:00
Henry_Du
dedb37e22b
feat: switch to client-side fetch for Fish Audio API to bypass server network restrictions
2026-08-01 17:45:48 +08:00
Henry_Du
1b6a2b7e33
feat: switch Fish Audio API endpoint to user's custom proxy domain (fishaudio.fse-media.group)
2026-08-01 17:42:24 +08:00
Henry_Du
7bfff51919
revert: switch back to direct Fish Audio API due to Vercel IP block
2026-08-01 17:37:52 +08:00
Henry_Du
f4c22cb713
feat: switch Fish Audio API endpoint to Vercel proxy to resolve ETIMEDOUT issues on server
2026-08-01 17:34:55 +08:00
Henry_Du
52ecdc8a16
Revert "fix: remove hardcoded windows proxy fallback that causes 500 error when proxy is unavailable"
...
This reverts commit 62ecf5642b .
2026-08-01 16:00:00 +08:00
Henry_Du
62ecf5642b
fix: remove hardcoded windows proxy fallback that causes 500 error when proxy is unavailable
2026-08-01 15:57:30 +08:00
Henry_Du
6150050f69
revert: move TTS generation back to server-side due to CORS issues
2026-08-01 12:01:38 +08:00
Henry_Du
6f122c7a2c
feat: add FISH_AUDIO_BASE env support for reverse proxy
2026-08-01 11:59:15 +08:00
Henry_Du
e3a88acf9b
Revert "feat: migrate TTS generation to frontend to utilize local browser proxy"
...
This reverts commit 5e600bb75d .
2026-08-01 11:58:20 +08:00
Henry_Du
5e600bb75d
feat: migrate TTS generation to frontend to utilize local browser proxy
2026-08-01 11:55:31 +08:00
Henry_Du
1d0c0e0703
fix: fallback to 127.0.0.1:7890 proxy on windows for local TTS generation
2026-08-01 11:50:18 +08:00
Henry_Du
c0f100a833
fix(console): map Beep files to Audio/beep
...
Store and present Beep assets under Audio/beep while keeping legacy Audio/general reads working so existing files remain accessible during the directory transition.
2026-08-01 11:42:38 +08:00