PCW wrote:If the BIAS is added, it should be 234 (so a -234 mm/sec velocity request from the PID output is translated to a 0 PWM value)
In addition the PWM scale should be set to 468 and the PID components MAX_OUTPUT should be set to 234 (that way the PIDs requested -234 velocity generates 0 PWM and +234 velocity generates 468 = full scale PWM)
I'm not sure how they are applied but there are already provisions output offsetting (OUTPUT_OFFSET)
Note that if it works it would have the opposite sign of your (added) BIAS (-234) since it its subtracted
Need help configuring the axis.
This is how drive expect PWM signals:
0% duty = -100% speed or torque
25% duty = -50% speed or torque
50% duty = 0 speed or torque
75% duty = +50% speed or torque
100% duty = +100% speed or torque
I can run y.axis in pncconf, but only in one direction. Assume DAC output scale = 10, then in Open loop test, Fast DAC speed of 5.1 move axis slow to one direction (both + and - button) and 4.9 to opposite direction. Increasing/decreasing this values increase speed.
In EMC, depend of configuration, I always get following error. This is my configuration:
#*******************
# AXIS Y
#*******************
setp pid.y.Pgain [AXIS_1]P
setp pid.y.Igain [AXIS_1]I
setp pid.y.Dgain [AXIS_1]D
setp pid.y.bias [AXIS_1]BIAS
setp pid.y.FF0 [AXIS_1]FF0
setp pid.y.FF1 [AXIS_1]FF1
setp pid.y.FF2 [AXIS_1]FF2
setp pid.y.deadband [AXIS_1]DEADBAND
setp pid.y.maxoutput [AXIS_1]MAX_OUTPUT
net y-index-enable <=> pid.y.index-enable
net y-enable => pid.y.enable
net y-output => pid.y.output
net y-pos-cmd => pid.y.command
net y-pos-fb => pid.y.feedback
# ---PWM Generator signals/setup---
setp hm2_5i20.0.pwmgen.02.output-type 1
I think this should be 4, but changing this does not chane nothing
setp hm2_5i20.0.pwmgen.02.scale [AXIS_1]OUTPUT_SCALE
net y-output => hm2_5i20.0.pwmgen.02.value
net y-pos-cmd axis.1.motor-pos-cmd
net y-enable axis.1.amp-enable-out => hm2_5i20.0.pwmgen.02.enable
#********************
# Axis Y
#********************
[AXIS_1]
TYPE = LINEAR
HOME = 0.0
FERROR = 0.005
MIN_FERROR = 0.0005
MAX_VELOCITY = 46.6666666667
MAX_ACCELERATION = 44.0
P = 500.0
I = 30.0
D = 0.0
FF0 = 0.0
FF1 = 0.0
FF2 = 0.0
BIAS = 234.0
DEADBAND = 0.0
ENCODER_SCALE = 1000.0
OUTPUT_SCALE = 468.0
OUTPUT_OFFSET = -234.0
MAX_OUTPUT = 234.0
MIN_LIMIT = -100.01
MAX_LIMIT = 800.0
HOME_OFFSET = 0.0