Library to handle the X_NUCLEO_IHM02A1 Motor Control Expansion Board based on the L6470 component.
Dependencies:
X_NUCLEO_COMMON
ST_INTERFACES
Dependents:
HelloWorld_IHM02A1
ConcorsoFinal
HelloWorld_IHM02A1_mbedOS
HelloWorld_IHM02A1-Serialinterpreter
... more
Fork of
X_NUCLEO_IHM02A1
by ST Expansion SW Team
« Back to documentation index
L6470_AppCMDs
Modules
L6470_AppCMDs_ToBePrepared
Functions
void L6470_SetParam (eL6470_RegId_t L6470_RegId, uint32_t Value)
SetParam command sets the register value equal to a new value.
uint32_t L6470_GetParam (eL6470_RegId_t L6470_RegId)
GetParam command reads the register value.
void L6470_Run (eL6470_DirId_t L6470_DirId, uint32_t Speed)
Run command produces a motion at fixed speed.
void L6470_StepClock (eL6470_DirId_t L6470_DirId)
StepClock command switches the device in Step-clock mode.
void L6470_Move (eL6470_DirId_t L6470_DirId, uint32_t N_Step)
Move command produces a motion of N_STEP microsteps.
void L6470_GoTo (uint32_t AbsPos)
GoTo command produces a motion to ABS_POS absolute position through the shortest path.
void L6470_GoToDir (eL6470_DirId_t L6470_DirId, uint32_t AbsPos)
GoTo_DIR command produces a motion to ABS_POS absolute position imposing a direction.
void L6470_GoUntil (eL6470_ActId_t L6470_ActId, eL6470_DirId_t L6470_DirId, uint32_t Speed)
GoUntil command produces a motion at fixed speed imposing a direction until an external switch turn-on event occurs.
void L6470_ReleaseSW (eL6470_ActId_t L6470_ActId, eL6470_DirId_t L6470_DirId)
ReleaseSW command produces a motion at minimum speed imposing a direction until SW is released.
void L6470_GoHome (void)
GoHome command produces a motion to the HOME position (zero position) via the shortest path.
void L6470_GoMark (void)
GoMark command produces a motion to the MARK position performing the minimum path.
void L6470_ResetPos (void)
ResetPos command resets the ABS_POS register to zero.
void L6470_ResetDevice (void)
ResetDevice command resets the device to power-up conditions.
void L6470_SoftStop (void)
SoftStop command causes an immediate deceleration to zero speed and a consequent motor stop; the deceleration value used is the one stored in the DEC register.
void L6470_HardStop (void)
HardStop command causes an immediate motor stop with infinite deceleration.
void L6470_SoftHiZ (void)
SoftHiZ command disables the power bridges (high impedance state) after a deceleration to zero; the deceleration value used is the one stored in the DEC register.
void L6470_HardHiZ (void)
HardHiZ command immediately disables the power bridges (high impedance state).
uint16_t L6470_GetStatus (void)
GetStatus command returns the STATUS register value.
Function Documentation
uint32_t L6470_GetParam
(
eL6470_RegId_t
L6470_RegId )
[protected, inherited]
GetParam command reads the register value.
Parameters:
L6470_RegId The identifier of the L6470 register to be addressed.
Return values:
ReceivedValue The register value.
Definition at line 772 of file L6470.cpp .
uint16_t L6470_GetStatus
(
void
)
[protected, inherited]
GetStatus command returns the STATUS register value.
Return values:
ReceivedValue The register value.
Definition at line 986 of file L6470.cpp .
void L6470_GoHome
(
void
)
[protected, inherited]
GoHome command produces a motion to the HOME position (zero position) via the shortest path.
Definition at line 891 of file L6470.cpp .
void L6470_GoMark
(
void
)
[protected, inherited]
GoMark command produces a motion to the MARK position performing the minimum path.
Definition at line 903 of file L6470.cpp .
void L6470_GoTo
(
uint32_t
AbsPos )
[protected, inherited]
GoTo command produces a motion to ABS_POS absolute position through the shortest path.
Parameters:
AbsPos The target absolute position.
Definition at line 831 of file L6470.cpp .
void L6470_GoToDir
(
eL6470_DirId_t
L6470_DirId ,
uint32_t
AbsPos
)
[protected, inherited]
GoTo_DIR command produces a motion to ABS_POS absolute position imposing a direction.
Parameters:
L6470_DirId The identifier of the L6470 motion direction.
AbsPos The target absolute position.
Definition at line 847 of file L6470.cpp .
void L6470_GoUntil
(
eL6470_ActId_t
L6470_ActId ,
eL6470_DirId_t
L6470_DirId ,
uint32_t
Speed
)
[protected, inherited]
GoUntil command produces a motion at fixed speed imposing a direction until an external switch turn-on event occurs.
Parameters:
L6470_ActId The identifier of the L6470 action about the absolute position.
L6470_DirId The identifier of the L6470 motion direction.
Speed The speed value as (([step/s] * 250e-9) / 2^-28)
Definition at line 865 of file L6470.cpp .
void L6470_HardHiZ
(
void
)
[protected, inherited]
HardHiZ command immediately disables the power bridges (high impedance state).
Definition at line 973 of file L6470.cpp .
void L6470_HardStop
(
void
)
[protected, inherited]
HardStop command causes an immediate motor stop with infinite deceleration.
Definition at line 949 of file L6470.cpp .
void L6470_Move
(
eL6470_DirId_t
L6470_DirId ,
uint32_t
N_Step
)
[protected, inherited]
Move command produces a motion of N_STEP microsteps.
Parameters:
L6470_DirId The identifier of the L6470 motion direction.
N_Step The number of microsteps.
Definition at line 819 of file L6470.cpp .
void L6470_ReleaseSW
(
eL6470_ActId_t
L6470_ActId ,
eL6470_DirId_t
L6470_DirId
)
[protected, inherited]
ReleaseSW command produces a motion at minimum speed imposing a direction until SW is released.
Parameters:
L6470_ActId The identifier of the L6470 action about the absolute position.
L6470_DirId The identifier of the L6470 motion direction.
Definition at line 879 of file L6470.cpp .
void L6470_ResetDevice
(
void
)
[protected, inherited]
ResetDevice command resets the device to power-up conditions.
Definition at line 925 of file L6470.cpp .
void L6470_ResetPos
(
void
)
[protected, inherited]
ResetPos command resets the ABS_POS register to zero.
Definition at line 914 of file L6470.cpp .
void L6470_Run
(
eL6470_DirId_t
L6470_DirId ,
uint32_t
Speed
)
[protected, inherited]
Run command produces a motion at fixed speed.
Parameters:
L6470_DirId The identifier of the L6470 motion direction.
Speed The speed value as (([step/s] * 250e-9) / 2^-28)
Definition at line 794 of file L6470.cpp .
void L6470_SetParam
(
eL6470_RegId_t
L6470_RegId ,
uint32_t
Value
)
[protected, inherited]
SetParam command sets the register value equal to a new value.
Parameters:
L6470_RegId The identifier of the L6470 register to be addressed.
Value The new value.
Definition at line 758 of file L6470.cpp .
void L6470_SoftHiZ
(
void
)
[protected, inherited]
SoftHiZ command disables the power bridges (high impedance state) after a deceleration to zero; the deceleration value used is the one stored in the DEC register.
Definition at line 962 of file L6470.cpp .
void L6470_SoftStop
(
void
)
[protected, inherited]
SoftStop command causes an immediate deceleration to zero speed and a consequent motor stop; the deceleration value used is the one stored in the DEC register.
Definition at line 938 of file L6470.cpp .
void L6470_StepClock
(
eL6470_DirId_t
L6470_DirId )
[protected, inherited]
StepClock command switches the device in Step-clock mode.
Parameters:
L6470_DirId The identifier of the L6470 motion direction.
Definition at line 806 of file L6470.cpp .