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.
Diff: hbCommand.cpp
- Revision:
- 36:2cc739c7e4cb
- Parent:
- 33:eb260dbfc22a
- Child:
- 38:24ee50452755
--- a/hbCommand.cpp Tue Dec 25 08:20:17 2018 +0000 +++ b/hbCommand.cpp Wed Jan 16 10:51:07 2019 +0000 @@ -128,36 +128,36 @@ else if (strcmp(g_CmdBuf , "spidimin")==0 ){g_PidPara.IMin = atof(&g_CmdBuf[arg2pos]);gf_PidParaUpdate=true;}//PIDの係数 積分下限値設定 else if (strcmp(g_CmdBuf , "spidv")==0 ){g_PidPara.V = atof(&g_CmdBuf[arg2pos]);gf_PidParaUpdate=true;}//PID2の角速度の係数 - //else if (strcmp(g_CmdBuf , "smot1ofs")==0 ){g_MotPara[0].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true;}//モーター1オフセット設定 - else if (strcmp(g_CmdBuf , "smot1hi")==0 ){g_MotPara[0].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true;}//モーター1上限値設定 - else if (strcmp(g_CmdBuf , "smot1low")==0 ){g_MotPara[0].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true;}//モーター1下限値設定 - //else if (strcmp(g_CmdBuf , "smot2ofs")==0 ){g_MotPara[1].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true;}//モーター2オフセット設定 - else if (strcmp(g_CmdBuf , "smot2hi")==0 ){g_MotPara[1].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true;}//モーター2上限値設定 - else if (strcmp(g_CmdBuf , "smot2low")==0 ){g_MotPara[1].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true;}//モーター2下限値設定 - //else if (strcmp(g_CmdBuf , "smot3ofs")==0 ){g_MotPara[2].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true;}//モーター3オフセット設定 - else if (strcmp(g_CmdBuf , "smot3hi")==0 ){g_MotPara[2].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true;}//モーター3上限値設定 - else if (strcmp(g_CmdBuf , "smot3low")==0 ){g_MotPara[2].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true;}//モーター3下限値設定 - //else if (strcmp(g_CmdBuf , "smot4ofs")==0 ){g_MotPara[3].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true;}//モーター4オフセット設定 - else if (strcmp(g_CmdBuf , "smot4hi")==0 ){g_MotPara[3].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true;}//モーター4上限値設定 - else if (strcmp(g_CmdBuf , "smot4low")==0 ){g_MotPara[3].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true;}//モーター4下限値設定 + // else if (strcmp(g_CmdBuf , "smot1ofs")==0 ){g_MotPara[0].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true;}//モーター1オフセット設定 + // else if (strcmp(g_CmdBuf , "smot1hi")==0 ){g_MotPara[0].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true;}//モーター1上限値設定 + // else if (strcmp(g_CmdBuf , "smot1low")==0 ){g_MotPara[0].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true;}//モーター1下限値設定 + // else if (strcmp(g_CmdBuf , "smot2ofs")==0 ){g_MotPara[1].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true;}//モーター2オフセット設定 + // else if (strcmp(g_CmdBuf , "smot2hi")==0 ){g_MotPara[1].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true;}//モーター2上限値設定 + // else if (strcmp(g_CmdBuf , "smot2low")==0 ){g_MotPara[1].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true;}//モーター2下限値設定 + // else if (strcmp(g_CmdBuf , "smot3ofs")==0 ){g_MotPara[2].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true;}//モーター3オフセット設定 + // else if (strcmp(g_CmdBuf , "smot3hi")==0 ){g_MotPara[2].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true;}//モーター3上限値設定 + // else if (strcmp(g_CmdBuf , "smot3low")==0 ){g_MotPara[2].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true;}//モーター3下限値設定 + // else if (strcmp(g_CmdBuf , "smot4ofs")==0 ){g_MotPara[3].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true;}//モーター4オフセット設定 + // else if (strcmp(g_CmdBuf , "smot4hi")==0 ){g_MotPara[3].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true;}//モーター4上限値設定 + // else if (strcmp(g_CmdBuf , "smot4low")==0 ){g_MotPara[3].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true;}//モーター4下限値設定 // else if (strcmp(g_CmdBuf , "smotofs")==0 ){ // g_MotPara[0].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true; // g_MotPara[1].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true; // g_MotPara[2].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true; // g_MotPara[3].offset = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true; // }//モーター1~4オフセット設定 - else if (strcmp(g_CmdBuf , "smothi")==0 ){ - g_MotPara[0].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true; - g_MotPara[1].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true; - g_MotPara[2].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true; - g_MotPara[3].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true; - }//モーター1~4上限値設定 - else if (strcmp(g_CmdBuf , "smotlow")==0 ){ - g_MotPara[0].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true; - g_MotPara[1].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true; - g_MotPara[2].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true; - g_MotPara[3].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true; - }//モーター1~4下限値設定 + // else if (strcmp(g_CmdBuf , "smothi")==0 ){ + // g_MotPara[0].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true; + // g_MotPara[1].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true; + // g_MotPara[2].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true; + // g_MotPara[3].limit_hi = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true; + // }//モーター1~4上限値設定 + // else if (strcmp(g_CmdBuf , "smotlow")==0 ){ + // g_MotPara[0].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[0]=true; + // g_MotPara[1].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[1]=true; + // g_MotPara[2].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[2]=true; + // g_MotPara[3].limit_low = atoi(&g_CmdBuf[arg2pos]);gf_MotParaUpdate[3]=true; + // }//モーター1~4下限値設定 else if (strcmp(g_CmdBuf , "rmo" )==0 ){gf_DbgPrint.bf.mo1=true;gf_DbgPrint.bf.mo2=true;gf_DbgPrint.bf.mo3=true;gf_DbgPrint.bf.mo4=true;}//リードモーターオフセット else if (strcmp(g_CmdBuf , "rmo1" )==0 ){gf_DbgPrint.bf.mo1=true;}//リードモーターオフセット1 else if (strcmp(g_CmdBuf , "rmo2" )==0 ){gf_DbgPrint.bf.mo2=true;}//リードモーターオフセット2