
#ifndef _ECATDEVICEAPI_STICKCONTROL_H_
#define _ECATDEVICEAPI_STICKCONTROL_H_
#include <stdint.h>
#define MAX_MODEL_NO 6

#ifdef __cplusplus
extern "C" {
#endif

int32_t ECAT_StSet_axis_stick_control_enable(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Enable);
int32_t	ECAT_StSet_axis_breakout_force(uint16_t DeviceNo, uint16_t AxisNo, float ForcePos, float ForceNeg, float Deg);
int32_t	ECAT_StSet_axis_operation_range(uint16_t DeviceNo, uint16_t AxisNo, float PostiveDeg, float NegativeDeg);
int32_t	ECAT_StSet_axis_coulomb_force(uint16_t DeviceNo, uint16_t AxisNo, float CoulombRefPos, float CoulombRefNeg, float VelocityZone);
int32_t ECAT_StSet_axis_control_mode(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Mode);
int32_t	ECAT_StSet_axis_end_stop(uint16_t DeviceNo, uint16_t AxisNo, float EndStopK, float EndStopZeta);
int32_t ECAT_StSet_axis_gradient_multiplier(uint16_t DeviceNo, uint16_t AxisNo, float Multiplier);
int32_t	ECAT_StSet_axis_reference_model_MBK(uint16_t DeviceNo, uint16_t AxisNo, float Mass, float Damping, float Stiff);
int32_t	ECAT_StSet_axis_reference_model_MZetaWn(uint16_t DeviceNo, uint16_t AxisNo, float Mass, float Zeta, float Wn);
int32_t ECAT_StSet_axis_gradient_zone_ratio(uint16_t DeviceNo, uint16_t AxisNo, uint16_t r1, uint16_t r2, uint16_t r3, uint16_t n1, uint16_t n2, uint16_t n3);
int32_t	ECAT_StSet_axis_gradient_positive(uint16_t DeviceNo, uint16_t AxisNo, float g0, float g1, float g2, float g3);
int32_t	ECAT_StSet_axis_gradient_negative(uint16_t DeviceNo, uint16_t AxisNo, float g0, float g1, float g2, float g3);
int32_t	ECAT_StSet_axis_force_limit(uint16_t DeviceNo, uint16_t AxisNo, float Limit);
int32_t	ECAT_StSet_axis_force_dead_zone(uint16_t DeviceNo, uint16_t AxisNo, float Force);
int32_t	ECAT_StGet_axis_force_error(uint16_t DeviceNo, uint16_t AxisNo, float *Force);
int32_t	ECAT_StSet_axis_max_velocity(uint16_t DeviceNo, uint16_t AxisNo, float Velocity);
int32_t	ECAT_StSet_axis_max_acceleration(uint16_t DeviceNo, uint16_t AxisNo, float Acc);
int32_t	ECAT_StSet_axis_sensor_parameters(uint16_t DeviceNo, uint16_t AxisNo, uint16_t SlaveNo);
int32_t	ECAT_StSet_axis_sensor_max_voltage(uint16_t DeviceNo, uint16_t AxisNo, float Voltage);
int32_t	ECAT_StSet_axis_sensor_max_torque(uint16_t DeviceNo, uint16_t AxisNo, float Torque);
int32_t ECAT_StSet_axis_operation_range_margin(uint16_t DeviceNo, uint16_t AxisNo, float Margin);
int32_t	ECAT_StSet_axis_trim_neutral_position(uint16_t DeviceNo, uint16_t AxisNo);
int32_t ECAT_StSet_axis_control_mode_default(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Mode);
int32_t	ECAT_StSet_axis_control_mode0_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Mass0, float Zeta0, float Wn0, float MaxAcc0, float MaxVel0, float Coulomb0);
int32_t ECAT_StSet_axis_trim_enable(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Enable);
int32_t ECAT_StSet_axis_trim_offset(uint16_t DeviceNo, uint16_t AxisNo, float Offset);
int32_t ECAT_StGet_axis_trim_offset(uint16_t DeviceNo, uint16_t AxisNo, float *Offset);
int32_t ECAT_StGet_trim_state(uint16_t DeviceNo, uint16_t *State);
int32_t	ECAT_StSet_axis_trim_release(uint16_t DeviceNo, uint16_t AxisNo, uint16_t on_off);
int32_t ECAT_StSet_stick_linking(uint16_t DeviceNo, uint16_t Value);
int32_t	ECAT_StGet_axis_model_V(uint16_t DeviceNo, uint16_t AxisNo, float *V);
int32_t	ECAT_StGet_axis_model_A(uint16_t DeviceNo, uint16_t AxisNo, float *A);
int32_t	ECAT_StSet_axis_force_average_time(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Time);
int32_t	ECAT_StSet_axis_force_filter_time_constant(uint16_t DeviceNo, uint16_t AxisNo, float Time_const);
int32_t	ECAT_StGet_axis_trip_state(uint16_t DeviceNo, uint16_t AxisNo, uint16_t *State);
int32_t	ECAT_StSet_axis_ad_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_position_error_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_acceleration_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_velocity_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_force_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_positive_travel_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_negative_travel_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_power_trip_level(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t ECAT_StSet_force_gain(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_position_gain(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_shaker_activate_mode(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Mode);
int32_t	ECAT_StSet_shaker_parameters(uint16_t DeviceNo, uint16_t AxisNo, uint32_t Waveform, float Amp, float Freq, float Fade_time);
int32_t	ECAT_StSet_axis_aeroforce_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Gradient, float Offset);
int32_t ECAT_StSet_host_input_force(uint16_t DeviceNo, uint16_t AxisNo, float Force);
int32_t	ECAT_StSet_axis_force_offset(uint16_t DeviceNo, uint16_t AxisNo, float Force);
int32_t	ECAT_StGet_axis_force(uint16_t DeviceNo, uint16_t AxisNo, float *Force);
int32_t	ECAT_StGet_link_state(uint16_t DeviceNo, uint16_t *State);
int32_t	ECAT_StSet_axis_force_sensor_direction(uint16_t DeviceNo, uint16_t AxisNo, float Dir);
int32_t	ECAT_StSet_axis_ap_trim_switch(uint16_t DeviceNo, uint16_t AxisNo, uint16_t m_switch);
int32_t	ECAT_StSet_axis_ap_velocity(uint16_t DeviceNo, uint16_t AxisNo, float Velocity);
int32_t	ECAT_StSet_axis_trim_velocity(uint16_t DeviceNo, uint16_t AxisNo, float Velocity);
int32_t	ECAT_StSet_axis_trim_init_position(uint16_t DeviceNo, uint16_t AxisNo, float Position);
int32_t	ECAT_StSet_axis_ap_force_override(uint16_t DeviceNo, uint16_t AxisNo, float Force);
int32_t	ECAT_StSet_axis_ap_trim_switch_parameters(uint16_t DeviceNo, uint16_t AxisNo, uint32_t m_switch, float AP_Vel, float Trim_Vel, float Trim_initpos, float AP_override);
int32_t	ECAT_StGet_axis_calculated_force(uint16_t DeviceNo, uint16_t AxisNo, float *Force);
int32_t ECAT_StMove_trim_position(uint16_t DeviceNo, uint16_t AxisNo, float Position, uint32_t Steps);
int32_t	ECAT_StGet_axis_ai(uint16_t DeviceNo, uint16_t AxisNo, float *Ai);
int32_t ECAT_StUpdateWheelControlLib(uint16_t DeviceNo, uint32_t Offset, char *Data, uint32_t DataSize, uint8_t LastFlag);
int32_t ECAT_StGetWheelControlLibVersion(uint16_t DeviceNo, char *Version, uint16_t *Size);
int32_t ECAT_StSet_axis_parameters(uint16_t DeviceNo, uint16_t AxisNo, float *Data, uint16_t Size);
int32_t ECAT_StGet_axis_parameters(uint16_t DeviceNo, uint16_t AxisNo, float *Data, uint16_t Size);
int32_t ECAT_StSet_axis_gradient_multiplier_ex(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, float Multiplier);
int32_t ECAT_StSet_axis_gradient_zone_ratio_ex(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, uint16_t r1, uint16_t r2, uint16_t r3, uint16_t n1, uint16_t n2, uint16_t n3);
int32_t	ECAT_StSet_axis_gradient_positive_ex(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, float g0, float g1, float g2, float g3);
int32_t	ECAT_StSet_axis_gradient_negative_ex(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, float g0, float g1, float g2, float g3);
int32_t ECAT_StSet_axis_car_speed(uint16_t DeviceNo, uint16_t AxisNo, float Value);
int32_t	ECAT_StSet_axis_coulomb_force_ex(uint16_t DeviceNo, uint16_t AxisNo, float GradientPos, float OffsetPos, float GradientNeg, float OffsetNeg, float VelocityZone);
int32_t	ECAT_StSet_axis_force_filter_cutoff_freq(uint16_t DeviceNo, uint16_t AxisNo, float Frequency);
int32_t	ECAT_StSet_axis_Backlash_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Mass_b, float B_b, float MaxAcc_b, float MaxVel_b, float Coulomb_b, float Backlash);
int32_t	ECAT_StSet_axis_Backlash_Enable(uint16_t DeviceNo, uint16_t AxisNo, uint32_t Enable);
int32_t	ECAT_StGet_axis_model_X(uint16_t DeviceNo, uint16_t AxisNo, float *X);
int32_t ECAT_STSet_axis_Tor_FeedForward_Gain(uint16_t DeviceNo, uint16_t AxisNo, float Gain);
int32_t ECAT_STSet_axis_Tor_Compensation(uint16_t DeviceNo, uint16_t AxisNo, float Pos, float Neg, float VelZone);
int32_t	ECAT_StSet_axis_cable_model_MZetaWn(uint16_t DeviceNo, uint16_t AxisNo, float Mass, float Zeta, float Wn);
int32_t	ECAT_StSet_axis_Fwd_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Mass, float B, float MaxAcc, float MaxVel, float Coulomb, float VelocityZone);
int32_t	ECAT_StGet_axis_Fwd_model_X(uint16_t DeviceNo, uint16_t AxisNo, float *X);
int32_t	ECAT_StGet_axis_Fwd_model_V(uint16_t DeviceNo, uint16_t AxisNo, float *V);
int32_t	ECAT_StGet_axis_Fwd_model_A(uint16_t DeviceNo, uint16_t AxisNo, float *A);
int32_t	ECAT_StSet_axis_Aft_parameters(uint16_t DeviceNo, uint16_t AxisNo, float B, float MaxAcc, float MaxVel);
int32_t	ECAT_StSet_axis_Cable_parameters(uint16_t DeviceNo, uint16_t AxisNo, float B, float K);
int32_t	ECAT_StSet_axis_Gcompensate_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Maxforce, float DegOffset);
int32_t	ECAT_StSet_axis_ai_offset(uint16_t DeviceNo, uint16_t AxisNo, float offset);
int32_t	ECAT_StSet_axis_Hydraulic_aft_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Mass, float B, float MaxAcc, float MaxVel);
int32_t	ECAT_StSet_axis_valve_parameters(uint16_t DeviceNo, uint16_t AxisNo, float b, float k, float Limit);
int32_t	ECAT_StSet_axis_boost_gradient_multiplier(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, float Multiplier);
int32_t	ECAT_StSet_axis_boost_gradient_zone_ratio(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, uint16_t r1, uint16_t r2, uint16_t r3);
int32_t	ECAT_StSet_axis_boost_gradient(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, float g0, float g1, float g2, float g3);
int32_t	ECAT_StSet_axis_Aft_model_mode(uint16_t DeviceNo, uint16_t AxisNo, uint16_t Mode);
int32_t	ECAT_StSet_axis_Host_Force_Test(uint16_t DeviceNo, uint16_t AxisNo, float Time, float Delay, float ForceMax);
int32_t	ECAT_StSet_axis_lateralforce_parameters(uint16_t DeviceNo, uint16_t AxisNo, float Gradient, float Offset);
int32_t	ECAT_StSet_axis_boost_gradient_zone_force(uint16_t DeviceNo, uint16_t AxisNo, uint16_t TableNo, float f1, float f2, float f3, float fmax);
int32_t	ECAT_StSet_axis_Sim_Pos_SinWave(uint16_t DeviceNo, uint16_t AxisNo,float Amp, float Freq, float time_s);
int32_t	ECAT_StGet_axis_Fwd_model_J(uint16_t DeviceNo, uint16_t AxisNo, float *J);
int32_t	ECAT_StSet_axis_max_Jerk(uint16_t DeviceNo, uint16_t AxisNo, float J);
int32_t	ECAT_STSet_grp_link(uint16_t DeviceNo, uint16_t GrpNo, uint16_t m_AxisNo, uint16_t s_AxisNo);

#ifdef __cplusplus
}
#endif

#endif /* _ECATDEVICEAPI_STICKCONTROL_H_ */
