瀏覽代碼

fix(grpc_BS,controller_midcar):fix steer dir error and stop mode shift error

fujiankuan 3 年之前
父節點
當前提交
8c10087d43

+ 1 - 1
src/controller/controller_midcar/main.cpp

@@ -95,7 +95,7 @@ void ListenRemotectrl(const char * strdata,const unsigned int nSize,const unsign
         xdecition.set_brake(100.0);
         xdecition.set_wheelangle(0.0);
         xdecition.set_speed(5);
-        xdecition.set_gear(3); //0P 1D 2R 3N
+        xdecition.set_gear(1); //0P 1D 2R 3N
         xdecition.set_handbrake(0);
         xdecition.set_grade(1);
         xdecition.set_mode(1);

+ 1 - 1
src/driver/driver_cloud_grpc_client_BS/vehicle_control.cpp

@@ -118,7 +118,7 @@ void VehicleControlClient::updateControlData(void)
     {
         xmsg.set_acc(throttleCMD);
         xmsg.set_brake(brakeCMD);
-        xmsg.set_wheel(steeringWheelAngleCMD);
+        xmsg.set_wheel((-1)*steeringWheelAngleCMD/5.5f);
 
         if(shiftCMD == org::jeecg::defsControl::grpc::ShiftStatus::SHIFT_DRIVE)
             xmsg.set_shift(1);