-
2 Attachment(s)
Arduino Tape Drive Emulator for Fanuc 6
Neither of my Fanuc 6M Vertical CNC machines had a way to truly "drip feed" through the 25 pin serial port. The serial port was only used for transferring a program from an external computer into the NC's memory, and not for drip feeding commands as it is running.
It seemed the only way to run a very large program was through the old Paper Reel to Reel Tapes. After looking into the electronics of how the tape drive worked (and determining I had a bad head reader) I decided to find a way to make a Tape Drive Emulator so that I could use this machine with very large programs. I made am interface board that has an Arduino MEGA with an attached shield with a Network Port on one end, and a Multipin Ribbon Cable Receptacle on the other end. It has been in service daily for over 2 years now without an issue. It has been put to the test and the only limitation is the size of the micro SD card. With gigabytes to play with I didn't have any space limitations anymore.
Has this been a problem for anyone else? I'm trying to determine if I should document and share the information of how I solved this problem.
Barch Designs
877-201-9771
-
Re: Arduino Tape Drive Emulator for Fanuc 6
This is absolutely of no use to me, but this kind of info would be priceless to someone struggling with a similar issue, so yes, please document it and post it as I'm positive others will find it useful at some point!
Better to have it and not need it than need it and not have it I reckon.
cheers, Ian
-
Re: Arduino Tape Drive Emulator for Fanuc 6
I agree, sounds like an awesome upgrade. Just the sort of thing that makes cnczone a great place.
Sent from my LG-D852 using Tapatalk
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Let me get clearer, Is anyone actually looking to put a Behind the Tape Reader (BTR) on a Fanuc 6 control, or is it a theoretical problem that could exist? I'm thinking of having a small run of professional circuit boards made to replace my prototypes, and I'm wondering if anyone would pay money for this Interface Board solution? I have to make about 10 of them to fill the minimum PCB order. If it really isn't an actual problem I'll just leave my prototypes in the machines as-is, but...
I would love to take the project further to include features such as
* Display % finished
* Current line output
* Control mid program starts
through a web app interface (Control it with your cell phone). I can only justify taking the time to work on the project though if it will directly help someone else.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Ahh, well I'm not. I just thought a post of the arduino sketch and a quick diagram or description of the connections would be invaluable to anyone else that may stumble upon this in the future.
I would think you could add all those features in the sketch relatively easily (except the last one maybe).
Sent from my LG-D852 using Tapatalk
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Can you please share the arduino sketch with schematic so I can use it to DNC my fanuc 6M ?
-
Re: Arduino Tape Drive Emulator for Fanuc 6
CAN we increase the baud rate between this BTR and the 6M? i have a BTR whose baud rate is fixed....the machine halts in between very small straight lines ...while simultaneously moving x , y and z axes..
-
Re: Arduino Tape Drive Emulator for Fanuc 6
BTRs have been around since the '80s. The Baudrate is between 150 and 600. Doubtful that there is much demand for yet another BTR.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
My feeling from this thread it most people think it may be useful for someone else, but I haven't seen a need for it by anyone personally (as memoryman said, yet another BTR). On my particular 6M machines the baud rates are selectable up to 1,200. I've pushed it a bit beyond that manually, but any faster and it starts skipping characters. The electronics just don't go faster than that on a 6M. I also get the small pauses when running a program with many lines of short distance. Best thing I have done with the Arduino is parse each line to remove any unneeded characters before it even gets sent to the machine (Line numbers, comments, etc). Second best thing is optimize your toolpath to use arcs instead of many small straight lines (Some CAD programs are notorious for generating arcs as many small lines)
The biggest problem that was solved for me was running a 2 Million Byte file on a machine with only 32 Thousand bytes of memory. I can run the whole program from start to finish through the Arduino BTR. Where as before I would have to break up the program into many small pieces and send it over to run each piece at a time. I have eliminated the time it took to transfer the program from a computer to the Fanuc memory each time, and I don't have to be there to keep changing to the next "chunk" every hour. I can now start my machine and walk away for 8-12 hours.
As a home shop I needed to find a cheaper solution than a expensive industrial BTR (which I know are just simple electronics and you're paying for the convenience of someone else building it for you). The Arduino and some 1/8 watt resistors are basically all it took to build the prototype.
Barch Designs
877-201-9771
-
I am in need of this arduino based BTR for replacing my old BTR running at 300 baudrate...unfortunately there is no jumper at all or any other switch to increase the BTR...
I do appreciate your efforts in building it so..would be grateful if you share the arduino sketch and the schematic
-
-
Re: Arduino Tape Drive Emulator for Fanuc 6
could you share your work...?
I need to build something alike to drip feed to my Fanuc 6M
-
Re: Arduino Tape Drive Emulator for Fanuc 6
I used the device IIN-DNC from STRAUS company which safely works before 38400 bits/sec baudrate. Reach such speed allows the double data buffering and built in Windows kernel the DNC software. This BTR device has an interfaces for RS232 and PTR+PUNCH connections, supports the all CNC protocols.
Manuals for it here:
IinDoc
Sorry, that much from it in russian.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
the btr baud rate is limited to the 6 control's tape speed; I think the maybe 600 Baud.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
does any body has details of 50 pinout on the fanuc main board...and the timing diagram of this port while it receives data from tape ..which pdf manual should i search?
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Quote:
Originally Posted by
memoryman
the btr baud rate is limited to the 6 control's tape speed; I think the maybe 600 Baud.
PTR interface in 2.5~3 times slowly than RS232C. For increase the baudrate it is necessary remake the interface PTR (CAT). Need to do that could read symbols under short pulse SP (sprocket). The Second way, add the patch to software for activation Drip Feed to RS232.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
can any body share or guide about the 50 pinout of the fanuc main board which receives data from the tape reader.....also i need the timing chart of its communication
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Hi, We didn't use a protocol. We literally just turned the 9th pin high or low by a delay function. The Fanuc tape reading head just turns 8 wires high or low and the 9th wire is like a firing pin. The Fanuc reads the 8 wire states when the 9th pin is active. I believe we found around 1 millisecond on and off worked about as fast as Fanuc would read it.
The arduino sketch just reads a text file character by character and then looks up the cross reference table to see what state the 8 pins should be in for that character. The arduino sets the state of those 8 pins and then makes the 9th pin active (I believe it was active low) for the delay time (just long enough for it to be read by the fanuc transistors.) To eliminate wasted time by sending non-movement characters such as comments and line numbers we also added a preview function to strip those characters before sending anything to the fanuc.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
bar, thank you for the information. Yes I saw the 8 bit likely driving lines, not aware of the 9th pin. Also, good to know you use a lookup table. I saw the characters table on the manual.
I think I can do it now with your information and the manual.
I will start doing some tests.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
There are several btrs on the market and have been for decades. I have been involved in two designs. The 9th signal is the sprocket signal. A friend at another company told me 20 years ago that they could read ~600 chars/sec.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
*paing* In my Arduino project I had to also use a 10th wire (works like CTS, Clear to Send) that is driven high and low from the NC side which the Arduino needs to listen to. It tells the Arduino when the NC is ready for data, and when to hold from sending data.
*mem* Thanks for sharing. wouldn't this equate to 4,800 baud then. 8 bits/wires for every character @ 600 characters per second? So I guess the tape reader has a baud rate of 4800
-
Re: Arduino Tape Drive Emulator for Fanuc 6
That's what I was wondering about know when the NC is ready for more data...
My plan was to check the schematic at home, but glad you xplained here.
Thank you!
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Will this work for a yasnac 2000B?
-
Re: Arduino Tape Drive Emulator for Fanuc 6
I'm not familiar with Yasnac controls, but I would guess it would be a similar process if the tape drives are similar technology. Basically all I did was look at how the reading head worked at the paper tape and then mimicked it electronically with an Arduino. Once I had that the rest was easy.
-
Quote:
Originally Posted by
barchdesigns
I'm not familiar with Yasnac controls, but I would guess it would be a similar process if the tape drives are similar technology. Basically all I did was look at how the reading head worked at the paper tape and then mimicked it electronically with an Arduino. Once I had that the rest was easy.
awesome! Did you send your gcode to the ardunio via USB or did you have to use a USB to rs232 serial adapter and send it through a max3232 chip mini board? Also on the output did you wire striat from the ardunio to the tape reader head or did you have to use a 74hc595 shift register? And can you email me the C++ program script? [email protected] I have no experience with the C++ programing, also I'm just using a ardunio uno V3
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Look closely at the pictures and you can see where I added an SD shield with Network on top of the Arduino. This allows the Arduino program to just read a text file right from the SD card. No need to "transfer" a program. It's completely independent from a computer. Just put your Gcode on the Sd card and pop it in. (Later we added an option to transfer a file over the network, but I actually find popping the SD card in and out is sometimes faster.)
Unfortunately my Arduino code is not open source at this time. For the prototype we wired straight (with resistors) between the Arduino and Fanuc 50 pin connector where we traced the read head wires back to. In the future I would recommend to opto isolate this. You'll have to check to see if your read head wires go straight to a connector or through some other circuitry first.
-
Quote:
Originally Posted by
barchdesigns
Look closely at the pictures and you can see where I added an SD shield with Network on top of the Arduino. This allows the Arduino program to just read a text file right from the SD card. No need to "transfer" a program. It's completely independent from a computer. Just put your Gcode on the Sd card and pop it in. (Later we added an option to transfer a file over the network, but I actually find popping the SD card in and out is sometimes faster.)
Unfortunately my Arduino code is not open source at this time. For the prototype we wired straight (with resistors) between the Arduino and Fanuc 50 pin connector where we traced the read head wires back to. In the future I would recommend to opto isolate this. You'll have to check to see if your read head wires go straight to a connector or through some other circuitry first.
OK cool, I'm going to try the rs232 route if I can't get it to work I'll go the SD card route, yeah mine doesn't go from the reader head to the main control boards it goes from the reader head to a small circuit board and then to the main control board, I was going to unhook the photoelectric sensors on the reader head and wire in 8 small relays just like the sensors are wired and let them open and close in the same way the photoelectric ones do, that is if I can't wire it direct, I've ordered enough stuff to try it several different ways this stuff is so cheap on eBay why not 😀 I can't wait to get it all here and start tinkering with it, I think writing the C++ code will be the hardest part for me, thanks for the info!
-
Re: Arduino Tape Drive Emulator for Fanuc 6
My reader head went to some circuit boards too, but when following the traces along the circuit board, the reader head wires were just routed directly to the 50 pin on the circuit boards....look closely and you may find the same thing.
-
Quote:
Originally Posted by
barchdesigns
My reader head went to some circuit boards too, but when following the traces along the circuit board, the reader head wires were just routed directly to the 50 pin on the circuit boards....look closely and you may find the same thing.
OK I'll check it out and see, thanks for the information, I'll probably have a few more questions in a week or so.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Is your ardunio outputting EIA RS244-A or ISO Tape format?
-
Ok, I'm decided to build the interface.
Have dismounted the tape reader, in my case is a A13B-0070-B001 unit, and have in the workbench.
Noticed it have the PCB A20B-0007-0750/078
I'm currently looking for the A20B-0007-0750/078 board schematic, it will make easier for me to understand how this thing deliver the output (active low or high) and all signaling. Anyway, started to desolder all the chips to make it easier to draw the schematic by hand,.
The only part I can't find the specs is the resistor network chips 40-1-98, SIP 6 pin.
It couples the light detectors with the LM339 comparators. The ohm readings are odd, not the usual resistor chips. looks it has 2 independent sections: pins 5 & 6 is a single 17k resistor while the pins 1,2,3,4 form some sort of bridge circuit or something else as the ohm readings are not easy to understand...
https://s32.postimg.org/6lv1w9i0x/20160706_194043.jpg
https://s32.postimg.org/drmsypr41/20160708_092744.jpg
https://s32.postimg.org/98f5qxym9/Chip_Resistor.jpg
-
Quote:
*paing* In my Arduino project I had to also use a 10th wire (works like CTS, Clear to Send) that is driven high and low from the NC side which the Arduino needs to listen to. It tells the Arduino when the NC is ready for data, and when to hold from sending data.
barch, wich one signal from the 50 pin cable use you to listen from the NC to hold/send data (as your 10th wire)...?
I will use the next pins:
Code:
IDC# NCconn Function
1 A1 D0
3 A2 D1
5 A3 D2
7 A4 D3
9 A5 D4
11 A6 D5
13 A7 D6
15 A8 D7
17 A9 Sprocket
Other Available pins (from NC)
IDC# NCconn Function
19 A10 /Error
21 A11 Ready or RDT
23 A12 *RWT
25 A13 Feed or FDT
27 A14 OPT
29 A15 *RWDT
31 A16 *CLT
33 A17 *RVT
Fanuc number the 50 pin ribbon pins as A1, A2, A3 where actual connector numbers are 1, 3, 5 etc. B1, B2, B3 are actually 2, 4, 8.
* From an old interface I have (broken), it uses D0..D7, SP and Feed.
* From the real Tape Reader I can see it uses D0..D7, SP, Feed, Ready.
So, wich one signal did use you to know when the NC wants or not wants more data (/Error, Ready, Feed)....?
-
Re: Arduino Tape Drive Emulator for Fanuc 6
Ok, everything is ready now. First test with the DIY interface did not work. I overlooked the ASCII chars must be converted to 7 bits + 1 parity bit for the D1-D8 so the NC can understand it.
I also readjusted the Sprocket timings and the character separation. Have done simulation from 50 pin end, full circuit test and now everything goes fine. Tape feed pin is pin#25.
Comments are also stripped out.
Will test this weekend on the real 6M controller.
-
Re: Arduino Tape Drive Emulator for Fanuc 6
This tape drive emulator could be used by any machine that uses this kind of tape reader. I feel like this hardware/software solution should be shared outside of just FANUC 6
-
Re: Arduino Tape Drive Emulator for Fanuc 6
I see a lot of potention in a microcontroller as a tape emulator. It also makes convenient MDI-typing possible on older controls. By using a Raspberry a screen and keyboard can be easily attached and also resuming from 'tape' (starting with last toolchange for example) can be easily done.
Is opto-isolation needed of some kind?
-
This thing works! Drip feed is now possible.
Ran a large program thru own software, using the micro as translator.
-
Could barchdesigns or someone else share this work with me as I need the same solution with FANUC SYSTEM 5 with no memory at all.
-
Quote:
Originally Posted by
ppaing126
This thing works! Drip feed is now possible.
Ran a large program thru own software, using the micro as translator.
paing
Could you please let me know 9th and 10th pins from NC side you used.
-
2 Attachment(s)
Re: Arduino Tape Drive Emulator for Fanuc 6
Hi guys,
So a friend of mine bought a Takamatsu with a Yasnac 2000G and a dead West Controls BTR.
I took the BTR home and took it apart as much as I needed to replace the ICs and socket them. While I was working on it any way, I made a schematic in Kicad of the board. It's a work in progress, and I still have the board layout to do. You are welcome to read it, use it, and poke fun at it (and me). Just not complain about it if you are silly enough to create PCB boards off of it without breadboarding it first.
The files that I have included should be all that you need, but I included a PDF for you as well. If I missed anything please let me know.
Enjoy!
-
2 Attachment(s)
Re: Arduino Tape Drive Emulator for Fanuc 6
So I fixed Thurston's board. Which consisted of removing all of the chips, installing sockets, fixing two blown traces, and putting in new chips. By all appearances it works.
However this "working" lathe that he bought, had the blown BTR as well as the serial cable for it has the common/ground connected to pin 5 rather than pin 7. So I can't imagine how it was supposedly working...
I re-did the schematic (and corrected a slew of errors on my part) as well as created a connection cross reference. Enjoy! :)