Pause usage for real time matlab control
조회 수: 3 (최근 30일)
이전 댓글 표시
Good morning to every body.
I 'm working on robotino real time control using only Matlab interface ( command windows).
I first simulate my program and i get table of values. Values are related to velocities that i calculate by the formula v = distance/dt in some m_file script. I have chosen dt = 0.02 in this m files.
Now i want the robotino to excute these velocities of the obtained table.
I made iteration as usual so that value can be read per row after every iteration. But i notice that it is so quick that the system can't exhibit the desired behavior.
I tried to use pause and i put pause(0.02) but I notice that the path I want my robotino to follow is extended (means it takes more times as if the distance is multiplied).
Please could you help me about the value of Pause i can use to get the same duration of real path like done in simulation ?
here is code example
for i=2:length(Vmobile)
OmniDrive_setVelocity( OmniDriveId, Vmobile(i,1), Vmobile(i,2), Vmobile(i,3));
pause(0.02)
end
thank you
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Performance and Memory에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!