Ardunio tape reader emulator

Can someone give me some guidance on making a tape reader emulator? I'm wanting to wire into the tape reader head so in theory all I should need is for the ardunio to output EIA - RS244-A binary format, the tape reader is a sanyo denki 2301C, the CNC control is a yasnac 2000B,
I have a serial to parallel 74HC595 8bit shift register chip coming, and a ardunio mega coming also, can you all tell me what else I will need? Thanks

Hi,
Is this a "Paper Tape" reader?? Is the output from the tape head parallel bits?

As I recall there were 9 holes (parity?) and if you have 9 parallel bits you can just read them with digital inputs.

I think you'd need 'parallel to serial' if you were going to use a shift register to connect to the reader. But Why?

It's not clear to me what you want to do. Do you want to fake/replace an existing tape reader head only, or replace the entire tape reader and output bytes via RS-244?

Where do you want to store your "tapes", on SD card?

@terryking228: 8 channel paper tape has only 8 bits, and a continuous transport track, no additional parity channel.

Here is the manual for CNC control yasnac 2000B
http://www2.i-logic.com/manuals/Yasnac2000.pdf

Here are some detail info that you can read

The Advanced Machine Interface (AMI) is designed to operate as a universal paper tape
emulator capable of dramatically increasing the performance of a Numerical Control
(NC) or Computer Numerical Controlled (CNC). The industry term for a device
interfacing via a controls tape reader interface is “Behind the Tape Reader” (BTR) adapter. The
AMI can be used in single control configuration or in multiple control networks

I'm wanting to send programs from my DNC software to the CNC machine with the ardunio as if I were running paper punch tape through it by wiring to the 8 or 9 sensors on the tape reader head, I'm wanting to make a BTR behind the tape reader but I Dont care if the tape reader works or not I just need a way to program it other than paper tape or MDI. Different places are wanting a war price for a BTR its late 70's early 80's tech that shouldn't be more than $30 or $40 bucks and they're asking anywhere from $1000 to $4000 for a BTR, that's not an option for me I only gave $200 for the old CNC lathe I think one can be made pretty easy with an ardunio. And who doesnt like making ardunio gadgets?

Btw I went with the ardunio uno rev3 instead or the mega

I still can't see what you want to make. Can you draw a diagram with all the components you want to retain, and where you want to connect the Arduino?

I'll try and explain it better, the tape reader is on an old 1979 mori seiki SL1 CNC lathe the lathe has a yasnac 2000B control the only way to program the control is by MDI manual data input or with the old EIA- RS244-A ACSII punched paper tape through the tape reader, the tape reader has a light bulb mounted right above where the tape runs through as the tape is run through it the light shines through the punched holes and activates the light detecting switches and sends the program to the control bit by bit from the 8bit paper tape, I'm wanting to wire into the light detecting switches and fool it into thinking I'm running paper tape through it when in reality I'll be sending it a program from my laptop by means of my cad-cam software and CNC editor software via RS232 serial communication, so I need to send my Gcode to the Ardunio from my PC then have the Ardunio convert it to ASCII EIA-RS244-A format and output it to 8 wires that I can wire into the light detecting switches on the tape reader head, I think there is a 9th wire that needs to be held high while the program is being received also. I just need to ad a RS232 port to this old CNC lathe I Dont need to be able to receive code from the lathe I just need to be able to send to it.

Okay, you want to hack the tape reader head, right?

For that purpose you have to add some electronic to override the light detecting switches. The simplest approach IMO is an array of 9 LED, which replace the light bulb and fake the light/dark sections of the tape. 8 LED are for the data, another one for the transport clock (latch signal). Do you think that you can modify the reader this way?
The best color of the LED has to be figured out, it may be IR as well.

For the software, do you have any idea how to convert the serial input data into RS-244 format? When you save the files in RS-244 format, no special handling should be required, you only have to map each of the 8 data bits into the right LED.

Another item is the tape speed. Do you have an idea, how fast a tape runs through the reader, i.e. how many characters per second?

Finally the begin and end of the tape must be handled. Some readers have another switch or sensor for that purpose, which starts the transport motor when a tape is detected, and stops the motor and ends the transmission at the end of the tape. Eventuall only 7 LED are required for the data, with the parity channel ignored. so that one LED could be used for the "tape present" signal.

Can you operate the reader without a machine attached to it, for testing purposes?

Exactly I want to hack the reader head, can I just do away with the light detecting switches and wire strait into the wires? It’d be kind of tight to mount the LEDs in there, and yes I’ll have to do some research on the start stop byte or bit, the reader is mounted to the machine I’ve never tried to use it because I Dont have any punch tape, I’ll have to figure out the clock speed also, but it won’t be a problem for the ardunio to convert the format?

For a direct connection you have to find out the signal levels, produced by the sensors in light and dark state. Most probably the sensors are followed by an amplifier, where it may be easier to enter the Arduino signals into/after that amplifier. In either case you have to determine the common (ground) line and polarity. What can you find out?

I'll have to do some testing and see if they're running through an amplifier, im sure they're just be closing to ground or power if that's the case can I just use an array of relays? Do you think they'll react quick enough?

Did a tape emulator back in the 80's using an xt pc with the parallel port.

You will also have to look at other signals coming from the cnc. Is the cnc telling the t.r. to go forward or backward or stop?

Since the cnc will be reading from the t.r. while running you should be very careful or some damage may result if a bit or two is misread.

If this is just your own and you will be running it then "playing around" will be fun but if this is in a shop where there are others or someone else will be running it then why not get a ready made B.T.R and skip the headaches and start making money.

NC machines may read the tape directly, but CNC machines most probably read the program into their memory and execute it from there. Otherwise it doesn't make sense to connect a single tape reader or control computer to multiple CNC machines, as shown in the various connection diagrams.

Yes it'll just be me running it in my garage, and it is a NC control, but I think you can set it to read the tape directly or store it to memory then read it, and buying a ready made BTR isn't an option for me they sell for way to much $ and I'd never justify buying one because I just tinker with the machine I Dont make $ with it.

Remember what "DNC" means and then you will understand that even on some modern cncs there is only so much memory. A large file will chew up that memory pretty fast and on that OOOOOOLD controller of the OP there is just enough for a basic program.

Hacking the tape reader head with LEDS is kind of silly IMO. You will still need to read other signals produced by the cnc so then you might as well produce the digital signals directly all on the connector lines.

You might be a little confused on those connection diagrams.

Yeah I'll just be doing simple machining on that old machine I just got it to play with, I'm thinking that replacing the light sensors with little relays and wiring it just like its wired now is probably the way to go, I'll have to do some research on the feed tape, rewind tape & stop tape signals, someone already made one on cnczone that works great but I haven't had any luck contacting him yet, he wired strait to the wires going to the sensors and held a 9th wire high while transferring data. I think I can figure it out with time, I was just hoping someone could shine some light on the subject that has more knowledge on it than me. and you all are thanks