Welcome! Log In Create A New Profile

Advanced

'Sync' connection on the stepper controllers?

Posted by Anonymous User 
Anonymous User
'Sync' connection on the stepper controllers?
June 17, 2007 01:36AM
On the stepper controller boards, there is a 2-pin connection with pins 1 and 2 marked as such, and the connector is marked as 'sync', but I can't find any info on what should be connected to that connector, or how it should be connected, etc. All I have found is a reference to it being used for syncing the steppers. What is the proper way to connect to this conector?
Re: 'Sync' connection on the stepper controllers?
June 17, 2007 04:55AM
They should be linked. I.e, run two wires between the three boards linking all the pin 1s together and all the pin 2s together. The signal is used to synchronise the stepping of the steppers so that you can move diagonally.


[www.hydraraptor.blogspot.com]
Anonymous User
Re: 'Sync' connection on the stepper controllers?
June 17, 2007 05:40AM
Thanks Nophead! Joost and I were going nuts trying to figure out exactly how they were supposed to be connected smiling smiley
Anonymous User
Re: 'Sync' connection on the stepper controllers?
June 30, 2007 02:35AM
I need some help figuring out my next problem... Lamarck is extruding fine in straight lines (only X movement or only Y movement), but it slows down to about 50%-75% of the straightline speed when doing diagonals. Unfortunately, the maximum speed that the steppers can move is also the optimum extrusion speed (approx. 4mm/sec), so I can't slow it down and fiddle with the angle speed to tweak it. I currently have the AngleSpeedFactor in the preferences set to 0, since as I increase it the motors slow down, but it is still moving quite a bit slower in the diagonal than it is in the non-diagonal movement.

Would problems with the sync connection cause this, or is something else going on?

Any help would be appreciated.
Re: 'Sync' connection on the stepper controllers?
June 30, 2007 12:31PM
Do you mean the straight line speed drops as the motors should slow down when doing a diagonal to keep that constant?


[www.hydraraptor.blogspot.com]
Anonymous User
Re: 'Sync' connection on the stepper controllers?
June 30, 2007 05:32PM
When extruding along a straight line on the X or Y axis, the head moves at full speed across the table, but when it runs at an angle to one of the axes (X and Y motors working together), the head moves significantly slower across the table. With the AngleSpeedFactor preference set to 0 and extruding at a 45deg angle to the X axis, the extruder head moves at about 50% of the speed across the table as it does when extruding a line at 0deg or 90deg to the X axis. If I increase the AngleSpeedFactor, the speed at 45deg becomes much slower and the speed at 0deg or 90deg is unchanged. If I set the AngleSpeedFactor to 1, it doesnot move at all at 45deg.

Does this make it more clear?
Re: 'Sync' connection on the stepper controllers?
June 30, 2007 06:11PM
Eric,
Yes it makes the problem clear, sorry I don't know what the solution is as I am not familiar with the official firmware / software yet. Odd that there should be an AngleSpeedFactor property though. I just use Pythagoras' theorem to correct the diagonal speed on my machine.

Chris


[www.hydraraptor.blogspot.com]
Anonymous User
Re: 'Sync' connection on the stepper controllers?
July 21, 2007 06:26AM
I've heard the the X card should have pin 1 going to say Y card pin 1 and the X card pin 2 should go to the Z card. In this thread, it say they should be connected as pins, (all pin1 shorted and all pin 2 shorted). They are a bidirectional I/O point, so they both can be a input or an output. There really needs to be documentation for the preference setup page. At a 45 degree angle you would think the X and Y would slow down to 2.82 mm/sec to give a resultant speed of 4 mm/sec
Re: 'Sync' connection on the stepper controllers?
July 21, 2007 01:29PM
I only have one StepperController so far, so this hasn't yet become something I can test! However, reading the firmware source code should quickly tell us how these lines are used.

The main PIC processsing loop (on each of the three axes) is in firmware/devices/stepmotor/stepmotor1.c and looks like this (well, the forum software will mangle it a bit, sadly):

if (SYNCA) // Only enable if SYNCA is by default high
syncEnabled = 1;

for( ; ; ) {
if (packetReady()) {
processCommand();
releaseLock();
}
if (syncEnabled && !SYNCA) {
// Sync line has dropped
// Spin until it goes high again (we trigger on the rising edge)
while(!SYNCA)
;
syncStrobe();
}
clearwdt();
}

SYNCB is not referenced at all in the current firmware code that I can see. The syncStrobe() code pulls SYNCA low, waits a bit, and then sets it tristate again.

So, my theory based on this code is that you need to connect all the Sync Pin 1's together, as stated in this thread. Connecting all the Sync Pin 2's together as well seems to be "futureproofing" for firmware features that are not yet present.

In case it helps, there are apparently 4 sync modes:

enum sync_modes {
sync_none, // no sync (default)
sync_seek, // synchronised seeking
sync_inc, // inc motor on each pulse
sync_dec // dec motor on each pulse
};

and the default is mode sync_none, i.e. don't use sync. This mode is changed using command 8, CMD_SYNC, for those examining CommDebug output or experimenting with poke. So something like

echo 8 1 | poke -v -w -d 2 -t /dev/ttyS0

should set the device at address 2 (X axis) to "sync_seek" mode.

Jonathan
Sorry, only registered users may post in this forum.

Click here to login