'''
Created on 07.11.2019

@author: JM
'''

class TMC4361_register:
    """
    Define all registers of the TMC4361.
    """
    GENERAL_CONF                                  = 0x00
    REFERENCE_CONF                                = 0x01
    START_CONF                                    = 0x02
    INPUT_FILT_CONF                               = 0x03
    SPI_OUT_CONF                                  = 0x04
    CURRENT_CONF                                  = 0x05
    SCALE_VALUES                                  = 0x06
    ENC_IN_CONF                                   = 0x07
    ENC_IN_DATA                                   = 0x08
    ENC_OUT_DATA                                  = 0x09
    STEP_CONF                                     = 0x0A
    SPI_STATUS_SELECTION                          = 0x0B
    EVENT_CLEAR_CONF                              = 0x0C
    INTR_CONF                                     = 0x0D
    EVENTS                                        = 0x0E
    STATUS                                        = 0x0F
    STP_LENGTH_ADD___DIR_SETUP_TIME               = 0x10
    START_OUT_ADD                                 = 0x11
    GEAR_RATIO                                    = 0x12
    START_DELAY                                   = 0x13
    CLK_GATING_DELAY                              = 0x14
    STDBY_DELAY                                   = 0x15
    FREEWHEEL_DELAY                               = 0x16
    VDRV_SCALE_LIMIT___PWM_VMAX                   = 0x17
    UP_SCALE_DELAY___CL_UPSCALE_DELAY             = 0x18
    HOLD_SCALE_DELAY___CL_DNSCALE_DELAY           = 0x19
    DRV_SCALE_DELAY                               = 0x1A
    BOOST_TIME                                    = 0x1B
    CL_ANGLES                                     = 0x1C
    SPI_SWITCH_VEL___DAC_ADDR                     = 0x1D
    HOME_SAFETY_MARGIN                            = 0x1E
    PWM_FREQ___CHOPSYNC_DIV                       = 0x1F
    RAMPMODE                                      = 0x20
    XACTUAL                                       = 0x21
    VACTUAL                                       = 0x22
    AACTUAL                                       = 0x23
    VMAX                                          = 0x24
    VSTART                                        = 0x25
    VSTOP                                         = 0x26
    VBREAK                                        = 0x27
    AMAX                                          = 0x28
    DMAX                                          = 0x29
    ASTART                                        = 0x2A
    DFINAL                                        = 0x2B
    DSTOP                                         = 0x2C
    BOW1                                          = 0x2D
    BOW2                                          = 0x2E
    BOW3                                          = 0x2F
    BOW4                                          = 0x30
    CLK_FREQ                                      = 0x31
    POS_COMP                                      = 0x32
    VIRT_STOP_LEFT                                = 0x33
    VIRT_STOP_RIGHT                               = 0x34
    X_HOME                                        = 0x35
    X_LATCH___REV_CNT___X_RANGE                   = 0x36
    XTARGET                                       = 0x37
    X_PIPE0                                       = 0x38
    X_PIPE1                                       = 0x39
    X_PIPE2                                       = 0x3A
    X_PIPE3                                       = 0x3B
    X_PIPE4                                       = 0x3C
    X_PIPE5                                       = 0x3D
    X_PIPE6                                       = 0x3E
    X_PIPE7                                       = 0x3F
    SH_REG0                                       = 0x40
    SH_REG1                                       = 0x41
    SH_REG2                                       = 0x42
    SH_REG3                                       = 0x43
    SH_REG4                                       = 0x44
    SH_REG5                                       = 0x45
    SH_REG6                                       = 0x46
    SH_REG7                                       = 0x47
    SH_REG8                                       = 0x48
    SH_REG9                                       = 0x49
    SH_REG10                                      = 0x4A
    SH_REG11                                      = 0x4B
    SH_REG12                                      = 0x4C
    SH_REG13                                      = 0x4D
    Freeze_Registers                              = 0x4E
    ENC_POS                                       = 0x50
    ENC_LATCH___ENC_RESET_VAL                     = 0x51
    ENC_POS_DEV___CL_TR_TOLERANCE                 = 0x52
    ENC_POS_DEV_TOL                               = 0x53
    ENC_IN_RES___ENC_CONST                        = 0x54
    ENC_OUT_RES                                   = 0x55
    SER_CLK_IN_HIGH_LOW                           = 0x56
    SSI_IN_CLK_DELAY___SSI_IN_WTIME               = 0x57
    SER_PTIME                                     = 0x58
    CL_OFFSET                                     = 0x59
    PID_VEL___PID_P___CL_VMAX_CALC_P              = 0x5A
    PID_ISUM_RD___PID_I___CL_VMAX_CALC_I          = 0x5B
    PID_D___CL_DELTA_P                            = 0x5C
    PID_E___PID_I_CLIP___PID_D_CLKDIV             = 0x5D
    PID_DV_CLIP                                   = 0x5E
    PID_TOLERANCE___CL_TOLERANCE                  = 0x5F
    FS_VEL___DC_VEL___CL_VMIN_EMF                 = 0x60
    DC_TIME___DC_SG___DC_BLKTIME___CL_VADD_EMF    = 0x61
    DC_LSPTM___ENC_VEL_ZERO                       = 0x62
    ENC_VMEAN_______SER_ENC_VARIATION___CL_CYCLE  = 0x63
    V_ENC                                         = 0x65
    V_ENC_MEAN                                    = 0x66
    VSTALL_LIMIT                                  = 0x67
    ADDR_TO_ENC                                   = 0x68
    DATA_TO_ENC                                   = 0x69
    ADDR_FROM_ENC                                 = 0x6A
    DATA_FROM_ENC                                 = 0x6B
    COVER_LOW                                     = 0x6C
    COVER_HIGH___POLLING_REG                      = 0x6D
    COVER_DRV_LOW                                 = 0x6E
    COVER_DRV_HIGH                                = 0x6F
    MSLUT__                                       = 0x70
    MSLUTSEL                                      = 0x78
    MSCNT                                         = 0x79
    CURRENTA_B                                    = 0x7A
    CURRENTA_B_SPI                                = 0x7B
    SCALE_PARAM___CIRCULAR_DEC                    = 0x7C
    ENC_COMP____                                  = 0x7D
    START_SIN______DAC_OFFSET                     = 0x7E
    VERSION_NO                                    = 0x7F
