1XD Closed Loop Servo Setup
-
Here's what I would do: (Step 1 of many)
Disconnect the 1XD and connect the motor to the servo controller.
Do not connect anything else to the servo.
Apply power to the servo drive.
What do you get for blinking lights or codes on the servo controller?Send us a photo of the setup.
-
Hey Code,
I have MOVEMENT! But only on the older drivers which are the ACS806
Here's my config
I changed my 1XD to address 20 so configure for your address
; Drives M569 P20.0 S1 R0 T5:5:5:5 ; physical drive 20.0 goes forwards M569 P0.0 S1 ; physical drive 0.0 goes forwards M569 P0.1 S1 ; physical drive 0.1 goes forwards M569 P0.3 S1 ; physical drive 0.3 goes forwards M584 X20.0 Y0.0 Z0.1 E0.3 ; set drive mapping M350 X16 I0 ; configure microstepping without interpolation M350 Y16 Z16 E16 I1 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z400.00 E420.00 ; set steps per mm M566 X6000.00 Y6000.00 Z60.00 E120.00 ; set maximum instantaneous speed changes (mm/min) M203 X120000.00 Y120000.00 Z180.00 E1200.00 ; set maximum speeds (mm/min) M201 X12000.00 Y12000.00 Z20.00 E250.00 ; set accelerations (mm/s^2) M906 Y300 Z800 E800 I30 ; set motor currents (mA) and motor idle factor in per cent M84 S30 ; Set idle timeout ; Axis Limits M208 X0 Y0 Z0 S1 ; set axis minima M208 X450 Y450 Z450 S0 ; set axis maxima ; Endstops M950 J4 C"!^20.io0.in" ; create input pin number 4 on 1XD board at CAN address 20 for servo alarm. The alarm is active low so invert the input and enable the pullup to prevent spurious alarms caused by noise M950 P5 C"20.io0.out" ; create a GPIO pin number 5 on 1XD board at CAN address 20 for alarm reset M574 X1 J4 S2 ; configure sensorless endstop for low end on X M574 Y1 S3 ; configure sensorless endstop for low end on Y M574 Z1 S2 ; configure Z-probe endstop for low end on Z ; Custom settings are not defined M581 P4 S0 T3 R1 ; invoke trigger 3 when an active-to-inactive edge is detected on input 4 and a file is being printed from SD card
This is still testing, so treat as test code. I'm still discovering, I do have to edit the Gear Numerator and Gear Denominator on the driver it self, which means you need your cable, I also had to set a few things in the driver for it to work, not sure what yours will be but here is a pic of what I set to get a few bits of rotation. I need to figure out what the gear denominator and numerator role play in this, also, I need to play with the timing in the config, but hey, it moves with no errors. So I'm chuffed for now.
Wiring for this driver is very different than the eld5 I have, but, I needed the alarm+ and Alarm- connected to IO0.0 out with inverted and pulled up,
Then all the dir+/- Pul+/- and Ena+/- to their corresponding pins, and my settings in the software for the driver are this
I must say that the driver software for the ACS series of drivers is pure K@K. Nothing under the motor parameters saves. And It seems no one in leadshine believes in firmware updates
Will post as I figure out stuff hopefully to help.
-
@shauncro I see my enable motor in the pic is active high, this should be set to low.
But what I find weird, is I only get movement for a 1/4 of the motor, so 50mm to -250mm if I disable motors and turn it to the next pole, I can move with in that pole, but the numbers are different. 50-350 etc currently have my Gear numerator set 1:1 with the denominator. Motor movement is slow though.
-
@alankilian Thanks for double checking. Everything is connected properly.
With everything connected or disconnected I am still receiving the blinking green light with no errors. I'm going to try a simpler motor/driver for now and I may come back to the Leadshine system later.
@shauncro Thanks for the details. I tested your config.g and servo driver settings with my Leadshine setup and am not getting any movement. If I come back to this setup and have success I'll let you know.
-
@code7 said in 1XD Closed Loop Servo Setup:
Thanks for double checking. Everything is connected properly.
With everything connected or disconnected I am still receiving the blinking green light with no errors. I'm going to try a simpler motor/driver for now and I may come back to the Leadshine system laterIf you want to send one motor driver and one motor to me I'll hook it up and getting working for you and send it back. No charge for postage or anything.
I only have a Duet2, but getting it working on that system will certainly get it working on your system also.
I've done this for other people in the past and have had success.
I'm in Cambridge, MA so you can estimate postage.
Let me know if you want to try this to get you a jumpstart on getting this working.
-
That's really kind @alankilian. I'll let you know if I decide to try this again.
-
@code7 OK, I've got your system setup on my bench.
I can connect using the Leadshine software on a Windows-10 computer using a USB-to-RS232 and your cable and I can read values from the stepper driver and I can command motion and the motor turns.
I also hooked up a pulse-generator and I can enable the stepper driver and the motor turns when I generate step signals.
So...... I don't have a Duet-3 so I can't hook up the 1XD board you sent, but I'll hook up my Duet2 and see if I can get the motor to move using GCODE from the Duet2.
-
@code7 I now have the Duet controlling the stepper motor through axis U driver 5 step/direction outputs.
I'll go back through this thread and see what I have hooked up differently than you did.
I really just hooked:
- Hooked PUL+ to Duet2 Step
- Hooked PUL- to Duet2 Ground
- Hooked DIR+ to Duet2 Direction
- Hooked DIR-- to Duet2 Ground
- Hooked ENA to Leadshine ground
- Hooked the COM+ to leadshine 24 Volts DC
I'll read some more and get back to you.
-
@code7 said in 1XD Closed Loop Servo Setup:
With everything connected or disconnected I am still receiving the blinking green light with no errors.
...
Leadshine contacted me and recommended the Differential Connection option wired as follows:The blinking green light means the Leadshine motor driver is not enabled.
The green light needs to be solid on when the driver is enabled.You absolutely must NOT connect EN+ to COM-IN since COM-IN is between 24 and 70 Volts! You might have dodged a smoke-event because you may not have had a common ground between the 1XD and the Leadshine power supply.
I'll look in to how to hook up the enable properly and write again.
-
I know you may have different hardware, but I have 2 Clearpath SDSK servo/steppers running from Duet step and direction outputs and they are providing awesome acceleration, no vibration and near zero noise at any speed.
They are a bit expensive and the specs are quite overkill, but they are highly recommended.
-
@alankilian Thanks for the update. Is there any other straightforward way to test the LeadShine encoder on the Duet2 or would you need a Duet3?
-
@coseng said in 1XD Closed Loop Servo Setup:
They
Thanks - I'll keep this in mind for future projects.
-
@code7 Everything works perfectly using my Duet2.
I think you just had the enable signal hooked up incorrectly.
- Hook COM+ from the Leadshine to +5 Volts on the 1XD
- Hook DI3/ENA from the Leadshine to the enable output on the 1XD
After that, you should be ready to roll.
I'll ship everything back to you soon.
-
@alankilian I sure appreciate your help on this. Thanks
-
-