Skip to content

Commit

Permalink
feat(hx711): add hx711 load cell amp
Browse files Browse the repository at this point in the history
* Adds HX711 Issue #101

* Changes from PR comments

* Fixes more `Hx711Element` case to `HX711Element`

* Adds Load sensors and Gauge Pressure sensors to board HX711 board

* Updates HX711 so it resizes when different sensors are active

* HX711 Element, removes unused code and makes width and height not user selectable.

* HX711 Element changes text to not be selectable.

* HX711 Element, Removes more unused code

* HX711 Element, changed default type to 50kg

* HX711 Element changes width/height to number

* HX711 Element, extracts sensor type to function with default.

Co-authored-by: Chris Wilson <>
  • Loading branch information
yepher authored Jan 12, 2022
1 parent c40b1d7 commit 328a44d
Show file tree
Hide file tree
Showing 4 changed files with 445 additions and 0 deletions.
19 changes: 19 additions & 0 deletions src/hx711-element.stories.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import { html } from 'lit';
import './hx711-element';

export default {
title: 'HX711',
component: 'wokwi-hx711',
};

const Template = ({ width, height, type = '50kg' }) =>
html`<wokwi-hx711 .type=${type} .width=${width} .height=${height}></wokwi-hx711>`;

export const loadCell50kg = Template.bind({});
loadCell50kg.args = { type: '50kg', width: 580, height: 430 };

export const loadCell5kg = Template.bind({});
loadCell5kg.args = { type: '5kg', width: 507, height: 269 };

export const gaugePressure = Template.bind({});
gaugePressure.args = { type: 'gauge', width: 509, height: 200 };
Loading

0 comments on commit 328a44d

Please sign in to comment.