Setting Up the 3020 Milling Machine


  • Linux

    This thread has been started to maintain notes on setting up the 3020 T Router …

    Some initial effort was put into getting this router to work as originally setup on Windows XP. However, the lack of readable documentation, software and drivers has led to reconsidering this idea.

    The current plan is to switch from Windows XP to Linux CNC (also called Linux EMC2) for the control computer.

    To date the following has been done:

    • The router has been setup on the table downstairs on the parts table off of the electrical room (The router consists of: the actual router, control computer, blue controller box, 120/240 V inverter (black box currently on top of blue box), cooling pump and tank (not setup yet), power bar with 220 V outlet plugins
    • The control computer has been replaced with a newer (faster) unit and a larger screen. (may have to go back to old unit as it has a parallel port … see below)
    • Linux CNC distribution has been installed on the new control computer

    This evening we took the controller card from the original computer and swapped it into the new computer. Right away we ran into configuration problems with this card; we could not identify it. We eventually managed to identify the card as (thank you Google):
    card
    There is a brief write-up for this card here.
    Unfortunately, we were not able to find any linux drivers for this card, and we also discovered that this is not a simple parallel port card. We think the card is a code interpreter; the control computer sends code instructions to this card and the card then sends control signals to the various router components. Given that EMC2 does this already this interpreter does not seem desirable as we assume that EMC2 will do a better job interpreting the g code. Given these 2 issues (lack of a linux driver and the nature of the card) we shelved getting this card working on the control computer.

    The current consensus is that the control computer running EMC2 under linux should drive the various router components directly via a parallel port connection (translating code directly into control signals) as this is how EMC2 is designed to work. Given this idea we are now thinking of switching to a control computer that has a parallel port installed (or directly on the motherboard). The new control computer does not have a parallel port, and we could not track down a PCI parallel port card to install in it.

    We also found the following pinout image for the existing 15 pin parallel port connector in the blue controller box:
    pinout
    We believe this connector image is correct and tells us the parallel port connections that need to be made.

    A typical parallel port image is:
    parallel port

    Questions:

    • which parallel port pins do we connect to the connector pins of the controller box? Do not have an answer yet for this but think the details may be in the EMC2 configuration setup.
    • Is the parallel port a 5V standard? Think the answer to this is yes but need to confirm.
    • Are the control signals for the router 5V? Think the answer is yes based on above image but how to confirm?

    The stepper drivers in the blue controller box are Moons SR Series Stepper Drivers (SR4H 4696351000177). These items look like a match.

    An alternative for the controller could be this if the above ideas do not work out.

    Anybody think of anything I am missing from this?

    Edit: Here is a list of resources for this machine

    Resources


  • Linux

    We will be working on this again this evening.
    The plan is to:

    • switch to a new computer with a parallel port
    • install Linux CNC on this computer
    • Connect the parallel port on this computer to the blue controller box of the router

  • Linux

    What was accomplished last night:

    • The router was setup on the table against the window behind the conference table
    • The computer that originally came with the router was setup with linux cnc; the hard drive was repartitioned and the computer was setup to dual boot linux and Windows XP (the linux account is froggy with the password for the makerspace wireless network)
    • A parallel port cable was cut open and the wires were matched to the pins (see below). This cut cable is sitting on the router bed.
    • The cable was connected to the parallel port and tested (it seems to work)

    The cable pin assignments are (thanks Tony!):

    Parallel Port # Wire colour Code
    Teal 14
    Blue 15
    Red/black 2
    Red/white 3
    Red 1
    Black/white 24
    Pink 4
    orange/black 7
    Pink/black 5
    Purple/white 20
    Black 23
    White 25
    Brown 17
    Orange 6
    Grey 21
    Green/black 12
    Grey/black 22
    Brown/white 18
    Yellow 9
    Green 11
    Blue/white 16
    Green/white 13
    Orange/white 8
    Yellow/black 10
    Purple/white 20
    Purple 19

  • 3D

    One of “Orange/black - 20, Purple/white - 20” is actually # 19. Sorry about that.


  • Linux

    As an initial try for configuring Linux CNC we tried the following mappings …

    Connector # (from green board ) Description (from Green Board) Parallel Port # Linux CNC Mapping
    4 X pulse 16 X Step
    9 x direction pin 17 x direction
    3 y pulse pin 3 y step
    10 y direction pin 4 y direction
    2 z pulse pin 5 z step
    11 z direction pin 6 z direction
    8 x limit switch pin 10
    7 y limit switch pin 11
    6 z limit switch pin 12
    E STOP IN pin 13
    12 spindle speed pin 7 (WHNI)
    13 spindle speed pin 8 (WHNI)
    5 spindle speed pin 9 (WHNI)
    15 5V pin 14 (WHNI)
    14 ground
    1 tools setting

  • Linux

    We were at it again last night. The highlights …

    • Fixed 3 of the parallel port pin assignments to color code on the wires … these fixes are reflected above.
    • Made an initial stab at configuring Linux CNC to use the parallel port (based on the table immediately above this post
    • Did an initial test of all of this by successfully jogging the y-axis stepper motor!

    We spent most of our time on jogging the stepper motor.

    • We were able to fairly quickly configure Linux CNC and verify that the right signals were coming from the parallel port to the green break-out board in the blue controller box.
    • finally figured out that some of (a fair bit of?) the wiring in the blue controller box is completely wrong
    • The wiring to the stepper controller we worked on (all of the stepper controllers?) is reversed
    • As soon as we flipped the wiring for the controller we were working on it worked
    • The ground signal does not seem to be connected properly from the parallel port to various components in the blue box
    • Last note: Playing with the stepper time intervals in Linux CNC did not always produce the expected results. It works with the current settings, but we are missing something here.

    Good progress last night!


  • Linux

    Some images of the variable frequency spindle driver (VFD) in the blue controller box:

    2015-12-01 18.29.05.jpg
    And
    2015-12-01 18.28.06.jpg

    Translating this information, we have a:
    XINFUTAI 200V 1.5kw VFD controller
    Model #: FT-C001521KD


  • Linux

    So, I have been trying to track down a data sheet for this VFD controller. So far no luck but I have matched this router to the manufacturing company:
    http://www.hflaser.com/desktop-cnc-router.html

    Interestingly, there is a Canadian contact #.


  • Linux

    I did a fair bit of reading trying to figure out the VFD controller supplied with this router …

    A really solid basic introduction to VFD’s:
    how a VFD works

    Setup video for 3020 on cnc linux:

    And finally (I think) the answer for the 3 outputs going to the spindle ( following is a comment from http://www.cnczone.com/forums/archive/index.php/t-106336.html):

    *Since NCStudio does not do PWM or voltage modulation… it has 3 wires going to the spindle that are simply high/low state (on/off).
    The spindle inverter has 3 ports for ‘programmable control’. So SaleCNC simply setup the 3 ports on the spindle for RPM speeds of 5k on port1, 10k on port2, and 24k on port3.
    You will see on an NCStudio breakout illustration 3 pins marked “H M L”… High, Medium & Low… NCStudio was actually designed to operate this way :(

    This does not mean it’s permanently stuck this way though… you can use the LCD control panel to reprogram the HML speed settings, or you can disable the 3 input ports and just manually set the RPM from that LCD panel before machining.*

    From this comment I take it that the 3 outputs going to the VFD controller are on/off switches telling the spindle to spin at one of 3 speeds; high, medium, low. I am guessing the high, medium and low settings are set via the actual VFD interface. So, as long as we can configure 3 fixed speed ‘switches’ in linux cnc we are all set?

    In other words, I believe the basic schematic for this router’s setup is somewhat identical to:
    NCStudio.jpg

    Other detail I may have figured out … where to get 5 volts. I did not find examples of anybody using a parallel port pin to supply a constant 5 volts. Instead, a USB cable was used to supply 5V/GND.

    One more question …
    Is the ‘tool check’ (tool settings) output being used? Where does it go in the blue controller box?


  • Linux

    We are stuck!

    The VFD controller remains a slightly magical black box that we can get to light up …

    We have not been able to find a datasheet for this controller and do not know how to program it. We have sent an email to the equipment manufacturer and posted to CNC forums to see if we can track down more information.

    Otherwise, we might want to consider replacing the controller with something like a Huanyang VFD. (see details here).

    Seen on ebay … not sure if this is the exact model we would be after?




  • Linux

    So, I posted requests for information about Xinfutai inverters on a couple of CNC boards and got a reply back this morning.

    Somebody over at forum.linuxcnc.org linked to this on-line manual that does in fact appear to be the installation/operating manual for the VFD inverter we have controlling the spindle of this machine!

    I’ve taken an initial look and it seems like the programming instructions should work for our inverter.
    The model #'s that the manual claims to cover are not a perfect match for our inverter, but I am not yet sure if that is me mis-interpreting what the manual is saying … it is not the easiest manual to understand.

    We should be able to check the wiring and decipher how the VFD is programmed now … there may be hope for this controller yet!


  • 3D

    Looks so much like the right manual! The controller at the makerspace misses some misc outputs (= gpio? O_o), but apart from that looks like that’s the right one.
    Seems like you can even control this box over serial port (in modbus protocol though)!
    To start the spin we need to put a high signal on terminal that is marked “forward” (or “backwards”) AND set the frequency. Frequency can be set either from predefined settings that reside on input pins (set it on high to go to predefined speed) or from external potentiometer (GND, FIV, 10V) or, if nothing else is configured (not sure about this one), can be set by turning the knob on the control panel.
    To set the operation mode - put either 0, 1 or 3 in parameter P101.
    If 0: Speed is controlled by the value of parameter P100. Can change with buttons (up, down).
    If 1: Potentiometer mode.
    If 3: Fancy knob mode.

    To disable the “set terminal S2 for medium speed” behaviour set parameter P102 to 0 (just to be able to operate the whole thing from panel). To set it back as it was – set P102 to 1.


  • Linux

    I am finding the manual a bit confusing, but I think I agree with what you are saying above. For initial testing we could just disable the external control and operate it from the panel (setting P102 to 0).

    I am assuming there was no direction control the way the VFD is currently wired (only spin forward in other words), as no control signal was provided for it from the computer board. This should be easy to change if we want.

    And the original setup was only set to use 3 pins for the pre-configured speed selection. I am curious why this was done (8 predefined speeds instead of16). I guess they only had 3 available outputs on the original 15 pin connector? Again, easy enough to change.

    I am very curious now to see if the actual wiring matches what the manual says …

    @arasbm you mentioned last week there were some components we could turn into a breakout board for the connector. What exactly were you thinking?


  • Linux

    Good progress this afternoon …

    • Changed the programming on the VFD controller to operate the spindle from the panel on the controller. This works and it is possible to turn the spindle on now. Would not recommend turning the spindle on again until the water cooling pump is hooked up. Does anybody know where the pump that came with this router went?
    • Re-wired the stepper drive controllers properly and tested them by jogging the motors using StepperConf. This all worked except for direction control of the x axis … did not have a chance to check it but I am guessing the wiring is not connected somewhere.

    Need to figure out the limit switches and proper settings (thread pitch and distances) for the axes …



  • awesome!
    the pump and supplies are in a big grey container under the bench.


  • Linux

    More progress this evening.
    The stepper motors and limit switches have been wired correctly and tested.
    We are now learning (struggling?) with Linux CNC configuration. We are working to setup the Linux-CNC configuration correctly; specifically we cannot seem to get the home/limit switches recognized at the correct locations.


  • Linux

    More progress yesterday afternoon … this machine is pretty much configured and working; we could possibly (hopefully?) try cutting a test piece next time!

    What we did:

    • Properly configured LinuxCNC for table size and homing direction. (NOTE: linuxCNC configuration is not intuitive … it REALLY pays to read the configuration document for linuxCNC before you start)
    • Hooked up the cooling pump to the spindle and successfully pumped water through it
    • Turned on the spindle and let it run for a while … it worked!

    There are a lot of little issues to resolve:

    • When the VFD controller for the spindle is first turned on it hums initially (more like a high pitched whine). Eventually, the spindle starts to spin and the whine fades away. I think what is happening here is that the VFD is ramping up frequency to start the spindle slowly and then accelerate it to the desired speed( problem being that at low frequency the spindle is not getting enough power to start so the spindle only kicks in after a period of time?).
    • the VFD is tripping the power bar we are using right before the 120/220 V transformer, so that the spindle only successfully powers up half the time (the rest of the time it is tripping). We discussed a number of solutions last night ranging right up to using a 220 volt circuit and bypassing the supplied transformer. What we did not talk about is simply taking the power bar out of the equation and plugging directly into a 120 volt outlet so that we are not relying on the fuse on the power bar (which is probably 10 amp?).
    • We are not able to control the frequency (and by extension spindle speed) from the control panel on the VFD. I am guessing we are still missing a setting to do this (need to read the VFD manual in more detail). We also do not really know right now what speed it is ramping up to (again, more reading).
    • proper wiring and a breakout board to clean up the connection between the computer and the controller.
    • Spindle cooling is very crude … we are currently pumping into a bucket. I am guessing we want something with a lid.
    • need to connect the kill switch.

  • Linux

    A little more progress yesterday …

    • Rewired the power cord to the 110/220 volt inverter (the black box) so that it uses a standard wall plug. This helped … the inverter power is no longer being tripped due to the fuse in the power bar going off (to be clear this power bar is no longer in the circuit)
    • Wired the panic button (the red button on the front of the blue control box) to ESTOP (emergency stop) in Linux CNC … this means that turning this button stops the router from moving now.


  • I am new, Very stoked on the progress of the cnc router, I would of liked to be of some help in the earlier processes, but moving forward.
    i imagine its pretty well up and running now or at least on the final stages.

    good work guys.



  • I continue to be amazed at the work being done on my router and I am very excited at the prospect of finally seeing it in action (I had it for two years in my garage and never used). Thank you very much to all who have worked on the project. Pierre was in my restaurant the other day and had a great suggestion to submit a graphic to convert and cut as a tutorial for those of us trying to get the basics of all the steps to take an image and output it to the router for cutting. I will send the graphic by Email and hopefully we can get some of the steps figured out and everybody able to use the software as well as the hardware. Merry Christmas and Happy new year.


Log in to reply