101 extern SLIP_Handle
SLIP_init(
void *pMemory,
const size_t numBytes);
107 extern void SLIP_run(SLIP_Handle slipHandle);
142 extern void SLIP_setup(SLIP_Handle slipHandle,
_iq sampleTime);
150 #endif // end of _SLIP_H_ definition
SLIP_Handle SLIP_init(void *pMemory, const size_t numBytes)
Initializes the encoder object.
struct _SLIP_Handle_ * SLIP_Handle
Defines the slip handle.
Contains the public interface to the types definitions.
int32_t incremental_slip
incremental amount of slip per sample time
int32_t enc_elec_angle
current electrical angle from encoder
int32_t enc_slip_angle
amount of total slip in Q24
void SLIP_setup(SLIP_Handle slipHandle, _iq sampleTime)
Initializes slip object parameters.
_iq sample_time
sample time of the SLIP module
int32_t enc_magnetic_angle
current magnetic angle in Q24
void SLIP_setSlipVelocity(SLIP_Handle slipHandle, _iq slipVelocity)
Set the amount of slip velocity and calculates the incremental slip.
_iq SLIP_getMagneticAngle(SLIP_Handle slipHandle)
Returns the current magnetic angle.
struct _SLIP_Obj_ SLIP_Obj
Defines the slip object.
void SLIP_run(SLIP_Handle slipHandle)
Based on the electrical angle and the incremental slip, calculates the magnetic angle.
void SLIP_setElectricalAngle(SLIP_Handle slipHandle, _iq electricalAngle)
Set the electrical angle.