Ask A Question

Subscribe You’re not receiving notifications from this thread.

simulation stack exceeded, but only for subcircuit

General • Asked 10 months ago by Derek Wheeler

Gravatar Derek Wheeler Commented on Oct 13, 2020:

I created a minimum circuit that demonstrates a problem I saw in a larger circuit. In this circuit, there's an input with a tristate gate attached to a common bus. Also on the bus is a D flip flop, with it's input from the bus, and it's output sent to a tristate gate which outputs to the bus. That's the upper circuit on the Main tab and that all works fine.

When I put the D flip flop into it's own subcircuit, I get 'simulation stack exceeded' when I change the input and try to latch that into the flip flop. That's the bottom circuit. So it's the exact same components, but just one of them is in a subcircuit.

Has anyone seen this behavior? Maybe I'm doing something wrong?


Gravatar Derek Wheeler Commented on Oct 27, 2020:

I've figured out a workaround and updated the example circuit. I added a new subcircuit that incorporates the tristate, rather than having the tristate in the main circuit. I added a new circuit at the bottom of the main circuit that shows this works and doesn't give the 'simulation stack exceeded' error.

Gravatar Satvik Ramaprasad Commented on Nov 09, 2020:

Yes this a known bug, the tristate has to be used only in the final circuits, we are looking for a fix for this.

Gravatar Derek Wheeler Commented on Nov 18, 2020:

Thanks Satvik!

Gravatar noulmao Commented on May 13, 2021:
this might do the job.

Gravatar noulmao Commented on May 13, 2021:

it uses a tristate so if it overflows (2 or more on) cout will turn on and give a 1 to the NOT gate and the LED. causing an overflow error. (this could help.)