Would you like to react to this message? Create an account in a few clicks or log in to continue.

You are not connected. Please login or register

SimulIDE 0.4.15 Tester builds

2 posters

Go down  Message [Page 1 of 1]

1SimulIDE 0.4.15 Tester builds Empty SimulIDE 0.4.15 Tester builds Thu Jul 29, 2021 11:04 am

arcachofo

arcachofo



Last edited by arcachofo on Tue Oct 26, 2021 9:34 am; edited 3 times in total

2SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Mon Aug 02, 2021 4:26 pm

bjosol



Hi
Tried a simple layut with one LED and push button controlled by Arduino Uno. Forgot to include the resistor at first and the LED where blinking about twice per second when the push button where pressed.
When i added a resistor the LED did not light up at all.
Had to cancel the build and start a new with the exact same layout and software and if i included the resistor from the beginning it all worked as it should.

See attached screen dumps.
Attachments
SimulIDE 0.4.15 Tester builds AttachmentLayout.PNG
You don't have permission to download attachments.
(38 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentLayut - Added resistor.PNG
You don't have permission to download attachments.
(15 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentINO.PNG
You don't have permission to download attachments.
(19 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentSimu after resistor added 1.PNG
You don't have permission to download attachments.
(24 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentSimu after resistor added 2.PNG
You don't have permission to download attachments.
(13 Kb) Downloaded 0 times

3SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Wed Aug 11, 2021 1:29 pm

arcachofo

arcachofo

Hi.

Sorry for the delay, but I can't reproduce the issue.
Everything is working ok for me.

4SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Thu Aug 12, 2021 7:08 am

bjosol



Strange that you do not get the same result as me but below test finally explains why my builds never work..!!

I removed the Arduino board and built the circuit below to reduce the potential fault sources The volt meter measure 5 volts when push button is pressed and 2.4V when push button is released.

If i power of the simulation and power on again it measure 0 volt before the push button is pressed, 5V when pressed and again 2.4 V when the button is released and the same happen if i remove the cable from the power source to the push button.

It is possible to change the resistance on the resistor and the color of the LED, the circuit will still work.

If i close the simulation and delete the resistor and put in a new the volt meter will show 0 volt and the LED will not work. If i then close the program and open up the same saved circuit then the volt meter will show 5 volt when the button is pressed but the LED will still not work.

If i keep the simulation running and replace the resistor (the time counter is ticking) then the LED will light up as well but the volt meter will still show 2.4V when not pressed. I can also insert a switch before the push button while the simultion is running and the LED will still work (volt meter still showing 2.4V when button is off).

If i shut of the simulation and insert another switch after the push button the the voltmeter will show 0 and the LED do not work. If i shut down the build and open it again it will work.

If i add yet another switch between the resistor and LED while the simulation is off the LED will not work and the voltmeter show 23.86 uV. If i close the build and open it again the volt meter will show 5V but the LED will not work. If i add the third switch while the simulation is running the volt meter will show 5V from the start but the LED will not work.

So something is fishy in my system at least.

Björn
Attachments
SimulIDE 0.4.15 Tester builds AttachmentSkärmklipp.PNG
You don't have permission to download attachments.
(25 Kb) Downloaded 0 times

5SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Thu Aug 12, 2021 6:07 pm

arcachofo

arcachofo

Strange that you do not get the same result as me
Yes, maybe i'm not doing exactly what you did, but this is how it is working for me:



I tried saving and opening again and all kind of combinations that came to my mind.
In all cases the circuit worked the same.


but below test finally explains why my builds never work..!!
I don't think those issues are related.
Just add a voltimeter in the Arduino circuit and see what happens.

6SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Thu Aug 12, 2021 9:52 pm

arcachofo

arcachofo

Finally I could reporduce the issue...

Problem arises if you don't stop the circuit before doing changes.

I think this will be changed to force simulation stop if changes are done.

7SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Fri Aug 13, 2021 1:34 am

bjosol



Halloj
Two comments.
First of all i forgot to mention that in some of the tests the LED on the Arduino board lit up even if the LED on the breadboard did not.

Secondly i see you put the components on the board differently.
I place them and then pull a cable betwen then while you "connect " them and then pull them out on the breadboard.
Maybe my way of pulling cables dont really connect to the components.

actually three comments, the times i succeeded mostly was actually when the simulation ws running. I had less success when it was stopped.

No four... the times when i have set the simulation to "animate" so the powered cables change colour (great feature by the way) then it change colour all the way to the resistor but not to the LED even if the LED light up with the exeption of the build where i have put a switch between the resistor and the LED. There it change colour past the resistor to the closed switch but not past it and this LED do not light up.

Björn

8SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Fri Aug 13, 2021 6:22 am

arcachofo

arcachofo

Secondly i see you put the components on the board differently.
I place them and then pull a cable betwen then while you "connect " them and then pull them out on the breadboard.
Maybe my way of pulling cables dont really connect to the components.
There is no difference.
If you want to try my method just press Ctrl key while touching two pins and separate then.


the times when i have set the simulation to "animate" so the powered cables change colour (great feature by the way) then it change colour all the way to the resistor but not to the LED even if the LED light up with the exeption of the build where i have put a switch between the resistor and the LED. There it change colour past the resistor to the closed switch but not past it and this LED do not light up.
Yes, that makes sense:
Before the resistor voltage is around 5 V which is > 2.5 V, so High state => Red color.
After the resistor voltage is around 2.4 V which is < 2.5 V, so Low state => Blue color.


First of all i forgot to mention that in some of the tests the LED on the Arduino board lit up even if the LED on the breadboard did not.
the times i succeeded mostly was actually when the simulation ws running. I had less success when it was stopped.
I can't reproduce this 2 things.
For me if I do the changes while the simulation is running it always fail.
If I stop the simulation, them do the changes, then start the simulation, it always work ok.

Even if I do the changes while simulation is running, if I stop and start again, it works ok every time:

9SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Fri Aug 13, 2021 7:19 am

bjosol



Ok now i see what we do different
I sometimes just pause the simulation and then do the changes and other times i power off the circuit while you consequently power off the circuit. Now i can also reproduce what you showed in the film clip.
If i power off and on after a change then it works as it do in the film clip.
Power off is the thing to do then.

That is why it seem to be so randomly for me, sometimes it works and sometimes not.

Björn

10SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Fri Aug 13, 2021 9:15 am

arcachofo

arcachofo

Yes, pausing and stoping are very different internally:
- Pausing just stops the execution of the simulation then resume it in the same point it was before.
- Stoping also stops the simulation, but restarts everything.

I was thinking in forcing simulation stop if changes are made in the circuit (0.5.16 works this way).
But this is a big change, better try to fix this issue.

11SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Sun Aug 15, 2021 2:26 pm

bjosol



Halloj
After fiddling a little i realize the power button dont only affect when the breadboard is re-built but also if you change something in the software for the Arduino board.

As a side note i have a few times ended up with connection problems when connecting the resistor directly to the LED but if i put a short piece of wire inbetween it works (see attached pictures).

The voltmeter screen dump is a bonus, cant remember in wich test i got that one but when powering of the circuit and on again it went back to normal.

Björn
Attachments
SimulIDE 0.4.15 Tester builds AttachmentThis LED do not light up.PNG
You don't have permission to download attachments.
(33 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentThis LED will light up.PNG
You don't have permission to download attachments.
(30 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentVoltmeter go bananas.PNG
You don't have permission to download attachments.
(7 Kb) Downloaded 0 times

12SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Mon Aug 16, 2021 12:59 am

arcachofo

arcachofo

After fiddling a little i realize the power button dont only affect when the breadboard is re-built but also if you change something in the software for the Arduino board.
This depends on the property "Auto load", if set, the Arduino will re-load firmware at simulation start.

As a side note i have a few times ended up with connection problems when connecting the resistor directly to the LED but if i put a short piece of wire inbetween it works (see attached pictures).
In simulide, Pins are only connected if there is a connector.
If you just put it toguether they are not connected.
With the exception of Probe, that can read voltages without being connected.

The voltmeter screen dump is a bonus, cant remember in wich test i got that one but when powering of the circuit and on again it went back to normal.
That's funny.
I will have a look and try to avoid situations like this.

13SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Tue Aug 17, 2021 2:32 pm

bjosol



Okidoki, well noted.
I found the auto load and will try and remember the connection issue.

Now i am going to sound like i am whining but i think i stumbled on another issue.
i am just trying to learn the programmig and the attached layout should as far as i understand work with a boolean instead of an int as data type but it doees not. If i change to an int the layout work but the attached sketch do not.
Or maybe i have misunderstood booleans completely.

Björn
Attachments
SimulIDE 0.4.15 Tester builds AttachmentBreadboard.PNG
You don't have permission to download attachments.
(16 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentSketch.PNG
You don't have permission to download attachments.
(16 Kb) Downloaded 0 times

14SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Tue Aug 17, 2021 8:03 pm

arcachofo

arcachofo

You are using variable inPin for 2 things.
If you use int inPint = 7 to hold the pin number.
You need another variable to hold the value of digitalRead().

And...
booleans can hold 2 values "true" or "false".
you can indeed "feed" an integer into a boolean, but it will take 0 as false and !=0 as true.

So..... boolean ledPin = 13;
Means boolean ledPin = true;

But you can't do:
   pinMode( true, OUTPUT );
   digitalWrite( true, HIGH );

digitalWrite and pinMode need a pin number.

If you do this, it will work:
   pinMode( 13, OUTPUT );
   digitalWrite( 13, HIGH );

15SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Wed Aug 18, 2021 6:22 am

bjosol



Halloj
Thank you very much for your feedback.

That was a bit of a revelation for both points and it cracked a nut that i have refused to understad for a while.

Björn

arcachofo likes this post

16SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Thu Aug 19, 2021 2:20 pm

bjosol



Halloj
Back to the volt meter again
Had the same thing happen that it showed a lot of figures.
Today i also started a new layout and when dragging new voltmeters to the breadboard some of them where showing GV from the start. I dragged ut 7-8 of them and i randomly get a volt meter with GV and others that are ”normal”.
I deleted all and next time i drag out volt meters one minute later i only get the ”normal” one.  
At the end of the build i drag out a few new ones just to see and the third and fifth is again GV (see screen dump).

Just thought i should let you know.

Björn
Attachments
SimulIDE 0.4.15 Tester builds AttachmentGV.PNG
You don't have permission to download attachments.
(5 Kb) Downloaded 0 times
SimulIDE 0.4.15 Tester builds AttachmentEnd of build.PNG
You don't have permission to download attachments.
(21 Kb) Downloaded 0 times

17SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Thu Aug 19, 2021 5:41 pm

arcachofo

arcachofo

Thanks.

I will have a look.

18SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Sun Oct 17, 2021 6:47 pm

arcachofo

arcachofo

Uploaded build at Rev 250.

Download links at first post:
https://simulide.forumotion.com/t260-simulide-0-4-15-tester-builds#1337

19SimulIDE 0.4.15 Tester builds Empty Re: SimulIDE 0.4.15 Tester builds Tue Oct 26, 2021 9:34 am

arcachofo

arcachofo

Uploaded build at Rev 253.

Download links at first post:
https://simulide.forumotion.com/t260-simulide-0-4-15-tester-builds#1337

Sponsored content



Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum