Commit Graph

2323 Commits

Author SHA1 Message Date
stefan schippers 29d2541b21 fix regression in get_sym_template() 2024-02-05 16:37:00 +01:00
stefan schippers fa533c725a remove dbg messages 2024-02-05 14:49:20 +01:00
stefan schippers 96494dc73a get_sym_template: fix possible unterminated result string 2024-02-05 13:47:49 +01:00
stefan schippers b2b5b48cfe replace chan configure with fconfigure for older tcl compatibility 2024-02-05 11:49:13 +01:00
stefan schippers 046c23addd add verilog_extra_dir symbol attribute to allow specify "ports by attribute" directions: verilog_extra_dir="VCC=input GND=input" verilog_extra="VCC GND" extra="VCC GND" ....; proc set_netlist_dir will show the last set simulation directory instead of the default ~/.xschem/simulations. Changed background color of menu radiobuttons for clarity. 2024-02-05 11:14:51 +01:00
stefan schippers fdc2fb5517 fix a regression in proc set_paths (erroneusly set file_dialog_files1) 2024-02-05 00:32:24 +01:00
stefan schippers 8ec3e52122 allow parametric models in subcircuits. Symbol inv.sym contains template="... modp=cmos_p_10 ...", pmos instance in inv.sch contains model=@modp, instance format string contains format="@name @pinlist @model w=@w l=@l, result is: "m2 y a VCCPIN VCCPIN cmos_p_10 w=wp l=lp" 2024-02-03 13:43:18 +01:00
stefan schippers 7bfed5907c added lcc[level].prop_ptr and lcc[level].templ printing in `xschem globals` command 2024-02-03 00:42:25 +01:00
stefan schippers 331722ab07 fix too early xctx->currsch increment in descend_symbol() 2024-02-02 10:48:51 +01:00
stefan schippers 304d42b928 Add WM_DELETE_WINDOW action on load_file_dialog widget 2024-01-31 18:54:30 +01:00
stefan schippers 8f3e0be4fe load_file_dialog: checkbutton for displaying only name / full path of component directories 2024-01-30 19:15:08 +01:00
stefan schippers 778dd2c0dc recognize integrated_noise, improve `xschem preview_window` command 2024-01-27 11:42:05 +01:00
stefan schippers a1c2569506 revert previous: print_spice_element(): do 2nd level translate() only on `model` tokens whose value contains @variables. 2024-01-22 18:57:42 +01:00
stefan schippers 24844b3d4c print_spice_element(): do 2nd level translate() only on `device_model` tokens whose value contains @variables. 2024-01-22 18:53:04 +01:00
stefan schippers 1f35fdf05c add `spectrum` type analysis in graph dialog sim type combobox. Make sp and spectrum aliases of ac in read_dataset() and extra_rawfile() 2024-01-22 01:19:27 +01:00
stefan schippers 9ceb274b5e print_spice_element(): when expanding format @variables, if substituted value contains @var do another round of translate() to replace @var with instance assigned var=xxx value 2024-01-21 00:00:01 +01:00
Stefan Schippers 289a979c61 translate() on device_model inst attr: avoid tcl_hook2 in get_tok_value() as already done in translate() 2024-01-20 19:52:16 +01:00
Stefan Schippers e50c6f0df1 pass instance `device_models=...` attribute through translate() so @vars are resolved 2024-01-20 19:40:49 +01:00
stefan schippers 38ff460694 added `xschem fill_reset` command to reset fill patterns defined via tcl array pixdata(n) 2024-01-15 15:53:49 +01:00
stefan schippers c46afdc582 add command `xschem fill_type n fill_type` 2024-01-15 00:45:24 +01:00
stefan schippers 17e24e0f5f has_included_subcircuit(): correctly handle bussed ports in symbol and spice .subckt file 2024-01-14 11:28:51 +01:00
stefan schippers ac04ce5c55 set tab/window title if xschem invoked with `xschem -n file.sch`. fix poweramp.sch testbench for Xyce sim. 2024-01-11 08:19:25 +01:00
stefan schippers a7f1b2a5f1 add Spectrum analysis recogniztion (yet another ac type) in raw files 2024-01-08 23:59:55 +01:00
stefan schippers 6c163d5cb0 has_included_subcircuit(): get symname from `schematic` attribute if set in instance or symbol, or use actual symbol name, add tb_symbol_include.sch example circuit 2024-01-08 17:19:12 +01:00
stefan schippers 8c55f3a99e add `hide=instance` attribute for in-symbol text objects (in addition to hide=true or hide=false). If set the text is invisible in instantiated symbols, but is visible if descending into the symbol 2024-01-08 15:47:01 +01:00
stefan schippers 0597bae9dc various improvements for automatic port order detection from included subcircuit via spice_sym_def and @pinlist in format string, documentation updates in tutorial_use_existing_subckt.html 2024-01-08 14:57:21 +01:00
stefan schippers d2c6566030 when doing spice netlist, if a symbol has the spice_sym_def attribute set and is using @pinlist in format string for port order, get the port order from the subckt given in spice_sym_def, either directly or through a .include line 2024-01-08 03:24:59 +01:00
Stefan Schippers 0f7785d588 initial implementation of `has_included_subcircuit()` 2024-01-07 19:51:48 +01:00
stefan schippers f0e739cf02 .load.l.paneright.list better positioning (remember last selection), print_spice_subckt_nodes(): use my_mstrcat() instead of fprintf, for future enhancements 2024-01-06 12:14:36 +01:00
stefan schippers dcef3d4b9d waves_callback(): do not set GRAPHPAN when setting cursor position numerically 2024-01-05 11:21:34 +01:00
stefan schippers 1fa490b066 some fixes on numerical cursor adjustments (for log X scales) 2024-01-05 03:13:51 +01:00
stefan schippers 90ce40da2c Right click on a graph cursor allows to set the cursor position numerically 2024-01-05 02:08:13 +01:00
stefan schippers 7982c67bf6 display cursor difference measurement also in log x axis graphs 2024-01-04 01:41:40 +01:00
stefan schippers 6215a89605 fix verilog_bitblast not declared as global in proc netlist (typo) 2024-01-02 23:18:00 +01:00
stefan schippers d77fb43e5e Configure simulators and tools: rearrange buttons behavior: `Accept, no SAve and CLose` and `Accept, SAve and Close` 2024-01-01 10:54:05 +01:00
stefan schippers d91daea84c extend interval raw file loading to `xschem raw read file type sweep1 sweep2` 2024-01-01 01:28:28 +01:00
Stefan Schippers cd6deb0bf9 xschem raw_read: allow specifying t1 and t2 to load only a portion of simulation file 2023-12-31 20:33:08 +01:00
stefan schippers 64ca25b9fe proc netlist: do not attempt to change a button color if xschem started with -x (no X) 2023-12-28 23:28:18 +01:00
stefan schippers a95e3597bc Implement vertical flip (shift-V) and vertical flip in place (alt-v), change netlisting mode command moved to bindkey ctrl-shift-V; when opening insert component dialog focus the File/Search entry box 2023-12-23 00:06:01 +01:00
stefan schippers fbfbef384c when pressing netlist button or executing `xschem netlist` command turn Waves button (if waves are loaded) to yellow to indicate old waves are shown 2023-12-22 16:28:49 +01:00
stefan schippers 77c99c2202 handle xyce y-devices in nspice netlists 2023-12-22 12:01:55 +01:00
stefan schippers f50a3b15fa doc updates (graphs) 2023-12-18 23:36:01 +01:00
stefan schippers 2a8c5e487a avoid %%BeginSetup, %%BeginPageSetup if doing eps 2023-12-12 02:18:31 +01:00
stefan schippers 78b26fc36d add missing %%EndSetup DSC comment 2023-12-12 01:59:27 +01:00
stefan schippers 61ad259ac9 removed redundant %%trailer dsc comment 2023-12-12 01:27:59 +01:00
stefan schippers ed477b90a5 eps export 2023-12-12 01:14:40 +01:00
stefan schippers 441e27e8ca preserve existing line width when creating new windows / tabs 2023-12-11 18:59:46 +01:00
stefan schippers bf0ef23739 setting line width in View menu will automatcally disable change line width with zoom 2023-12-11 18:31:19 +01:00
stefan schippers 379938fe03 if selection is present when exporting pdf assume it is a bboxed pdf, do not print page title. Fix set_viewport_size setting line width to 1 instead of using current value 2023-12-11 18:28:23 +01:00
stefan schippers b95289ca5e better line width calculation / restore in export images 2023-12-11 16:06:49 +01:00
stefan schippers 7e820d05b0 update docs about new additions to the `xschem print` command 2023-12-11 15:22:36 +01:00
stefan schippers 4cb060f817 better placement of graphs in image exports. If something is selected export image will export selection. Add ability to specify area to print in ps/pdf export (set media size to bbox) 2023-12-11 15:18:46 +01:00
stefan schippers f042b940c2 add xschemrc option ps_page_title (default: enabled, 1) to set or hide page title in ps/pdf exports, more precise graph exports in svg and ps/pdf 2023-12-11 10:43:09 +01:00
stefan schippers c360187d8a fast option in `xschem unhilight_all` 2023-12-10 22:15:20 +01:00
stefan schippers 39769187d3 add `xschem set cursor[12]_x` commands for moving graph cursors 2023-12-10 00:28:44 +01:00
stefan schippers 7a39f4d6ca better resolution of exported graphs in ps/pdf and svg 2023-12-09 23:39:33 +01:00
stefan schippers 1285ba0cd4 while opening a sub-schematic in another window propagate cursora/b/ annotate info 2023-12-09 13:26:18 +01:00
stefan schippers c8ced06bbe add `fast` option in xschem hilight_instname. mos_power_ampli: use hilight to show devices with high current 2023-12-09 11:39:04 +01:00
stefan schippers b21ac67cc4 add `xschem set hilight_color` command 2023-12-09 02:09:36 +01:00
stefan schippers eb471528f9 better cut wires inside symbols --> break_wires_at_pins(1) 2023-12-09 00:32:41 +01:00
stefan schippers e23345ad0b removed some #ifndef-ed code in cairo_jpg.c 2023-12-08 13:38:36 +01:00
stefan schippers e53ca7fff8 xschem setprop: if new attribute changes symbol (as in case of generators) do a match_symbol() to update 2023-12-08 00:36:49 +01:00
stefan schippers d094ef55b7 fix setting old_translated_sym in update_symbol() 2023-12-07 18:28:44 +01:00
stefan schippers a0237b59b3 eliminated some redundant operations on instance flags (set_inst_flags() does the job) 2023-12-07 18:07:42 +01:00
stefan schippers 8c81f629d0 fix a regression introduced by saving/restoring tcl context in preview_window() 2023-12-07 16:02:31 +01:00
stefan schippers 8269eff430 save / restore tcl context when creating / destroying preview window 2023-12-05 18:50:46 +01:00
stefan schippers b8fecf997b avoid showing alert box if enabling / disabling stretch mode by bindkey 2023-12-05 17:32:48 +01:00
stefan schippers c090773afe Opening sub-schematic in new window/tab will inherit raw file loaded and annotation. ngspice::ngspice_data is preserved on context switches now 2023-12-05 13:13:59 +01:00
stefan schippers b2aad10650 changed attribute text_n_size to text_size_n (for efficienty reasons), improved get_tok_val() (use strstr for quick return "" if no token found) 2023-12-03 23:11:36 +01:00
stefan schippers 28ed1351f1 spice.awk: do not join user code lines 2023-12-03 21:33:03 +01:00
stefan schippers 6648652ae5 allow instance attribute `text_n_size=s` (where s is a double and n is an integer) to set symbol text item `n` to size `s` 2023-12-03 12:26:18 +01:00
stefan schippers 6c1dadd27c flush unused symbols at end of netlist 2023-12-02 23:25:54 +01:00
stefan schippers 8305024cd6 break.awk: do not break user code lines in spice netlists 2023-12-02 23:00:44 +01:00
stefan schippers b2965f4c3d attribute default_schematic=ignore: if set in a symbol xschem will not descend into the default schematic associated to symbol. Instances MUST specify a schematic attribute 2023-12-02 13:17:32 +01:00
stefan schippers 5cb5ec9031 local_netlist_dir: use only last path component of schematic when creating simulation directories 2023-12-02 04:28:04 +01:00
stefan schippers c424a25d66 add xctx->last_command in xshem globals debug command 2023-12-02 00:58:57 +01:00
stefan schippers a797bc593f when in `persistent command` wire or line placement mode, a first escape clear the ongoing placement, a second escape clears the wiring or line-ing command 2023-12-01 23:05:07 +01:00
stefan schippers b9ef032a2a Add SImulation radiobutton for setting local netlist directory as [library]/simulation/[cellname]. Change netlisting directory if `set local_netlist_dir` is set via --tcl cmdline 2023-12-01 14:08:42 +01:00
stefan schippers 37c6229a21 xinit.c: do a `xschem set format lvs_format` if lvs_netlist is set via xschemrc or command line 2023-12-01 12:11:12 +01:00
stefan schippers 4090011a64 avoid tk_messageBox in reload schematic warning message (blocks event loop). Avoid using xschem specific XSCHEM_SHAREDIR in utile/utile (can be used standalone) 2023-11-30 20:52:28 +01:00
stefan schippers b507276fa0 fix add bus in graph dialog (use ; separator after bus alias name) 2023-11-30 04:15:33 +01:00
stefan schippers 159460efd4 fix unneeded extra_rawfile switch back in graph_fullyzoom() 2023-11-30 01:00:25 +01:00
stefan schippers 898d0538a0 Allow tcleval() in vhdl_format attributes, allow intance setting of vhdl_format (override symbol). Add missing space in @pinlist expansion in print_verilog_primitive and print_vhdl_primitive 2023-11-29 13:46:24 +01:00
stefan schippers 30b77d7447 allow tcleval() in verilog_format attributes, allow intance setting of verilog_format (override symbol) 2023-11-29 12:20:35 +01:00
stefan schippers c069afcc40 fix occasional crashes due to graph_fullxzoom() getting sweep variable index in raw file before switching to graph-specific raw file 2023-11-29 01:26:45 +01:00
stefan schippers 83c692caa9 copy between windows: allow to navigate between more than 2 windows 2023-11-28 18:41:38 +01:00
stefan schippers e467c5641d fix a crashing bug if aborting (in destination window) a copy operation between different windows ( hash_wire(XDELETE...) ) 2023-11-28 15:26:27 +01:00
stefan schippers e25ded5e74 expandlabel(): if a node name begins with `$` assume it will be processed downstream by some scripts. Don`t expand anything 2023-11-28 12:24:43 +01:00
stefan schippers 28bf3b57cf rename some myload_* stuff to file_dialog_* 2023-11-27 15:08:15 +01:00
stefan schippers 4e650811db fix proc ev and proc evo not evaluating correctly braced {...} expressions 2023-11-27 12:42:49 +01:00
stefan schippers fdc3ceefeb vsource.sym and ammeter.sym no more use tcleval() to handle @savecurrent attribute (calling tcleval() is overkill for such a trivial task and may expose to side effects if $ (and other) characters are used ) 2023-11-27 12:13:53 +01:00
stefan schippers 26fbb82f6b fix unwanted head_undo_ptr change when doing a netlist. Add current backannotation info in capa.sym, ind.sym, isource.sym, isource_table.sym 2023-11-27 00:01:45 +01:00
stefan schippers c4e9310d45 allow to load raw files even if netlist type set to `symbol`. Better to_eng function, `xschem raw_query value node {}` returns value at cursor b position 2023-11-26 12:54:37 +01:00
stefan schippers 1dfca8e256 add file_dialog default_geometry variable to set file / component selector initial size. Better panes width allocation and stretching 2023-11-25 23:44:09 +01:00
stefan schippers d71122bb68 update pv_ngspice.sch 2023-11-24 18:22:10 +01:00
stefan schippers 3449d25681 wm transient: set relative to parent window (which is not always `.` in windowed interface). 2023-11-23 22:24:52 +01:00
stefan schippers 1f4b437593 proc waves: set semaphore only for external viewers run in foreground 2023-11-23 00:28:09 +01:00
stefan schippers 7a5d649adc (2) fix wrong list of viewers in proc set_sim_defaults and unsetting semaphore in proc waves 2023-11-23 00:01:02 +01:00
stefan schippers 76540724df fix wrong list of viewers in proc set_sim_defaults and unsetting semaphore in proc waves 2023-11-22 23:50:17 +01:00
stefan schippers aafe94822a save_file_dialog: file filter by default set to `*` (show all files) 2023-11-22 01:41:16 +01:00
stefan schippers eb6f9f1f4e fix a small memory leak in spice_netlist.c 2023-11-21 10:48:56 +01:00
stefan schippers 8d155af82f `Alt-e` does a true descend sub-schematic and opens it in another window 2023-11-20 17:53:28 +01:00
stefan schippers d4cde62870 add draw option in schematic_in_new_window(), create_new_tab(), create_new_window() 2023-11-20 00:12:13 +01:00
stefan schippers 2c773c4a25 poweramp.sch and mos_power_ampli.sch updates 2023-11-19 12:52:57 +01:00
stefan schippers f4f61d23a6 comments added 2023-11-18 23:13:52 +01:00
stefan schippers 84d945238f `xschem annotate_op file [level]`: added `level` optional integer to specify the hierarchy level op raw data refers to. Add xschem set raw_level to modify the raw level loaded raw file refers to 2023-11-18 12:55:57 +01:00
stefan schippers 2c48b7399e update manual page for sky130 installation (switch from adms to openvaf) 2023-11-18 12:03:09 +01:00
stefan schippers 7da63c19e2 regression fix: xschem netlist did not return exit code 2023-11-18 01:49:50 +01:00
stefan schippers 2dac7f1735 added execute(exitcode,id) will not be deleted at end of sim. proc graph_tag_nodes works with or without graphdialog open. If it is open it will tag nodes therein, if not it merely returns start and end indexes of nodes in its txt argument 2023-11-17 21:36:34 +01:00
stefan schippers 41f66117e9 more code in proc graph_tag_nodes 2023-11-17 14:32:25 +01:00
stefan schippers 48a9a94ab2 offloaded proc graph_tag_nodes from proc graph_update_nodelist, moved rcode and colors into tctx:: context 2023-11-17 14:05:49 +01:00
stefan schippers 913614b558 some fixes in draw() (transform multiple op in dc sweep also if per-node rawfile specified), handle per-node rawfile in graph_fullyzoom() 2023-11-17 01:20:52 +01:00
stefan schippers 397293f227 spice netlist: use symbol for port list of top level schematic only if it is of type subcircuit 2023-11-16 23:37:16 +01:00
stefan schippers 760fbbbc4a allow newlines in (quoted) node names in graphs:
"alias_name;
node_name %
dataset raw_file.raw sim_type
"
2023-11-16 02:58:26 +01:00
stefan schippers a50bfb3622 when doing spice netlisting if top level has a symbol (and the symbol has i/o ports) use the symbol for printing the top level subckt port list. This ensures same port ordering when netlisting a testbench containing a component and netlisting the component itself. Tab context menu: open Symbol / open Schematic will use the search_schematic setting and search counterpart accordingly. 2023-11-16 01:26:55 +01:00
stefan schippers 5117001a9c revert changes: `allow tcleval() in node alias names` and `allow tcleval(xxxx) in % dataset specification on graph nodes`: just wrap the whole list of nodes (including aliases, % specifications et all) into a tcleval(...) 2023-11-16 00:02:25 +01:00
stefan schippers c85727ae62 draw_graph(): revert back tcleval() on node, color, sweep graph attrs 2023-11-15 21:27:05 +01:00
stefan schippers be914f4ee4 raw_read(): clear text floater caches if a rawfile is successfully read 2023-11-15 21:04:10 +01:00
stefan schippers b1f72ada59 isonlydigit() will return true also for negative integers 2023-11-15 20:15:02 +01:00
stefan schippers 83345932a5 allow to specify per-node raw file in graphs with the syntax: alias_name ; node_name % [dataset] [rawfile] [sim_type] 2023-11-15 19:18:28 +01:00
stefan schippers babd340da9 report previous netlist error also if doing current level only netlist 2023-11-15 00:32:41 +01:00
stefan schippers 5d3b7bd7d0 report error if trying to do a netlist and the file can not be written (example: broken simulation symlink) 2023-11-14 23:40:41 +01:00
stefan schippers 852f2bd25d remove dbg stuff 2023-11-14 02:15:07 +01:00
stefan schippers d0ee3a34fa fix additional intersection checks in `proc touches` 2023-11-14 02:12:23 +01:00
stefan schippers 8c431a51f8 allow to block change color of selected waves using text selection in signal list 2023-11-14 01:22:41 +01:00
stefan schippers b691021f66 typo in my_strdup2() dbg message 2023-11-13 23:52:50 +01:00
stefan schippers f4df48813f copy_hierarchy_data() initial implementation for future hierarchy cloning. Alt-Shift-E and Alt-Shift-I to edit schematic / symbol in a new xschem process. `xschem raw switch`: allow also integer index (as returned by `xschem raw info`) instead of `file type` to switch raw file 2023-11-13 18:00:30 +01:00
stefan schippers 0bc0f8e5eb read_dataset(): better get name of unknown sim types from raw file 2023-11-12 22:11:51 +01:00
stefan schippers 52291c562d reset_caches() back into prepare_netlist_structs() (no measurable slowdown) 2023-11-12 20:56:57 +01:00
stefan schippers 6360fc1700 refactor reset_flags() to reset_caches(). scripts that set tcl variables that go into attributes via tcleval() should call `xschem reset_caches` to get all things updated. 2023-11-12 20:53:37 +01:00
stefan schippers 0df3cfcc7b better recognize global nets in LCC schematics (translate(), @spice_get_voltage(..) ) 2023-11-12 13:43:31 +01:00
stefan schippers ecca0ba2be better swap_windows() function (used when closing a window in multi-window(non-tabbed) interface, resolved_net() recognize global nodes. remove static data from record_global_node(), put in xctx. Remove dead code from translate() (@spice_get_voltage) 2023-11-12 13:01:11 +01:00
Stefan Schippers 8c29d0e812 fix error in capa-2.sym and missing check for null xctx->inst[].instname in get_pin_attr() 2023-11-11 20:03:20 +01:00
stefan schippers 8856ab6e0d add min() and max() clipping functions in wave calculator 2023-11-11 12:13:38 +01:00
stefan schippers d4b8f25455 xschem raw_read just loads or reloads the waves, does not toggle. use xschem raw_clear to unload 2023-11-11 11:40:36 +01:00
stefan schippers f3aac428a4 fix rel_sym_path when XSCHEM_LIBTRARY_PATH contains paths with trailing `/` 2023-11-11 11:30:27 +01:00
stefan schippers bdd641cad3 allow tcleval(xxxx) in % dataset specification on graph nodes 2023-11-11 00:03:22 +01:00
stefan schippers 2a67e60376 allow tcleval() in node alias names 2023-11-10 23:42:09 +01:00
stefan schippers 117f071500 fix del() function in wave processor (did not plot the right %n dataset if specified) 2023-11-10 23:23:13 +01:00
stefan schippers 7368344d85 waves callback(): absolute X panning will not switch raw file if no rawfile is specified in graph 2023-11-10 18:50:58 +01:00
stefan schippers ccc5dab228 better wire connection dot sizing at small smap values 2023-11-10 17:43:41 +01:00
stefan schippers 1991b409e0 fix small memory leak 2023-11-10 15:43:36 +01:00
stefan schippers 3f85766c10 add debug_tcleval variable for specific debugging of tcleval() constructs in the schematic 2023-11-10 14:57:37 +01:00
stefan schippers 565ab605cf better xschem raw clear comand (if rawfile and sim_type specified delete only specified simulation data, not all analyses of rawfile) 2023-11-10 12:24:21 +01:00
stefan schippers 87f9a4e09b reset floater caches on save(As) schematic - better done 2023-11-09 19:20:17 +01:00
stefan schippers 1b737c4ac7 reset floater caches on save(As) schematic 2023-11-09 19:13:55 +01:00
stefan schippers 40e66122e8 typo in xschemrc 2023-11-09 17:32:25 +01:00
stefan schippers 769c7d4663 Add incremental_select tcl variable. It is normally set. If set show selected objects while dragging a selection rectangle. If unset show selection at end of drag operation. Fix possible endless loop whiel zooming on X axis if raw file has only one point (OP). Also if graph specifies custom plot switch to that raw file to get correct x range. 2023-11-09 16:41:53 +01:00
stefan schippers 8231cd65db set_first_sel(): returns first selected element (if any) 2023-11-09 15:12:56 +01:00
stefan schippers 584f88fba1 object iterator, object spatial hash table for all objects. tbu in the future maybe. Fix crashing bug when copying ngspice_probe.sym if annotation is enabled 2023-11-09 13:57:58 +01:00
stefan schippers 35359aed20 backannotate_at_cursor_b_pos(): allow backannotating b cursor on graphs created from multiple OP points 2023-11-09 04:10:06 +01:00
stefan schippers 7d92a32f5e added Waves ->Op in addition to Waves->Op annotate 2023-11-09 04:04:43 +01:00
stefan schippers 518250b3cc Waves->OP does backannotation, not only loading OP raw file; removed Simulation->Graph->load/unload raw file (redundant, now in Waves) 2023-11-09 02:49:02 +01:00
stefan schippers 3751104b34 graph dialog: file selector for graph-specific raw file 2023-11-09 01:59:17 +01:00
stefan schippers 22bd6733fc better alert_ dialog, tab ctx menu: do not try to open netlist if not existing (yet), Simulation->set netlist dir will disable local_netlist_dir 2023-11-09 01:21:12 +01:00
stefan schippers 75c8376a04 fix draw_crosshair when xctx->semaphore not zero, fix tabs context menu issues with `open schematc/symbol`; set_modify: do not attempt to reconfigure menu buttons (Simulate-Netlist-Waves) if invoked from preview dialog 2023-11-08 22:45:31 +01:00
stefan schippers 4fef5e2761 enhanced Waves menu button, "Use simulation dir..." option does not pring up file selector 2023-11-08 11:16:43 +01:00
stefan schippers ed9d6905de handle errorCode=NONE (close pipe was with error but no error code) 2023-11-08 04:02:33 +01:00
stefan schippers b51af6422e call simuldir if doing netlist from commandline (xschem -x -r -n -s -q ... ) 2023-11-08 03:46:36 +01:00
stefan schippers 4ff28fd39d avoid calling simuldir in load_schematic when traversing hierarchy during netlisting 2023-11-08 02:52:50 +01:00
stefan schippers c485e7ef7a better handle error color codes for processes that get killed 2023-11-08 02:27:56 +01:00
stefan schippers eb7ad4cd8e cleanup set_netlist_dir tcl proc 2023-11-08 00:44:29 +01:00
stefan schippers a128df47e0 proc simuldir: set directory to [xschem current_dirname]/simulation but do not create it until doing the netlist 2023-11-07 23:39:18 +01:00
stefan schippers acbe76329c execute_fileevent: polling for processes that do close stdout 2023-11-07 18:10:33 +01:00
stefan schippers f04477d236 if local_netlist_dir is set to 1 change netlist_dir at circuit load (and save-as) 2023-11-07 17:25:18 +01:00
stefan schippers 41ade18616 fix previously disabled kill for foreground subprocess via Simulate button 2023-11-07 15:37:40 +01:00
stefan schippers 98a95b7f6b proc simulate: handle foreground processes correctly 2023-11-07 14:25:36 +01:00
stefan schippers c57d5d815f kill_running_cmds: do not try to kill process if execute(pipe,...) not existing; simulate_from_button : don`t do further actions and forget if no process was killed; proc simulate: dont set tctx::...simulate_id, change button color if invoked in foreground 2023-11-07 14:10:16 +01:00
stefan schippers 366fa86d57 do not sel tctc::*_simulation_id var if no process was started due to errors /missing command 2023-11-07 12:44:56 +01:00
stefan schippers 089592122d fix mis-interpretation of % as a dataset designator when present in wave alias names 2023-11-07 01:05:45 +01:00
stefan schippers a5b65ea494 add execute(win_path,$id) variable to keep track the tab/window subprocesses started from, for cleanup buttons 2023-11-07 00:40:57 +01:00
stefan schippers aeafaf5052 execute_fileevent: delete ..*simulate_id only if called from related id 2023-11-06 19:14:32 +01:00
stefan schippers 71f5994798 reset simulation button on save AS 2023-11-06 19:03:19 +01:00
stefan schippers 714724561d add a catch {} in execute_fileevent (non existent ..._simulate_id var) 2023-11-06 16:59:14 +01:00
stefan schippers 98def78164 simulation button will go yellow while sim is running.Clicking a yellow simulate button will kill simulation. 2023-11-06 16:47:14 +01:00
stefan schippers f531422761 restore semaphore on simulate button to avoid multiple clicks running multiple identical sims. 2023-11-06 03:07:20 +01:00
stefan schippers e5431d86c5 fix setting netlist button color code statwe variable (tctx::...._netlist) 2023-11-06 01:44:25 +01:00
stefan schippers 881d8a4ed9 various fixes for Simulator/Netlist button color codes 2023-11-05 14:13:20 +01:00
stefan schippers 27114408ec reset simulate and netlist button colors on load new file 2023-11-05 02:42:06 +01:00
stefan schippers a6fa6135c9 remove debug msg 2023-11-05 01:51:34 +01:00
stefan schippers 4a0c007540 fix yet another issue with set_modify() 2023-11-05 01:42:25 +01:00
stefan schippers 3bd3956042 Netlist and Simulate buttons will be colored in red or green depending on the outcome of the associated operation 2023-11-05 00:14:55 +01:00
stefan schippers 88e7f4fea4 fix a problem in set_modify() (inconsistent prev_set_modify state after netlist of modified circuit) 2023-11-04 22:50:57 +01:00
stefan schippers cfdaebf5e1 add `xschem instance_number` command to easily get/set the position of instance in the list 2023-11-04 20:43:04 +01:00
Stefan Schippers 299b29bf87 fix parameter count check in xschem getprop 2023-11-04 18:46:26 +01:00
Stefan Schippers a5f660e54a improve drawing quality of crosshair with (now default) fix for broken gpu enabled 2023-11-04 18:29:15 +01:00
Stefan Schippers fd5a1e0bdf fix draw_crosshair() (dont get obscured by rubber placement) 2023-11-04 15:56:42 +01:00
stefan schippers 4be10f1707 remove dbg message 2023-11-04 15:07:09 +01:00
stefan schippers 7022fbf073 xschem simulate sets the Simulate button color. removed redundant proc simulate_button 2023-11-04 14:49:15 +01:00
stefan schippers bd43be9be6 rename a local variable to make tcc happy 2023-11-04 12:03:41 +01:00
stefan schippers 0b93634fee Better Simulation->Graphs-> Load raw file (ask filename) 2023-11-03 23:37:09 +01:00
stefan schippers a5ee182d59 add some Symbol menu entries (place net label / change instance texts to floaters) 2023-11-03 15:10:22 +01:00
stefan schippers 2c26bfbaa9 fix some garbage while moving / copying and zooming. faster draw_selection(gctiled) if big selection (use a single XCopyArea), do not allow to descend/go_back if other UI action is pending, initial implementation of `xschem floaters_from_selected_inst` command, get_tok_val() allow quotes in tokens, like a"22"33=123 even if with_quotes unset (it is intended for token values not for tokens themselves) 2023-11-03 14:36:35 +01:00
stefan schippers b7e5af9b4b add inherited_pin[] in make_sym_from_spice.awk 2023-11-02 19:39:01 +01:00
stefan schippers 234a70d0a3 fix version print in make_sch_from_spice.awk and make_sym_from_spice.awk 2023-11-02 19:29:00 +01:00
stefan schippers e86857d410 code cleanup in make_sch_from_spice.awk and make_sym_from_spice.awk 2023-11-02 19:23:11 +01:00
stefan schippers 794df4dfc3 add make_sym_from_spice.awk, cut down from make_sch_from_spice.awk 2023-11-02 19:07:15 +01:00
stefan schippers 7727a9f924 add necessary comment in edit_text_property() 2023-11-02 13:30:03 +01:00
stefan schippers 722b1f4575 small improvements in edit_text_property() and get_instance() 2023-11-02 13:24:15 +01:00
stefan schippers 0a4c59cc30 xschem selected_set, search: include text objects. xschem getprop: allow to retrie the text value with txt_ptr 2023-11-01 14:19:26 +01:00
stefan schippers 240db67df2 add comments in xschemrc for bespice_listen_port 2023-11-01 02:27:23 +01:00
stefan schippers 1955d6d386 setup_tcp_bespice: if port 0 is given let TCL find a free port 2023-11-01 02:23:21 +01:00
stefan schippers 18f337734d setup_tcp_bespice: use stderr for messages 2023-11-01 00:31:35 +01:00
stefan schippers b60a5a4c4b Add command `xschem setprop text n txt_ptr value` to change a text object text field, set stdout in line buffer mode if used in a pipe, better protect some commands against no X connection 2023-10-31 18:39:42 +01:00
stefan schippers ff24678fec draw_temp_symbol(): update symbol bbox before doing XCopyArea (fix_broken_tiled_fill && gctiled) 2023-10-31 13:10:16 +01:00
stefan schippers 7842890f0c select_rect(): no more direct usage of fix_restore_rect() (now done in drawtemprect(xctx->gctiled,...). Some dialogs no more transient (having always on top is a hassle for some). The fix_broken_tiled_fill is now set to 1, make this alternate drawing method the default 2023-10-30 22:47:25 +01:00
stefan schippers e282abb5f1 optimized XCopyArea for draw_graph(flags & 1), removed redundant OUTSIDE macro 2023-10-30 18:03:52 +01:00
stefan schippers 11c8c47ad3 faster draw_temp_symbol() if fix_broken_tiled_fill and gc==gctiled 2023-10-30 17:17:00 +01:00
stefan schippers d7247d55e6 fix `destroy_all_windows()` not destroying windows in non tabbed interface (late usage of tclresult()) 2023-10-30 02:09:49 +01:00
stefan schippers 814839a132 fix `destroy_window()` not destroying window in non tabbed interface (late usage of tclresult()) 2023-10-30 02:02:03 +01:00
stefan schippers 8f2af6803a remove some dead code, fix redrawing in `xschem move_instance` command 2023-10-30 00:57:28 +01:00
stefan schippers 36b1a9f9e7 fix delete_only_rect_line_arc_poly() (used in change_layer) 2023-10-30 00:22:25 +01:00
stefan schippers 52e36cc46b add portable sleep_ms() function 2023-10-29 23:52:33 +01:00
stefan schippers 391a744302 xschem setprop command: redraw all viewport if show_pin_net_names is enabled 2023-10-29 22:22:05 +01:00
Stefan Schippers 958c5a1525 set_modify() returns now # of floaters, use this info to redraw all viewport in `xschn setprop` commands 2023-10-29 20:02:23 +01:00
stefan schippers d776d6a351 better handle operating point clear / update when switching / reading / clearing raw files. dont use operating point data (ngspice::ngspice) above the hierarchy level where raw file has been loaded. 2023-10-29 14:04:52 +01:00
stefan schippers b680f5da20 redraw screen if executing `xschem raw_read` (and raw file already loaded, thus unloading waves) 2023-10-29 12:54:55 +01:00
stefan schippers a19020ed78 removed find_inst_to_be_redrawn() and related code (not worth doing) 2023-10-29 11:11:45 +01:00
Stefan Schippers d5fd026196 xschem raw command: delete also last (base) raw file in clear subcommand 2023-10-28 17:12:32 +02:00
stefan schippers a76dca4f29 add menu entry in Options for fix_mouse_coord 2023-10-28 11:51:21 +02:00
stefan schippers 78981f2c2f disabled testmode 2023-10-28 11:22:37 +02:00
stefan schippers a2ed8fefb6 added an optional fix (fix_mouse_coord) that uses an alternative method for getting mouse coordinates in KeyPress/KeyRelease events. This should hopefully work around some remote desktop connection softwares that report wrong mouse coordinates (may be absolute vs relative to window?) 2023-10-28 11:19:23 +02:00
stefan schippers 8ac4c6030d getpgrp() tcgetpgrp() are unix specific: protect with #ifdef __unix__ 2023-10-28 01:20:51 +02:00
stefan schippers 8b784d01d9 fix unrestored bbox coordinates in draw_selection() 2023-10-28 01:03:21 +02:00
stefan schippers b965fb0ba4 improvements in the `Fix for GPUs with broken tiled fill`, no more flickering in selections 2023-10-27 23:45:54 +02:00
stefan schippers 364fb55df1 avoid doing unselect_all() if nothing to unselect 2023-10-27 12:42:08 +02:00
stefan schippers 6362ebb214 add tanh() function in wave expression evaluator 2023-10-27 10:48:53 +02:00
stefan schippers 9f1b447c16 previous fix did not fix. Fix the fix 2023-10-26 19:38:25 +02:00
stefan schippers 4985fb6e61 fix crash if extra_rawfile(2, ...) is called when no initial raw file is loaded 2023-10-26 19:27:11 +02:00
stefan schippers c68866c994 add `wm transient .dialog .` to all toplevel dialogs to prevent focus robbery on cinnamon/mate desktops when some other app is always-on-top 2023-10-26 19:13:49 +02:00
stefan schippers bfc60add06 tab context menu: Do not use saved file to decide if symbol or schematic. Use netlist_type 2023-10-26 08:29:52 +02:00
Stefan Schippers 34113c1c5f added tab ctx menu `Save` 2023-10-25 20:30:20 +02:00
stefan schippers 2fec681728 puntuation in texts 2023-10-25 18:13:48 +02:00
stefan schippers f9d3661c15 fix tab context menu close (invalid switching after deletion) 2023-10-25 16:47:11 +02:00
stefan schippers 8e844ff913 remove (unneeded) `edit file` tab-bar context menu entry 2023-10-25 16:33:24 +02:00
stefan schippers 27488a1020 add tabs ctx menu `open term in sim directory` 2023-10-25 16:28:10 +02:00
stefan schippers b31358a468 New thumbnails for tabs ctxmenu 2023-10-25 13:01:00 +02:00
stefan schippers 9a0375cc4b do not add `Edit netlist` ctx menu button for symbol tabs 2023-10-25 12:14:48 +02:00
stefan schippers 3d4113ad26 tabs bar context menu 2023-10-25 11:43:43 +02:00
stefan schippers d83acf710d add `xschem text_string` command, update displayed floaters if a text object is changed 2023-10-24 18:47:58 +02:00
stefan schippers 94b43d41ed add double click in process list to get status, add Simulation menu entries to display data and stderr of last completed job 2023-10-24 14:28:59 +02:00
stefan schippers 82387c7f2f remove unneeded grab set in property_search 2023-10-24 11:45:13 +02:00
stefan schippers 0819211bb0 when doing a select by area with shift pressed the object under the mouse will not be unselected if it was already selected (xctx->already_selected) 2023-10-23 23:41:39 +02:00
stefan schippers 512b297e35 add validity checks for xctx->inst[n].ptr < 0 (unresolved instance) 2023-10-23 22:49:52 +02:00
stefan schippers fec9c1b7e3 fix fullxzoom if a single curve is selected with find_closest_wave() (returns a dataset number) in a double variable DC sweep (there are no multiple datasets, just sweep var wrapping) 2023-10-23 17:20:51 +02:00
stefan schippers 2aeafac85c if selecting a waweform dataset with `t` key update text floaters that might contain the dataset information. When closing the process list dialog also close the process status sub-dialog. 2023-10-23 16:03:27 +02:00
stefan schippers 4f4872fa7b execute_fileevent: use exit status instead of stderr data in status report 2023-10-23 10:33:08 +02:00
stefan schippers d82ad002e8 better fill nodes listbox when selecting in-graph raw file, simulation->graph menu reordering 2023-10-23 09:28:29 +02:00
stefan schippers 447a5b8ae6 add ngspice interactive/control/batch simulation modes 2023-10-23 01:00:09 +02:00
stefan schippers 6e776262e6 remove debug msg 2023-10-23 00:05:34 +02:00
stefan schippers 10857629e1 add option --pipe (alias for -r / ----no_readline) 2023-10-22 22:16:17 +02:00
stefan schippers 2a8b0b40d8 add some additional help text in simulator config dialog 2023-10-22 12:14:49 +02:00
stefan schippers 8f3fedab1f fix a bug when closing with ctrl-q (ie from callback(), calling proc quit_xschem) and there are multiple windows, some with changed data (switch_tab() was skipped due to xctx->semaphore). Process status dialog window will not be updated if vertical slider is not positioned to bottom 2023-10-22 02:53:03 +02:00
stefan schippers d5d090afc0 better line-rectangle touch check for backward rectangle selection (intersection select) 2023-10-21 23:48:56 +02:00
stefan schippers 5c27e48ccf fix rectangle intersection checker macro (RECT_TOUCH) 2023-10-21 22:37:01 +02:00
Stefan Schippers 73c4a17c2c dragging to the right a selection rectangle will select objects fully enclosed. Dragging to the left will select all objects intersected by the select rectangle. 2023-10-21 19:09:17 +02:00
stefan schippers 109cef6c52 detect if program started in background and detach from console 2023-10-21 11:37:59 +02:00
stefan schippers f2fd7e6e48 remove debug messages 2023-10-21 11:05:47 +02:00
stefan schippers 99f31e4535 periodic update of process status dialog, updated delta_sigma and rom8k examples for allowing batch mode ngspice run 2023-10-21 10:58:02 +02:00
stefan schippers e603a71651 fix typo 2023-10-21 10:07:31 +02:00
stefan schippers 8a8d9f0148 added comments for sub-process management, disabled list sub-processes on windows (need specialized version) 2023-10-21 09:47:37 +02:00
stefan schippers 2e4e754a3e add context menu entries for rotate and flip selection, add basic sub-process control in Simulation menu, enabled again Rotate and Flip from Edit menu, fix svg export from CLI (was resetting line width), add cascade menus in Simulation 2023-10-21 09:27:02 +02:00
stefan schippers 8e1df1b157 add proc sim_cmd to substitute variables in simulator commands and return the resulting command 2023-10-19 18:18:20 +02:00
stefan schippers 0e583cfac1 add tooltip showing full path of schematic when hovering the mouse over a tab 2023-10-19 15:14:29 +02:00
stefan schippers 0325b14499 add `none` i/o buffering mode (in addition to `line`) in execute `status` argument 2023-10-19 13:01:25 +02:00
stefan schippers efb0351812 fix fullxzoom when selecting more (unlocked) graphs, graphs have a custom rawfile specified and current loaded sim is not of the same type (for example OP) 2023-10-19 10:47:01 +02:00
stefan schippers 1b7a035220 fix graph_fullxzoom in case of non monotonical sweep x axis variable 2023-10-18 16:10:08 +02:00
stefan schippers 0178e1c287 add @symref attribute that resolves to the full symbol reference as specified in instance: example: "sky130_fd_pr/pfet_01v8_lvt.sym" 2023-10-18 13:18:29 +02:00
stefan schippers f9114a0888 proc graph_fill_listbox : use "xschem raw read" instead of "xschem raw switch" so if user enters a new file it will be immediately loaded 2023-10-18 10:48:23 +02:00
stefan schippers cc5864e12f fix 2 bugs in extra_rawfile(): xctx->extra_idx assignment in extra_rawfile "read" subcommand and return value if no command executed. Add "file_exists "procedure to be used in graph_edit_properties for rawentry resolution 2023-10-18 10:15:39 +02:00
stefan schippers a41a0bf9fd add noise analysis recognition in raw files 2023-10-18 02:56:06 +02:00
stefan schippers ad07999dd3 do not use text widget -selectbackground on tcl8.4 2023-10-17 23:35:16 +02:00
stefan schippers ecbbb68447 replace text widget "count -displaylines" with alternative tcl8.4 compatible 2023-10-17 23:31:13 +02:00
stefan schippers 8e8145a241 fix regression on input_line tcl procedure. buggy if empty cmd ws passed as argument 2023-10-17 23:06:49 +02:00
stefan schippers 52572a6ca4 update cmos_example.sch 2023-10-17 18:16:48 +02:00
stefan schippers 9917c8276b revert to KeyRelease events (instead of FocusOut) for various widgets in graphdialog (better feedback), fix premature deallocation of data in child process in filter_data() 2023-10-17 17:05:10 +02:00
stefan schippers 025454e79e fix a regression in graph_fullyzoom() if graph contains more than one expression 2023-10-17 16:39:25 +02:00
stefan schippers 306c5d0d15 fix two small memory leaks, doc updates (xschem raw command) Raw.filename renamed to Raw.rawfile 2023-10-17 16:08:27 +02:00
stefan schippers 9fda2adccb fix graph_fullxzoom if displaying multiple op (transformed to dc sweep) sims 2023-10-17 14:20:34 +02:00
stefan schippers b165720bc8 allow loading more and different analyses from the same raw file. Implied tcleval() in rawfile given in graphdialog, transform multiple saved OP sims into a dc sweep. 2023-10-17 14:00:43 +02:00
stefan schippers 8cfd51d8f9 add the ability to load multiple raw files with different analyses in a single schematic ( extra_rawfile() ) 2023-10-17 00:42:31 +02:00
stefan schippers 5da81a7aea shut down some gcc false warnings (uninitialized vars), add read_more_rawfile() 2023-10-16 11:16:12 +02:00
stefan schippers f10555917e optimized usage of interpolate_yval(), add raw->cursor_b_val[] 2023-10-16 09:53:03 +02:00
stefan schippers d1309a8a47 fix uninitialized var in interpolate_yval() 2023-10-15 13:24:19 +02:00
stefan schippers a7bcfb7941 do interpolation when annotating "b" cursor values in schematic, as done with measurements with "a" cursor. 2023-10-15 12:05:48 +02:00
stefan schippers f87ab46310 refactor table_read(), less pointer indirections 2023-10-15 10:24:13 +02:00
stefan schippers 53286346e1 doc updates, tcl rawfile variable in place for future per-graph raw file 2023-10-14 23:41:19 +02:00
stefan schippers 663991ce70 add "filename" member in Raw (raw file) struct 2023-10-14 23:09:40 +02:00
stefan schippers 537cedbafe better graphdialog layout, remove tcl redundant raw_level var 2023-10-14 22:43:58 +02:00
stefan schippers 8ceb4b6b41 fix false wcnt warning in draw_graph() 2023-10-13 23:09:27 +02:00
stefan schippers 25ab8a8b8a cursor `a` measurements in graph match the %n dataset specified on nodes if any (or default to dataset 0) 2023-10-13 23:04:45 +02:00
Stefan Schippers c6a3880b9d fix a bug in draw_graph_points() changing and not restoring linewidths if called with idx==-1 2023-10-13 18:46:15 +02:00
stefan schippers 617e6b3b8d update live backannotation if "a" and "b" cursors are swapped, syntax node%n is now allowed to plot only dataset "n" of the node. Update html docs and example autozero_comp circuit 2023-10-13 15:51:51 +02:00
stefan schippers 6ad282a3df remove some global tcl vars 2023-10-13 09:41:34 +02:00
stefan schippers cd01e5d314 in digital graphs use gr->magy (ylabmag attribute) to rescale node names on Y axix, as done in analog graphs on Y axis labels 2023-10-13 00:25:40 +02:00
stefan schippers c86d48f321 expandlabel(): do bus_char substitution even if taking the shortcut 2023-10-13 00:04:58 +02:00
stefan schippers ae58077447 move replace_key to global_array_list (it is an array var) 2023-10-12 21:09:45 +02:00
stefan schippers 88a5befbf2 add some cascade menus for less frequently used entries. better description of xschem unselect_all command 2023-10-12 19:37:22 +02:00
stefan schippers 676ce4fe3d lock attribute for rectangles: work the same as for instances (can only double click to reset attributes, not selectable until lock reset to 0), add commands "xschem selected_set rect" and "xschem select_inside x1 y1 x2 y2" 2023-10-12 11:15:12 +02:00
stefan schippers a5545c3dbf fix keybinding doc typo 2023-10-11 23:56:36 +02:00