586,117 active members*
3,378 visitors online*
Register for free
Login
IndustryArena Forum > CNC Electronics > CNC Machine Related Electronics > Need help with data transfer hookup for PC to Bandit I Level II Firmware Loaded Contr
Results 1 to 10 of 10
  1. #1
    Join Date
    Jun 2007
    Posts
    13

    Need help with data transfer hookup for PC to Bandit I Level II Firmware Loaded Contr

    Need help with data transfer hookup for PC to Bandit I Level II Firmware Loaded Control
    I have a CNC Bandit (Summit/Dana)control operating a Supermax milling machine which works fine entering programs by hand with the keypad on the control or with the old data recorder (cassette player/recorder)to save programs on a cassette tape but of course all the data has to be typed in initially by hand. I want to be able to send and receive programs to the control from my PC (Win XP) using RS232 serial USB and possibly send and receive to the data recorder (cassette tape).The 2 cables I have now each have a 25 pin male "DB" connector which connects to the data recorder and the bandit control on the supermax milling machine. Obviously I wish to get from the DB 25 pin male to the PC from each unit. I need to interface from DB 25 pin male to a USB serial on the PC.
    7 data bits 2 stop bits Xon/Xoff Even Parity no EOB no LF/CR.

    Need help with:
    Info on proper connection of devices.
    Converter for RS232 from serial female USB on PC to DB25 pin male on cable going to Bandit CNC Control or Data Recorder (Cassette Tape Recorder/Player)
    RS232 Drivers
    RS232 Software

    Thanks,
    Mike

    Mikes Custom Bikes

    [email protected]

  2. #2
    Join Date
    Aug 2006
    Posts
    281
    Did you ever get this? I have a serial adapter on mine. I can give you the pin outs or I may have a spare serial interface soon. I'm just about to start tearing my machine apart.

    Sadly (or luckily...depending on your position) I also just finished writing a program that converts standard G-code to Bandit and also transmits it over serial all in one app. I did one test with it and it worked good (When comparing code generated to known good code). The one thing I forgot to put in was a G90 (absolute mode) at the start of the program...so when I was running a test program I had to do a quick panic stop...and the machine never woke up again .

    It's a shame it died because I started adding another feature that would scan the entire code after converting it and look for duplicate sets of code...the biggest duplicates would be consolidated into subroutines (a huge help for space conservation) - but I never had a chance to finish this and since I can't test it I probably never will.

    If you ever get the Serial functioning, your welcome to try the software out for yourself. or let me know if you still need the pinouts.

  3. #3
    Join Date
    Mar 2003
    Posts
    4826
    Chris,
    What did you do to it, hit it with a sledge? I used to stop mine with the RESET button all the time, no harm done.
    First you get good, then you get fast. Then grouchiness sets in.

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  4. #4
    Join Date
    Aug 2006
    Posts
    281
    Quote Originally Posted by HuFlungDung View Post
    Chris,
    What did you do to it, hit it with a sledge? I used to stop mine with the RESET button all the time, no harm done.
    ha ha, no not until a few hours went by that is.

    Well, I'll admit it...here's what went down. In a panic, I just turned feed rate to hold...then reset everything (and added some code to my program). Then went to reupload it and nothing was working right. Tried to jog it back to home and error light was getting thrown at almost everything (remember I put it on hold? I didn't) Anyway, I just figured it was in a normal state of "Bandit" (as happens often) and I rebooted it. Servos never squeeled again. I later saw the hold problem, but that didn't help anything. In the past this problem occured because the sensor that looks for air pressure was stuck or broken. it's probably the same thing, but I'm just sick of mucking with it.

    You told me a long time ago that the Bandit Controllers seem basically fine until you actually try to build something (or something like that) and you were right. Everytime I would use it, it would fight me with something stupid...not starting, or what really ticked me off was the math being wrong. The arc would be accurate to 1/10,000 and it would still fire off saying it wasn't. This really started being a problem when I started beign able to draw parts because the programs would put in super tiny arcs (moving only .0001 at times). 99% of the time it would handle the math fine, but it never failed at about line 700 it would crash. My new program was taking these problems into account and would convert arcs that small to just straight lines.

    Not to mention the whole 1000 lines of code.

    Honestly, I'm very scared to start ripping it apart though. I'm sure it'll be fine, but scary none the less.

  5. #5
    Join Date
    Mar 2003
    Posts
    4826
    You know, I've got a couple of knee mills with working Shadow cnc's that I'm not using....they're both functional, I just don't like them any more
    First you get good, then you get fast. Then grouchiness sets in.

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  6. #6
    Join Date
    Aug 2006
    Posts
    281
    What a sales pitch! lol

  7. #7
    Join Date
    Jan 2006
    Posts
    23
    Chris,
    I'm just getting ready to try to get my PC talking to the Bandit control on a Lagun mill I picked up. I would be interested in trying your program. The typing thing is a little slow for me, but so far the mill is working OK.

    J.

  8. #8
    Join Date
    Aug 2006
    Posts
    281
    Long story short (very long story)...but I just tried it and I found a couple small bugs in it. They might not take long to fix, but I'm not ever going to be running my Bandit anymore so it's really going to be difficult to fix it.

    Right now I can give you a Bandit Post Processor file for SheetCam. It works most of the time as long as you don't have complex arcs. It seems that it would sometimes enter in a duplicate arc on clockwise arcs. The good news is that they were rare and it would stop running when it happened, not go crazy.

    I also have a program for transmitting the files to the bandit over serial. It really speeds things up.

    Here's the post processor data. Sheetcam offers a trial version I think and it's worth checking out. PM me your email and I'll email you the transmit program.

    You can copy this to a textfile. rename it "Bandit.post" and then copy it to "program files/sheetcam/posts/"

    Hope that helps for now.

    Code:
    --  Minimum Post Processor for Bandit COntroller
    --
    --  Modified 8/19/2007
    --  Chris Haugen
    
    function init()
       setcommentchars ("()", "[]")  --make sure ( and ) characters do not appear in system text
       --CH English/metric taken out because scale is a switch on the Front Panel.
       text ("N001&nG90n")
       bigarcs = 1 --stitch arc segments together
       minarcsize = 0.1 --arcs smaller than this are converted to moves
    end
    
    function newline()
       line = line + 10
    end
    
    function finish()
       text("n")
       modalnumber ("Z", (endz + tooloffset) * scale, "0.0000")
       text ("M2n")
       endz = safez
       rapid()
    end
    
    function rapid()
       if (feedrate ~= feedrateval) then
          text ("F")
          number (feedrate * scale, "0")
          text (".n")
          feedrateval = feedrate
       end
       modalnumber ("/X", endx * scale, "0.0000")
       modalnumber ("/Y", endy * scale, "0.0000")
       text("n")
       modalnumber ("Z", (endz + tooloffset) * scale, "0.0000")
       eol()
    end
    
    function move()
    
       if (feedrate ~= feedrateval) then
          text ("F")
          number (feedrate * scale, "0")
          text (".n")
          feedrateval = feedrate
       end
    --      text("n")
          modalnumber ("X", endx * scale, "0.0000")
          modalnumber ("Y", endy * scale, "0.0000")
          modalnumber ("Z", (endz + tooloffset) * scale, "0.0000")
       eol()
    end
    
    function arc()
       --Here is where we need to break an arc into quadrants
       --arccenterx & y is it's physical location
       --I'm not allowing Z arcs since my machine can't do it
       --Quadrants 1(X+Y+),2(X+Y-),3(X-Y-),4(X-Y+)
    
       modalnumber ("Z", (endz + tooloffset) * scale, "0.0000")
       text("n")
       arc_currentx = round3(currentx - arccentrex,4)
       arc_currenty = round3(currenty - arccentrey,4) 
       arc_endx = round3(endx - arccentrex,4)
       arc_endy = round3(endy - arccentrey,4)
       arc_distancetocenter = math.sqrt((arc_currentx * arc_currentx) + (arc_currenty * arc_currenty))
       current_quadrant = ""
       finish_quadrant = ""
    
       if (arc_currentx >= 0 and arc_currenty > 0 and arcangle > 0) then current_quadrant = "1";end
       if (arc_currentx > 0 and arc_currenty >= 0 and arcangle < 0) then current_quadrant = "1";end
       if (arc_currentx > 0 and arc_currenty <= 0 and arcangle > 0) then current_quadrant = "2";end
       if (arc_currentx >= 0 and arc_currenty < 0 and arcangle < 0) then current_quadrant = "2";end
       if (arc_currentx <= 0 and arc_currenty < 0 and arcangle > 0) then current_quadrant = "3";end
       if (arc_currentx < 0 and arc_currenty <= 0 and arcangle < 0) then current_quadrant = "3";end
       if (arc_currentx < 0 and arc_currenty >= 0 and arcangle > 0) then current_quadrant = "4";end
       if (arc_currentx <= 0 and arc_currenty > 0 and arcangle < 0) then current_quadrant = "4";end
    
       if (arc_endx >= 0 and arc_endy > 0 and arcangle<0) then finish_quadrant = "1";end
       if (arc_endx > 0 and arc_endy >= 0 and arcangle>0) then finish_quadrant = "1";end
       if (arc_endx > 0 and arc_endy <= 0 and arcangle<0) then finish_quadrant = "2";end
       if (arc_endx >= 0 and arc_endy < 0 and arcangle>0) then finish_quadrant = "2";end
       if (arc_endx <= 0 and arc_endy < 0 and arcangle<0) then finish_quadrant = "3";end
       if (arc_endx < 0 and arc_endy <= 0 and arcangle>0) then finish_quadrant = "3";end
       if (arc_endx < 0 and arc_endy >= 0 and arcangle<0) then finish_quadrant = "4";end
       if (arc_endx <= 0 and arc_endy > 0 and arcangle>0) then finish_quadrant = "4";end
       
       if (current_quadrant == finish_quadrant) then
       --if the move starts and ends in the same quadrant
          text("X"); number ( endx * scale, "0.0000")
          text("Y"); number (endy * scale, "0.0000")
          text("/X"); number ((arccentrex) * scale, "0.0000")
          text("/Y"); number ((arccentrey) * scale, "0.0000")
          text("n")
       else
          while (current_quadrant ~= finish_quadrant) do
          --finish point is not in the current quadrant
             if(arcangle <0) then
                if (current_quadrant == "1") then
                   new_current_quadrant = "4"
                   currentxval = 0
                   currentyval = arc_distancetocenter
                end
                if (current_quadrant == "2") then
                   new_current_quadrant = "1"
                   currentxval = arc_distancetocenter
                   currentyval = 0
                end
                if (current_quadrant == "3") then
                   new_current_quadrant = "2"
                   currentxval = 0
                   currentyval = -arc_distancetocenter
                end
                if (current_quadrant == "4") then
                   new_current_quadrant = "3"
                   currentxval = -arc_distancetocenter
                   currentyval = 0
                end
                current_quadrant = new_current_quadrant 
             else
                if (current_quadrant == "4") then
                   new_current_quadrant = "1"
                   currentxval = 0
                   currentyval = arc_distancetocenter
                end
                if (current_quadrant == "3") then
                   new_current_quadrant = "4"
                   currentxval = -arc_distancetocenter
                   currentyval = 0
                end
                if (current_quadrant == "2") then
                   new_current_quadrant = "3"
                   currentxval = 0
                   currentyval = -arc_distancetocenter
                end
                if (current_quadrant == "1") then
                   new_current_quadrant = "2"
                   currentxval = arc_distancetocenter
                   currentyval = 0
                end
                current_quadrant = new_current_quadrant 
             end
    
             currentx = currentxval
             currenty = currentyval
    
    	 --if (round3(arc_currentx,1) == round3(arc_endx,1)) then
    	--	text ("*******X=Xn");
    	 --end
    
    
             text("X"); number ((arccentrex+currentx) * scale, "0.0000")
             text("Y"); number ((arccentrey+currenty) * scale, "0.0000")
             text("/X"); number ((arccentrex) * scale, "0.0000")
             text("/Y"); number ((arccentrey) * scale, "0.0000")
             text ("n")
          end
          --we have moved into the finish quadrant
    
          text("X"); number (endx * scale, "0.0000")
          text("Y"); number (endy * scale, "0.0000")
          text("/X"); number ((arccentrex) * scale, "0.0000")
          text("/Y"); number ((arccentrey) * scale, "0.0000")
          text("n")
       end
    
       eol()
    end
    
    function round3(num, idp)
      local mult = 10^(idp or 0)
      return math.floor(num * mult + 0.5) / mult
    end
    
    
    function spindlecw()
       text (" M03")
       eol()
    end
    
    function spindleccw()
       text (" M04")
       eol()
    end
    
    function spindleoff()
       text (" M05n")
    end
    
    
    function newprocess()
       if (plungerate <= 0) then
          warning("WARNING: Plunge rate is zero")
       end
       if (feedrate <= 0) then
          warning("WARNING: Feed rate is zero")
       end
    end
    
    function toolchange()
       --text (" M6 T")
       --number (tool, "0")
       eol()
    end
    
    function spindlechanged()
       --if (spindlespeed <= 0) then
       --   warning("WARNING: Spindle speed is zero")
       --end
    end
    
    function newpart()
    end
    
    
    function floodon()
       text(" M08n")
    end
    
    function miston()
       text(" M07n")
    end
    
    function coolantoff()
       text(" M09n")
    end
    
    function drill()
       --Bandit Drill Cycle G83
       -- It will Move down to "DrillStart"
       -- Then it will Peck down "peckdepth"
       -- And rapid retract "retract"
       -- Until it reaches full depth
       -- then return to where it started
    
       rapid()
    
       modalnumber ("Z", (endz+drillstart) * scale, "0.000")
       text ("n")
    
       text ("/Z")
       number (drillz * scale, "0.000")
       text ("Z")
       number (peckdepth*scale,"0.000")
       text ("/Z")
       number (retract*scale,"0.000")
       text ("G83n")
       
       nonmodalnumber ("Z", (endz+drillstart) * scale, "0.000")
       text ("n")
    end

  9. #9
    Join Date
    Jan 2006
    Posts
    23
    Chris64
    Thanks for the info. I have a coworker that is helping me. He is also struggling with the way The Bandit controller does arcs. This should help out.
    I'll send you a PM with my email. In the future I'll probably go a simuliar route as you are with the upgrade, but right now I'll settle for just being able to make simple parts.

    J.

  10. #10
    Join Date
    Aug 2006
    Posts
    281
    Quote Originally Posted by jjclear View Post
    Chris64
    Thanks for the info. I have a coworker that is helping me. He is also struggling with the way The Bandit controller does arcs. This should help out.
    I'll send you a PM with my email. In the future I'll probably go a simuliar route as you are with the upgrade, but right now I'll settle for just being able to make simple parts.

    J.

    No prob. Emails sent to both of you. Let me know if you don't get it. My work email might not allow me to send EXE's (or your email might not allow you to receive it).

    The arcs are actually pretty easy (especially 90 degree arcs). Where it gets confusing is that it can't arc through 0°, 90°, 180° or 270° so if you need an arc that starts at 45° and goes CW to 100°, you need two arcs, one from 45°-90° and one from 90°-100°.

    I encourage you both to:
    1) get a graphics program that generates DXF files (this is very standard so there's lots of support)
    2) Get a simple CAM system like Sheetcam (There are others, just look at the software section of this forum). But you at least have the post file for bandit for sheetcam.
    3) use the program I sent you to upload the file. You can also use Hyper Terminal, but it's a pain.

    This is still not without it's problems, but it will make your life a lot easier.

    Even simple parts are a pain when you program them manually. Especially when you have to write a program that follows a basic arc contour with a .005 finishing pass offset using a .375 end mill. The math on this gets a little tedious.

    Also, my Bandit would default to G91 (relative mode), but when writing programs, I would recommend writing them in G90 (absolute mode). This way if you need to make a small mod, you don't have to edit other things to counter the affects of your change.

    Good luck.

Similar Threads

  1. Replies: 0
    Last Post: 12-02-2007, 02:43 PM
  2. Replies: 0
    Last Post: 12-01-2007, 10:37 PM
  3. kcam4 and pminmo l297-unipolar contr.
    By amakarevski in forum Uncategorised CAM Discussion
    Replies: 4
    Last Post: 10-31-2007, 04:28 PM
  4. Fanuc 9M data transfer problem
    By YOO in forum Fanuc
    Replies: 1
    Last Post: 01-18-2007, 03:26 PM
  5. Bandit level II~help requested
    By opua in forum DNC Problems and Solutions
    Replies: 10
    Last Post: 07-09-2005, 04:18 AM

Posting Permissions

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