LiveSPICE, my real time circuit simulator project

Started by dsharlet, November 13, 2013, 09:25:03 PM

Previous topic - Next topic

tubegeek

"dartboard-designed pedal circuits"

PRR:
When you write your next book, I suggest this would be a terrific title.
Can I get an autographed copy please? Pretty please? With red velvet cake on top?

This thread is making me seriously consider configuring some machine around here (I think I have an idle Linux box that will work) for Windows booting: I've generally avoided this on religious grounds. The future VST feature possibility that you mentioned, alphadog808, is ESPECIALLY intriguing to me... I work a bit with ProTools in my day job.
"The first four times, we figured it was an isolated incident." - Angry Pete

"(Chassis is not a magic garbage dump.)" - PRR

dsharlet

I've released a new version that addresses a bit of the feedback I received. Link: https://github.com/dsharlet/LiveSPICE/releases

- Make sure to uninstall any old version before installing this version! There are many breaking changes in the way components are stored.

- There is now limited support for importing SPICE models. D, NPN, and PNP models are supported, though I should warn you that most of the parameters are ignored. I tested it on the LTspice library successfully, as well as a few other random libraries I found on the web. However, I do not have a component library with a license that is compatible with me shipping it with the application; you'll have to find your own components at the moment. Just copy and paste SPICE library files into the My Documents\LiveSPICE\Components folder and they should show up in the library. If you find D, NPN, or PNP models that don't work with LiveSPICE, I'd like to hear about it and get a sample if possible!

- You can now control the pots and variable resistors in the circuit from the simulation mode. You can click on the weird programmer art knobs that show up on top of the pots/resistors to adjust the value. There is some latency between when you make the change and when the change is reflected in the simulation. Here's a pic of what I mean:



I still have not addressed the input/output voltage or dB issue, I wanted to deal with the SPICE model issue first.

Quote from: tubegeek on November 17, 2013, 06:22:25 AM
This thread is making me seriously consider configuring some machine around here (I think I have an idle Linux box that will work) for Windows booting: I've generally avoided this on religious grounds. The future VST feature possibility that you mentioned, alphadog808, is ESPECIALLY intriguing to me... I work a bit with ProTools in my day job.
To clarify: I'm not going to be able to build this feature for a while. It will require some big improvements to my computer algebra system, which is definitely the most challenging part of this project (I've probably spent 90% of the effort on the project up till now on that part). This feature (exporting VST plugins) is pretty much my most wanted feature, but it's a long term feature with many stepping stones to get there :)

tubegeek

Quote from: dsharlet on November 17, 2013, 11:51:27 PM
I've released a new version...

And this makes you: DA BOMB! You go, girl!

Quote
To clarify

Clarification duly noted, I just wanted to add my voice to the clamoring masses.
So - Wednesday of next week then?

;)
"The first four times, we figured it was an isolated incident." - Angry Pete

"(Chassis is not a magic garbage dump.)" - PRR

wookie

This project looks really sweet.  Thanks for your effort!

Currently my install will crash when performing the audio setup test for either ASIO or windows audio drivers.  Would you like users to upload issues to GitHub?  I currently see only issues opened by you, so I wasn't sure if you had a separate channel for submitting stuff like this that you'd prefer I used.  Also, I don't see any sort of log file in the install directory to provide along with the description.  Is a log file generated in the users directory somewhere, or is there currently no log file being generated?  I've only tried this on my work PC at the moment.  I'll run through the same procedure with my studio PC soon and let you know how that works as well.

Again, thanks for starting this!

dsharlet

Quote from: wookie on November 21, 2013, 12:30:23 PM
Currently my install will crash when performing the audio setup test for either ASIO or windows audio drivers.  Would you like users to upload issues to GitHub?  I currently see only issues opened by you, so I wasn't sure if you had a separate channel for submitting stuff like this that you'd prefer I used. Also, I don't see any sort of log file in the install directory to provide along with the description.  Is a log file generated in the users directory somewhere, or is there currently no log file being generated?
Submitting the issue on GitHub would be great!

There's no log for the audio IO system yet, I should probably add something along those lines for this kind of situation. For the time being, can you try to describe your setup? Number of input/output channels that show up, which ASIO driver/device you are using, etc.?
QuoteI've only tried this on my work PC at the moment.  I'll run through the same procedure with my studio PC soon and let you know how that works as well.

Again, thanks for starting this!
Thank you for (attempting to) try it out :)

wookie

The issue's been posted to GitHub.  Thanks for the excuse to make a GitHub account!

FYI this is on a work PC that's new to me in the last 3 weeks.  I haven't really done much audio work on this box before, but I do have a working install of Pd-extended that's using ASIO4ALL v2.  So there is at least a basic functionality to the ASIO driver system.  I also needed to do the update to .NET framework 4.5 to get this to run, but I'm still getting a missing dependency somewhere I think as the exception dump has a missing dll line in it.

dsharlet

#26
Hi All,

I finally got around to implementing some of the feedback I got here. I have made a few releases since I last posted, here is a summary of the changes:

- Numerical stability should be much improved
- Added JFET models, better op-amp models
- More responsive controls (like pots) during simulation, though they're still nowhere near what I'd like to have
- The audio channels interface has been redesigned and it maps a bit better between audio IO and the components on the circuit. It also allows you to more accurately describe the voltage of the signal inputs and outputs (you tell it what the voltage @ 0dBFS is for each channel, instead of just a generic gain).
- Hopefully big improvements to audio IO issues. I tracked down one really annoying crash when using the windows audio IO, and the ASIO4All should be a little bit better, though it's still really picky about showing channels that are in use by other apps (like chrome). I assume this is a general problem with ASIO4All and not just something I'm doing wrong.

The current release can be found here: https://github.com/dsharlet/LiveSPICE/releases

I've spent most of the time since trying to build my simulation and math stuff to allow the system to be compiled to a VST plugin. That's proving to be quite difficult...

Here's what it looks like today, the pictures on my site are slightly out of date:


I'd love to hear feedback if you try it out!

MaxPower

I assume this still requires .NET Framwork 4.5?
What lies behind us and what lies before us are tiny matters, compared to what lies within us - Emerson

dsharlet

#28
It does, sorry! For the next release, I will work on going to .NET framework 4.0.

I decided to actually try targeting .Net framework 4.0 instead, and it seems to be working after re-implementing a bunch of stuff I was using from 4.5. I uploaded another release that uses .Net framework 4.0:

https://github.com/dsharlet/LiveSPICE/releases

Nephenix

If you could also add a support for midi messages that would be even more awsome !
Btw I'm a computer engineering student and if you need some more people for that project I'm here.

vigilante397

#30
First of all, I think LiveSPICE is an amazing idea. I don't remember if I have the latest version or not, but I've been getting an error every time I try to simulate. I'm at school right now (electrical engineering student, happy to lend any knowledge I pretend to have), but I'll double check when I get home.

EDIT: Yup, I have the latest one, and when I try to run the audio configuration it throws me a "Unhandled Exception: Provide value on 'MS.Internal.Markup.StaticExtension.'

Is this a common problem, or does my computer suck?  :P I'll accept either answer.
  • SUPPORTER
"Some people love music the way other people love chocolate. Some of us love music the way other people love oxygen."

www.sushiboxfx.com

upspoon12

I have the same issue and i would absolutly love it if this program was running smoooooth as silk. It would get MUCH great use.

ashcat_lt

#32
Quote from: dsharlet on March 09, 2014, 12:26:22 AM
...you tell it what the voltage @ 0dBFS is for each channel, instead of just a generic gain...
Was that my idea?  ;)  

One would assume that that is peak-to-peak voltage, but you might want to specify somewhere, just for clarity.  Also, in the pic you show this seems to be set at 1.414V, which is right around -4dbVU on a +4dbu system.  IRL, most interfaces will put 0dbfs at more than 20V peak-to-peak.  It's arbitrary, I suppose, because user configurable, but...  

Be aware that higher values on the input slider will be like adding gain, but on the output slider it will be like attenuation.  It's almost counterintuitive, but if you think about it for a minute I think you'll dig.

Voltron

#33
Schematics not showing on main editor. Mixed views components/properties windows.



Emulation window seems to be running ok. I'll try a previous build to see if issue solves.

Running Preview 12 under Windows Vista with the latest update.

vigilante397

I got a new computer about a month ago with a top-notch processor and I downloaded the latest (Preview 12) version of LiveSPICE, and it was AMAZING. I plugged my guitar straight into my USB interface which typically has very low latency, and it was fantastic. Obviously there was a little bit of latency, but if there were a perfect real-time SPICE simulator then pedals would just be inconvenient :P I have a project I started on the breadboard several months ago that had been scrapped because my breadboard and I had a falling out, but has now been resurrected and is sounding fantastic! ;D Thank you for your effort in creating this product, and when the commercial version becomes available I will definitely be getting one.
  • SUPPORTER
"Some people love music the way other people love chocolate. Some of us love music the way other people love oxygen."

www.sushiboxfx.com

J0K3RX

Man I gotta try this! What was that part in the 1st post about exporting VST's?
Doesn't matter what you did to get it... If it sounds good, then it is good!

vigilante397

Quote from: J0K3RX on February 04, 2015, 11:05:31 PM
Man I gotta try this! What was that part in the 1st post about exporting VST's?

I don't think that has been implemented yet, but that would be SO COOL. I doubt there are any truly perfect SPICE programs out there, but this one has become my favorite, and hopefully with the final version (everything up to this point still says "Preview") there will be loads more goodies, like VST exporting. ;D
  • SUPPORTER
"Some people love music the way other people love chocolate. Some of us love music the way other people love oxygen."

www.sushiboxfx.com

eeviac

#37
This is great stuff. Installed preview 12 half an hour ago and I'm up and running with a virtual Demo Tape Fuzz. Latency is great on windows 8 using a lexicon lambda interface and ASIO4ALL.

Getting lots of 'system diverged' crashes if I move knobs too much.

Ice-9

Is it possible to import schematics made in TinaTI into live spice without having to re draw them all from scratch.
www.stanleyfx.co.uk

Sanity: doing the same thing over and over again and expecting the same result. Mick Taylor

Please at least have 1 forum post before sending me a PM demanding something.

acobberson

I too am interested in imports. I have plenty of things I have created in Eagle that make sense on paper (or screen I guess) but have not put aside the time to breadboard them. An import from Eagle, Altium, etc would be out of this world. For now I will start with my simple circuits though to get a feel for the simulator. Man, what an incredible piece of software.