Hardware manual

46
pxmc_dbg_gnr
This function is seen from outside of the PXMC library and in fact
it prepares all necessary elements for storing the speed
generator profile.
pxmc_dbgset
This function sets debugging options for a given motor.
Nowadays it is possible only to switch on or off debugging. It is
also possible to give as a parameter a pointer to a function for
debugging. This function sets PXMS_DBG_b flag automatically so
we don't need to worry about it.
*- function is not accessible from outside of the library.
5.3.7. PXMC_GEN_INFO.H
This is just header file, which defines several constants and fields for others functions.
These functions are later responsible for initialization generator(s).
5.3.8. PXMC_GEN_SPDTRP.C
This file contains mainly implementation of all generators which are available for a motor
control. Now, because a generator works as finite state machine, so it is possible to
represent it by a pointer to a functions which describe it. In other words we can imagine it
as a trapezoid, where at the beginning our pointer shows to a function which increases
speed. When the maximal speed will be reached then we automatically change the
pointer to function which will keep the speed as a constant. Then before we reach desired
position we change the pointer to another function which will slow down and finally will
stop our motor.
Name of pole
Short description
pxmc_add_cspdfg
Adds fine-grained speed to requested position.
pxmc_add_vspd
Adds variable speed to requested position.
pxmc_set_spd
Sets new value of requested speed.
pxmc_set_spdfg
Sets new value of fine-grained speed.
pxmc_spdfg_gnr
Constant speed fine-grained generator.
pxmc_spd_gacc
Smooth transition to new requested speed.
pxmc_nop_gd
No-operation generator state.
pxmc_cont_gi
Initializes continuation generator. This type of generator is
temporarily used when new generator parameters are
computed.
pxmc_trp_gi
Initializes trapezoid generator. This complex generator realizes
motion to requested end position with trapezoid speed profile.
pxmc_trp_spdfg_gi
Initializes fine-grained trapezoid generator.