-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,14 @@ | ||
# ScriptSynthGUI | ||
A Flask/React GUI for ScriptSynth | ||
A Web-based GUI for writing ScriptSynth configuration files. | ||
|
||
## Why? Why would you do this? | ||
ScriptSynth was designed as an easy-to-use tool for data acquisition from various hardware devices. Requiring only a YAML file, ScriptSynth vastly improves on existing solutions by allowing anyone to record data from many hardware devices and save that data to many different platforms and file types. | ||
|
||
This was too hard. Because people can't write YAML. Even if there's directions __and examples__ on how to do so in the ScriptSynth README. | ||
|
||
So I made this. I made this for people who can't read. | ||
|
||
## Features | ||
ScriptSynthGUI is a single-page app, with options on the left, and a preview of the YAML file on the right. Click the 'Save YAML' button to download the YAML file and use it with ScriptSynth. | ||
|
||
![Screenshot](/docu/Demo1.PNG) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
from flask import Flask, request, send_file, jsonify | ||
from flask_cors import CORS | ||
import yaml | ||
import os | ||
|
||
app = Flask(__name__) | ||
CORS(app) | ||
|
||
@app.route('/generate-config', methods=['POST']) | ||
def generate_config(): | ||
data = request.json | ||
with open('config.yaml', 'w') as file: | ||
yaml.dump(data, file, default_flow_style=False) | ||
return jsonify({'message': 'Config generated successfully!'}) | ||
|
||
@app.route('/download-config', methods=['GET']) | ||
def download_config(): | ||
path = 'config.yaml' | ||
return send_file(path, as_attachment=True) | ||
|
||
if __name__ == '__main__': | ||
app.run(debug=True) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
commands: | ||
- baud: '' | ||
command: '' | ||
port: '' | ||
time: '' | ||
hardware: | ||
- acquisition_type: FINITE | ||
buffer_size: '20000' | ||
cage_position: '' | ||
channels: | ||
Channel 0: Sp,etjomg | ||
Channel 1: sp,etjomg else | ||
Channel 2: something | ||
Channel 3: '' | ||
Channel 4: '' | ||
device: '' | ||
hw_type: '' | ||
interface: '' | ||
name: NIDAQ | ||
sampling_freq: '5000' | ||
terminal_config: RSE | ||
metadata: ea;lkjalkjfsadf | ||
output: | ||
CSV: {} | ||
sampling_frequency: 1Hz | ||
test_name: HTOE Test |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Flask | ||
flask-cors | ||
PyYAML |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.