根因: SatelliteRepo.calculatePasses() 在耗时计算期间如果被重复调用, 会启动多个协程同时遍历卫星列表,导致: 1. 重复的 SGP4 轨道计算(CPU/电池浪费) 2. passes MutableStateFlow 被多次更新,触发下游 UI 重组风暴 3. _isCalculating 标志被后续调用覆盖,可能提前置 false 修复: 在 _isCalculating.value = true 之前检查当前值,如果已在计算中则 直接 return,拒绝并发调用。 影响: 防止用户快速切换过滤条件、旋转屏幕等场景下的重复计算。 _isCalculating 现在是真正的互斥信号量(简化版,无等待队列)。
Look4Sat: Satellite tracker
Radio satellite tracker and pass predictor for Android, inspired by Gpredict
Track satellite passes with ease!
Thanks to Celestrak and SatNOGS you have access to over 9000 active satellites.
You can search the entire database by NORAD Catalog Number or the satellite's name.
Orbital positions and passes are calculated relative to your location.
To get reliable data make sure to set the station position via the app Settings.
The application is built using Kotlin, Coroutines, Jetpack Compose and Navigation.
It is now and always will be completely ad-free and open-source.
Main features:
- Predicting satellite positions and passes for up to 10 days
- Showing the list of currently active and upcoming satellite passes
- Showing the active pass progress, polar trajectory and transceivers info
- Showing the satellite positional data, footprint and ground track on the map
- Custom TLE satellite data import is available via Three Line Element .txt files
- Offline first: calculations are made offline. Weekly TLE data update is recommended.
License
The Look4Sat application code is licensed under the GNU General Public License v3.0.
The CW decoder in feature/cw bundles the DeepCW
neural decoding model, licensed under the GNU Affero General Public License v3.0 only
(AGPL-3.0-only). Because the combined work incorporates an AGPL-3.0 component, the
combined work is distributed under the
GNU Affero General Public License v3.0 — GPL-3.0 Section 13 permits the
combination, and AGPL-3.0 Section 13 applies to the combined work as a whole.
Model provenance and attribution are documented in
feature/cw/licenses/NOTICE.md; the original GPL-3.0
text is preserved at feature/cw/licenses/Look4Sat-GPL-3.0.txt. The CW model runs
locally on-device and does not provide services over a network.





