. .
Page 1 of 5 123 ... LastLast
  1. #1
    FREE USB-Parallel Port Interface
    Released 08/03/2006 - Updated 12/03/2006.

    Do you drive your Motor Controller usually via the Printer Port?

    Well now you can convert it to USB with this very simple Circuit below. We supply the PCB design FREE, the Firmware FREE and the Windows Application FREE

    You just build it, use it and let us know of any improvements we can make.

    To compliment our new FREE Beta USB Application (Shown Below) along with new Firmware, we are going to release a very simple circuit that people can build themselves that will let you control any parallel port stepper motor controller via USB.

    With this simple circuit and our Firmware you will be able to simply plug it into your existing Controller box and using our software, run your Gcode via the USB Port.

    The reason this will work with any existing Controller box that uses the parallel port to control the Clock and Signal lines is because we will release standard Firmware that will cover different pin configurations as needed.

    Find below the first picture of version 1.0

    As you can see, this is not going to cost you a lot of money to make!!!!!!!!!
    Click image for larger version. 

Name:	usb-par-release.jpg 
Views:	3580 
Size:	254.4 KB 
ID:	25572

    PCB and Components.

    Please find below the PCB layout.
    Size of PCB is 75MM * 75MM
    Click image for larger version. 

Name:	USB-PAR1Bottomlow.jpg 
Views:	1151 
Size:	84.9 KB 
ID:	25569
    Click image for larger version. 

Name:	USB-PAR1Ooverlaylow.jpg 
Views:	1385 
Size:	63.4 KB 
ID:	25573

    Click here to download the Hi Resolution images: usb-par-hi-respcb600dpi.zip

    These are 600DPI JPG and need to be viewed and printed in Adobe Photoshop for an exact scale.
    Also included are postscript files as well.

    We are also releasing the PCB Layout in Gcode for people wanting to mill their own.
    Click image for larger version. 

Name:	gcodepcb.jpg 
Views:	892 
Size:	151.5 KB 
ID:	25570

    Milling PCB below with 0.2mm engraving bit.
    Click image for larger version. 

Name:	gcodepcb2.jpg 
Views:	822 
Size:	120.5 KB 
ID:	25571

    Drilling PCB below with 0.8MM drill bit.
    Click image for larger version. 

Name:	gcodepcb3.jpg 
Views:	837 
Size:	137.8 KB 
ID:	25575

    Click here to download the Gcodes: usb-par-gcodev1.zip

    Inside this file are two Gcodes, one for the Milling and the other for the drilling.

    Components:
    1 * 25pin socket
    1 * 18F4550 Chip
    1 * 40 pin Dip Socket.
    1 * USB Socket
    1 * 20mhz Xtal (the Pic internally clocks this upto 48mhz)
    2 * 22pf ceramics
    1 * 4k7 resistor
    1 * 1k resistor
    1 * LED
    1 * 0.1uf ceramic decoupling cap.
    1 * 0.1uf electrolytic capacitor
    1 * 22uf electrolytic capacitor
    1 * little tactile push switch for resetting Pic, not really needed.

    And a PCB about 75mm * 75MM

    Firmware Version 1.2 released 12/03/2006:

    Click here to download the Firmware Version 1.2 Type1: usb-par-firmwarev12-type1.zip

    This code is for use with the 18F4550 Pic Chip.
    You will need a suitable Pic Chip programmer that supports the 18F4550.
    The fuses have all been set in the hex file, so simply load up, Program and Verify.
    Type 1 is configured for the following Pin Configurat

    Pin2: Step X-Axis
    Pin3: Direction X-
    Pin4: Step Y-Axis
    Pin5: Direction Y-Axis
    Pin6: Step Z-Axis
    Pin7: Direction Z-Axis
    Pin10: Z-Limit Switch
    Pin11: Emergency-Stop Switch
    Pin12: Y-Limit Switch
    Pin13: X-Limit Switch

    As we have said before, if you need the firmware customised to suit your controller then please email us and we will re-compile and release here.
    Command Structure for Firmw
    Command Structure Ver 1.2 upwa
    Commands are sent 11 bytes at a t

    This first byte gets broken down into 8 bits and they do the following:
    bit0= X Axis Direction
    bit1= Y Axis Direction
    bit2= Z Axis Direction
    bit3= Travel kind, this is for the firmware to tell it to use different routines for G00 travelling or G01 cutting, 1=Travelling 0=Cutting
    If you set this bit to 1 then the firmware will not care about how it gets to this position and it will just clock each Axis until it gets there.
    If you set it to 0 then it will move the X and Y axis at even pulses to get to it's destination giving the correct line needed. This option takes more processing time, so speed pauses may have to be adjusted.
    bit4= Tells Firmware to ignore limit switches 1=ignore 0=do not ignore
    bit5= always 0
    bit6= always 0
    bit7= always 0

    The next 3 bytes control how many pulses you wish to send to the X-Axis.
    On our machine 533.333 pulses =1mm so to tell it to travel we first have to round up and break to binary int(533.333)=533

    533 binary= 00000000 00000010 00010101

    now we get our 3 bytes from this

    1st byte 00000000 = 00
    2nd byte 00000010 = 02
    3rd byte 00010101 = 21

    By doing it this way we can send a max 16777215 pulses which = 31457MM (103 feet!) Travel

    The next 3 bytes control how many pulses you wish to send to the Y-Axis.
    This is the same as the X-Axis
    The next 2 bytes control how many pulses you wish to send to the Z-Axis.
    Same as the X-Axis but this time only 2 bytes(16bits)
    Final 2 bytes is Pulse Width Delay
    0050 = Pulse delay in Microseconds for speed.
    This will differ depending on the Step Mode that the controller box is set to.
    Find some examples below, obviously we round up because we only send 4 digits to the controller.
    Eighth Step Timings:
    A 2250 Microsecond pause gives 25.4mm or 1 Inch Travel per minute.
    A 1125 Microsecond pause gives 50.8mm or 2 Inch Travel per minute.
    A 0562.5 Microsecond pause gives 101.6mm or 4 Inch Travel per minute
    A 0281.25 Microsecond pause gives 203.2mm or 8 Inch Travel per minute
    A 0140.625 Microsecond pause gives 406.4mm or 16 Inch Travel per minute
    A 0070.3125 Microsecond pause gives 812.8mm or 32 Inch Travel per minute
    A 0035.15625 Microsecond pause gives 1625.6mm or 64 Inch Travel per minute
    A 0017.578125 Microsecond pause gives 3251.2mm or 128 Inch Travel per minute

    So to work out what pause we needed for say 45IPM we would use 2250/45 which gives us 0050
    To work backwards and see what a pause of 50 would get, we would take 2250/50 which would give us 45IPM.
    The motors we use on the CNCDuDeZ Frame max out at about 50 Microsecond pause, which gives us a respectable approx 45IPM!

    Quarter Step Timings:
    A 4500 Microsecond pause gives 25.4mm or 1 Inch Travel per minute.
    A 2250 Microsecond pause gives 50.8mm or 2 Inch Travel per minute.
    A 1125 Microsecond pause gives 101.6mm or 4 Inch Travel per minute
    A 0562.5 Microsecond pause gives 203.2mm or 8 Inch Travel per minute
    A 0281.25 Microsecond pause gives 406.4mm or 16 Inch Travel per minute
    A 0140.625 Microsecond pause gives 812.8mm or 32 Inch Travel per minute
    A 0070.3125 Microsecond pause gives 1625.6mm or 64 Inch Travel per minute
    A 0035.15625 Microsecond pause gives 3251.2mm or 128 Inch Travel per minute

    Half Step Timings:
    A 9000 Microsecond pause gives 25.4mm or 1 Inch Travel per minute.
    A 4500 Microsecond pause gives 50.8mm or 2 Inch Travel per minute.
    A 2250 Microsecond pause gives 101.6mm or 4 Inch Travel per minute
    A 1125 Microsecond pause gives 203.2mm or 8 Inch Travel per minute
    A 0562.5 Microsecond pause gives 406.4mm or 16 Inch Travel per minute
    A 0281.25 Microsecond pause gives 812.8mm or 32 Inch Travel per minute
    A 0140.625 Microsecond pause gives 1625.6mm or 64 Inch Travel per minute
    A 0070.3125 Microsecond pause gives 3251.2mm or 128 Inch Travel per minute

    Full Step Timings:
    Use below full step for speed of 25.4mm or 1 Inch Travel per minute.
    A 9000 Microsecond pause gives 50.8mm or 2 Inch Travel per minute.
    A 4500 Microsecond pause gives 101.6mm or 4 Inch Travel per minute
    A 2250 Microsecond pause gives 203.2mm or 8 Inch Travel per minute
    A 1125 Microsecond pause gives 406.4mm or 16 Inch Travel per minute
    A 0562.5 Microsecond pause gives 812.8mm or 32 Inch Travel per minute
    A 0281.25 Microsecond pause gives 1625.6mm or 64 Inch Travel per minute
    A 0140.625 Microsecond pause gives 3251.2mm or 128 Inch Travel per minute

    Every time you send a 11byte command you will get 2 bytes back from the controller that will give you in ASCII the answer OK. This is the same whether sending Serial or USB.

    You will also get a 2 byte ASCII code sent back for AUX1 inputs which are triggered:
    XL X-Axis Limit Reached
    YL Y-Axis Limit Reached
    ZL Z-Axis Limit Reached
    XY X-Axis and Y-Axis Limits Reached
    XZ X-Axis and Z-Axis Limits Reached
    YZ Y-Axis and Z-Axis Limits Reached
    XA X-Axis, Y-Axis and Z-Axis Limits Reached
    ES Emergency Stop Activated.

    Application:

    Please Check the USB-Software link to download our Beta Application: cncdudezusb17.zip
    Click image for larger version. 

Name:	screenpcb.jpg 
Views:	1464 
Size:	231.9 KB 
ID:	25579

    Setting up and testing:
    After you have assembled your new Interface, simply plug in a USB lead and Windows XP will automatically detect the Interface as a USB Hid Device.
    You can confirm this by checking in device manager of your machine.
    Now connect your Printer Port cable from the Interface to your controller box and you are ready to go.

    Run up the software, set up the pulses per MM parameter and try out the Jog.

    Please make sure you read the HELP File first.
    Last edited by Lee Roberts; 27-03-2019 at 12:16 AM.
    .Me

  2. The Following User Says Thank You to Lee Roberts For This Useful Post:


  3. #2
    I've done a (very) quick hash at a schematic - with a few revisions:
    1. The PIC to be programmed in-circuit with a PICkit2 or PICkit3. You'll need to make sure your CNC device is unplugged when you do this (since it pings a couple of the pins), and also don't press the switch when you do it!
    2. The >400nF capacitor has been included
    3. The component numbering has been altered


    The new layout is smaller, and doesn't have any wire jumpers. However, it is designed primarily for photo-etching (the .zip file contains the PDFs for the schematic, layout and PCB itself, at a 1:1 scale - I use the latter for my photo-etching of boards).

    If you want to remain faithful to the original design (i.e. you don't need the ICSP header), then you can replace D1 with a wire, and remove PL1.

    If this treads on anyone's toes, please let me know.
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	CNCDuDeZ-schem.jpg 
Views:	30431 
Size:	134.5 KB 
ID:	677   Click image for larger version. 

Name:	CNCDuDeZ-layout.jpg 
Views:	13163 
Size:	86.3 KB 
ID:	678  
    Attached Files Attached Files

  4. The Following 4 Users Say Thank You to tribbles For This Useful Post:


  5. #3
    hi
    i made one cnc router mechine but i can not building driver controler for 3 axies motor steper-please help me for make driver controler (with pc) thank's

  6. #4
    Do you have the schematics in Eagle PCB format?

  7. try www.cncdudez.co.uk instead, but both links are working

    This version is NOT the smoothstepper shown in the video, thats a commercial product with a Mach3 plugin. I don't think there is a Mach3 driver for CNCDudez' interface

  8. #6
    Does the computer make the "dee-dum" noise when you plug it in/unplug it? If not, you have not got a working USB interface.

    As it is HID rather than Generic Serial, did it ask for the .inf file location when you first plugged it in?

  9. #7
    If any USB device makes the noise, they all will.

    The computer finds a USB device and gets it's unique product ID number. Then it goes "dee-dum" and looks for software matching that number.

    No noise means there is a problem in the firmware or the hardware.

    Product ID numbers are a problem if you want to make USB devices. The numbers are free but you have to join the USB club to get them which costs about £3k IIRC. When I needed numbers I searched the web and found a USB club member wanting to sell me ten numbers for a hundred pounds or so which is how I got around it. Wonder what number you are using.

  10. The Following User Says Thank You to Robin Hewitt For This Useful Post:


  11. The USB device ID is a combination of device, interface and endpoint configurators. These are set by firmware after the PIC is reset and then the sequence is:

    When the device is initially attached to the bus, the host
    enters an enumeration process in an attempt to identify
    the device. Essentially, the host interrogates the device,
    gathering information such as power consumption, data
    rates and sizes, protocol and other descriptive
    information; descriptors contain this information. A
    typical enumeration process would be as follows:
    1. USB Reset: Reset the device. Thus, the device
    is not configured and does not have an address
    (address 0).
    2. Get Device Descriptor: The host requests a
    small portion of the device descriptor.
    3. USB Reset: Reset the device again.
    4. Set Address: The host assigns an address to the
    device. >> this is where the de dum sound occurs
    5. Get Device Descriptor: The host retrieves the
    device descriptor, gathering info such as
    manufacturer, type of device, maximum control
    packet size.
    6. Get configuration descriptors.
    7. Get any other descriptors. >>during 5,6,7 Windows refines its understanding of the device, this is where you'll see 'Found generic HID' followed by 'Found <some device class>'
    8. Set a configuration. >>this is where windows tries to load the required software

    Since the ProductID is expensive the specifics are often in the later configurators, using a generic ProductID at the top level.

    If you are unable to get Windows to recognise the USB device, you could try downloading a USB diagnostic tool. Does the device appear in Device Manager as an 'Unknown device' with a yellow question mark? If so then Windows is not recognising the descriptor as one of the generic classes. If it doesnt appear at all then the USB controller isnt able to do the initial reset/enumeration (steps 1 - 3 above) and Windows will never know the device exists. If this is the case then the problem is in your hardware or software (including the Microchip USB libraries) and without a full scale debugger and source code and the knowledge to use it there is little anyone can do to help.

  12. The Following User Says Thank You to irving2008 For This Useful Post:


  13. #9
    I just had a quick look on www.usb.org and it seems you can now get vendor ID numbers for a mere $2k.

    Not as bad as I remembered it but they've now added a clause to say you can't sell numbers on. Too late guys :naughty:

  14. The Following User Says Thank You to Robin Hewitt For This Useful Post:


  15. #10
    If you're using a Microchip product (which this is), then you can apply for a PID and use their VID - although if usb.org has changed their rules, then I don't know if it's still applicable (I did download their application form a week ago though, so it's not been removed - but then I did find a direct link to it off another website, and they may have not removed it; only their links to it).

Page 1 of 5 123 ... LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. What is the function of a parallel port breakout board?
    By hbx in forum Machine Control Software
    Replies: 13
    Last Post: 12-03-2013, 06:18 PM
  2. Stepper motor drive using mach3 from parallel port
    By hmarwat370 in forum General Electronics
    Replies: 0
    Last Post: 04-02-2013, 08:55 AM
  3. parallel port address
    By Dan Brown in forum Artsoft Mach (3 & 4)
    Replies: 6
    Last Post: 07-01-2010, 12:04 PM
  4. Laptop, ie no parallel port?
    By tompsky in forum Laptops & Tablets
    Replies: 3
    Last Post: 11-11-2008, 07:12 PM
  5. Which USB parallel port emulator is the best
    By bruce_miranda in forum General Electronics
    Replies: 1
    Last Post: 18-09-2008, 03:38 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •