??? 10/13/06 12:21 Read: times |
#126398 - simulation versus real life Responding to: ???'s previous message |
Abhishek Bk said:
I want test if a certain design is logically sound or not.
For example if my design is behaving strangely say every X number of inputs, there is a big chance that there is something wrong with logic employed in the circuit. Or the program might be carrying a glitch. If there was a tool where I could if my design is logically correct or not, it would be great. I am afraid this is the sort of things for which the (digital) simulators are not very well suited. I'd say they are intended to prove the basic functionality, but not really for the extras. This is the same with the '51 (and other mcu) simulators. There is always a great deal of abstraction (simplification) in simulators and it's in layers. For example, the '51 simulators usually work in instruction cycles (the top layer, let's call it layer 0), which hides the exact timing of what's going on on the ports, i.e. that the outputs are overwritten in say 5th clock cycle of the appropriate instuction cycle (layer 1). Of course, layer 1 simulator is more complex, hence slower, more expensive etc. Nevertheless, it takes time while the signal propagates from the port latches to the actual port, that would be layer 2 simulation, even more complex. If you are interested in what exactly happens under various loads on the pin, in terms of both delays and voltage levels and ramps, you are already in layer 3 (SPICE); but at this layer it is already virtually impossible to simulate a whole microprocessor/controller. Of course we can continue down there where Heisenberg's principle prevents us to be more precise, but in commonday electronics, we usually are satisfied by what SPICE gives us. So, the best thing what you can do is, you first make some digital simulation, and try to spot the possibly problematic spots (around edges etc.) - using your brain, sorry, that's the best thing we have. You can then possibly simulate some small portion of the circuit e.g. in SPICE inputting various stimuli, and having a look at it in more detail. JW |