Closed suguruhamada1003910 closed 1 year ago
Is the problem occuring also with the joystick ? It looks like a latency problem
Did you change the configuration of the gearbox (4 instead of 14) ratio in configuration.json
file:
[
{
"name": "SWD_CORE",
"nbStepRevolutionElec": 6,
"nbPolePair": 5,
"reduction": 14.0,
"diameter": 125.0
}
]
Is the problem occuring also with the joystick ? It looks like a latency problem
Yes. This problem is occurring with joystick.
Did you change the configuration of the gearbox (4 instead of 14) ratio in configuration.json file: Yes. I already changed the value of reduction for SWD125. I'm using SWD125.
I cannot reproduce this problem with SWD Core.
Can you try using a higher velocity demand with for example cmd_vel=0.2
instead of 0.1.
After some investigations, we offer you to set-up the integrative value of SWD's PID controller. This should improve its behavior as it has a lower ratio (/4).
Please try to change the value of the integrative parameter to 2
in the SWD:
motctrl_speed_pid_i ==> U32 0x2156:00
You can do it in the commissioning for instance.
Example:
can_open_client.setValueUInt8(0x2156_00_20, 2)
After some investigations, we offer you to set-up the integrative value of SWD's PID controller. This should improve its behavior as it has a lower ratio (/4).
Please try to change the value of the integrative parameter to
2
in the SWD:motctrl_speed_pid_i ==> U32 0x2156:00
You can do it in the commissioning for instance. Example:
can_open_client.setValueUInt8(0x2156_00_20, 2)
Thank you for reply.
I tried can_open_client.setValueUInt8(0x2156_00_20, 2)
but it fails. You said motctrl_speed_pid_i ==> U32 0x2156:00
. It is right what I use UInt8 function?
BTW, what is the default value of motctrl_speed_pid_i
?
No indeed, sorry for the mistake, you should use the method: setValueUInt32()
To get the value that was set before, you can do a get and print the value, e.g. getValueUInt32()
I could change the value! I try to adjust program again.
I come back to you, to see how is the robot going with the new parameters ?
I come back to you, to see how is the robot going with the new parameters ?
I changed the value of P motctrl_speed_pid_p
and I motctrl_speed_pid_i
.
As a result, I think the behavior of rotation is good!!
Nice !!! What did you set as P parameter ?
Nice !!! What did you set as P parameter ?
I set 300.
Hi support.
I'm developing navigation program with SWDs. Then, SWD may swing greatly from side to side. I'm investigating the cause. https://1drv.ms/f/s!AqHxzXmtIbtrqh0vZ2LrlN8o_MeD?e=YETsib
I noticed that when the SWD rotates clockwise after turning right, or rotates clockwise after turning left, it moves like ignoring the input to cmd_vel. https://1drv.ms/f/s!AqHxzXmtIbtrqh-q1WP-jk5iQ-gY?e=FOleuA
I suspect this is the cause of the problem. The navigation program is looking at the gyro sensor, and when the program try to move to the right or left, the SWD ignores the value of cmd_vel for a while and does not rotate, so the program input to cmd_vel to try to rotate further, and I think it is going too far.
Do you have any solution or do you know the cause of the behavior of SWD?
Note: When I try to move SWD right, stop and right, SWD is running according to cmd_vel immidiately. https://1drv.ms/f/s!AqHxzXmtIbtrqh4-d7fgdl9IbecD?e=E5AJ5J