We've been building a SPICE-like mixed-mode circuit simulator plus a SVG-based schematic editor, HTML5/Canvas-based plotting, in about 20K lines of CoffeeScript. No browser plugins required -- runs directly in the browser's JavaScript engine, and all simulation is client-side. (We generate and factor big matrices on the client side.) We currently do DC, time-domain simulations, and frequency-domain analysis (small signal, "Bode plots" if you're familiar with the lingo). Circuit analysis results compare well to "real" desktop SPICEs. We evaluate real and complex electrical quantities. In fact, we have a graphing calculator essentially embedded in our tool. Since it's browser-based, it's immediately Windows/Mac/Linux cross-platform, unlike most software EDA tools which are Windows-only. Check out the cross-tab copy-paste functionality as well!
If you look at any electronics forum online, it's normal to see scanned hand-drawn schematics, or static screenshots from various desktop tools. There's no reason why we shouldn't instead be sharing useful URLs that enable editing and simulation. If someone uses CircuitLab and posts a public URL, they enable the entire community to easily open their circuit, make a few changes, simulate / iterate, and share the new version.
I briefly considered doing something like this myself, there are some interesting ways to monetize this if you manage to become the web circuit designer/simulator.
Some things you might want to consider:
* be more Mac friendly -- backspace instead of delete, Cmd instead of Ctrl on Macs
* It feels unnatural that I have to press a button on the menu to enter a placement mode. Something like drag and drop might be more natural.
* There's no obvious way to delete stuff with the mouse
Your mileage may vary though, just me 3 cents. Other than that, looking pretty good. Good luck!
Thanks! Yes, there are some important Mac usability issues we need to take a closer look at. Ctrl-click, etc. Some of these will be limited by what kinds of UI events we have access to in-browser, but others are just tweaks we need to make on our end.
20K lines of CoffeeScript is about an order of magnitude more than I've ever dealt with in a single project. Any complaints, concerns, ideas or tips that you learned along the way?
It's about 15K of code + 5K of unit tests (Jasmine). CoffeeScript is amazing and it really enabled a project of this scope to be fun and manageable. We are very happy customers :)
No tips really. We have several subdirectory builds with independent Makefiles which all get catted together (as we started long before the v1.2.0 join option). Many thanks!
I haven't looked at it yet (in a few moments we'll see how it handles mobile devices), but if it holds up to your hype, this could be an amazing application. I have to ask, is the entire simulation client side, and what's the largest functional circuit you've created and still had good performance (as in does it seem to be able to be able to be optimized to eventually be an EDA competitor, or will it mainly be the smaller circuits as folks are learning?)
10 BJTs, and an op-amp, all in a highly-coupled, high-gain loop. If you open this one and run the time-domain simulation with the saved settings as-is, it takes my laptop a good 23 seconds to crank through 80 time points. However, that circuit generates somewhere around ~700 highly non-linear simultaneous equations that need to get solved at every timestep.
We are certainly performance-limited right now by not running closer to the hardware, but if simulation performance turns out to be a key bottleneck/feature, we'd look at things like Google's Native Client.
Very impressive! A few comments and first impressions:
Wires seem to remain in the same place as components move. I'd love to see wires that connect two components and whose ends follow those components as they move.
Typo on several elements: s/contolled/controlled/
The zoom widget doesn't seem to let me set a precise zoom level. If I zoom around a bit, then type "100%" and hit enter, I end up with 96%. Also, you might consider providing some standard zoom shortcuts, such as "100%" and "fit to circuit".
I'd really like to have keyboard shortcuts to quickly switch between components; perhaps some kind of search-based mechanism, where I can hit a key to bring up a search box, type a few letters to get to a component, hit enter, and have that component selected.
How can I "export" a schematic to some useful standard format (other than a read-only PDF)? (In particular, a netlist, or something usable as an initial input to a PCB tool?)
I'd love to have the ability to save a circuit with named nodes as a "part", which I can then use as an IC-like component in other circuits, hiding the details of that circuit normally but drilling down into it if desired. Ideally, this would support versions of individual parts, making it easy to upgrade a circuit using a previous version of a part to a new version. Also, ideally the part could have parameters of its own, and use those parameters to assign parameters to its own components.
Any plans for collaborative editing and "team" repositories?
Do you have any plans to support more of the EDA workflow? For instance, a decent PCB layout tool? This seems like a great opportunity for a future business model: find one or more good board fabrication companies willing to do small-run work, and work with them to provide an easy way to go from CircuitLab to a built board.
Yes, wires do currently stick to the grid, not to the elements. I wouldn't mind having some mode where they do stick to the elements to make parts a bit easier to move around.
Nestable subcircuits (named nodes as a "part") is on the long-term roadmap, but it's a big feature -- it'll take some time.
As far as collaborative editing, team workspaces, netlist export, PCB layout: we're thinking about all of them, and will just have to see where the users take us!
Very nice, I like it. I've come across a few online/web-based logic and circuit sims before (example logic.ly , http://www.falstad.com/circuit/index.html) but this one seems the most complete and polished. I'm signing up for it right away.
Looks great! Have you looked into trying to do any realtime feedback like in Bret Victor's recent talk? (amazing watch - http://vimeo.com/36579366 the circuit part is ~23 min in)
If you look at any electronics forum online, it's normal to see scanned hand-drawn schematics, or static screenshots from various desktop tools. There's no reason why we shouldn't instead be sharing useful URLs that enable editing and simulation. If someone uses CircuitLab and posts a public URL, they enable the entire community to easily open their circuit, make a few changes, simulate / iterate, and share the new version.
Looking forward to hearing your feedback!