Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of TVDctrller2017_brdRev1_ver6 by
Diff: TVDCTRL.cpp
- Revision:
- 58:ac3d182732c9
- Parent:
- 57:02b7178cd083
- Child:
- 59:7fdf1168c5c3
diff -r 02b7178cd083 -r ac3d182732c9 TVDCTRL.cpp --- a/TVDCTRL.cpp Tue Jan 09 06:14:28 2018 +0000 +++ b/TVDCTRL.cpp Tue Jan 09 10:09:01 2018 +0000 @@ -685,7 +685,7 @@ e[rlFlag][1] = e[rlFlag][0]; } - printf("%f %f\r\n", e[0][0], e[1][0]); +// printf("%f %f\r\n", e[0][0], e[1][0]); outputTrq[0] = myMin(reqMotorTrq[0], lastMotorTrq[0]); //ちっさい方を出力トルクとして採用 outputTrq[1] = myMin(reqMotorTrq[1], lastMotorTrq[1]); //ちっさい方を出力トルクとして採用 @@ -693,8 +693,8 @@ for (int rlFlag = 0; rlFlag < 2; rlFlag++) { if(outputTrq[rlFlag] > 45.0) outputTrq[rlFlag] = 45.0; - if(outputTrq[rlFlag] < 0.0) - outputTrq[rlFlag] = 0.0; + if(outputTrq[rlFlag] < -10.0) + outputTrq[rlFlag] = -10.0; } if(myAbs(e[0][0]) > myAbs(e[1][1])) { //右輪の空転が大きい場合