ECS is an electronic circuit simulator that runs in the browser.
You can try the hosted version of the application:
Make sure you have git installed.
To build and run this app locally you will need a few things:
- Use Unix-like OS;
- Install JDK version 8 (tested with OpenJDK 8);
- Install Ant;
- Install Nginx (tested with 1.20.2);
Clone this repository:
git clone git@github.com:barsukon/electronic-circuit-simulator.git
Setup dependencies:
./bin/dev setup
The web application can be compiled and run locally with:
./bin/dev setup
./bin/dev compile # This will put the artifacts in to the "war" directory
./bin/dev start
Just for reference the files you'll deploy should look like this:
-+ Directory containing the front page (eg "ecs")
+- ecs.html - full page version of application
+- iframe.html - see notes above
++ ecs (directory)
+- various files built by GWT
+- circuits (directory, containing example circuits)
+- setuplist.txt (index in to example circuit directory)
You can link to the full page version of the application using the link shown above.
If you want to embed the application in another page then use an iframe with the src being the full-page version.
You can add query parameters to link to change the applications startup behaviour. The following are supported:
.../ecs.html?cct=<string> // Load the circuit from the URL (like the # in the Java version)
.../ecs.html?ctz=<string> // Load the circuit from compressed data in the URL
.../ecs.html?startCircuit=<filename> // Loads the circuit named "filename" from the "Circuits" directory
.../ecs.html?running=<true|false> // Start the app without the simulation running, default true
.../ecs.html?hideSidebar=<true|false> // Hide the sidebar, default false
.../ecs.html?hideMenu=<true|false> // Hide the menu, default false
.../ecs.html?editable=<true|false> // Allow circuit editing, default true
./bin/dev setup
– download JDK, Ant and GWT, generatebuild.xml
;./bin/dev compile
– compile project;./bin/dev package
– make package from yourwar
;./bin/dev codeserver
– run GWT code server;./bin/dev webserver
– run Python'shttp.server
to host your app;./bin/dev start
– run both ofcodeserver
andwebserver
.
Bug reports and pull requests are welcome on GitHub at https://github.com/barsukon/electronic-circuit-simulator. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct.
Everyone interacting in the ECS project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.
The application is available as open source under the terms of the GNU General Public License version 2.
Copyright 2023 barsukon team
Leave a star ⭐ if you find this project useful.