Skip to content

Comments

[mpcc-49] C++ MPCC interface bugs fixed, interface was changed to absolute values of throttle and brakes#97

Open
KarasevPavel wants to merge 24 commits intodevelopfrom
dev/pkarasev/MPCC-49
Open

[mpcc-49] C++ MPCC interface bugs fixed, interface was changed to absolute values of throttle and brakes#97
KarasevPavel wants to merge 24 commits intodevelopfrom
dev/pkarasev/MPCC-49

Conversation

@KarasevPavel
Copy link

No description provided.

@KarasevPavel KarasevPavel added the enhancement New feature or request label Oct 7, 2024
@KarasevPavel KarasevPavel self-assigned this Oct 7, 2024
@KarasevPavel KarasevPavel requested a review from mak22223 October 7, 2024 20:23
@KarasevPavel KarasevPavel changed the title Dev/pkarasev/mpcc 49 [mpcc-49] C++ MPCC interface bugs fixed, interface was changed to absolute values of throttle and brakes Oct 7, 2024
Copy link

@mak22223 mak22223 left a comment

Choose a reason for hiding this comment

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

Hard to check maths of the model and all these parameters. Eventually we should add tests.

mak22223
mak22223 previously approved these changes Oct 6, 2025
Comment on lines -30 to 34
"lowerInputBounds":{
"dThrottleL": -1.0,
"dThrottleL": -240.0,
"dSteeringAngleL": -1.0,
"dBrakesL": -1.0,
"dBrakesL": -1862.0,
"dVsL": -5.0
Copy link

Choose a reason for hiding this comment

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

That means that we potentially can have negative motor and brake torques?

Copy link
Author

Choose a reason for hiding this comment

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

It is maximum negative rate of change


set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_FLAGS "-O0 -g")
Copy link

Choose a reason for hiding this comment

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

?

Copy link
Author

Choose a reason for hiding this comment

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

Will recheck

Comment on lines 31 to 34
nSqp = n_sqp;
sqpMixing = sqp_mixing;
nNoSolvesSqp = 0;
nReset = n_reset;
Copy link

Choose a reason for hiding this comment

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

These can be included in initialization list

State x = x0;
auto t1 = std::chrono::high_resolution_clock::now();
int solver_status = -1;
x(sIdx) = track_.porjectOnSpline(x);
Copy link

Choose a reason for hiding this comment

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

porject -> project

Comment on lines 137 to 140
if (validInitialGuess)
updateInitialGuess(x);
else
generateNewInitialGuess(x);
Copy link

Choose a reason for hiding this comment

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

It's better not to omit braces

Comment on lines 170 to 171
if (nNoSolvesSqpMax < nSqp)
initialGuess = tempGuess;
Copy link

Choose a reason for hiding this comment

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

Same

Comment on lines 95 to 97



Copy link

Choose a reason for hiding this comment

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

Garage for sale

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

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants