Continuing with our series What you didn’t know about EAGLE we will teach users how to modify existing script files eagle.scr and default-assign.scr to make customization to their workflow.
There comes a time in every user’s journey with EAGLE where they feel like they have a preferred workflow. They discover there are commands they use more often or options that they seem to always be using. At this point, the desire for customizations and defaults setups begins to emerge. Thankfully, EAGLE contains a configuration script which can be used to easily customize your workflow.
Eagle.scr is EAGLE’s configuration script and it allows users to setup EAGLE in a way to best suit how they like to work (Fig 1). This is the ideal place store default values for grids widths, drill sizes, etc. It also allows you to create custom menus for each editor and adjust shortcuts for each editor independently (this last operation is best performed now using the default-assign.scr (Fig 2) that comes with EAGLE).
Fig 1. The eagle.scr file
The eagle.scr file runs every time a new editor is opened, that’s how it enforces the defaults. The file itself is very straight forward consisting of a list of EAGLE commands which are executed one right after the other. The eagle.scr file contains headings which separate the commands depending on what editor the commands are for, any commands above the first heading(SCH) apply to all of the editors. Keep in mind that because the commands are executed in order, it possible that command in one of the headings may undo the general settings you define at the top. Each command is listed in the file just as if it were entered into EAGLE’s command line.
Fig 2. The default-assign.scr
As mentioned earlier, the eagle.scr file can be used to define shortcuts however, in newer versions of EAGLE we recommend you create the shortcuts in a separate file. The default-assign script is the ideal place to do this. Notice that you can assign more than just a single command to a shortcut. You can assign other scripts and ULPs. You can also call multiple commands with a single shortcut giving you the power to automate repetitive tasks.
Feel free to explore these files, they will allow you to wield EAGLE in a more efficient and productive way.
Comments are greatly appreciated.
CadSoft Support Team
support@cadsoftusa.com