8000 Simulink: investigated copy elimination, enforce more checks in test by FreyJo · Pull Request #1391 · acados/acados · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Simulink: investigated copy elimination, enforce more checks in test #1391

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

Merged
merged 3 commits into from
Dec 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -244,13 +244,13 @@
disp('failed');
quit(1);
end
%
%
pi_signal = out_sim.logsout.getElement('pi_all');
pi_simulink = pi_signal.Values.Data(1, :);
disp('checking pi values, should match solution in MATLAB.')
if norm(pi_simulink(:) - pi_traj(:)) > 1e-8
disp('failed');
% quit(1);
quit(1);
end

x1_signal = out_sim.logsout.getElement('x1');
Expand All @@ -259,7 +259,7 @@
disp('checking x1_value')
if norm(x1_val(:) - x1_ref(:)) > 1e-8
disp('failed');
% quit(1);
quit(1);
end

u0_signal = out_sim.logsout.getElement('u0');
Expand All @@ -268,7 +268,7 @@
disp('checking u0_value')
if norm(u0_val(:) - u0_ref(:)) > 1e-8
disp('failed');
% quit(1);
quit(1);
end

end
2 changes: 1 addition & 1 deletion interfaces/acados_matlab_octave/AcadosOcp.m
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ function make_consistent(self, is_mocp_phase)
elseif ignore_initial
stage_type_indices = [2, 3];
else
stage_type_indices = [1, 2, 3]
stage_type_indices = [1, 2, 3];
end

stage_types = {'initial', 'path', 'terminal'};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -720,8 +720,7 @@ static void mdlOutputs(SimStruct *S, int_T tid)
double buffer[{{ buffer_size }}];
double tmp_double;
int tmp_offset, tmp_int;
{#- TODO: probably the whole buffer stuff can be avoided! #}
{#- TODO: use something like ocp_nlp_set_all(nlp_solver, nlp_in, nlp_out, "x", in_sign); for initializing #}
{#- NOTE: buffer is necessary as ssGetInputPortRealSignalPtrs does not return double pointer #}

/* go through inputs */
{%- set i_input = -1 %}
Expand Down
Loading
0