How shm-white/skywalker_general_embedded_code works
SkyWalker is a Zephyr-based robot-control framework, with paired sentry chassis and gimbal application skeletons as its principal integrated workflow. Operator input and referee state feed command and global-safety decisions on the gimbal controller; commands cross the interboard link to locally guarded chassis and gimbal motion, with feedback and heartbeats returning across the link. The README also documents reusable DJI/DM motor, IMU, control, referee, DR16, and swerve capabilities. Application excerpts establish the main task ownership; unsampled subsystem wiring is shown only where documented.
Main entry points: src/main.cpp Gimbal application · interboard_link.cpp Interboard link · src/main.cpp Chassis application · can_bus.cpp CAN bus
Components 26
Sentry Applications
- Gimbal application
applications/sentry_gimbal/src/main.cpp - Chassis application
applications/sentry_chassis/src/main.cpp - Command router
applications/sentry_gimbal/src/command_router.cpp - Chassis hardware
applications/sentry_chassis/src/chassis_hardware.cpp
Communications
- DR16 service
lib/communication/remote.cpp - Referee service
lib/communication/referee.cpp - Interboard link
lib/communication/interboard_link.cpp - Frame parser
lib/communication/interboard_parser.cpp
Robot Decisions
- Global safety
lib/robotics/safety.cpp - Command management
lib/robotics/command.cpp - Local safety
include/robotics/safety/chassis_local_safety.hpp - Power limiter
lib/robotics/chassis_power_limiter.cpp - Swerve chassis
lib/robotics/swerve.cpp - Yaw gimbal
lib/robotics/yaw_gimbal.cpp
Motion and Control
- Control algorithms
lib/control - Motor API
drivers/motor/motor.cpp - Motor groups
drivers/motor/group.cpp
Hardware Drivers
- CAN bus
drivers/motor/can_bus.cpp - DJI protocol
drivers/motor/dji/dji_protocol.cpp - DM protocol
drivers/motor/dm/dm_protocol.cpp - BMI088 IMU
drivers/imu/imu.c - Kalman filter
drivers/kalman_filter/kalman_filter.c
Other components
- Operator
- Referee system
- CAN motors
- IMU sensor
Connections 32
- Operator → DR16 service: sends frames
- DR16 service → Gimbal application: publishes state
- Referee system → Referee service: sends frames
- Referee service → Gimbal application: publishes state
- Gimbal application → Command management: maps intent
- Gimbal application → Global safety: evaluates inputs
- Command management → Gimbal application: produces commands
- Global safety → Gimbal application: returns decisions
- Gimbal application → Command router: routes output
- Command router → Gimbal application: publishes local command
- Command router → Interboard link: publishes chassis control
- Interboard link → Frame parser: parses frames
- Frame parser → Interboard link: delivers frames
- Gimbal application → Interboard link: sends heartbeat
- Interboard link → Chassis application: delivers control
- Chassis application → Interboard link: sends feedback
- Interboard link → Gimbal application: delivers feedback
- Chassis application → Local safety: checks motion
- Chassis application → Power limiter: limits effort
- Chassis application → Chassis hardware: commands hardware
- Chassis hardware → Swerve chassis: runs chassis
- Gimbal application → Yaw gimbal: commands yaw
- Yaw gimbal → Control algorithms: uses control
- Motor API → Control algorithms: applies targets
- Motor API → Motor groups: checks group
- CAN bus → Motor API: updates motors
- CAN bus → DJI protocol: encodes and decodes
- CAN bus → DM protocol: encodes and decodes
- CAN motors → CAN bus: exchanges CAN
- IMU sensor → BMI088 IMU: provides samples
- BMI088 IMU → Kalman filter: filters estimates
- Swerve chassis → Control algorithms: uses algorithms