Skip to content

Added Boomerang code - #35

Open
Cavaire3D wants to merge 19 commits into
Jerrylum:mainfrom
Cavaire3D:main
Open

Added Boomerang code #35
Cavaire3D wants to merge 19 commits into
Jerrylum:mainfrom
Cavaire3D:main

Conversation

@Cavaire3D

Copy link
Copy Markdown

This introduces a new format that generates boomerang code for xVecLib.

Screenshot_20240509_165921
Code exported:
robo.set(59, -34);
imu.set_rotation(270);
ou.printCoords();
ou.moveToBoom( -59.924, -50.746, 347.5795700547434, 0.0672986800982153,5);
ou.moveToBoom( -45.96, 36, 90, -0.12368406072104425,5);

@Jerrylum

Copy link
Copy Markdown
Owner

Is the library open source? Can I have the link of the repository?

@Cavaire3D

Copy link
Copy Markdown
Author

Repository is https://codeberg.org/xVec/xVecLib
Documentation (Work in Progress) is https://xvec.codeberg.page

@Jerrylum Jerrylum left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR.

Since I modified the internal API for formats after you submitted your PR, you need to refactor your format. It doesn't happen very often.

Please tell me what your format is generating. I see it generates a sequence of moveToBoom function calls with five parameters. I would like to learn more about the function as well as the algorithm that you are using. Is it a modified Boomerang algorithm? Explanations with figures are welcome.

Remove console.log function calls, use Logger when necessary.

@Cavaire3D

Copy link
Copy Markdown
Author

This function is a boomerang controller implementation created using Boomerang controller.
It is one of many methods provided by my library, all of which require a tuned PID controller and odometry.

The format calculates the lead by using the control that has the most impact to the segment (the one that is the furthest away) as the carrot point. It then calculates the lead by rearranging the equation.

The documentation for this method is unfinished, and will be posted https://xvec.codeberg.page/class_x_y_zv_lib_1_1_p_i_d_ab96f6a3edb6bccf97d240b3154b0110b.html#ab96f6a3edb6bccf97d240b3154b0110b when finished.

I will update the code now to use the requested logger.

@Cavaire3D
Cavaire3D requested a review from Jerrylum May 12, 2024 20:30

@Jerrylum Jerrylum left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The next step is writing test cases

Comment thread src/format/xVecLibBoomerangFormatV0_1/GeneralConfig.tsx

@Jerrylum Jerrylum left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see you started working on the test cases. Please keep going, and address the following change requests:

Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/PathConfig.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated
Comment thread src/format/xVecLibBoomerangFormatV0_1/index.tsx Outdated

@Jerrylum Jerrylum left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you still working on the PR?

@Cavaire3D

Copy link
Copy Markdown
Author

I am still working on this PR, but testing has revealed a few major bugs that I am currently working out. I will push changes once I fix those bugs.

@Cavaire3D
Cavaire3D requested a review from Jerrylum October 20, 2024 23:33

@Jerrylum Jerrylum left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image You modified the file permission of multiple files, please change them back before I can continue to review your pull request. Thank you.

@Logieboyyyyyyyyy

Logieboyyyyyyyyy commented Jan 15, 2026

Copy link
Copy Markdown

Fixed file permissions as requested and cleared conflicts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants