How to program a RAM chip using an external file inside Proteus simulator ?

dl324

Joined Mar 30, 2015
18,333
Very simple and direct, to program or communicate with them.
I have a laptop running WinME that I use for my EPROM programmers. I have a half dozen or so that are called Willem (or compatible) EPROM programmers after the person who popularized them. I was a moderator on his website, but I lost interest when he died.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
Im curious now... if these EPROM programmers that you have, are universal. Meaning if it can be adapted to load data into any modern device. Like RAM or a PIC MCU perhaps?
I never managed to acquire an universal programmer that can program all types of microcontrolers, from diverse brands, including microchip and more other. Ive seen some, I cant remember their names, and are still used today on the newest MCU's by some veterans. Im not one, but I like the things that worked in the past and still work even today.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
Ive checked that as well. Yes...
I have a problem. Are these toggle buttons intended to be clicked with the mouse? Or they move from some command elsewhere?
If im clicking them with my mouse, they wont toggle. None of it, not even the yellow one.
I managed to load the chip though !!!
1661657782420.png
 

dl324

Joined Mar 30, 2015
18,333
I don't have any pictures handy on this computer, but I had the component diagram for his latest programmer:
Willem4v1.jpg

The switches you highlighted are at the lower right corner of the board. When you select a device, the program tells you how to set the switches. Setting switches incorrectly can do bad things to the devices or boards.

The yellow thing on the left is a jumper setting.

It doesn't matter for what you can do with the program. The switches and jumpers route signals to the correct pins on the sockets.

The only thing you have to do is select a device of the appropriate size because the program will only read that much data and that's how much data it will write.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
also none of these textboxes are editable
although I understand when something is gray out is not supposed to work...but Im putting this info as well here.
1661658323093.png
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
My best 'educated' guess, is that I have to write the program by hand in most probably binary or hexa form,
and use this program to verify each line (probably), and only export to a *.bin file that can be loaded into my Proteus simulator.
- I am right?
but how this "code in binary" should look like? Give me an example.
 
Last edited:

Ian Rogers

Joined Dec 12, 2012
1,136
Unfortunately you are correct.. I've been working on a sine rom for a frequency generator so all the values have to be typed out.

BUT I generated the file in excel sine and triangle, then copied into a text editor and used a home brew program to read this and convert to binary..

I have a program called ZTW ( Z Tree for Windows ) Z tree is ancient but I love it to bits...
My programmer is the XGecu ProTL868 II the software is free..

I also have many home brew editors that do what I want them to do as I said before.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
Thank you mister @Ian Rogers for the straight answer. I really dont care how old a software is or how it looks. I only care how well I can resolve my problems with it. To be clear, im one of those practical guys, and not the theory and mythology guy.
I am much learning this as I kind of remembering stuff back in the days, but the memory is extra blurred. Thats why I need some help in reactivating the old ways if I can call them that.
Can you give me what you usually use and find most useful ? The things you mentioned already. Both commercial and custom home made? For me is very illuminating and fascinating how people are usually working. Especially people like you, all the guys here, that are actually engineers, not like me a poor artist (literally). I learn the best this way. By imitating your style of doing things.
Also very important to me at this stage is to actually see a file that you create, a test 'code', --before-- you transform it into *.bin with your program. Put it into a zip file or here in the code section of your answer panel.
Thank you.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
I find your A Tree for windows or ztw v2.2 But from what I can observe, it might be very much a trial 30 days. Aaaah. I will take it anyway and see why you like it so much.
1661683801418.png
I also find the XGecu ProTL866 II (not 868) version 1215
1661684001982.png
With this occasion check your versions as well.
Im waiting for a file from you that can be inserted into the converter. To get the idea how it should be.
....
1661684428494.png
 
Last edited:

Thread Starter

q12x

Joined Sep 25, 2015
2,227
Ive installed and they are running both your programs !
So...how do I make a file that can be converted with these programs? I mean what kind of content should I put in the main file? Simply binary? like 0b00000001 ? and multiple addresses for the RAM like this: 0b00000001; 0b00000001; 0b00000001; where ';' represents the new address? or something... at this point is very unclear how the format should be.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
I believe.... this ZTree program is pretty much like my Total Commander I use even today, but this one is the very old school version, I remember this kind of commander I used in DOS mode, in windows 94-95 or even earlier windows having processors like 386 and 486. I remember it very well from those times. The computer I was using was branded as Hewlet-Packard and it come with mouse, monitor and keyboard and also a printer - that was the standard those times. From America direct. It was a family friend. Also it had games thats why I was all day on that PC and the poor man had to support me in his home, but I was a cute child so he let me stay as much as I wanted... actually probably from those times I stay all night all these years, haha.
Anyway... back to the bizniz, Im not completly sure how you are transforming with a commander, a file type into another. It may have a special function just for that probably. Very weird since I cant remember everything. But I remember something.
1661686033631.png
 

dl324

Joined Mar 30, 2015
18,333
How do I write the program with it ?
The edit feature in the Buffer tab doesn't seem to work on Win10. On Win98/ME, you just click or double click (can't remember which) on a data location and change the data. Obviously that would be tedious if you had a lot of data to enter/change.

If something is too tedious to do manually, I write a combination of scripts and/or programs to do it for me. The table in the Proteus files in that other thread were entered manually. When I wanted to program an M27C4002 with the conversion table, I wrote a program to create the .bin file. Then I used an Arduino Mega to verify that the programming was correct.
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
Im using 2732 RAM chip.
Lets put 4 outputs for 4 Adress pins. On A0 to lit D0, on A1 to lit D1, etc.
I want the file, or the code, that is BEFORE the *.bin conversion.
I know I am very clear and that you get it very clear as well....
Here is my test circuit:
1661699032774.png

The edit feature in the Buffer tab doesn't seem to work on Win10. On Win98/ME, you just click or double click on a data location and change the data.
Im using w7 here and it is not working to edit that Buffer cells too.
I will use manual 'coding' anyway. Like I mentioned already.
 

dl324

Joined Mar 30, 2015
18,333
Im using 2732 RAM chip.
Technically this is an EPROM (Erasable Programmable Read Only Memory). RAM is Random Access Memory; it could be static or dynamic.
Lets put 4 outputs for 4 Adress pins. On A0 to lit D0, on A1 to lit D1, etc.
This is a small amount of data and easy to enter manually.

You have to tie the unused address lines LOW.

So you want a look up table that gives:
Code:
Address  Data
      1  0x01
      2  0x02
      4  0x04
      8  0x08
 

Thread Starter

q12x

Joined Sep 25, 2015
2,227
Not working
my first code that I put to be transformed into bin was this:
Code:
0001
0010
0011
0100
The second code that I put to be transformed into bin was YOUR code that you just give me :
Code:
0x01
0x02
0x04
0x08
Neither worked !
This is the bin file that is generated:
Code:
0x01
0x02
0x04
0x08ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ
....
and in proteus, the Output bits are random.
 
Last edited:

dl324

Joined Mar 30, 2015
18,333
The data I gave you represented the data in hexadecimal format. If you replace 0x01 with 1 it should work.

This circuit will do the encoding you specified:
encode1.jpg
Where D = A3, C = A2, B = A1, and A = A0.

The logic could be simplified, but I left unsimplified so you can see the pattern more easily.
 
Top