pylonDetection::pylonDetection(const tChar* __info) : cFilter(__info)
{
    targetPylon = Point2d(0,-1000);
//    pylonCertainty = 0;
    pylonLost = 0;
    sign = -1;

    turn_around = false;
    flip_sign = false;
    is_turning = false;

    type_sign  = -1;

    car_angle = 0.0;
    pylonDetectionCounter = 0;
    signDetectionCounter = 0;
    frameCounter = 0;
    SetPropertyStr("Color Calibration Parameters","/home/odroid/AADC/calibration_files/pylonCalibration.xml");
    SetPropertyBool("Color Calibration Parameters" NSSUBPROP_FILENAME, tTrue);
    SetPropertyStr("Color Calibration Parameters" NSSUBPROP_FILENAME NSSUBSUBPROP_EXTENSIONFILTER, "XML Files (*.xml)");
    SetPropertyStr("Camera Calibration Parameters","/home/odroid/AADC/calibration_files/cameraParameters.xml");
    SetPropertyBool("Camera Calibration Parameters" NSSUBPROP_FILENAME, tTrue);
    SetPropertyStr("Camera Calibration Parameters" NSSUBPROP_FILENAME NSSUBSUBPROP_EXTENSIONFILTER, "XML Files (*.xml)");
    SetPropertyInt("Debug Image",3);
    SetPropertyStr("Debug Image" NSSUBPROP_VALUELIST, "1@Threshold|2@Color|3@Model|4@Off|");

    SetPropertyInt("Speed turning",35);
    SetPropertyInt("Speed driving",35);
    SetPropertyFloat("Curvature Gain",1.0);
    SetPropertyFloat("Curvature Gain" NSSUBPROP_REQUIRED, tTrue);
    SetPropertyFloat("Angular Gain",2.0);
    SetPropertyFloat("Angular Gain" NSSUBPROP_REQUIRED, tTrue);
}
UltrasonicACC::UltrasonicACC(const tChar* __info) : cFilter(__info) {


	/* create the filter properties */
	SetPropertyStr(USACC_CONFIG_DRIVING_FILE, "../../../../utilities/UltrasonicACC/UltrasonicACC.xml");
	SetPropertyBool(USACC_CONFIG_DRIVING_FILE NSSUBPROP_FILENAME, tTrue);
	SetPropertyStr(USACC_CONFIG_DRIVING_FILE NSSUBPROP_FILENAME NSSUBSUBPROP_EXTENSIONFILTER, "XML Files (*.xml)");
	SetPropertyStr(USACC_CONFIG_DRIVING_FILE NSSUBPROP_DESCRIPTION, "The XML defining the behaviour for the DRIVING MODE of the ACC has to be set here");

	SetPropertyStr(USACC_CONFIG_PARKING_FILE, "../../../../utilities/UltrasonicACC/UltrasonicACC_Parking.xml");
	SetPropertyBool(USACC_CONFIG_PARKING_FILE NSSUBPROP_FILENAME, tTrue);
	SetPropertyStr(USACC_CONFIG_PARKING_FILE NSSUBPROP_FILENAME NSSUBSUBPROP_EXTENSIONFILTER, "XML Files (*.xml)");
	SetPropertyStr(USACC_CONFIG_PARKING_FILE NSSUBPROP_DESCRIPTION, "The XML defining the behaviour for the PARKING MODE of the ACC has to be set here");

	SetPropertyBool(USACC_DEBUG_XML_BORDER_WARNING, tFalse);
	SetPropertyStr(USACC_DEBUG_XML_BORDER_WARNING NSSUBPROP_DESCRIPTION, "If enabled a warning is printed to console each time the border points of the given xml are reached");

	SetPropertyBool(USACC_DEBUG_PRINT_INITIAL_TABLE, tFalse);
	SetPropertyStr(USACC_DEBUG_PRINT_INITIAL_TABLE NSSUBPROP_DESCRIPTION, "If enabled the loaded points of the interpolation table of the XML are printed to console");

	SetPropertyInt(USACC_COUNTER_THRESHOLD_NOMOVE,3);//noMovementThreshold
	SetPropertyStr(USACC_COUNTER_THRESHOLD_NOMOVE NSSUBPROP_DESCRIPTION, "Defines the approximate time in seconds that should be waited until Feedback 'NoMovement' is sent");

	SetPropertyInt(USACC_COUNTER_THRESHOLD_MOVEAGAIN,1);//MovementAgainThreshold
	SetPropertyStr(USACC_COUNTER_THRESHOLD_MOVEAGAIN NSSUBPROP_DESCRIPTION, "Defines the approximate time in seconds that should be waited until Feedback 'MovingAgain' is sent");

	SetPropertyFloat(USACC_LOWERBOUND_SPEED,0.05); //modifiedSpeedLowerBound
	SetPropertyStr(USACC_LOWERBOUND_SPEED NSSUBPROP_DESCRIPTION,"Defines the remaining value of speed that is seen as 'no movement'.");

	SetPropertyInt(USACC_SENSOR_SCALING_FRONT,15);
	SetPropertyInt(USACC_SENSOR_SCALING_FRONT NSSUBPROP_MIN,15);
	SetPropertyInt(USACC_SENSOR_SCALING_FRONT NSSUBPROP_MAX,60);
	SetPropertyStr(USACC_SENSOR_SCALING_FRONT NSSUBPROP_DESCRIPTION, "With value 30, the sensor pointing in direction of current steering angle is weighted with '1', while the two sensors next to it are weighted with '0.5'; "
			"DECREASING this value leads to steeper slope of weighting function, that means sensors next to 'main'-sensor are weighted LESS, e.g. with 15: only main sensor is taken into account!");

	SetPropertyInt(USACC_SENSOR_SCALING_REAR,20);
	SetPropertyInt(USACC_SENSOR_SCALING_REAR NSSUBPROP_MIN,15);
	SetPropertyInt(USACC_SENSOR_SCALING_REAR NSSUBPROP_MAX,60);
	SetPropertyStr(USACC_SENSOR_SCALING_REAR NSSUBPROP_DESCRIPTION, "With value 30, the sensor pointing in direction of current steering angle is weighted with '1', while the two sensors next to it are weighted with '0.5'; "
			"DECREASING this value leads to steeper slope of weighting function, that means sensors next to 'main'-sensor are weighted LESS, e.g. with 15: only main sensor is taken into account!");

	SetPropertyFloat(USACC_SENSOR_FRONT_CHECK_LIMIT, 0.4);
	SetPropertyFloat(USACC_SENSOR_FRONT_CHECK_LIMIT NSSUBPROP_MIN,0.0);
	SetPropertyFloat(USACC_SENSOR_FRONT_CHECK_LIMIT NSSUBPROP_MAX,1.5);
	SetPropertyStr(USACC_SENSOR_FRONT_CHECK_LIMIT NSSUBPROP_DESCRIPTION, "US values greater this property are ignored, area should then be checked with 3D camera (values in meter)");

	SetPropertyBool(USACC_DEBUG_OUTPUT_TO_CONSOLE,tFalse);
	SetPropertyStr(USACC_DEBUG_OUTPUT_TO_CONSOLE NSSUBPROP_DESCRIPTION, "If enabled additional debug information is printed to the console (Warning: decreases performance)");

	SetPropertyBool(USACC_EXT_DEBUG_OUTPUT_TO_CONSOLE,tFalse);
	SetPropertyStr(USACC_EXT_DEBUG_OUTPUT_TO_CONSOLE NSSUBPROP_DESCRIPTION, "If enabled all US values are printed to the console (Warning: decreases performance)");


	m_bdebugModeEnabled = tFalse;
	m_bextendedDebugModeEnabled = tFalse;
	/* initialize to neutral mid-setting, corresponds to an angle of zero degree */
	tmp_steeringAngle.f32_value = 90;
}
LaneFollower::LaneFollower(const tChar* __info) : cFilter(__info)
{
    SetPropertyFloat("curvature fact",1.0);
    SetPropertyFloat("steering alpha pos",1);
    SetPropertyFloat("steering alpha orientation",1);

    m_steering = 0;
    m_lf_enabled = true;
    m_cd_enabled = false;
    m_ps_enabled = false;

}
void ROI::InitializeProperties()
{
    hoodScanLineNumber = 4;
    roomScanLineNumber = 4;
    maxHoodDetectionCount = 5;
    isHoodDetectionEnabled = true;
    isRoomDetectionEnabled = true;
    rgbVideoManipulation = VIDEO_NONE;
    depthVideoManipulation = VIDEO_NONE;
    roomHeightManipulation = 0.85f;

    SetPropertyInt(HOOD_SCANLINE_NUMBER_PROPERTY, hoodScanLineNumber);
    SetPropertyBool(HOOD_SCANLINE_NUMBER_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(HOOD_SCANLINE_NUMBER_PROPERTY NSSUBPROP_DESCRIPTION, "Number of hood scanlines");
    SetPropertyInt(HOOD_SCANLINE_NUMBER_PROPERTY NSSUBPROP_MIN, 0);

    SetPropertyFloat(ROOM_HEIGHT_MANIPULATION_PROPERTY, roomHeightManipulation);
    SetPropertyBool(ROOM_HEIGHT_MANIPULATION_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(ROOM_HEIGHT_MANIPULATION_PROPERTY NSSUBPROP_DESCRIPTION, "Reduces the room height by the given percentage");
    SetPropertyFloat(ROOM_HEIGHT_MANIPULATION_PROPERTY NSSUBPROP_MIN, 0);
    SetPropertyFloat(ROOM_HEIGHT_MANIPULATION_PROPERTY NSSUBPROP_MAX, 1);

    SetPropertyInt(ROOM_SCANLINE_NUMBER_PROPERTY, roomScanLineNumber);
    SetPropertyBool(ROOM_SCANLINE_NUMBER_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(ROOM_SCANLINE_NUMBER_PROPERTY NSSUBPROP_DESCRIPTION, "Number of room scanlines");
    SetPropertyInt(ROOM_SCANLINE_NUMBER_PROPERTY NSSUBPROP_MIN, 0);

    SetPropertyInt(MAX_HOOD_DETECTION_COUNT_PROPERTY, maxHoodDetectionCount);
    SetPropertyBool(MAX_HOOD_DETECTION_COUNT_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(MAX_HOOD_DETECTION_COUNT_PROPERTY NSSUBPROP_DESCRIPTION, "Max hood detection dount");
    SetPropertyInt(MAX_HOOD_DETECTION_COUNT_PROPERTY NSSUBPROP_MIN, 0);

    SetPropertyBool(DETECT_HOOD_PROPERTY, isHoodDetectionEnabled);
    SetPropertyBool(DETECT_HOOD_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(DETECT_HOOD_PROPERTY NSSUBPROP_DESCRIPTION, "Detect hood");

    SetPropertyBool(DETECT_ROOM_PROPERTY, isRoomDetectionEnabled);
    SetPropertyBool(DETECT_ROOM_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(DETECT_ROOM_PROPERTY NSSUBPROP_DESCRIPTION, "Detect room");

    SetPropertyInt(RGB_VIDEO_MANIPULATION_PROPERTY, rgbVideoManipulation);
    SetPropertyBool(RGB_VIDEO_MANIPULATION_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(RGB_VIDEO_MANIPULATION_PROPERTY NSSUBPROP_VALUELIST, "1@None|2@Crop|3@Rect");
    SetPropertyStr(RGB_VIDEO_MANIPULATION_PROPERTY NSSUBPROP_DESCRIPTION, "Defines method which is used to manipulate the RGB image");

    SetPropertyInt(DEPTH_VIDEO_MANIPULATION_PROPERTY, depthVideoManipulation);
    SetPropertyBool(DEPTH_VIDEO_MANIPULATION_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(DEPTH_VIDEO_MANIPULATION_PROPERTY NSSUBPROP_VALUELIST, "1@None|2@Crop|3@Rect");
    SetPropertyStr(DEPTH_VIDEO_MANIPULATION_PROPERTY NSSUBPROP_DESCRIPTION, "Defines method which is used to manipulate the Depth image");
}
void YawToSteer::InitializeProperties()
{
    SetPropertyFloat(STEERING_COMPANSATION_FACTOR_PROPERTY, compensationValue);
    SetPropertyBool(STEERING_COMPANSATION_FACTOR_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(STEERING_COMPANSATION_FACTOR_PROPERTY NSSUBPROP_DESCRIPTION, "P-Part");

    SetPropertyFloat(DEVIATION_THRESHOLD_PROPERTY, deviationThreshold);
    SetPropertyBool(DEVIATION_THRESHOLD_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(DEVIATION_THRESHOLD_PROPERTY NSSUBPROP_DESCRIPTION, "Threshold before steering");

    SetPropertyFloat(ABRUPT_VARIATION_THRESHOLD_PROPERTY, abruptVariationThreshold);
    SetPropertyBool(ABRUPT_VARIATION_THRESHOLD_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(ABRUPT_VARIATION_THRESHOLD_PROPERTY NSSUBPROP_DESCRIPTION, "Reinit if senderYaw suddenly changes above this value");
}
CarFollower::CarFollower(const tChar *info) : cFilter(info),m_hTimer(NULL),logger(OID_SR_CARFOLLOWER)
{
	m_firstTime = tTrue;


	SetPropertyInt(PROP_CYCLETIME, 500);
	SetPropertyBool(PROP_CYCLETIME NSSUBPROP_ISCHANGEABLE, tTrue);
	SetPropertyStr(PROP_CYCLETIME NSSUBPROP_DESCRIPTION, "The control step for the local sequence timer.");
	SetPropertyFloat(PROP_SPACING, 0.5);
	SetPropertyBool(PROP_SPACING NSSUBPROP_ISCHANGEABLE, tTrue);
	SetPropertyStr(PROP_SPACING NSSUBPROP_DESCRIPTION, "The spacing maximum between cars");
	SetPropertyFloat(PROP_SPEEDSPACING, 1.0);
	SetPropertyBool(PROP_SPEEDSPACING NSSUBPROP_ISCHANGEABLE, tTrue);
	SetPropertyStr(PROP_SPEEDSPACING NSSUBPROP_DESCRIPTION, "The speed to compensate distance between cars");

}
FunctionDriver::FunctionDriver(const tChar *__info) : cFilter(__info), logger(FILTER_NAME)
{
    speed = 2;
    sinWidth = 10;
    sinLength = 15;

    SetPropertyFloat(SPEED_PROPERTY, speed);
    SetPropertyBool(SPEED_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(SPEED_PROPERTY NSSUBPROP_DESCRIPTION, "Speed in m/s.");

    SetPropertyFloat(SINWIDTH_PROPERTY, sinWidth);
    SetPropertyBool(SINWIDTH_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(SINWIDTH_PROPERTY NSSUBPROP_DESCRIPTION, "Breite");

    SetPropertyFloat(SINLENGTH_PROPERTY, sinLength);
    SetPropertyBool(SINLENGTH_PROPERTY NSSUBPROP_REQUIRED, tTrue);
    SetPropertyStr(SINLENGTH_PROPERTY NSSUBPROP_DESCRIPTION, "Weite");
}
// -------------------------------------------------------------------------------------------------
LaneFilter::LaneFilter(const tChar* __info) {
// -------------------------------------------------------------------------------------------------
  cMemoryBlock::MemSet(&input_format_, 0, sizeof(input_format_));
  
  SetPropertyBool("debug", false);
  SetPropertyBool("headlights_enabled", true);
  SetPropertyInt("scan_rate", 50);
  SetPropertyFloat("lum_threshold", 100);
}
cParkingspotDetection::cParkingspotDetection(const tChar* __info):cFilter(__info)
{
	/****************** Start of Debug ***************/
	SetPropertyBool(AF_PROP_SHOW_LOG,tTrue);
	SetPropertyStr(AF_PROP_SHOW_LOG NSSUBPROP_DESCRIPTION, "If true show log values");

	/****************** Distance Factor ***************/
	SetPropertyFloat(AF_PROP_DIST_FACTOR,0.16536);
	SetPropertyStr(AF_PROP_DIST_FACTOR NSSUBPROP_DESCRIPTION, "Factor to increase the return distance");

}
cMarkerDetectFilter::cMarkerDetectFilter(const tChar* __info):cFilter(__info)
{
    UCOM_REGISTER_TIMING_SPOT(cString(OIGetInstanceName()) + "::Process::Start", m_oProcessStart);

    flagtoreducespeed = tFalse;
    f32Areatoreducespeed = 400;
    var_lan_acc_input = 90.0f;
    var_lan_acc_output = 90.0f;
    global_i = 0;
    var_finish_flag = tTrue;
    FrameCount = 0;
    ManeuverJuryID = MANEUVER_INTERSECTION_DEFAULT;
    var_maneuver_id = TestArray[global_i];//(tFloat32)MANEUVER_INTERSECTION_RIGHT; //TestArray[global_i]; //global_i = 0;
    SetPropertyBool(MD_ENABLE_IMSHOW,tFalse);
    SetPropertyBool(MD_ENABLE_IMSHOW NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_ENABLE_IMSHOW NSSUBPROP_DESCRIPTION, "If true imshow will be enabled");

    SetPropertyBool(MD_ENABLE_IMSHOW_VER,tFalse);
    SetPropertyBool(MD_ENABLE_IMSHOW_VER NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_ENABLE_IMSHOW_VER NSSUBPROP_DESCRIPTION, "If true imshow will be enabled for vertical lines");

    SetPropertyBool("Debug Output to Console", tFalse);    
    SetPropertyStr("Debug Output to Console" NSSUBPROP_DESCRIPTION, "If enabled additional debug information is printed to the console (Warning: decreases performance)."); 

    //RETURN_NOERROR;
    SetPropertyStr("Dictionary File For Markers",""); 
    SetPropertyBool("Dictionary File For Markers" NSSUBPROP_FILENAME, tTrue); 
    SetPropertyStr("Dictionary File For Markers" NSSUBPROP_FILENAME NSSUBSUBPROP_EXTENSIONFILTER, "YML Files (*.yml)"); 
    SetPropertyStr("Dictionary File For Markers" NSSUBPROP_DESCRIPTION, "Here you have to set the dicitionary file which holds the marker ids and their content"); 

    SetPropertyStr("Calibration File for used Camera",""); 
    SetPropertyBool("Calibration File for used Camera" NSSUBPROP_FILENAME, tTrue); 
    SetPropertyStr("Calibration File for used Camera" NSSUBPROP_FILENAME NSSUBSUBPROP_EXTENSIONFILTER, "YML Files (*.yml)"); 
    SetPropertyStr("Calibration File for used Camera" NSSUBPROP_DESCRIPTION, "Here you have to set the file with calibration paraemters of the used camera"); 
    
    SetPropertyInt("Video Output Pin",1);
    SetPropertyStr("Video Output Pin" NSSUBPROP_VALUELIST, "1@None|2@Detected Signs|");
    SetPropertyStr("Video Output Pin" NSSUBPROP_DESCRIPTION, "If enabled the video stream with the highlighted markers is transmitted at the output pin (Warning: decreases performance)."); 

    SetPropertyFloat("Size of Markers",0.117f);
    SetPropertyStr("Size of Markers" NSSUBPROP_DESCRIPTION, "Size (length of one side) of markers in m"); 

    SetPropertyFloat(MD_REQUIRED_MARKER_SIZE, 900.0);
    SetPropertyBool(MD_REQUIRED_MARKER_SIZE NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_REQUIRED_MARKER_SIZE NSSUBPROP_DESCRIPTION, "MarkerDetection::The marker size above which manuevers processing starts");

    SetPropertyInt(MD_COUNT, 2);
    SetPropertyBool(MD_COUNT NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_COUNT NSSUBPROP_DESCRIPTION, "MarkerDetection::Minimum number of lines to be detected for markers to be considered");

    SetPropertyInt(MD_RANGE_ROWS_R1, 0);
    SetPropertyBool(MD_RANGE_ROWS_R1 NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_ROWS_R1 NSSUBPROP_DESCRIPTION, "MarkerDetection::The first row R1 to be taken (R1,) (R2,)");

    SetPropertyInt(MD_RANGE_ROWS_R2, 250);
    SetPropertyBool(MD_RANGE_ROWS_R2 NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_ROWS_R2 NSSUBPROP_DESCRIPTION,"MarkerDetection::The second row R2 to be taken (R1,) (R2,)");

    SetPropertyInt(MD_RANGE_COLS_C1, 0);
    SetPropertyBool(MD_RANGE_COLS_C1 NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_COLS_C1 NSSUBPROP_DESCRIPTION, "MarkerDetection::The first col C1 to be taken (,C1) (,C2)");

    SetPropertyInt(MD_RANGE_COLS_C2, 250);
    SetPropertyBool(MD_RANGE_COLS_C2 NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_COLS_C2 NSSUBPROP_DESCRIPTION, "MarkerDetection::The second col C2 to be taken (,C1) (,C2)");

    SetPropertyInt(MD_RANGE_ROWS_R1_L, 20);
    SetPropertyBool(MD_RANGE_ROWS_R1_L NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_ROWS_R1_L NSSUBPROP_DESCRIPTION, "LineDetection::The first row R1 to be taken (R1,) (R2,)");

    SetPropertyInt(MD_RANGE_ROWS_R2_L, 50);
    SetPropertyBool(MD_RANGE_ROWS_R2_L NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_ROWS_R2_L NSSUBPROP_DESCRIPTION,"LineDetection::The second row R2 to be taken (R1,) (R2,)");

    SetPropertyInt(MD_RANGE_COLS_C1_L, 90);
    SetPropertyBool(MD_RANGE_COLS_C1_L NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_COLS_C1_L NSSUBPROP_DESCRIPTION, "LineDetection::The first col C1 to be taken (,C1) (,C2)");

    SetPropertyInt(MD_RANGE_COLS_C2_L, 20);
    SetPropertyBool(MD_RANGE_COLS_C2_L NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_COLS_C2_L NSSUBPROP_DESCRIPTION, "LineDetection::The second col C2 to be taken (,C1) (,C2)");

    SetPropertyInt(MD_RANGE_ROWS_R1_VER, 30);
    SetPropertyBool(MD_RANGE_ROWS_R1_VER NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_ROWS_R1_VER NSSUBPROP_DESCRIPTION, "LineDetection_VER::Theq first row R1 to be taken (R1,) (R2,)");

    SetPropertyInt(MD_RANGE_ROWS_R2_VER, 60);
    SetPropertyBool(MD_RANGE_ROWS_R2_VER NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_ROWS_R2_VER NSSUBPROP_DESCRIPTION,"LineDetection_VER::Theq second row R2 to be taken (R1,) (R2,)");

    SetPropertyInt(MD_RANGE_COLS_C1_VER, 30);
    SetPropertyBool(MD_RANGE_COLS_C1_VER NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_COLS_C1_VER NSSUBPROP_DESCRIPTION, "LineDetection_VER::Theq first col C1 to be taken (,C1) (,C2)");

    SetPropertyInt(MD_RANGE_COLS_C2_VER, 60);
    SetPropertyBool(MD_RANGE_COLS_C2_VER NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_RANGE_COLS_C2_VER NSSUBPROP_DESCRIPTION, "LineDetection_VER::Theq second col C2 to be taken (,C1) (,C2)");

    SetPropertyInt(MD_GREY_TRESHOLD, 100);
    SetPropertyBool(MD_GREY_TRESHOLD NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(MD_GREY_TRESHOLD NSSUBPROP_DESCRIPTION, "The threshold value for canny to detect lines.");

    UCOM_REGISTER_TIMING_SPOT(cString(OIGetInstanceName()) + "::Process::End", m_oProcessEnd);    
}
cSteeringCalibrationFilter::cSteeringCalibrationFilter(const tChar* __info):cFilter(__info)
{
  	m_maxValue = 100;
	SetPropertyFloat("Max Value",m_maxValue);
	SetPropertyFloat("Max Value" NSSUBPROP_REQUIRED, tTrue);
}
cPParking::cPParking(const tChar* __info):cFilter(__info) {
	m_sensor_front_long = m_sensor_front_short = 0;

	m_pparkluecke = 80;
	SetPropertyFloat("Parallel Parkluecke", m_pparkluecke);
	SetPropertyFloat("Parallel Parkluecke" NSSUBPROP_REQUIRED, tTrue);
	m_pdistanz_a = 100;
	SetPropertyFloat("Parallel Distanz A", m_pdistanz_a);
	SetPropertyFloat("Parallel Distanz A" NSSUBPROP_REQUIRED, tTrue);
	m_pdistanz_b = 180;
	SetPropertyFloat("Parallel Distanz B", m_pdistanz_b);
	SetPropertyFloat("Parallel Distanz B" NSSUBPROP_REQUIRED, tTrue);
	m_pwinkel1 = 30;
	SetPropertyFloat("Parallel Winkel 1", m_pwinkel1);
	SetPropertyFloat("Parallel Winkel 1" NSSUBPROP_REQUIRED, tTrue);
	m_pwinkel2 = 30;
	SetPropertyFloat("Parallel Winkel 2", m_pwinkel2);
	SetPropertyFloat("Parallel Winkel 2" NSSUBPROP_REQUIRED, tTrue);
	
	m_cparkluecke = 35;
	SetPropertyFloat("Cross Parkluecke", m_cparkluecke);
	SetPropertyFloat("Cross Parkluecke" NSSUBPROP_REQUIRED, tTrue);
	m_cdistanz_a = 50;
	SetPropertyFloat("Cross Distanz A", m_cdistanz_a);
	SetPropertyFloat("Cross Distanz A" NSSUBPROP_REQUIRED, tTrue);
	m_cwinkel1 = 30;
	SetPropertyFloat("Cross Winkel 1", m_cwinkel1);
	SetPropertyFloat("Cross Winkel 1" NSSUBPROP_REQUIRED, tTrue);
	m_cwinkel2 = 90;
	SetPropertyFloat("Cross Winkel 2", m_cwinkel2);
	SetPropertyFloat("Cross Winkel 2" NSSUBPROP_REQUIRED, tTrue);
	m_cdistanz_b = 180;
	SetPropertyFloat("Cross Distanz B", m_cdistanz_b);
	SetPropertyFloat("Cross Distanz B" NSSUBPROP_REQUIRED, tTrue);
	
}
cNotbremse::cNotbremse(const tChar* __info):cFilter(__info) {
	m_sensor_front_long = m_sensor_front_short = 0;

	m_stopDistance = 8;
	SetPropertyFloat("Hard Stop Distance", m_stopDistance);
	SetPropertyFloat("Hard Stop Distance" NSSUBPROP_REQUIRED, tTrue);
	m_slowDistance15 = 15;
	SetPropertyFloat("Slow down to 15 Distance", m_slowDistance15);
	SetPropertyFloat("Slow down to 15 Distance" NSSUBPROP_REQUIRED, tTrue);
	m_slowDistance25 = 20;
	SetPropertyFloat("Slow down to 25 Distance", m_slowDistance25);
	SetPropertyFloat("Slow down to 25 Distance" NSSUBPROP_REQUIRED, tTrue);
	m_slowDistance30 = 50;
	SetPropertyFloat("Slow down to 30 Distance", m_slowDistance30);
	SetPropertyFloat("Slow down to 30 Distance" NSSUBPROP_REQUIRED, tTrue);
	m_slowDistance_back = 15;
	SetPropertyFloat("Back Distance", m_slowDistance_back);
	SetPropertyFloat("Back Distance" NSSUBPROP_REQUIRED, tTrue);
	m_stuck_time = 5;
	SetPropertyFloat("Stuck Time in s", m_stuck_time);
	SetPropertyFloat("Stuck Time in s" NSSUBPROP_REQUIRED, tTrue);
	m_stuck_distance = 10;
	SetPropertyFloat("Stuck Distance", m_stuck_distance);
	SetPropertyFloat("Stuck Distance" NSSUBPROP_REQUIRED, tTrue);
	
	m_cTimer = 0;
	t_accelerate_old = 0;
	m_hTimer = NULL;
}
Exemple #14
0
PIDController::PIDController(const tChar* __info) : cFilter(__info), m_f64LastMeasuredError(0), m_f64SetPoint(0), m_lastSampleTime(0),m_f64LastSpeedValue(0)
{
    SetPropertyFloat(WSC_PROP_PID_KP,1.5);
    SetPropertyBool(WSC_PROP_PID_KP NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_KP NSSUBPROP_DESCRIPTION, "The proportional factor Kp for the PID Controller");

    SetPropertyFloat(WSC_PROP_PID_KI,1.5);
    SetPropertyBool(WSC_PROP_PID_KI NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_KI NSSUBPROP_DESCRIPTION, "The integral factor Ki for the PID Controller");

    SetPropertyFloat(WSC_PROP_PID_KD,1);
    SetPropertyBool(WSC_PROP_PID_KD NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_KD NSSUBPROP_DESCRIPTION, "The differential factor Kd for the PID Controller");

    SetPropertyFloat(WSC_PROP_PID_SAMPLE_TIME,0.025);
    SetPropertyBool(WSC_PROP_PID_SAMPLE_TIME NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_SAMPLE_TIME NSSUBPROP_DESCRIPTION, "The sample interval in msec used by the PID controller");

    SetPropertyFloat(WSC_PROP_PID_MAXOUTPUT,2.5);
    SetPropertyBool(WSC_PROP_PID_MAXOUTPUT NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_MAXOUTPUT NSSUBPROP_DESCRIPTION, "The maximum allowed output for the wheel speed controller (speed in m/sec^2)");

    SetPropertyFloat(WSC_PROP_PID_MINOUTPUT,-2.5);
    SetPropertyBool(WSC_PROP_PID_MINOUTPUT NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_MINOUTPUT NSSUBPROP_DESCRIPTION, "The minimum allowed output for the wheel speed controller (speed in m/sec^2)");

    SetPropertyInt(WSC_PROP_PID_WINDUP, 3);
    SetPropertyStr(WSC_PROP_PID_WINDUP NSSUBPROP_DESCRIPTION, "Method for Anti Windup (1: Off, 2: Reset integral term, 3: Stabilize integral term)");
    SetPropertyStr(WSC_PROP_PID_WINDUP NSSUBPROP_VALUELISTNOEDIT, "1@No|2@Reset|3@Stabilize");

    SetPropertyBool(WSC_PROP_PID_SETZERO, tTrue);
    SetPropertyBool(WSC_PROP_PID_SETZERO NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_SETZERO NSSUBPROP_DESCRIPTION, "True: When Setpoint is zero, Output is set to zero (AADC default True)");

    SetPropertyBool(WSC_PROP_PID_USEDIRINPUT, tTrue);
    SetPropertyBool(WSC_PROP_PID_USEDIRINPUT NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PID_USEDIRINPUT NSSUBPROP_DESCRIPTION, "True: Use car speed direction info based on set speed input, False: use measured input for direction info");

    SetPropertyBool(WSC_PROP_DEBUG_MODE, tFalse);
    SetPropertyStr(WSC_PROP_DEBUG_MODE NSSUBPROP_DESCRIPTION, "If true debug infos are plotted to registry");

    SetPropertyFloat(WSC_PROP_PT1_OUTPUT_FACTOR, 1);
    SetPropertyBool(WSC_PROP_PT1_OUTPUT_FACTOR NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PT1_OUTPUT_FACTOR NSSUBPROP_DESCRIPTION, "The factor to normalize the output value");

    SetPropertyFloat(WSC_PROP_PT1_TIMECONSTANT, 1.5);
    SetPropertyBool(WSC_PROP_PT1_TIMECONSTANT NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PT1_TIMECONSTANT NSSUBPROP_DESCRIPTION, "Time Constant for PT1 Controller");

    SetPropertyFloat(WSC_PROP_PT1_CORRECTION_FACTOR, 1.15);
    SetPropertyBool(WSC_PROP_PT1_CORRECTION_FACTOR NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PT1_CORRECTION_FACTOR NSSUBPROP_DESCRIPTION, "Correction factor for input set point");

    SetPropertyFloat(WSC_PROP_PT1_GAIN, 6);
    SetPropertyBool(WSC_PROP_PT1_GAIN NSSUBPROP_ISCHANGEABLE, tTrue);
    SetPropertyStr(WSC_PROP_PT1_GAIN NSSUBPROP_DESCRIPTION, "Gain for PT1 Controller");

    SetPropertyInt("Controller Typ", 2);
    SetPropertyStr("Controller Typ" NSSUBPROP_VALUELISTNOEDIT, "1@P|2@PI|3@PID|4@PT1");

    //m_pISignalRegistry = NULL;
}