"Always configure FBA for analog input" flag

Hi,
I’m using Jrk G2 18v19.
I would like to received the position feedback (FBA) while working with feedback mode: “None”.
I tried using the “Always configure FBA for analog input” flag. but it didn’t help.

How can I read the position without using position control?

Thanks a lot
Yakir

Hello, Yakir.

When the "Always configure FBA for analog input” option is enabled, the Jrk G2 should use the FBA pin as an analog input, so you should be able to get that reading with the “Analog reading FBA” variable.

Can you post more details about what you are trying and what results you are getting? Also, could you run “jrk2cmd --status --full” from a Command Prompt and post the output you get?

Brandon

Hi Brandon,
Thanks for the replay,

I’m trying to get the motor “piston” position while using speed control (Feedback Mode=None).
I’m using Pololu Jrk2 configuration Utility and in the Feedback parameter it says N/A.

When i’m writing on Command Prompt “jrk2cmd --status --full” I received the following:

Name:                         Jrk G2 18v19
Serial number:                00318210
Firmware version:             1.01
Command port:                 COM14
TTL port:                     COM8
Last reset:                   Power-on reset
Up time:                      0:03:16

Input:                        2048
Target:                       2048
Feedback:                     0
Scaled feedback:              0
Error:                        -2048
Integral:                     0
Duty cycle target:            0
Duty cycle:                   0
Last duty cycle:              0
Current:                      0 mA
Raw current:                  43 mV
Hard current limit:           18.94 A
Encoded hard current limit:   59
Current chopping:
  Consecutive count:          0
  Occurrence count:           0
RC pulse width:               0
FBT reading:                  0
VIN voltage:                  11.910 V
PID period exceeded:          No
PID period count:             19664
Force mode:                   None

Errors currently stopping the motor:
  - Awaiting command
Errors that occurred since last check: None

SCL pin:
  Digital reading:            1
SDA pin:
  Analog reading:             292
  Digital reading:            0
TX pin:
  Digital reading:            1
RX pin:
  Digital reading:            1
RC pin:
  Digital reading:            0
AUX pin:
  Digital reading:            1
FBA pin:
  Analog reading:             63424
  Digital reading:            0
FBT pin:
  Digital reading:            1

Overall status: 'Motor stopped: waiting for a command.'

Now I do see that FBA pin: Analog reading: 63424
which is amazing, but not see it in the Grk2 UI.

By the way, I see that the changing profile is not changing linearly,
In the close area the position changes in high rate but on the area of the full open it changes very slowly,
Is it by design? it can affect the PID performance to be different in opposite directions.

Thanks a lot!

With the feedback mode set to “none” it is normal for the Jrk G2 Configuration Utility to display “N/A”, even with “Always configure FBA for analog input” enabled. The “Feedback” displayed in the “Status” tab of the Jrk G2 Configuration Utility is only associated with the analog input on FBA when the feedback mode is set to “Analog”. Enabling “Always configure FBA for analog input” tells the Jrk to still allocate time to reading the analog voltage and update the “Analog reading FBA” variable, but it does not use it for feedback.

Can you be more specific when you say the “changing profile is not changing linearly”? What are you changing and what response are you getting? Are you referring to the reading on the FBA pin or the output to the motor?

Brandon

Brandon thanks for the reply,

you can see in the following graph that when the velocity is constant (max duty cycle) the feedback is not changing linearly. In the beginning (=close area) the change rate is very high, while in the middle the rate get slower.
It effect the PID performers to be different in each direction.


Please advise,
Best regards,
Yakir

Are you using a potentiometer for your feedback? If so, you might check to make sure it is wired correctly (incorrectly wiring a potentiometer could cause nonlinear behavior like that).

Brandon

Thanks Brandon,
indeed there was wiring issue.

Thanks a lot!!

1 Like