Position Chaining and DR flag issues in SBL1360

6 years 8 months ago #29532662 by tarang27

I am trying to use the position chaining commands in the SBL controllers.(As described on pg134 of the latest manual)
The behaviour that I'm seeing is not what the flowchart describes. And hence i feel it may be a bug in the firmware. Here's the issue,

I load the current position target(P) and the next target(PX) initially. Now i keep reading the DR flag till it turns 1. When it turns 1, i take the next trajectory point and load it in PX again. Now according to the flowchart, DR should automatically reset when i load the new PX values, so that i can continue the same flow and wait on DR again to load the next points in my trajectory.

Heres a pseudo code for what I've implemented,
// traj is a array of 10 trajectory points
writeTarget(traj[0]) // Load P
writeNextTarget(traj[1]) // Load PX
while(traj_index<9) {
    while(readDR() != 0) { // Reads DR flag
        writeNextTarget(traj[traj_index]) // Load PX

My code is simply implementing the flowchart and should work properly if the DR flag is reset. But what happens is that the DR is 0 till the 1st point is reached. So my code loads the 3rd target. But after loading the 3rd target, the DR flag never resets and the 4th, 5th, ... , 10th target all get loaded into PX, before the actual 2nd destination is reached. So my motor moves like this - point 1, point 2 and then directly jumps to point 10.

Is this a bug in the firmware?
Ideally, the DR flag should reset to 0 as soon as a new PX value is set, which would match the flowchart and make the DR flag useful. The DR flag is not reset'able from the user space, which is why i think it could be a bug in the firmware.

If this is not a bug and is expected behaviour, is there any setting I am missing? In that case, can you help me with an updated flowchart or an alternate method to run a set of say 10-15 position points in a sequence?

Has anybody else here implemented position chaining with the DR flag running reliably?


Please Log in or Create an account to join the conversation.

6 years 8 months ago #29532664 by niko

this is a resolved issue. Contact This email address is being protected from spambots. You need JavaScript enabled to view it. for providing a beta firmware.

Please Log in or Create an account to join the conversation.

Moderators: tonysantoni
Time to create page: 0.057 seconds