Jump to main content

##

# 3.3.23.6 tmcRef_State_s Struct

## C

    // Floating point structure defining the state of the reference control module.
    typedef struct
    {
        bool enable;                         /* Flag indicating reference control module enable status */
        bool initDone;                       /* Flag indicating reference control  module initialization status */
        float32_t lowerLimit;                /* Lower limit for the reference value */
        float32_t upperLimit;                /* Upper limit for the reference value */
        float32_t reference;                 /* The current reference value that the speed control uses */
        float32_t rampRate;                  /* The rate at which the reference value is allowed to change per control cycle */
    }tmcRef_State_s;

    // Fixed point structure defining the state of the reference control module.
    typedef struct
    {
        bool enable;                         /* Flag indicating reference control module enable status */
        bool initDone;                       /* Flag indicating reference control  module initialization status */
        int16_t_t lowerLimit;                /* Lower limit for the reference value */
        int16_t_t upperLimit;                /* Upper limit for the reference value */
        int32_t scaledLowerLimit;            /* Scaled lower limit for the reference value */
        int32_t scaledUpperLimit;            /* Scaled upper limit for the reference value */
        int32_t scaledReference;             /* Scaled reference value */
        int32_t scaledRampRate;              /* Scaled ramp rate       */
        int16_t reference;                   /* Reference value */
    } tmcRef_State_s;

## Summary

Reference control Module Structure.

## Description

This structure holds the parameters for the reference control module. It includes control flags, speed reference value, its limits, and the rate of change (ramp rate).

## Remarks

Refer the generated header file for the exact typedef signature..