robotpy / robotpy/mostrobotpy

StateSpaceArm example requires missing LinearSystem::Slice(int)

Open
#166 0 comments 0 reactions 0 assignees View on GitHub
package: wpimath
Dominant language
Python
Stars
27
Forks
29
Avg merge
4d 6h
Merged PRs (30d)
12

Description

This currently doesn't type check, and the example is disabled in the tests:

https://github.com/robotpy/examples/blob/242924b3843fdcc6efc2cefa8eac7bfff8b6bc48/StateSpaceArm/robot.py#L59

because `LinearSystemId.singleJointedArmSystem` returns a `LinearSystem<2, 1, 2>`.

The upstream examples slice the outputs of this `LinearSystem`:

https://github.com/wpilibsuite/allwpilib/blob/0695a4db8912a65f175c814c30075cc3e87b313f/wpilibcExamples/src/main/cpp/examples/StateSpaceArm/cpp/Robot.cpp#L48-L51

https://github.com/wpilibsuite/allwpilib/blob/0695a4db8912a65f175c814c30075cc3e87b313f/wpilibjExamples/src/main/java/edu/wpi/first/wpilibj/examples/statespacearm/Robot.java#L64

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.