Menu

Subcircuit when to use Fixed Voltage component for inputs and Probe for outputs?

Circuits
Anonymous
2019-07-12
2019-08-12
  • Anonymous

    Anonymous - 2019-07-12

    https://pastebin.com/bTBRneNz

    https://pastebin.com/qCDbX3yC

    I'm guessing that I'll need to move the pot and switches outside the
    package. My question is mainly for Toggle Switch-41, but applies to
    the others I'd guess. The common is connected to Ground, so do I need
    to expose that pin? What about for A and B, they are outputs so the
    natural assumption is that these should be setup as inputs... However
    the value inputted is either NC or Gnd, it's conceivable then that
    this would be better served as an output to ground?

    Thanks for the quick responses, is there a Discord or IRC that would
    be a better fit for questions like this?

     
  • Anonymous

    Anonymous - 2019-07-12

    I bet it would be helpfull to have the project that generated the subcircuit.
    https://pastebin.com/WriX4Y9E

     
  • Santiago

    Santiago - 2019-07-12

    Nice project...

    Not sure wich simulide version are you using, but there are lot of improvements and fixes in all regarding subcircuits in later versions.

    I think you should write to my email to talk about this.

     
  • Anonymous

    Anonymous - 2019-07-18

    I can see that the 74XX189 is going to be a bit of a beast, so I'll want to make sure I've the basics down prior to takcling it.... Plus there is performance to consider, any thoughts?

    https://gitlab.com/cheako/simulide/blob/5ca3edbe5d330fbd60342209c882a5a87749c166/74XX189.simu

     
  • Santiago

    Santiago - 2019-07-18

    You are right, 555 was not working in subcircuits.

    This issue and some other issues in subcircuits are solved in last svn commit (trunk).
    There is also implemented a new much easier system to create packages and subcircuits.
    I think you should definetly try last svn commit (trunk).

    I did a simplified version of your 555 based clock and the corresponding subcircuit, very simple and working well. Think that 2 of the 3 555 are just for debouncing purposes, switches in simulide don't bounce, so these 555 are not needed to get the same functionality.
    Attached all files needed working for last svn commit (trunk).

    Any gate-level subcircuit for this task will be very complex.
    I guess you are working in a complex project with many subcircuits, i think you should try to use the simplest and fastest subcircuits you can, better if you use fast single components instead of gate-level subcircuits. If not you can end up with a huge circuit that will be too slow to simulate.

    To get your project working eficiently in simulide will probably require some more fixes and new components. This is a good chance to test, fix and improve simulide capabilities.

    About null deref in node:
    Fixing that will hide the real problem. the program should never come to this code if there are not connectors in both pins.
    But again... some of these bugs might be solved in later versions.

     
  • Anonymous

    Anonymous - 2019-07-18

    I was thinking about it and the answer is more philosophical than logical. If the goal was just to play with an emulated bread board computer it would be much simpler to whip up something along the lines of the Virtual Apollo Guidance Computer software. The power of using software like SimulIDE would simply be lost if a circuit was engineered to only function inside SimulIDE. Thus I think it's important to duplicate this computer in such a way as to map out(or design) the intended real-world solution. One area of exploratory compromise is using components that might be difficult or impossible to come by. What would become of such a circuit, given it could not reasonably be built? I think that's the measure that design decisions should be weighed, if the design would not function IRL the same as it does in SimulIDE then the compromise would seem to go too far.

    I'm fine using 0.2.9, I understand it's not supposed to be a LTS but it does appear to be the latest release. I wouldn't mind patching a list of discovered flaws that were fixed in trunk, does such a list exist? The main issue with testing and unstable is that there may be a handful of flaws that were corrected, but it's more than possible that a greater number of flaws were introduced. Ignore the number of flaws, the severity of flaws will increase inversely proportional to the age of the flaw. It's significantly better to have a handful of old bugs than an unknown number of new ones.

    This might be something you could consider going forward, labeling each commit with a severity so that in the future a query could be made to cherry pick the best commits from trunk. It's not that you need to manage a LTS, but enable the user-base to create a stable version given a release and a collection of notable and noteworthy commits. The hand-waving of "Things are fixed in trunk." has one simple pitfall, unless you can say what's been fixed you can't really show that trunk is significantly better. Is trunk 10% better or only 0.003% better, a notable metric seemingly important for anyone choosing between trunk and something else.

     
  • Santiago

    Santiago - 2019-07-19

    If you stay in 0.2.9, here is a tutorial to create subcircuits:
    http://simulide.blogspot.com/p/blog-page_30.html

    List of changes since 0.2.9:

    New Features:
    - Simulation speed improved.
    - Bjt simulation improved.
    - Bjt: threshold property.
    - Pic open collector pins.
    - About dialog.
    - Circuit properties save to simu file.
    - Text Component: Font property.
    - Seven Segment: configurable led properties.
    - Seven Segment: vertical pins.
    - Resizable Resistor Dip.
    - Mux and Demux shape.
    - Led Brightness more realistic.
    - Animate wires (Logic States).
    - Subcircuit Logic Models.
    - Open Collector Gates.
    - Resizable Latch.
    - Group Logic Components.
    - Terminal monitor labels.
    - Subcircuit inverted pins.
    - Resizable Led Bar.
    - Configurable switches.
    - Disable unused pins.
    - Left-Click+ctrl: select/unselect.
    - Latch: Inverted property.
    - Led Matrix Vertical pins
    - Bidirectional Bus.
    - Diagonal wires.
    - Improbed mosfet switching speed.
    - Latch trigger property
    - Resizable interface font.
    - High dpi screens: font auto-resize (experimental).
    - RamTable: clear some rows, or entire table.
    - Norm. Close Push button.
    - Copy Arduino hex to circuit folder.
    - RamTable: Load all variables from current program.
    - RamTable: Load all values of an array at once.
    - RamTable: Make sections movable.
    - Show Circuit Time and Mcu freq.
    - Show Led polarity.
    - Show Meters polarity.
    - MCU freq. decimal values.
    - Chip/Logic_Symbol for subcircuits.
    - Bjt BC diode.
    - Bjt faster switch.
    - multi-channel plotter, resizable scale.
    - Wave gen. frequency decimal values.
    - Oscope improved.
    - Windows OS console output.
    - Remove selected connectors.
    - Auto-connect pins.
    - Add short info to Component names.
    - Refactoring Bus: Fully analogic bidirectional Buses.
    - Bus start Bit.
    - Debugger GcBasic Step Over (experimental).
    - File Browser: Show hidden.
    - File Browser: Settings bookmark.
    - Graphic Package creation.
    - Ramtable case insensitive.
    - 74 IC Logic Symbols.
    - CD IC Logic Symbols.
    - Help widget and files.
    - Ramtable: 4 cols: Name, Type, Dec.Value, Value.
    - GcBasic: Strings in RamTable

    Bug Fixes:
    - Text size in svg.
    - Potentiometer.
    - Hd44780 rotation.
    - Clock components update.
    - Editor: enter key, crash first time.
    - Some components mouse interaction.
    - Pic serial monitor missing characters.
    - Pic simulation not restarting in some cases.
    - Pic wdt not clean at start.
    - Buses not working for sizes != 8 bit.
    - Fix Gates oscillating in some cases.
    - Issues moving Component with leds (7seg, matrix, etc.)
    - Crash on missing package files in some cases.
    - Redraw Issues (Text and Gates).
    - Move Connectors issues.
    - Subcircuit: not connected pin issue.
    - Component names not correctly translated.
    - PIC16F1823 wrong package.
    - Terminal Monitor issues.
    - Gates resizing issues.
    - Pic Serial, error sending several characters at once.
    - Editor: cursor lost at eof in find/replace
    - Led bright update at low circuit speeds.
    - AVR initialization.
    - Midbutton Circuit panning not working properly.
    - Transistors in subcircuits
    - 74HC574 not working.
    - Open collector gates.
    - ADC, DAC pin numbers.
    - Ledbar resize grounded.
    - Mosfet not working properly at Rdson<1
    - Latch not working in some subcircuits.
    - Logic Comopenets wrong impedances in subcircuits.
    - Resistor and Capacitor wrong values in Subcircuit.
    - Debugger: Line indicator not showing.
    - RamTable show integer negative values.
    - Arduino GND pins not working since 0.3.10
    - Build fails due to missing math.h include.
    - Switches crash: change n. poles with circuit running.
    - Audio Out: crash when null audio device.
    - Plotter not properly synchronized in debugger.
    - Debugger: Arduino Unsigned variables not detected.
    - Debugger: Arduino compiler crashing when no mcu on the circuit.
    - Subcircuit: initEpins issue.
    - Transistors in subcircuits (finally).
    - Latches in old circuits not working afther 0.3.10.
    - Avoid closing document while debugging.
    - Modification in circuit while debugging or simulating MCUs.
    - Atmega8 not working.
    - LM555 power pins.
    - LM555 in subcircuits.
    - Wrong voltage in "PNP biasing" example.
    - Avoid program blocking in "End" GcBasic statement while debugging.
    - Switches not properly removed.
    - Wrong voltage in "PNP biasing" example final fix.
    - Avoid program blocking simulating AVR entering "sleep".
    - Wave gen. frequency accuracy.
    - Wrong Circuit Time.
    - Delete SR04 while running may crash.
    - GcBasic arrays errors in RamTable.
    - Crash setting mcu logic symbol=true.
    - Remove unintended components when removing single wire.
    - Crash removing Arduino in some cases (related to built-in led pin).
    - Problem in RamTable with variables changed in source code.
    - Plotter crashing randomly.
    - ResistorDip in Subcircuits.
    - Wire Lines disconnected in some cases.
    - Animate circuit resets after copy/paste.
    - Copy unintended components if previously selected.
    - Clock in subcircuits.
    - RamTable may crash when not debugging.
    - Filter file types in open dialogs.
    - Debugger fully interruptable.
    - AVR and PIC assemblers not found msg.
    - Adding led while circuit is running (wrong start step).
    - Some missing icons.
    - Relay: crash in changes when circuit running.
    - Keypad: crash in changes when circuit running.
    - LedMatrix: properties reset at size change.
    - 7segment: color reset at size change.
    - Subcircuit: error not cleared when package not found.
    - Volt. Reg: voltage not updated until circuit restart.
    - Current Source initialization afther restart.
    - 555 CV pin wrong impedance.
    - 555 not cleanly removed.
    - Values with units in SubCircuits: wrong value.
    - Clock in SubCircuit not cleanly removed.
    - Weird lines in connectors: Moving+Undo connenctors with leght=0.
    - Uppercase asm instructions not recognized.
    - Crash compiling Pic asm with filames containing spaces.

    New Components:
    - Function Component.
    - Dip Switch.
    - BCD to 7s
    - SR04 Ultrasonic Ranging Module
    - Analog multiplexer.
    - Frequencimeter
    - Package
    - Configurable Ram/Rom

    • IC 74:
      74HC75
      74HC85
      74HC137
      74HC139
      74HC147
      74HC148
      74HC154
      74HC155
      74HC160
      74HC161
      74HC162
      74HC163
      74HC190
      74HC191
      74HC192
      74HC193
      74HC194
      74HC238
      74HC283
      74HC390
      74HC393
      74HC688
      74HC4017
      74HC4020
      74HC4022
      74HC4028
      74HC4024
      74HC4040
      74HC4511
      74HC4514
      74HC4515
      74HC4518
      74HC4520
      74HC4543
      74HC181
      74HC174
      74HC182
      74HC590
      74HC592
      74HC4060
      74HC4060
      74HC40102
      74HC40103
      74XX176
      74XX177
      74XX196
      74XX197
      74XX490
      74HC4051

    • CD IC:
      CD4511
      CD4555
      CD4556
      CD4018
      CD4026
      CD4033
      CD4516
      CD40110

    • Pics:
      pic12f1840
      pic16c71
      pic16f87
      pic16f505
      pic16f630
      pic16f676
      pic16f684
      pic16f716
      pic16f871
      pic16f884
      pic16f887
      pic16f913
      pic16f914
      pic16f916
      pic16f917
      pic16f1503
      pic16f1825
      pic18c242
      pic18c252
      pic18c442
      pic18c452
      pic18f248
      pic18f258
      pic18f448
      pic18f458
      pic18f2221
      pic18f2321
      pic18f2420
      pic18f2520
      pic18f4420
      pic18f4520
      pic18f14k22
      pic12c508
      pic12c509
      pic12ce518
      pic12ce519
      pic16c84
      pic16c712
      pic16c716

     
  • Anonymous

    Anonymous - 2019-07-19

    I tried to put this somewhere else, but it doesn't seem like it would fit nicely anywhere. Consider condensing your forum topics, having a home for everything is nice but given the volume it's unnecessary.

    Am I wrong in thinking that the 0.2.9 branch was not created using the svn copy command? I found something that was close and with git was able to rebase.
    http://svnbook.red-bean.com/en/1.7/svn.branchmerge.using.html

    I had a go at mapping these to commits and it starts out great, but eventually the noise to signal causes a rethinking of this strategy. It's odd to me that r458 is when 0.2.9 is created, and indeed it's close to a perfect fit for r457, however the latest commit is only r495!

    Ignore the git commit hashes, they don't mean anything except for what to cherry-pick.

    • Text size in svg.
      r480 a0e79d88ccd1d270ce3d2f933a570aba25cf75c5

    • Potentiometer.
      <what it?="" about=""></what>

    • Hd44780 rotation.
      r474 c56867d22a3f32075f6f66cf6dcfa7a9cde9de1d

    • Clock components update.
      r457?? This is obviously part of r458, well not obviously.

    • Editor: enter key, crash first time.
      r464 9e66c5598e3244a7e8789214c0c6e2f2087c3b6f

    • Some components mouse interaction.
      ??r479?? 16efd40bb6052ffe21933b8b09b08c0ea82c2f92

    • Pic serial monitor missing characters.
      r465 ede98d7ed95b38ab6518dd8d4acc3552d9bb4457

    • Pic simulation not restarting in some cases.
      <descriptive i="" but="" this="" enough,="" commit="" find="" can't=""></descriptive>

    • Pic wdt not clean at start.
      <again, be="" because="" this="" of="" could="" "git="" svn"="" way="" the="" works=""></again,>

    • Buses not working for sizes != 8 bit.
      r483 75661ce478421a45b35a4ef8753a554f8cf2193f

    • Fix Gates oscillating in some cases.
      <potential be="" r458="" of="" should="" part="" not="" found="">
      r431 arcachofo: Improve diode stability in some cases.</potential>

    • Issues moving Component with leds (7seg, matrix, etc.)
      <not found=""></not>

    • Crash on missing package files in some cases.
      <not for="" &="" found:="" except="" r61?="" r60=""></not>

    • Redraw Issues (Text and Gates).
      <potential not="" found="">
      r418 arcachofo: BugFix: Solve probe redraw issue.</potential>

    • Move Connectors issues.
      <not leds="" (7seg,="" description="" attempted,="" found="" previously="" "issues="" etc.)"="" component="" matrix,="" to="" moving="" too="" in="" not="" close="" the="" with=""></not>

    • Subcircuit: not connected pin issue.
      <not found=""></not>

    • Component names not correctly translated.
      <more info="" sound="" like="" effect="" dosn't="" it="" needed,="" an="" ignore="" to="" as="" stability="" tempted="" usability="" or="" delete="">
      Consider moving translations to a seperate repository, it's anoying to have these commits interlaced with code changes. It's like having someone on your team who can't do whitespace correctly, constantly generating whitespace commits.</more>

    • PIC16F1823 wrong package.
      <1823 NOT FOUND, gave up>

    • Terminal Monitor issues.
      <more info="" needed=""></more>

    How many issues, what are there severity?

    • Gates resizing issues.
      <not found=""></not>

    I'm reminded of Louis Rossmann's fav. saying, "For some reason..."

    • Pic Serial, error sending several characters at once.
      <not but="" to="" similar="" bug="" found,="" previous=""></not>

    • Editor: cursor lost at eof in find/replace
      <not found=""></not>

    • Led bright update at low circuit speeds.
      <not info="" found="" needed="" more=""></not>

    • AVR initialization.
      <not found=""></not>

    Last record processed, EOL.

     
  • Anonymous

    Anonymous - 2019-07-19

    I found the commit about the pot, I wasn't aware my searches were case sensitive.

    This commit mixes bugfixes and whitespace, if you must mix code and whitespace change then please don't do that at least. On top of that it dosn't look complete and isn't minimal at the same time.
    https://sourceforge.net/p/simulide/svnrepo/462/

     
  • Anonymous

    Anonymous - 2019-08-10

    I've finished up on the Hazel-rs project I was working on and can take a look back at this. Last time I discovered that many of the commits that were bugfixes wheren't, IMHO, applicable to a stable branch.

    As a side not I went looking for the EEPROM persistance patches, and discovered that many of the most recent commits where lacking in historical content(looks like they are large patchess instead of digestable patch sets). This could explain why I was unable to locate the commits that fixed bugs, they were not commited as patches.

    Is there another repo or something I should be looking at?

     
  • Santiago

    Santiago - 2019-08-10

    No, this is the only repo.
    Since a year or so I'm only using it to upload new versions.

     
  • Anonymous

    Anonymous - 2019-08-11

    That's regretable, my main concern is that there is nothing to bisect when looking into issues. Likewise you are not getting the bennifits of CI.

    Is this because of SVN? I noticed that one of the tags or branches was created using a system copy command instead of an svn copy.

    SVN was never a great solution, many of the things it was supposed to do well it never did and for everything else it was mediocre. SF is also showing it's age, with many projects finding homes elsewhere.

    For example take a look at what CI or static webhosting look like in gitlab: https://gitlab.com/cheako/simulide/pipelines/71992003
    https://cheako.gitlab.io/mikemestnik_net/
    https://mikemestnik.net/ <-- SSL support for free.

     
  • Santiago

    Santiago - 2019-08-12

    Main problem in my side is that i have a very limited amount of time to put here.
    And keeping a repo with proper commits for every single change is very time consuming.
    I prefer using that time actually working in the program and get something usable in years instead of decades.

    in Any case a project like this is just not possible in 0.2.9 , there are too many problems and missing features.

    0.3.12 is intended to be an LTS and it is capable of something like what you want. Indeed i built an small cpu wich helped me to find some bugs, problems and limitations. There is even a hidden very simple "compiler" that generates a data file that can be loaded into program memory.
    There are still some changes to upload, next commit will do it.