Author Topic: Parallel Port Breakout  (Read 5891 times)

0 Members and 1 Guest are viewing this topic.

Offline ZilloloTopic starter

  • Contributor
  • Posts: 12
Parallel Port Breakout
« on: November 18, 2013, 08:08:50 pm »
Hello friends,

this is my first thread, so please excuse any silly errors I make.
I have been tasked with designing a breakout board for a parallel port. Now after playing around a bit I came up with what I attached,
but since this is my first real project I'm rather sceptical about it.
I just wanted to ask what you would do differently or whether I should just throw this schematic in the bin.

Thanks in advance for any help!
 

Offline Kremmen

  • Super Contributor
  • ***
  • Posts: 1289
  • Country: fi
Re: Parallel Port Breakout
« Reply #1 on: November 18, 2013, 08:25:43 pm »
It depends. Almost certainly the op amps are not what you actually need. Or they might be - it is not obvious.
What is the application of the breakout board, i.e. what will it connect to the PC?

Maybe the attached schematic might give you some ideas. It is a breakout board for small 4 axis CNC routers i made some time ago. Feel free to use anything you want and if you have questions i am happy to help.
The mystery circuit around Q1, Q3 and Q15 is a charge pump that only enables the outputs after the PC delivers a steady pulse of > 10 kHz to port pin 1. This is needed because the parallel port pins are in random states after boot. Not good for machinery that need to be under control at all times.
Also all inputs/outputs are opto isolated for partial noise and common voltage protection.

Nothing sings like a kilovolt.
Dr W. Bishop
 

Offline ZilloloTopic starter

  • Contributor
  • Posts: 12
Re: Parallel Port Breakout
« Reply #2 on: November 18, 2013, 08:31:50 pm »
Thanks for the answer.

The breakout board is supposed to be connected to a CNC router, like yours.
Sadly I cannot seem to be able to open your attachment.
Also since this CNC router has 5 axis there are no pins on the parallel port available for the charge pump,
do you maybe have any advice for that?

Thanks in advance

Edit: I have been able to open the attachment now, Google Chrome seems to have some issues with it.
« Last Edit: November 18, 2013, 08:36:07 pm by Zillolo »
 

Offline kxenos

  • Frequent Contributor
  • **
  • Posts: 284
  • Country: gr
Re: Parallel Port Breakout
« Reply #3 on: November 18, 2013, 08:36:55 pm »
Have you considered schmitt triggers? Also is there a requirement that the outputs must be isolated like Kremmen's circuit? If not, the CNC's ground will be attached to the PC's ground. Is this what you plan?
 

Offline matkar

  • Regular Contributor
  • *
  • Posts: 153
  • Country: si
  • Sixty percent of the time it works EVERY time.
Re: Parallel Port Breakout
« Reply #4 on: November 18, 2013, 08:37:36 pm »
Search the web for examples. Here is one: http://www.cuteminds.com/index.php/optobreak
Usually isolation is a good thing and use buffers/inverters instead of voltage followers. Adding a local voltage regulator for the supply might make sense.
 

Offline ZilloloTopic starter

  • Contributor
  • Posts: 12
Re: Parallel Port Breakout
« Reply #5 on: November 18, 2013, 08:42:25 pm »
Have you considered schmitt triggers? Also is there a requirement that the outputs must be isolated like Kremmen's circuit? If not, the CNC's ground will be attached to the PC's ground. Is this what you plan?
What are the disadvantages of connecting the both grounds? Could this be a possible source of errors?

Search the web for examples. Here is one: http://www.cuteminds.com/index.php/optobreak
Usually isolation is a good thing and use buffers/inverters instead of voltage followers. Adding a local voltage regulator for the supply might make sense.
Thanks for the site, will have a look at it!
I already get a regulated 5V in from my power supply, so I think another voltage regulator would be overkill? Correct me if I'm wrong please.

Thanks in advance and thanks for the help guys!
 

Offline kxenos

  • Frequent Contributor
  • **
  • Posts: 284
  • Country: gr
Re: Parallel Port Breakout
« Reply #6 on: November 18, 2013, 08:58:39 pm »
ground loops and ground bounce have to be avoided but the most significant factor is protection of the motherboard in case something goes wrong to the outside circuit. Especially when you have a power circuit connected like stepper motor drivers etc. where there is a possibility that in case of fault more than 5V go to the parallel port
 

Offline matkar

  • Regular Contributor
  • *
  • Posts: 153
  • Country: si
  • Sixty percent of the time it works EVERY time.
Re: Parallel Port Breakout
« Reply #7 on: November 18, 2013, 09:43:07 pm »
I already get a regulated 5V in from my power supply, so I think another voltage regulator would be overkill? Correct me if I'm wrong please.

I don't know what kind of connector are you planning to use for alimentation but in case of terminal block you risk reverse connection. At least place some components to protect your circuit against reverse polarity.
And definitely use optocouplers or other means of isolation.
 

Offline Kremmen

  • Super Contributor
  • ***
  • Posts: 1289
  • Country: fi
Re: Parallel Port Breakout
« Reply #8 on: November 18, 2013, 09:59:36 pm »
Thanks for the answer.

The breakout board is supposed to be connected to a CNC router, like yours.
Sadly I cannot seem to be able to open your attachment.
Also since this CNC router has 5 axis there are no pins on the parallel port available for the charge pump,
do you maybe have any advice for that?

Thanks in advance

Edit: I have been able to open the attachment now, Google Chrome seems to have some issues with it.
The axes on my board are all with individual enable outputs. If you can manage with a common enable then that will free 3 outputs and you can have one more axis with pulse/dir and one with pulse only. Or if you handle enable with other means, then you might be able to have 5 pulse/dir channels.
Please be aware that the charge pump functionality is not really optional; you need it unless you can be sure that no motion is possible before the PC software has properly initialized the parallel port. You can do it with other means but the charge pump is commonly used for that purpose and most PC based CNC control software supports it.
Nothing sings like a kilovolt.
Dr W. Bishop
 

Offline ZilloloTopic starter

  • Contributor
  • Posts: 12
Re: Parallel Port Breakout
« Reply #9 on: November 18, 2013, 10:07:21 pm »
I don't know what kind of connector are you planning to use for alimentation but in case of terminal block you risk reverse connection. At least place some components to protect your circuit against reverse polarity.
And definitely use optocouplers or other means of isolation.
I will keep that in mind, thank you!

The axes on my board are all with individual enable outputs. If you can manage with a common enable then that will free 3 outputs and you can have one more axis with pulse/dir and one with pulse only. Or if you handle enable with other means, then you might be able to have 5 pulse/dir channels.
Please be aware that the charge pump functionality is not really optional; you need it unless you can be sure that no motion is possible before the PC software has properly initialized the parallel port. You can do it with other means but the charge pump is commonly used for that purpose and most PC based CNC control software supports it.

I've got it something like this: 5 x Step, 5 x Dir,1 x Spindle PWM for the outputs
Do you have any suggestion on how I could do this with this limited amount of pins?
As far as I understand I NEED 10 outputs for the step/dir signals, so I have only got 1 left
 

Offline IanB

  • Super Contributor
  • ***
  • Posts: 11891
  • Country: us
Re: Parallel Port Breakout
« Reply #10 on: November 18, 2013, 10:15:04 pm »
I've got it something like this: 5 x Step, 5 x Dir,1 x Spindle PWM for the outputs
Do you have any suggestion on how I could do this with this limited amount of pins?
As far as I understand I NEED 10 outputs for the step/dir signals, so I have only got 1 left

You could in principle send binary coded values to the port and decode them on the breakout board to generate individual signals. Four pins would give you 15 outputs (treating 0000 as "off"), and eight pins 255 outputs. But then of course the driver software on the PC would have to know how to drive the port...
 

Offline ZilloloTopic starter

  • Contributor
  • Posts: 12
Re: Parallel Port Breakout
« Reply #11 on: November 18, 2013, 10:26:16 pm »
I've got it something like this: 5 x Step, 5 x Dir,1 x Spindle PWM for the outputs
Do you have any suggestion on how I could do this with this limited amount of pins?
As far as I understand I NEED 10 outputs for the step/dir signals, so I have only got 1 left

You could in principle send binary coded values to the port and decode them on the breakout board to generate individual signals. Four pins would give you 15 outputs (treating 0000 as "off"), and eight pins 255 outputs. But then of course the driver software on the PC would have to know how to drive the port...

That's a wonderful idea, but I don't think my software can do that.
I could use 2 parallel ports at the same time, the only problem with that is, that we don't have any PCs with 2 parallel ports.

EDIT: What do you guys think about using 2 parallel ports? Maybe I could organize an old PC with 2 connectors. That would solve the problem, wouldn't it?
« Last Edit: November 18, 2013, 10:29:06 pm by Zillolo »
 

Offline Kremmen

  • Super Contributor
  • ***
  • Posts: 1289
  • Country: fi
Re: Parallel Port Breakout
« Reply #12 on: November 19, 2013, 07:51:47 am »
2 parallel ports is the "standard" way to solve this problem. You can buy an adapter board to get the 2nd port to a computer that doesn't have one as standard. Software such as LinuxCNC and Mach 3 have the capability to use dual parallel ports.

Nothing sings like a kilovolt.
Dr W. Bishop
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf