fritzing / fritzing-app

Fritzing desktop application
http://fritzing.org
Other
3.95k stars 820 forks source link

[LED example] An error occured when starting the simulation #3977

Open SergioArrighi opened 1 year ago

SergioArrighi commented 1 year ago

Current Behaviour

Hello, I just opened the led example of the simulator set of examples. Pushing the simulate button results in an error message: "An error occurred when starting the simulation"

I downloaded the software today and I'm unsure where to see version number

image

Build: 0.9.10 <e.g. Version 0.9.3 (b5c895d32 2016-04-19) Cocoa [Qt 5.12.2]

Operating System: MacOS 11.6

Steps to reproduce:

Expected Behaviour

The simulation starts

failiz commented 1 year ago

It seems that the ngspice library is not found or that it fails to get the wrapping functions. Did you compile it or is the downloaded from the website?

SergioArrighi commented 1 year ago

Hello, thanks for reply! I downloaded the installed .dmg

failiz commented 1 year ago

@SergioArrighi , and did you use the default options or did you modify something during installation? Maybe you could try to uninstall it and try to install it again. @KjellMorgenstern , did you test the simulation in macos 11.6? Any ideas?

SergioArrighi commented 1 year ago

Hello, I simply drag the application icon in the dmg to the application folder, then I activate the simulator in the beta tab. I tried to delete app and reinstall but I'm experiencing the same issue. I will try to build it from git repo and let you know. Many thanks!

KjellMorgenstern commented 1 year ago

I have tested the 0.9.10 dmg on Big Sur and Monterey. @SergioArrighi report seems plausible, but to be sure: The version information can be seen in the About Dialog. On macOS, you'll find that in the top left menu bar "Fritzing -> About Fritzing". Please send a screenshot.

SergioArrighi commented 1 year ago

Hello, sorry I couldn't find it for my initial report.

image

Thanks and best regards

lukaslabryszewski commented 1 year ago

Same issue. Installed the app from the official website DMG file.

Debug Log:

Try path /Applications/Fritzing.app/Contents/MacOS/ngspice.dylib
Couldn't load ngspice Cannot load library /Applications/Fritzing.app/Contents/MacOS/ngspice.dylib: (dlopen(/Applications/Fritzing.app/Contents/MacOS/ngspice.dylib, 5): Library not loaded: /usr/local/opt/gcc/lib/gcc/11/libstdc++.6.dylib
  Referenced from: /Applications/Fritzing.app/Contents/MacOS/ngspice.dylib
  Reason: image not found)
offobject commented 1 year ago

Same issue, just purchased

macOS Mojave 10.14.6 Fritzing 0.9.10

meierich commented 1 year ago

Same issue macOS Catalina 10.15.7 Fritzing 0.9.10 Way - it makes me mad! Thanks for hints Erich

meierich commented 1 year ago

Andres Faiña

Dos enyone know to contact Andres Faina ? (vgl screen shot)

KjellMorgenstern commented 1 year ago

Guys, dont' be mad, it is clearly marked as beta feature. "Same issue" is a bit thin: For more than half of the issues reported, people had a high value resistor in the circuit, so the LED would not light up. Supporting old versions of macOS (which are not even supported by Apple anymore) also is quite a challenge.

failiz commented 1 year ago

Andres Faiña

Dos enyone know to contact Andres Faina ? (vgl screen shot)

I'm here.

meierich commented 1 year ago

Okei - Thanks a lot! old version of macOS, you got the point. high value resistor: I was just trying a standard (the simplest) example suggested of Fritzing regards erich

Am 19.11.2022 um 18:23 schrieb Kjell @.***>:

Guys, dont' be mad, it is clearly marked as beta feature. "Same issue" is a bit thin: For more than half of the issues reported, people had a high value resistor in the circuit, so the LED would not light up. Supporting old versions of macOS (which are not even supported by Apple anymore) also is quite a challenge.

— Reply to this email directly, view it on GitHub https://github.com/fritzing/fritzing-app/issues/3977#issuecomment-1320928991, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4I7IFO6YRGV6Q535UE7X2LWJEEJRANCNFSM6AAAAAAQNR7PPU. You are receiving this because you commented.

failiz commented 1 year ago

For more than half of the issues reported, people had a high value resistor in the circuit, so the LED would not light up.

The PR of simulator improvements makes the light of the LED more noticeable at low currents. Are you receiving a lot of issues by mail? I have not seen that reported here.

KjellMorgenstern commented 1 year ago

Through all kind of channels, as most users are not developers who have a github account. The simple_led.fzz example has a 220 Ohm resistor, but the battery only supplies 3V... so a LED that stays dark is not unusual. The text box next to it suggests to play around with the resistor value. I thought that was intentional, so there is something to discover besides just clicking "Start". Just mentioning it here so people don't dig into debug logs when the solution is just reading the instructions.

Back to the main issue, the error loading the library. My guess is that it is related to libstdc++.6.dylib as also reported by @lukaslabryszewski . However, it is not yet clear why this happens. The library is included with Fritzing. In case of Catalina and before, it might be necessary to build against older libraries. But we also got reports on Big Sur and later.

lukaslabryszewski commented 1 year ago

@KjellMorgenstern I'm a software developer, although not familiar with inner workings of this application. If there is anything I can do to help you debug this issue please let me know any steps that I could follow to help you figure this out. I see the library in the package so not sure why the software can't find it. Perhaps a permission or executable signing issue?

lukaslabryszewski commented 1 year ago

Not sure if this helps:

Screenshot 2022-11-20 at 2 59 30 AM Screenshot 2022-11-20 at 3 00 49 AM
failiz commented 1 year ago

Through all kind of channels, as most users are not developers who have a github account. The simple_led.fzz example has a 220 Ohm resistor, but the battery only supplies 3V... so a LED that stays dark is not unusual. The text box next to it suggests to play around with the resistor value. I thought that was intentional, so there is something to discover besides just clicking "Start".

It was intentional, but maybe it is not the best for the simplest example (I do not use the examples in my teaching, I build the circuits "live".)

If there are too many persons who think the simulator is not working, maybe it is better to decrease the resistance to 100 ohms to make the light noticeable (specially with the PR improvement).

solaSell commented 1 year ago

Same problem today January 25 2023. Even the other examples under simulator give similar error message

KjellMorgenstern commented 1 year ago

@solaSell Good to know you have seen something on January 25 2023 ;-) But it would be more helpful if you added exact Fritzing version, macOS version and error messages (exact as in "screenshot"-exact)

hanskristianjonas commented 1 year ago

Same problem today (March 21 2023), with pictures.

Error_msg

fritzing_version

system

I have no idea what I am doing, please keep this under consideration when offering help. Any help is very much appreciated though.

dd121 commented 1 year ago

Same error:

image image
amyeguo commented 1 year ago

Using version 0.9.10 of Fritzing, macOS Big Sur Version 11.7.7

Experiencing an error when trying to use the simulator, even after decreasing the resistance value from 220 ohms to 100.

Screen Shot 2023-06-23 at 12 03 21 PM

Here is the debug log when I press "Simulate":

Screen Shot 2023-06-23 at 11 52 19 AM
failiz commented 1 year ago

From https://fritzing.org/releases/1-0-0 "Known issues: The simulator does not work on Catalina and Big Sur. A workaround is planned."

KjellMorgenstern commented 1 month ago

Support for Catalina has been dropped, but the issue remains for Big Sur.

There is still the problem with Big Sur that prevents signed dynamic libraries (ngspice in this case) to load system libraries.

The error message is now clearer: image

"File system relative paths not allowed in hardened programs"

Which is irritating, since a) /usr/local/opt/gcc/... is an absolute path b) there is no such path in a vanilla Big Sur installation, and neither on my test VM.

If I manually add a copy (from xcode 12) there, it will complain: image