hneemann / Digital

A digital logic designer and circuit simulator.
GNU General Public License v3.0
4.35k stars 440 forks source link

Oscillation in Delay after EEPROM - bug? #1188

Open mengstr opened 1 year ago

mengstr commented 1 year ago

This design bugs out with an oscillation when I run it. It seems like I can't hook up a Delay directly to the data of an EEPROM. An Inverter or a Driver between the EEPROM and the Delay makes the problem go away.

delaybug

delaybug.zip

hneemann commented 1 year ago

That is an interesting one! Thank you for pointing this out. Although I'm not sure if this is a bug or not. The problem can also be produced in a simpler way:

delayDebug

This way, an infinite stream of random numbers is fed into the delay gate, which thus never reaches a steady state. It only occurs when the delay time is set to a value greater than one. I have to think a bit about this problem before I understand what is best to do.

mengstr commented 1 year ago

Yes, I see now that I can put a 1-gate delay infront of the one with the longer delay and it works. For the time being that is less confusing than putting a double inverter or a driver there. :)