|
@@ -916,7 +916,7 @@ iv::decition::Decition iv::decition::DecideGps00::getDecideFromGPS(GPS_INS now_g
|
|
|
obsDistanceAvoid = -1;
|
|
|
esrIndexAvoid = -1;
|
|
|
roadPre = -1;
|
|
|
- dSpeed = 80;
|
|
|
+ //dSpeed = ServiceCarStatus.mroadmode_vel.mfmode0;
|
|
|
|
|
|
gpsTraceOri.clear();
|
|
|
gpsTraceNow.clear();
|
|
@@ -1141,7 +1141,7 @@ iv::decition::Decition iv::decition::DecideGps00::getDecideFromGPS(GPS_INS now_g
|
|
|
|
|
|
|
|
|
// dSpeed = getSpeed(gpsTraceNow);
|
|
|
-
|
|
|
+ dSpeed =80;
|
|
|
planTrace.clear();//Add By YuChuli, 2020.11.26
|
|
|
for(int i=0;i<gpsTraceNow.size();i++){
|
|
|
TracePoint pt(gpsTraceNow[i].x,gpsTraceNow[i].y);
|
|
@@ -3755,7 +3755,8 @@ void iv::decition::DecideGps00::transferGpsMode2( const std::vector<GPSData> gps
|
|
|
static int speed_slowdown_flag=0;
|
|
|
static bool lock_flag=false;
|
|
|
double forecast_distance=0;
|
|
|
- int forecast_point_num;
|
|
|
+ int forecast_point_num=0;
|
|
|
+ bool cross=false;
|
|
|
|
|
|
double secLowSpeed=ServiceCarStatus.mroadmode_vel.mfmode18/3.6; //m/s
|
|
|
if(secSpeed>secLowSpeed)
|
|
@@ -3765,6 +3766,17 @@ void iv::decition::DecideGps00::transferGpsMode2( const std::vector<GPSData> gps
|
|
|
if((PathPoint+forecast_point_num+2)>gpsMapLine.size())
|
|
|
forecast_point_num=0;
|
|
|
}
|
|
|
+ if((PathPoint+forecast_point_num-8>0)&&(PathPoint+forecast_point_num+8<gpsMapLine.size()))
|
|
|
+ {
|
|
|
+ for(int i=PathPoint+forecast_point_num-8;i<PathPoint+forecast_point_num+8;i++)
|
|
|
+ {
|
|
|
+ if(gpsMapLine[i]->mode2==5000)
|
|
|
+ cross=true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ givlog->debug("decition_brain","PATHFORE: %d,Forecast: %d,cross: %d",
|
|
|
+ PathPoint+forecast_point_num,forecast_point_num,cross);
|
|
|
|
|
|
if( gpsMapLine[PathPoint]->mode2==3000){
|
|
|
if(obsDistance>4){ //7 zj-5
|
|
@@ -3785,7 +3797,7 @@ void iv::decition::DecideGps00::transferGpsMode2( const std::vector<GPSData> gps
|
|
|
obstacle_disable=0;
|
|
|
}else if(gpsMapLine[PathPoint]->mode2==4000){
|
|
|
ServiceCarStatus.msysparam.vehWidth=5.6;
|
|
|
- }else if((gpsMapLine[PathPoint+forecast_point_num]->mode2==5000)||(gpsMapLine[PathPoint+forecast_point_num+1]->mode2==5000)||(gpsMapLine[PathPoint+forecast_point_num-1]->mode2==5000)){
|
|
|
+ }else if(cross==true){
|
|
|
speed_slowdown_flag=1;
|
|
|
lock_flag=false;
|
|
|
}else if(gpsMapLine[PathPoint]->mode2==5001){
|