Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Subcircuit terminals shared between all Instances. #93

Open
Merilix opened this issue Jun 10, 2024 · 3 comments
Open

Subcircuit terminals shared between all Instances. #93

Merilix opened this issue Jun 10, 2024 · 3 comments
Labels

Comments

@Merilix
Copy link

Merilix commented Jun 10, 2024

Because the pins of subcircuits are made of named nodes, they are all he same if you have multiple instances.
They behave like they are connected parallel.

Terminals of a subcircuit must be independent of other instances. They should be build of an element say "pin" which behaves like a normal unnamed node.

@pfalstad
Copy link
Owner

Can you give an example? I'm not seeing that.

https://tinyurl.com/2kfz7jkl

@Merilix
Copy link
Author

Merilix commented Jul 6, 2024

I can't see how test1 in your example is made.
But here you go https://tinyurl.com/22cholyb
Thats my sub-circuit: https://tinyurl.com/2buafrrx

Intended was to show the behavior of induced current/voltage in a loop using DC simulation.
Wanted to simplify that: https://tinyurl.com/26xl3qam
My sub-circuit was meant to represent a single segment of the wire loop.

@pfalstad
Copy link
Owner

pfalstad commented Jul 6, 2024

There are some known bugs with 2-terminal voltage sources in subcircuits. This looks like another one.

I used a workaround to fix your subcircuit: https://tinyurl.com/28rots7t

I also added some grounds, just to fix the voltage colors, but it works without the grounds.

I took your subcircuit and added a ground, not connected to anything, like so: https://tinyurl.com/25olne3u Then I select everything but the ground and do "Create Subcircuit". Then it works.

@pfalstad pfalstad added the bug label Jul 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants