Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pick a reasonable value for ARM_TELEOP_MAX_GOAL_DIFF_FROM_CURRENT_RAD #26

Open
brettle opened this issue Mar 5, 2024 · 6 comments
Open
Assignees

Comments

@brettle
Copy link
Member

brettle commented Mar 5, 2024

public static final double ARM_TELEOP_MAX_GOAL_DIFF_FROM_CURRENT_RAD = 0; // placeholder

The current placeholder value will prevent the arm from being moved at all. Pick a value that corresponds to the distance the arm will travel if it accelerates at its max acceleration to its max velocity and then decelerates at its max acceleration back to 0.

@Juliaaaahhhh
Copy link
Contributor

I changed it to 0.5 for now as another placeholder - that is what the value of this constant was in Robotcode 2023

Commit:
a594629

@brettle
Copy link
Member Author

brettle commented Mar 6, 2024

Strongly recommend doing the math here. Note that the arm may continue to move for up to ARM_TELEOP_MAX_GOAL_DIFF_FROM_CURRENT_RAD radians after the user stops moving the stick. At the moment that means it might continue to move for ~28 deg!

@brettle brettle reopened this Mar 6, 2024
@sofiebudman
Copy link
Contributor

senac did math and we changed to 1.8345
9efab59

@FriedLongJohns
Copy link
Contributor

@sofiebudman show work

@brettle
Copy link
Member Author

brettle commented Mar 9, 2024

The current value is definitely not correct. 1.8345 radians is 105 degrees. That could allow the arm to continue moving for 105 degrees after the the user has let go of the joystick.

@brettle
Copy link
Member Author

brettle commented Mar 9, 2024

Per my original comment on the issue, you want to compute the value that corresponds to the angle the arm will move if it accelerates at MAX_FF_ACCEL_RAD_P_S to MAX_FF_VEL_RAD_P_S and then decelerates at MAX_FF_ACCEL_RAD_P_S back to 0.

Note that at the moment the variable MAX_FF_VEL_RAD_P_S is commented out, but the (currently incorrect, due to issue #27) attempt to compute it occurs here.

stwiggy added a commit that referenced this issue Mar 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants