Would you like to react to this message? Create an account in a few clicks or log in to continue.

You are not connected. Please login or register

Ram and 74HC670 and 74xx170

3 posters

Go to page : 1, 2  Next

Go down  Message [Page 1 of 2]

1Ram and 74HC670 and 74xx170 Empty Ram and 74HC670 and 74xx170 Sat Jan 30, 2021 2:20 pm

Mistral



Hi, I am trying to simulate Ben Eaters Z80 project. I am at the Ram-module now - https://eater.net/8bit/ram
The Ram in Simulide has no Qn outputs so I can't use it but the package on itself works fine after trying. Because I can't use the Ram I wanted to use the 4x4 registers 74HC670 and/or the 74xx170 which are both available in Simulide. I hooked everything up and tried for almost two hours to get the Q-outputs high but it doesn't seem to work. My software version is 0.4.14-SR4.
Does anybody have the same problem or no problem at all?
Please let me know. Thank you.

Ram and 74HC670 and 74xx170 ZCP6KYj



Last edited by Mistral on Sat Jan 30, 2021 3:44 pm; edited 6 times in total (Reason for editing : Tried to add picture)

2Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Jan 30, 2021 4:06 pm

arcachofo

arcachofo

HI.
You are right, there is some problem here.

Let me have a look.

3Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Jan 30, 2021 4:48 pm

arcachofo

arcachofo

Yes... there is a bug that afects a few subcircuits.

Fortunately there is a workaround.
Attached a .zip containing "ic74" and "icCD" folders.

Go to: SimulIDE_0.4.14-SR4_xxx/share/simulide/data
And replace those folders (with simulide closed).

After that 74HC670 and 74xx170 should work normally.
Attachments
Ram and 74HC670 and 74xx170 Attachmentdata.zip
You don't have permission to download attachments.
(356 Kb) Downloaded 4 times

4Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Jan 30, 2021 6:37 pm

Mistral



@arcachofo

I tested both of them and the 670 is acting according to the datasheet but the 170 is yet not.
In the picture below they have the same input set up but the output of the 170 is not responding.

I want to thank the makers and the helpers of this program. I like it very much.

Have a nice evening.

Ram and 74HC670 and 74xx170 IbVOFDJ

5Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Jan 30, 2021 8:15 pm

arcachofo

arcachofo

It is working for me.
Remember that the 170 is open collector.

6Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Mon Feb 01, 2021 9:44 am

Mistral



Ok, I'll take a closer look. I continued with the 670 so I didn't have to use the 170. 

*****

I changed my test and leds are on now, everything okidoki. 
My mistake, sorry.
Thanks.

7Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Wed Feb 10, 2021 10:59 pm

Mistral



IC 74HC173 is missing its MR pin.
Not a big problem but it was used in Ben Eaters' previous mentioned breadboard project that I am trying to simulate. I almost finished it, you can check my github page and I also made public on Tweakers the things you can do with Simulide, see the read me. As a favour in return for using your software.

https://github.com/Alectus/Z80-Breadboard-Simulation

8Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Thu Feb 11, 2021 12:00 am

arcachofo

arcachofo

Wow... great project.

IC 74HC173 is missing its MR pin.
There is an error in the Logic Symbol package file.

Fortunately it is easy to solve:
Edit file: SimulIDE_0.4.14-SR4_Win64/share/simulide/data/ic74/74HC173_LS.package
With this content:
Code:
<!DOCTYPE SimulIDE>

<package name="Package" pins="14" width="4" height="12" >

    <pin side="left" pos="1"  type="" id="D0"  label="D0" /><!-- packagePin1 -->
    <pin side="left" pos="2"  type="" id="D1"  label="D1" /><!-- packagePin2 -->
    <pin side="left" pos="3"  type="" id="D2"  label="D2" /><!-- packagePin3 -->
    <pin side="left" pos="4"  type="" id="D3"  label="D3" /><!-- packagePin4 -->
    <pin side="left" pos="5"  type="" id="MR"  label="MR" />
    <pin side="left" pos="6"  type="" id="CP"  label="CP" /><!-- packagePin5 -->
    <pin side="left" pos="7"  type="inverted" id="!E1"  label="!E1" /><!-- packagePin6 -->
    <pin side="left" pos="8"  type="inverted" id="!E2"  label="!E2" /><!-- packagePin7 -->
    <pin side="left" pos="10"  type="inverted" id="!OE1"  label="!OE1" /><!-- packagePin8 -->
    <pin side="left" pos="11"  type="inverted" id="!OE2"  label="!OE2" /><!-- packagePin9 -->
    
    <pin side="right" pos="1"  type="" id="Q0"  label="Q0" /><!-- packagePin10 -->
    <pin side="right" pos="2"  type="" id="Q1"  label="Q1" /><!-- packagePin11 -->
    <pin side="right" pos="3"  type="" id="Q2"  label="Q2" /><!-- packagePin12 -->
    <pin side="right" pos="4"  type="" id="Q3"  label="Q3" /><!-- packagePin13 -->
    
</package>

Next time you open simulide MR pin will be there.

When you get it finished you could add it to this section:
https://simulide.forumotion.com/f12-projects-made-in-simulide

9Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Thu Feb 11, 2021 4:50 pm

Mistral



Thank you for your amazing software.
I am not completely going to finish it. Because of a different Ram in Simulide there are no q-pins and so the program I would have to use is slightly different then Bens', at the ram (top left in my set up) it needs an extra clock pulse to move data on the bus. This is the original:
https://eater.net/8bit/ram
That means I would have to rewrite some things from his original program that is ready available.
https://github.com/beneater/eeprom-programmer
Maybe, with a lot of effort I could manage that but for now I rather spent my time on something else then programming. Of course if somebody else wants to finish it than he or she is welcome. After I check everything again I will put it in the section you mentioned. I think by next week or so. Just now I added the 8 chapters together in Github, here is the picture of the total. And also the .simu-file.
https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/8%20Chapters%20together.PNG

https://raw.githubusercontent.com/Alectus/Z80-Breadboard-Simulation/main/8%20Chapters%20together.simu

What you see in the picture is the result 42 like in Bens video no.36 at the end :
https://www.youtube.com/watch?v=dXdoim96v5A&list=PLowKtXNTBypGqImE405J2565dvjafglHU&index=36



Last edited by Mistral on Thu Feb 11, 2021 6:18 pm; edited 6 times in total (Reason for editing : added some links)

10Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Thu Feb 11, 2021 6:06 pm

arcachofo

arcachofo

That is a great project, I can't believe you made it work in simulide.

74189 is already implemented in development version:

Ram and 74HC670 and 74xx170 7418910

11Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Thu Feb 11, 2021 6:54 pm

Mistral



I didn't know if it would work either. Just went along with Bens'steps, which are modular and tested piece by piece and just wanted to see how far I or Simulide could get. The only real difficulty I had was with the ram-section and that's why I asked the Help question about the 670. About 10 different set up versions I tried before I finally came to this one, and as you can see without the 670. Now maybe and propably there are other ways to do this but this is what I came up with.
The Cpu left under is not tested yet but also should work because I have used the Nano programmer before and that went fine. To move data around like in video no.36, these are the steps: 
https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/8%20Chapters%20together.txt
Except for the Cpu all modules are tested as stand alone and most of them in the 8 chapters set up and working. To write data into the Ram from the bus with this 8 chapters setup is not tested yet but I expect no problems with that.

Your development 74xx189, is that downloadable and are the pins adjustable in number size like the ram-module, for example 10 A-pins? I am planning to replace the 173's anyway with the adjusted MR versions, which are 8 of them, so  I might as well change the ram-module in one go.

By the way, I see there is no !OE? I guess it is not a pin in the real chip 74xx189 and that also would mean it is not adjustable. But that's oké, I am very pleased with how far Simulide could get as it is.

Edit, I see now this is the 189 exactly like it is used in the original. That's great! So, can it be downloaded?

Oh, and there was one more small difficulty. The 3xLM555 clock section is going fine but later at the 7-segment displays section it is used again, top left corner in this schematic:
https://eater.net/8bit/output
It has very small capacitors hooked up and I suppose that's why it didn't go so well, or maybe I had to try it a little bit more. The LM555 in that section I disconnected it and replaced it with a generator. The 555 I left there floating in space. Afterwards it came to be an advantage because it got pretty crowded there. To fit everything together on my small laptop screen I drew close to compact as possible.



Last edited by Mistral on Thu Feb 11, 2021 10:12 pm; edited 1 time in total

12Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Thu Feb 11, 2021 9:18 pm

Mistral



I pasted your code with Notepad++ inside the 74HC173.package instead of the 74HC173_LS.package.
Like I said, I'm not a programmer and now you know why  scratch
Luckily I copied the original to my desktop so I could recover it.
And it turns out that I don't have to replace 8 pieces of them after all. It showed up automatically in my 8 chapters set up with the extra MR-pin. Tested it with the before mentioned data shifting 'protocol', as described in the .txt-file, and is going just like before.
Thank you very much.

13Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Fri Feb 12, 2021 3:31 pm

Mistral



There is something I can't explain.
Ben's project is modular and for testing I used dipswitches (ds) and fixed volt buttons where he used jumpers to Vcc or Gnd. Putting it together I kept my ds. But in fact they are redundant now and wanted to remove them. In the original there are 2 ds. One 4-size for manually adressing the ram (to the left of the run/prog selection switch) and one 8-size for manual program of 8 bits to the ram-address.
The other four ds are redundant and are not part of the original circuit. 
I removed one (actually all of them but to keep it short I will not describe all the things I did when testing) and it turns out that the program counter is not able to output anymore. Or actually, it is still outputting but the buslines are pulling it to Low. Compare these two pictures please, I marked it. So how can a ds that was already full open after removal make this difference?
It is not a big problem because I can just leave this one inside but it puzzles me.

With DS
https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/Dipswitch%20markers.PNG
Without DS
https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/Dipswitch%20markers%202.PNG

Also notice in the picture with DS that the line left to the ds is red en the same line to the right is blue.

The clock is on manual, so this is step by step operating. It seems that the ds is causing a delay in the Simulide program?

The other ds I can remove with no issues so far. Still testing.

14Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Fri Feb 12, 2021 4:50 pm

arcachofo

arcachofo

I removed one (actually all of them but to keep it short I will not describe all the things I did when testing) and it turns out that the program counter is not able to output anymore. Or actually, it is still outputting but the buslines are pulling it to Low. Compare these two pictures please, I marked it. So how can a ds that was already full open after removal make this difference?
It is not a big problem because I can just leave this one inside but it puzzles me.
Might be an error in simulide or just a voltage issue.
There are lots of things connected to that bus, each one sinking a little bit of current.
It is possible that you are right in the limits of the fanout of whatever is driving the lines.
Switches have a resistance, very low but there is a voltage drop there.

Also notice in the picture with DS that the line left to the ds is red en the same line to the right is blue.
You can check the actual voltages at both sides of the switch.
Could happen that in one side it is 2.5 and in the other 2.49 or something like that.

I have not tested this, just the first thing that comes to my mind.
But it is vey probable that it is just an error in simulide.

You can also try to save the new version of the circuit, open again and see if it works after that.

I will have a look...

15Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Fri Feb 12, 2021 5:13 pm

Mistral



Thanks, I was hoping to give you some feedback about possible issues. But also I am still testing. What you said about voltage drop is what myself came to mind. In the original there are 10K resistors on the bus. https://eater.net/8bit/bus I am not very experienced with this kind of bus-knotting but anyway, I left them out. Want to put them where the mentioned ds is now.
May I ask one more question? Is the development 74xx189 still in the make or can I already have a copy of it?

16Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Fri Feb 12, 2021 5:52 pm

arcachofo

arcachofo

In the original there are 10K resistors on the bus.
In my opinion those resistors are to drive the lines low when they are floating.

Is the development 74xx189 still in the make or can I already have a copy of it?
74189 does not work in 0.4.14, only 0.4.15 and up.


IC models in simulide have the default values for Logic I/O voltages and impedances.
A project like this would require to fine tune then to the real devices. If not, some issues might arise.
Not only voltages and impedances, but propagation delays can cause problems as well.
0.4.xx versions don't simulate propagation delays other than the simulation step size.
In 0.5.xx it is possible to simulate and set values for these delays with more accuracy, but this version is still in it's early stages.

17Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Fri Feb 12, 2021 8:33 pm

Mistral



Thank you again for your explanations and your help. I tried some things but didn't help much. You are right, sometimes closing and opening Simulide can make a difference but I didn't do that with every modification. 
I replaced the ds with diodes. Seems silly but it also seems cheating to me to use a ds in order to let the circuit function. Now it's going as good as before and the 4 dipswitches are out of the way.


https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/8%20chapters%20removing%20dipswitches%203.PNG

https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/8%20Chapters%20Removing%20Dipswitches3.simu

And there was indeed a voltage drop over the dip. I think it was about 65 microVolt.

In this video Ben tells about the resistors at 11:30
https://www.youtube.com/watch?v=-6JAgFWCL9w
And he told somewhere that he had some issues with the bus. I tried like him to make one bus line from top to bottom with those resistors in place but didn't go smoothly. 
Well, my circuit is already rather different than his with the ram-section I used so it doesn't bother me too much.

Chips, I just realise now that with this diode set-up I can't write from the bus to the ram. silent
Back to the drawing table.



Last edited by Mistral on Fri Feb 12, 2021 9:09 pm; edited 4 times in total (Reason for editing : Placed the wrong picture)

18Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Fri Feb 12, 2021 9:29 pm

arcachofo

arcachofo

I think the problem is somewhere else.

Definetly bus voltages are not ok:
Ram and 74HC670 and 74xx170 Volts10

But this seems to me like two outputs driving the line.
From the right side of the DS there is 5V coming (not sure the origin).
From the left side there is 0V coming, probably from that 273?
So the voltage at that node is around 2.5V
At the DS there is a slight volt drop, so one side is slightly below 2.5 and the other slightly above 2.5, that makes the difference in color.

The problem is that i have no idea how this work and how i managed to get those lines at high state, so i can't reproduce it...

19Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 2:07 am

Mistral



I've been trying for hours and went back to the old situation with all the ds back in place but it turned out that I could not write into the ram. I said before that I didn't test that yet and didn't except any problems with it but that was an underestimation. 
I have placed some buffers in the circuit, removed all the excessive ds, placed a 100 Ohm resistorblock and on the left I looped the 8x probes, which where first hanging in air, back to the busline.
And this seems stable. Can write to ram, program counter is working and read from the ram and move it to the A , B and Instruction registers on the right. Oke, it takes a clock pulse extra but thats oke I guess.

https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/All%20but%20one%20ds%20removed%20-%203simu.png

https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/All%20but%20one%20ds%20removed%20-%203simu.simu

I can't really explain it, I suppose the buffers give more power. Not sure if it would function in real life, I don't have all these Ic's.

And if you, or other readers are curious about how this circuit is supposed to operate but don't have time to watch all Bens 44 video's than I suggest to take a look at no. 36.

https://www.youtube.com/watch?v=dXdoim96v5A&list=PLowKtXNTBypGqImE405J2565dvjafglHU&index=36

20Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 4:03 am

arcachofo

arcachofo

Yes Buffers give more power, they are used in buses for that purpose.

But The problem here is that the 273 is always driving the lines.
While the Program Counter is driving lines 0-3 at the same time.

Edit:
The Program Counter or any other part taking the bus.

21Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 10:34 am

Fizik_S

Fizik_S

Mistral, Especially for you, I made models of RAM chips 74XX169, 74XX219. I wanted to make them for a long time, but due to problems with SimulIDE, it did not work. I spied the solution from arcachofo. Now the models are working. I checked in SimulIDE 0.4.14-SR4. It won't work in earlier versions! Installing models: unzip the archive to the directory "SimulIDE_0. 4. 14-SR4_xxx/share/simulate/data". After restarting the program, the "memory_is" group should appear.
Ram and 74HC670 and 74xx170 Memory10
Attachments
Ram and 74HC670 and 74xx170 Attachmentmemory_is.zip
You don't have permission to download attachments.
(6 Kb) Downloaded 2 times

22Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 11:06 am

Mistral



arcachofo wrote:Yes Buffers give more power, they are used in buses for that purpose.

But The problem here is that the 273 is always driving the lines.
While the Program Counter is driving lines 0-3 at the same time.

Edit:
The Program Counter or any other part taking the bus.

At first there was no 273 in the ram-section. Video 36 of course doesn't make clear my ram set-up so I will try to put it in context.
This was ram as stand-alone before:
https://github.com/Alectus/Z80-Breadboard-Simulation/blob/main/Ram%20Build%20Completed.PNG
Where Ben uses 1 bus transceiver I used two because my Simulide ram has bi-directional inputs/outputs, the D-input pins also serve as Q-output. One 245 bus transceiver closes on clockpulse on its !OE and the other has an inverted clock on its !OE. So in reading mode the ram needs to go to the bus and one transceiver lets through and the other blocks. When writing from the bus into the ram other way round. 
Now if there was no option to make it possible to write into Ram manually with dipswitches, this ram-section would not be so massive. But Ben put it there and so did I. 
ttps://eater.net/8bit/ram
One can also use Notepad to enter the data, what I don't have to tell you of course.
Now when I placed the ram inside the bigger circuit the clock turned out to be out of sync. Then I placed the latching 273 without really taking a good look what effects it has on the whole.

I placed buffers, saw that the PC output was unstable, placed resistor-pack, going better but not completely, realised like with the diodes that the buffers block data transfer from ram to registers, than looped the 8xprobes back on the bus. These probes I had only placed them to see what is going on, as indicators. So now there is this loop and maybe the buffers can be removed again, together with the 100 ohm pack and who knows what else more can be changed now. Place one thing, other becomes obsolete. Don't think this will be finished next week. 

About the program counter, it has to be kept in mind what is on the bus. For example, if the PC has !OE enabled you cannot also put the A-register on !OE enabled. Or any other section. Yes, it can but than there is conflict and messy data bus lines. Thats when the control logic comes into view to handle that. Now done by hand with the buttons. And for myself I made this before mentioned txt-protocol but don't need it anymore because I repeated it many times.

Ps, in my latest version the adress-lines just above the buffers where mixed up. Well, I'll take it easy and casual test some more. But there might be more bugs inside. So far and except of that it is is looking good.



Last edited by Mistral on Sat Feb 13, 2021 1:39 pm; edited 8 times in total (Reason for editing : spelling errors, added link etc.)

23Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 11:43 am

Mistral



@Fizik_S
Thank you for doing this for me, I am using 0.4.14-SR4 win64 so that should fit. When this circuit is enough tested and going more smoothly I will try to make a second version with the new components 169, 219. 
And of course I will download and test them a little bit today.


Okay, I have them. Great!

24Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 3:00 pm

arcachofo

arcachofo

Fizic_S wrote:Mistral, Especially for you, I made models of RAM chips 74XX169, 74XX219.
If someone could do it, it's Fizic (the author of almost all subcircuits in simulide).

Mistral wrote:Now when I placed the ram inside the bigger circuit the clock turned out to be out of sync. Then I placed the latching 273
You will find some other solution for sure.

Mistral wrote:But there might be more bugs inside.
I found a possible issue in the control unit, so it is not showing up yet:
Control pins of that 161 should be to +5V (as per Ben schematics)

Ram and 74HC670 and 74xx170 Cu10


And just in case you didn't know:
In buses you can select bus size and start bit.
This is useful to ditribute bus bits in cases like this (ALU):

Ram and 74HC670 and 74xx170 Alubus10

25Ram and 74HC670 and 74xx170 Empty Re: Ram and 74HC670 and 74xx170 Sat Feb 13, 2021 3:29 pm

Mistral



Thanks a lot for your tips, I didn't know that yet.
Have been testing and it is working. Not using the manual ds but only the fixed volt buttons and it is possible to write and read to and from the ram and from every register you like. And even correct it if one forgets to close a button. Sometimes to correct I also had to make use of the Bus 2xAB-!AB button, this clears most lines. Or the clr pc. I wrote the table of three inside ram using a, b, alu register etc.

I am gonna leave it like this for now, not trying to change registers or buffers etc. Want to watch the rest of Bens video's 37-44 again. And later place some 7-segments at the registers. Also later, I would like to fix that the display is one-clock tick behind the bus-line. Ben Eater let's the display only show numbers after a register in command but I am using it continuessely, in other words, that display section is always open in my set-up. Can be closed though. 
Shall tie up that unused pin of the 161. Tnx.
And tidy up the circuit, without making fundamental changes and place it on git, and in the project section at Simulide forum.

Ps, anybody is free to alter, improve or adjust this circuit. It is open source like I used it from somebody else. Am very interested in other peoples' ideas and makings.

And one more note, after manual program with dips and you switch from prog to run, address 0 becomes 0000. Not sure what is going on there or if it always happens.

Sponsored content



Back to top  Message [Page 1 of 2]

Go to page : 1, 2  Next

Permissions in this forum:
You cannot reply to topics in this forum