From 469316bdb30abc08b062fe97dc166eaca4e8051b Mon Sep 17 00:00:00 2001 From: Johannes Maron Date: Mon, 30 Sep 2024 09:04:11 +0200 Subject: [PATCH] Update readme and add contributing guide --- CONTRIBUTING.md | 34 ++++++++++++++++++++++++++++++++++ README.md | 14 +++++++------- 2 files changed, 41 insertions(+), 7 deletions(-) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..07172d0 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,34 @@ +# Contributing + +Welcome to the DP100 WebApp project! We are happy that you are interested in contributing to this project. + +## Architecture + +### WebHID + +This project is based on the [WebHID](https://developer.mozilla.org/en-US/docs/Web/API/WebHID_API) API. +It enables you to connect to Bluetooth or USB, like our power supply, via the browser. + +### Javascript & ESM + +Since we already rely on a browser environment, +we use the [ESM](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules) module system. +All code is written in vanilla Javascript. + +### Dependencies + +We use [μPlot](https://github.com/leeoniya/uPlot) for the graphing because it is lightweight and fast. +Everything else is build via Web Components with the help of [Lit](https://lit.dev/). + +## Development + +This project is based on the [WebHID](https://developer.mozilla.org/en-US/docs/Web/API/WebHID_API) API. +It is a work-in-progress and not feature-complete. The Modbus implementation has been reverse-engineered +from the Windows library (`ATK-DP100DLL(x64)_2.0.dll`), which can be found as part of the official software. + +If you want to contribute to this project, you can clone this repository and open the `index.html` file in your browser. + +You will need to enable write mode on Linux, since most distributions default to read-only. +You can find this and other useful tips in the [Chrome Dev Tips][dev-tips]. + +[dev-tips]: https://developer.chrome.com/docs/capabilities/hid#dev-tips \ No newline at end of file diff --git a/README.md b/README.md index ea22f2a..fa78c59 100644 --- a/README.md +++ b/README.md @@ -11,16 +11,16 @@ A browser interface for the DP100 digital power supply by Alientek. ## Usage -You don't need to install anything to use this webapp. -Just visit [this link](https://johannes.maron.family/DP100-WebApp/) and you're good to go. +Grap you DP100 power supply and connect the DP100 via it's USB-A port to your computer. -## Development +Now, visit [DP100 WebApp](https://johannes.maron.family/DP100-WebApp/) and you're good to go. -This project is based on the [WebHID](https://developer.mozilla.org/en-US/docs/Web/API/WebHID_API) API. -It is a work-in-progress and not feature-complete. The Modbus implementation has been reverse-engineered -from the Windows library (`ATK-DP100DLL(x64)_2.0.dll`), which can be found as part of the official software. +_Note, not all browsers support WebHID yet and on Linux you might need to enable write mode first, +see [Contributing Guide](CONTRIBUTING.md)._ -If you want to contribute to this project, you can clone this repository and open the `index.html` file in your browser. +## Development & Contributing + +We welcome contributions to this project. Please read the [Contributing Guidelines](CONTRIBUTING.md) for more information. ## Credits