jacknewman12 / koradmote Goto Github PK
View Code? Open in Web Editor NEWA simple control server for Korad power supplies
License: MIT License
A simple control server for Korad power supplies
License: MIT License
The lower library already does this. We should be able to easily list all ports on the device that are most likely connected to a PSU.
Currently if a psu is failing to update there is no warning for that individual PSU in the web interface.
Note: Use musl for linux so we can ignore the libudev
dependency.
I think the target matrix should be:
x86_64-unknown-linux-musl
x86_64-pc-windows-gnu
arm-unknown-linux-musleabihf
- Whatever the Mac OS one is -
The -v
flag currently does nothing.
Would probably be nice to dump the serial ports + settings, rocket mounts, etc.
Original feature just splits the database (containing the serial port + current status) and the combines it again once the threads are complete.
Task is to change it so that each thread takes the serial port permanently and pushes the status results to a mpsc. The receiver thread can then push the changes to the status dict (and maybe also trigger a websocket push once its implemented).
This should make it a little easier to recreate serial devices if something goes wrong with them (im looking at you windows) and means we can just poll the PSUs as fast as possible without hurting the web interface speed.
Should probably make the update_state
and set_power
function return a Result
. Currently is very rare to fail, and its mostly harmless (the next UI update will probably show the real state).
Also adding a with_context({psu_name})
would be nice
TODO: Should we retry the update? Push some information back up to the user?
Should be very simple to import the entire Status from the Ka3005p driver:
{"voltage":0.0, "current":0.0, "power":false}
to
{"voltage":0.0, "current":0.0, "channel1": "CV","channel2": "CV","beep": "On","lock": Unlocked,"output": "On"}
Note this ticket doesn't involve updating the web interface to show all this data. (Is this extra data even useful for the user?)
This is simply so we don't have to redefine the state struct ourselves.
I think warp
might be better than rocket
for such a small project.
TODO: Merge over to warp and see if it reduces the memory footprint (its only 2mb atm).
Also just curious how that library compares in features.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.