2024-09-11 19:34:41 +02:00
|
|
|
function dq = diffdrive(t, q, u_discr, sim_data)
|
2024-07-31 21:21:01 +02:00
|
|
|
theta = q(3);
|
2024-09-06 15:49:04 +02:00
|
|
|
%dq = T(q)*W*u
|
|
|
|
|
|
|
|
% T_q (unicycle)
|
|
|
|
T_q = [cos(theta), 0; sin(theta), 0; 0, 1];
|
|
|
|
% W*u
|
|
|
|
Wu = diffdrive_to_uni(u_discr, sim_data);
|
|
|
|
dq = T_q*Wu;
|
2024-07-14 15:16:05 +02:00
|
|
|
end
|