init: ShowenV2 项目骨架 — 数字生命窗口平台

- core/ 跨平台内核骨架 (Plugin trait, Message, ServiceManager, Config)
- plugins/ 空桩 (video, http, ble, screen, wifi)
- PROGRESS.md 进度跟踪, TEAM.md 团队档案
- cargo check 零 warning 通过

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
showen
2026-03-12 05:03:58 +08:00
commit 23f4d46287
21 changed files with 2223 additions and 0 deletions

29
src/main.rs Normal file
View File

@@ -0,0 +1,29 @@
use anyhow::Result;
use showen_v2::core::config::AppConfig;
use showen_v2::core::service_manager::ServiceManager;
fn main() -> Result<()> {
let config_path = std::env::args()
.nth(1)
.unwrap_or_else(|| "configs/dog_state_machine.json".to_string());
println!("ShowenV2 — 数字生命窗口平台");
println!("加载配置: {}", config_path);
let config = AppConfig::from_file(&config_path)?;
config.validate_paths()?;
let mut manager = ServiceManager::new(config);
// TODO: 按平台注册插件 (Commit 8)
// manager.register(Box::new(VideoPlugin::new()));
// manager.register(Box::new(HttpPlugin::new()));
// manager.register(Box::new(BlePlugin::new()));
// manager.register(Box::new(ScreenPlugin::new()));
// manager.register(Box::new(WifiPlugin::new()));
manager.start_all()?;
manager.run()?;
Ok(())
}