Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Simple EEPROM Programmer through Parallel Port

Status
Not open for further replies.

mr.lemarc

New Member
Hi

Read through this forum for many months, to get supplement to my class studies. Unfortunately, I am now completely surrendering myself to your guys input, because I am truly out of breath and energy to push through any further with my lab project.

Here is my class' project objective:

--Design and implement the hardware and software of a simple EEPROM programmer with common TTL IC's that are mostly available. The EEPROM program is designed to connect to a standard PC's parallel printer port and work independent of processors speed. An assembly program to read and write data from/to the EEPROM programmer from a PC is also to be developed.

I have hard wired a schematic, using the following devices:

32Kx8 EEPROm ( ATC28C256)
4 74LS374
74LS257 Mux
74LS138 Decoder
Printer Cable DB25


the DB25
-- Base +0 address will be used to send output data that are used as address signals to EEPROM, data to EEPROM, and control signals to EEPROM

--BASE+1 address will be used to read 4-bit data from EEPROM

--BASE+2 address will be used to send 4-bit output to use as control and input signals of 74LS138 and select signals to 74LS257 MUX

Welll...

the hardwiring is pretty much taken care because we were given a general schematic and I have completed the actual wiring on my breadboard.

However, using the DOS system, I am completely stuck on how to read,write to the EEPROM. Data is to be verified correct, in our case , I will be using LED's.

But if you guys can figure a way to use DOS to read/write through the DB25, I am open to ideas.

I have spent the last few days trying to get this work, and have always failed at writing the assembly program.

Thanks.
 
mr.lemarc said:
anyoneee....?

hi,
Are you able to use Visual Basic 5, rather than the Assembler..?:rolleyes:

Also what operating system are you using. DOS X.X ? Is the PC just loaded with DOS, no Windows etc.

You will find it virtually impossible to verify the data looking at the data in the EEPROM, using LED's, for this size of memory.

EDIT:
Can you post the schematic, also showing the connections to the parallel port?
Which DOS Assembler program are you using?


Look here: **broken link removed**
 
Last edited:
what the instructor has suggested and as many are trying...

is to type up the code in notepad, use masm to load on a diskette

then load that diskette into the DOS system and run from there.
attached is the logicworks schematic (original post)
 
mr.lemarc said:
sorry,wouldnt let me. here it is

hi,
Looked thru your circuit design, sorry to say, your design is flawed and needs a redesign.:(

eg: The 374 clocking and selection, EEPROM R/W, CS and OE??... etc.

Are you planning to read the EEPROM in two nibbles.. some of the ParaPort inputs are inverted.

Who designed the circuit.?
 
hi,
A little more detail regarding your design.

1. You have linked ALL the LS374 latch 'clocks' together, ALL connected to the same 8 bit databus input.
Whatever data is on the bus will clocked into ALL the 374 at the clock pulse!.

2. The 374 /OEnable lines are connected to the 138 'one of 8' outputs.
How do you expect the EEPROM address to be 'held' steady during a Read/Write cycle ,
if you can only SELECT one 374 Address latch??

3. The 374 latch connected to the EEPROM control lines OE,CE and RW is also connected to the 138.
Will these lines be 'floating' if the 374 is not selected? [ this also applies to ALL the 374 outputs, when not selected, use PUR's]

4. How do you plan to select the 'READ' data nibbles via the 257, there are no control lines connected to the LS257.

The method I have used in the past, is to have the 374 latch clocks connected to the 138 selector.

1. Place the low address byte on the parallel data bus [ &378, D0 thru D7] ,
use a 138 select line to CLOCK the low address byte into the 374.

Repeat this for the high address byte. The EEPROM now has the data location address on its pins.

2. Place the 'data' on the parallel bus and use the $37A I/O lines to cycle the EEPROM's control lines [do a Write operation]

3. For a Read operation, if the PC's I/O port lines &378 are now SET as an input, use the $37A I/O lines to do a EEPROM Read.

4. If your PC's Parallel port $378 cannot be made a Read as well as a Write, you will have to Read two nibbles, using the 257 and the parallel port $379 four 'In' lines.

REMEMBER: the 4, $379 should be connected using 4 O/C buffers.

Hope this helps.
 
Last edited:
Another Schematic Design

Here is another Schematic Design you may want to look it. It is more updated and also has a few changes.


**pm for schematic** REMOVED IT
 
Last edited:
thanks

btw. thanks for such a detailed response....


ericgibbs said:
hi,
A little more detail regarding your design.

1. You have linked ALL the LS374 latch 'clocks' together, ALL connected to the same 8 bit databus input.
Whatever data is on the bus will clocked into ALL the 374 at the clock pulse!.

2. The 374 /OEnable lines are connected to the 138 'one of 8' outputs.
How do you expect the EEPROM address to be 'held' steady during a Read/Write cycle ,
if you can only SELECT one 374 Address latch??

3. The 374 latch connected to the EEPROM control lines OE,CE and RW is also connected to the 138.
Will these lines be 'floating' if the 374 is not selected? [ this also applies to ALL the 374 outputs, when not selected, use PUR's]

4. How do you plan to select the 'READ' data nibbles via the 257, there are no control lines connected to the LS257.

The method I have used in the past, is to have the 374 latch clocks connected to the 138 selector.

1. Place the low address byte on the parallel data bus [ &378, D0 thru D7] ,
use a 138 select line to CLOCK the low address byte into the 374.

Repeat this for the high address byte. The EEPROM now has the data location address on its pins.

2. Place the 'data' on the parallel bus and use the $37A I/O lines to cycle the EEPROM's control lines [do a Write operation]

3. For a Read operation, if the PC's I/O port lines &378 are now SET as an input, use the $37A I/O lines to do a EEPROM Read.

4. If your PC's Parallel port $378 cannot be made a Read as well as a Write, you will have to Read two nibbles, using the 257 and the parallel port $379 four 'In' lines.

REMEMBER: the 4, $379 should be connected using 4 O/C buffers.

Hope this helps.
 
hi,
That looks better, have you checked your PC for a bi-directional $378 [pins 2 to 9] data port?

Watch for the 379/A pins some are inverted.

Lets know how it goes.
 
Dos Code Now

I dont think the pins are bi-directional, and have accounted for the inverted pins.

I have a dos code in notepad form but I dont really want to publicly post up code.

So if you want, and have time, could you pm me your email and ill attach it there.

I cant seem to attach through a PM in the forums

let me know. thanks
 
Last edited:
hi,
To check your PC for a bi-directional $378 port, just in case for future use.
Write &2C to the Parallel Control port and then read &378.
Normally the operating system sets the Control port to &0C. [its bit 5 for I/O]

In the BIOS settings select EPP for the port.

It would be best if you posted your code as a *.asm to the forum, rather than directly to me, I am sure other members would like to participate.;)

I have not loaded the ASM86 or MASM assemblers into my PC for the past 15 years!!, I use Visual Basic Pro5.
I used to write all my programs in 8086/286 assembly about 25 years ago.:)

Regards

EDITED: added gif, ref grounding of output pins.
 
Last edited:
ericgibbs said:
hi,
I have not loaded the ASM86 or MASM assemblers into my PC for the past 15 years!!, I use Visual Basic Pro5.
I used to write all my programs in 8086/286 assembly about 25 years ago.:)

I also use VB5pro and also wrote in asm around 15-20 years ago. Can I ask why you use VB5 and not VB6? I have both and simply found no advantage with VB6 (except USB HID control) and found the non resident help a big setback in VB6.

Do you, or anyone else, know of an assembler that will allow me to write assembly DLLs that I can call from VB. I'm assuming that I will be able to write native 386 code and use the old GlobalAlloc type calls.

Mike.
 
Pommie said:
I also use VB5pro and also wrote in asm around 15-20 years ago. Can I ask why you use VB5 and not VB6? I have both and simply found no advantage with VB6 (except USB HID control) and found the non resident help a big setback in VB6.

Do you, or anyone else, know of an assembler that will allow me to write assembly DLLs that I can call from VB. I'm assuming that I will be able to write native 386 code and use the old GlobalAlloc type calls.

Mike.
Hi Mike,
Did you finish those cans before bedtime the other night?;)

I have never had a need to upgrade to VB6, most times when I play with a VB6 source file, I just knock out 'retained' etc and they run fine.

The odd routines in VB6 which are useful, such as 'replace' can easily be written in VB5.
All my text books are VB5 related, API's and Applications.

I write external modules for the Oshonsoft Simulator, which is compatible with VB5.
Have you written any ActiveX/DLL's using VB5, its pretty simple once you get used to the procedure.

What sort of programs do write with VB?
 
ericgibbs said:
Hi Mike,
Did you finish those cans before bedtime the other night?;)

Wrong continent, we have stubbies here.

I have never had a need to upgrade to VB6, most times when I play with a VB6 source file, I just knock out 'retained' etc and they run fine.

The odd routines in VB6 which are useful, such as 'replace' can easily be written in VB5.
All my text books are VB5 related, API's and Applications.

My bestest book is by Dan Appleman. He also didn't progress to VB6.

I write external modules for the Oshonsoft Simulator, which is compatible with VB5.
Have you written any ActiveX/DLL's using VB5, its pretty simple once you get used to the procedure.

I haven't, probably because I've had no need.

What sort of programs do write with VB?

These days, not much. I'm pretty much retired and just do stuff to keep me occupied. I'm currently working on (playing with) a serial GLCD pic circuit and a VB interface. You can draw in windows and see it on the LCD and then store the result in program memory. I intend to make it available to all when I get it finished. The bit I'm kinda pleased with at the moment is the radial line function - you send it a start position, length and angle and it (the pic) plots the line.

I'll attach it for laughs. It will hang if you try to load from file or rom but should give you an idea. Bugger, exe = not allowed.

Mike.
 
Here it is Zipped.

Mike.
Edit, just realised how unfinished that looks. It will get better.
 
Last edited:
hi Mike,
Missing a bmp from your exe.:rolleyes:
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top