|
LightLib
PROS library for VEX V5: EKF/MCL localization, RAMSETE path following, high-level chassis API
|
Pose, sensor specs, and the global odometry / pose-estimation API. More...
#include <cmath>#include <vector>#include "LightLib/drive/mcl_config.hpp"#include "light/distance.hpp"#include "light/gps.hpp"#include "light/imu.hpp"#include "light/motor_group.hpp"#include "light/rotation.hpp"Go to the source code of this file.
Classes | |
| struct | Pose |
| Field-frame 2D pose. More... | |
| class | TrackingWheel |
| Single tracking wheel — works with either a Rotation sensor (preferred) or a powered MotorGroup. More... | |
| struct | DistanceSensorSpec |
| Distance sensor mount for LightCast. More... | |
| struct | OdomSensors |
| Bundle of all sensors used by the LightLib pose estimator. More... | |
Namespaces | |
| namespace | light |
| Initialize once via init(); poll getPose/setPose from any task. | |
Functions | |
| void | light::reset () |
| Reset all internal pose state to (0, 0, 0). | |
| void | light::init (OdomSensors sensors, MCLConfig cfg={}) |
| Initialize the estimator. | |
| void | light::stop () |
| Stop the background odometry task. | |
| void | light::moveToPoint (float targetX, float targetY, int timeout, float maxSpeed, bool reversed) |
| Drive to a field-relative point (legacy). | |
| Pose | light::getPose (bool radians=false) |
| void | light::setPose (Pose pose, bool radians=false) |
| Overwrite the current pose. | |
| Pose | light::getSpeed (bool radians=false) |
| Pose | light::getLocalSpeed (bool radians=false) |
| Pose | light::estimatePose (float time, bool radians=false) |
Linear extrapolation of pose time seconds ahead at current velocity. | |
| void | light::update () |
| Force one update (normally called by the background task). | |
| Pose | light::getPoseRad () |
| Radian-only accessor; trajectory code MUST use this to avoid deg/rad bugs. | |
Pose, sensor specs, and the global odometry / pose-estimation API.
Fuses wheel-tracking deltas + IMU(s) + optional GPS + optional LightCast.
Definition in file odometry.hpp.