PDA

View Full Version : Physicist trying to do engineering. Not going well. After advice with 4 axis gantry.



dr_rob
05-12-2016, 06:48 PM
Hello everyone,

I have been reading posts on this forum for the last few months, but have gotten to the point where I need some help.

I have put together a 4 axis gantry (picture attached) which I would like to control from my PC. I have 4 motors (NEMA 34, NEMA 23XL, NEMA 23 and a NEMA 17) which come with inbuilt encoders, but for now I will not be using the encoders. But may wish to in the future. The gantry is going to be used to drive a microphone around near a speaker.

My current problem is that I am a little stuck on how to actually control the system. I have 2 power supplies (to run 2 motors each) and 4 microstep drivers (3 MSD752 (https://www.motioncontrolproducts.co.uk/products/10/30/msd752-microstepping-drive/), and 1 MSD880 (https://www.motioncontrolproducts.co.uk/products/10/36/msd880-high-performance-microstepping-drive/)from Motion Control). I think I have powered each of the micro-controllers up, and the motors. But where I am getting rather lost is what data to send to the drivers.

I have a parallel port which is connected to a RoutOut CNC break out board (http://www.routoutcnc.com/lptcon.html).

From many of the videos and blogs I have seen people have been using MACH software to send data to the BoB (their BoB's look to be a lot fancier than mine however!) and then onto the drivers. My issue is that I can't install MACH3 software (which most people look to use, I can install MACH 4 however) and am not too sure how to send data to the drivers without it.

I was wondering if anyone out there has any simple advice on how I could control the motors using the BoB I have.

Sorry for this being such a stupid questions but I've gotten myself into that stage where I am reading about stuff which might well be way too detailed for what I am trying to do!

Any advice would be very much appreciated.

Rob

m_c
06-12-2016, 12:08 AM
What version of windows are you trying to install Mach on?
To use the parallel port driver, it must be a 32bit version up to Windows 7. Any 64bit version, or Windows 8 onwards, the parallel port driver will not work.

Mach3/4 itself should install and run fine on any version of windows, it's just the parallel port driver that has the version restrictions.

JAZZCNC
06-12-2016, 12:19 AM
Hi Rob,

First don't get too hung up on the Bob cheap or Expensive they all do the same Job which is providing an easy way to connect to the Pulse device. They don't actually do much more than pass signals thru and thou not recommended you don't actually need one at all.
You could connect directly to the parallel port cable but it doesn't provide any isolation to the PC so not recommended as could damage the PC if anything goes wrong.

The Pulse device in your case would be the PC parallel port which needs Motion control software like Mach3/4 which provide Parallel port Driver which interfaces with the PC.

So put simply you need Motion control software like Mach3/4 or LinxCNC.
In your Case I suggest using LinxCNC as it's free and can be run directly from Boot CD ( I think.? I'm not into linx others will correct me if wrong).

To run Machine the process goes.

Control software >>>Pulse Device(parallelport)>>>BOB (optional) >>>Motor Drive>>>Motor.

Why can't you install Mach3.? is it because using 64Bit PC.?

dr_rob
06-12-2016, 12:46 AM
What version of windows are you trying to install Mach on?
To use the parallel port driver, it must be a 32bit version up to Windows 7. Any 64bit version, or Windows 8 onwards, the parallel port driver will not work.

Mach3/4 itself should install and run fine on any version of windows, it's just the parallel port driver that has the version restrictions.

Hi m_c,

Thanks for the info. I appreciate that a lot. Having read through some of the forums it looks like the issue might be that my work runs all sorts of virus software in the background which can interfere with the Mach3 installation. I am going to try and get that resolved by hopefully persuading them to let me wipe the HD and have a machine totally dedicated to the scanning unit.

Thanks again!

dr_rob
06-12-2016, 12:54 AM
Hi Jazz,

Thank you for the detailed reply. I really appreciate it.

I did wonder why the BoB was so bare. When I turned it over to look at the pins a lot of them were not connected to anything. My only concern was that the BoB I have does not have any protection (from what I can see) for the PC. I think all it does it makes connection easier. And some of them look to need a 5V power supply which threw me off!

My problem with the software is probably due to my work running all sorts of virus/network software which causes conflicts often. But hopefully I will have a dedicated Win 7 machine running all the software for the gantry. But I will look into Linux as it might be easier to integrate with some of our other software.

My other question was with the stepper driver device. I have powered it from the main power supply and then connected the motor. Remaining on the controller was Pul +, Pul -, Dir +, Dir -, and En +, En -. Do you happen to have a good source of info I could look at regarding how to wire this end of the system up? This evening I have ended up reading all about the input signals for a stepper motor but I fear I might be going into more detail that I need. And then you end up feeling lost!

Again, thank you for the help, it's really nice of you.

Rob

Clive S
06-12-2016, 09:04 AM
I suggest using LinxCNC as it's free and can be run directly from Boot CD ( I think.? I'm not into linx others will correct me if wrong).I don 't think you can run a machine directly off the live linuxcnc disk. But you can use it to look at the interface and get the feel for it.
http://www.linuxcnc.org/linuxcnc-2.7-wheezy.iso Mach3 might be better to play with and the demo version will let you use it for a max of 500 lines of code.

komatias
06-12-2016, 02:42 PM
Hi Dr Rob,

Dr George here :D

Which university you working in?

JAZZCNC
06-12-2016, 09:18 PM
My other question was with the stepper driver device. I have powered it from the main power supply and then connected the motor. Remaining on the controller was Pul +, Pul -, Dir +, Dir -, and En +, En -. Do you happen to have a good source of info I could look at regarding how to wire this end of the system up?

Can't give source where to look but I can explain it easy enough.

The Motion control device provides OUTPUTS which it sends out signals and pulses required to tell the drives which direction and how far to move. These OUTPUTS basicly fall into two types MOTOR OUTPUTS for each Axis and General OUTPUTS which provide 5Vdc Signal.
Each OUTPUT as Positive Negative connection.

So DIR connection is MOTOR OUTPUT and controls the Direction to travel. This is done by sending 0V or 5v depending on direction.
PUL Connection is the PULSE MOTOR OUTPUT which gives stream of pulses relating to how far to move.

The En is Signal to the drive to ENABLE/DISABLE. Often this isn't used and left unconnected.
If used this would be connected to General OUTPUT or could be controlled by external device like relay by sending 5Vdc.

So in your case there will be Pins on the BOB which are MOTOR OUTPUTS and Some which are General OUTPUTS. If using the parallel port they tend to stick to standard arrangement. ie: Pin2 =XDir Pin3=Xpul etc.

There will also be pins for INPUTS.

Hope this helps.

Neale
06-12-2016, 11:09 PM
19843

If it helps, here's a rough wiring diagram that would suit a lot of break-out boards and stepper drivers. As JazzCNC says, the Enable signal is sometimes considered optional; if you leave it disconnected then the stepper driver defaults to "Enabled" anyway. The "Pulse" connection is sometimes marked "Step"; again, previous post explains why.

I've just had a quick look at the "manual" for your BOB; not very helpful, is it? However, you should be able to identify step and dir signals for each axis (=stepper driver). Doesn't appear to be an Enable output anyway but I might have misread it. All ground connections (- connections on stepper driver) go to a single common ground terminal on the BOB. The manual then tells you what pin numbers in Mach3 you should configure for each signal (Mach3>Config>Ports and Pins). However, there is still this question about whether you are running on a 32-bit Windows; the parallel port driver will not work on any 64-bit Windows version.

dr_rob
07-12-2016, 03:41 PM
Hi Dr Rob,

Dr George here :D

Which university you working in?

Hi Dr George,

I work at the University of Bristol. Do you happen to be in my part of the world?!

Rob

dr_rob
07-12-2016, 03:59 PM
19843

If it helps, here's a rough wiring diagram that would suit a lot of break-out boards and stepper drivers. As JazzCNC says, the Enable signal is sometimes considered optional; if you leave it disconnected then the stepper driver defaults to "Enabled" anyway. The "Pulse" connection is sometimes marked "Step"; again, previous post explains why.

I've just had a quick look at the "manual" for your BOB; not very helpful, is it? However, you should be able to identify step and dir signals for each axis (=stepper driver). Doesn't appear to be an Enable output anyway but I might have misread it. All ground connections (- connections on stepper driver) go to a single common ground terminal on the BOB. The manual then tells you what pin numbers in Mach3 you should configure for each signal (Mach3>Config>Ports and Pins). However, there is still this question about whether you are running on a 32-bit Windows; the parallel port driver will not work on any 64-bit Windows version.

Hi Neale,

Thank for the diagram. Very, very handy.

Yep, the instructions for the BoB are terrible! But I'm pretty sure from your diagram and Jazz's description of the system I will be able to figure it out without too much trouble.

As for the version of Windows, I am going to source a 32bit verison of Windows. I was going to go with Windows 7, unless you think a later/earlier version is better suited to the job?

Thanks again for the help. I think the BoB was causing me the most confusion but I think I got it now!

Rob

Neale
07-12-2016, 04:30 PM
Win7 is the latest that came with a 32-bit version, I believe, so that's the one to go for. Probably the best and most stable version of recent years as well.

- Dr Brian (well, everyone else is boasting about it...)

komatias
07-12-2016, 04:46 PM
Hi Dr George,

I work at the University of Bristol. Do you happen to be in my part of the world?!

Rob

Well what a coincidence...I am a Bristol Uni Alumnus. Did my doctorate with Drinkwater and Wilcox on the Ultrasonics team.

Just supplied special bit of 3D printing kit to a chappy in the aerospace department too :chuncky:

If you are one of those that works late, I could pop over and have a chat tonight even. Drop me a private message and we can go from there.

komatias
07-12-2016, 04:48 PM
Win7 is the latest that came with a 32-bit version, I believe, so that's the one to go for. Probably the best and most stable version of recent years as well.

- Dr Brian (well, everyone else is boasting about it...)

Damn straight! Who says PhD' are useless :D

dr_rob
07-12-2016, 05:19 PM
Can't give source where to look but I can explain it easy enough.

The Motion control device provides OUTPUTS which it sends out signals and pulses required to tell the drives which direction and how far to move. These OUTPUTS basicly fall into two types MOTOR OUTPUTS for each Axis and General OUTPUTS which provide 5Vdc Signal.
Each OUTPUT as Positive Negative connection.

So DIR connection is MOTOR OUTPUT and controls the Direction to travel. This is done by sending 0V or 5v depending on direction.
PUL Connection is the PULSE MOTOR OUTPUT which gives stream of pulses relating to how far to move.

The En is Signal to the drive to ENABLE/DISABLE. Often this isn't used and left unconnected.
If used this would be connected to General OUTPUT or could be controlled by external device like relay by sending 5Vdc.

So in your case there will be Pins on the BOB which are MOTOR OUTPUTS and Some which are General OUTPUTS. If using the parallel port they tend to stick to standard arrangement. ie: Pin2 =XDir Pin3=Xpul etc.

There will also be pins for INPUTS.

Hope this helps.

Thank you Jazz,

I think with your explanation (much clearer than a lot of info I have found online) and the one from Neale has clarified things immensely to be honest.

I was having a little play with the BoB today and with a meter I could see the voltages coming out of some of the pins (not quite 5V but 3.6V, which may either be normal or it's because I have had to use a PCI expansion slot in the PC as it didn't come with a parallel port). My next step is to get a dedicated PC assigned for the job, install Win7(32 bit) and then install Mach3. Then I think I will be on the home run!

Thanks again for saving me a lot of hair-pulling.

Rob

JAZZCNC
07-12-2016, 08:24 PM
I was having a little play with the BoB today and with a meter I could see the voltages coming out of some of the pins (not quite 5V but 3.6V, which may either be normal or it's because I have had to use a PCI expansion slot in the PC as it didn't come with a parallel port).

Possibly because of the PCI. It's very common for modern PC's to only supply 3.6V. However this is BAD NEWS for CNC and you need close to 5v to work correctly.
With 3.6V you will have trouble because there isn't difference between HIGH and LOW.?
When I said 0v and 5V I actually should have also said LOW & HIGH because that what really matters to CNC. LOW is anything from 0v to 2.5v HIGH is anything thing from 3.1 to 5V.
So with only 3.6v there not enough difference between Hi - Low signals and just slight difference or drop in voltage can cause missed steps and all sorts of strange happenings.

Only letters could put after my name are "NFC" or "CFS" but Hope that helps expalin little more.

Clive S
07-12-2016, 10:20 PM
Only letters could put after my name are "NFC" or "CFS" but Hope that helps expalin little more.What's wrong with DCM (don't come Monday)


So with only 3.6v there not enough difference between Hi - Low signals and just slight difference or drop in voltage can cause missed steps and all sorts of strange happenings.


That's why as you know you need a bob with a level shifter to bring them back to 5V or a decent motion controller.

cropwell
07-12-2016, 11:34 PM
That BoB is a Larff innit ! 16 for a D25 to screw terminals connector.

A chinese 5 axis BoB will do isolation, spindle control, coolant relay all for a small Bank of England drinking voucher. I wouldn't put that connector board anywhere near my computer (apart from the bin next to it).

Cheers

Rob (if you want the letters behind my name it's 'F. in B.;VD and scar')