From ee80236053b6c3293bdf6d8639c3379cc01b52c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20St=C3=B6r?= Date: Sun, 10 Jan 2016 23:32:51 +0100 Subject: [PATCH] Register updated HX711 doc file --- docs/en/modules/hx711.md | 16 ++++++++-------- mkdocs.yml | 2 ++ 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/docs/en/modules/hx711.md b/docs/en/modules/hx711.md index afed237f..0e0169e7 100644 --- a/docs/en/modules/hx711.md +++ b/docs/en/modules/hx711.md @@ -1,20 +1,19 @@ # HX711 Module -This module provides access to an HX711 load cell amplifier/ADC. The HX711 is an inexpensive 24bit ADC with programmable 128x, 64x, and 32x gain. Currently only channel A at 128x gain is supported. - -Note: To save ROM image space, the hx711 module is not compiled into the firmware by default. +This module provides access to an [HX711 load cell amplifier/ADC](https://learn.sparkfun.com/tutorials/load-cell-amplifier-hx711-breakout-hookup-guide). The HX711 is an inexpensive 24bit ADC with programmable 128x, 64x, and 32x gain. Currently only channel A at 128x gain is supported. +Note: To save ROM image space, this module is not compiled into the firmware by default. ## hx711.init() Initialize io pins for hx711 clock and data. #### Syntax -`hx711.init(clk,data)` +`hx711.init(clk, data)` #### Parameters -- `clk` pin the hx711 clock signal is connected to. -- `data` pin the hx711 data signal is connected to. +- `clk` pin the hx711 clock signal is connected to +- `data` pin the hx711 data signal is connected to #### Returns `nil` @@ -24,6 +23,7 @@ Initialize io pins for hx711 clock and data. -- Initialize the hx711 with clk on pin 5 and data on pin 6 hx711.init(5,6) ``` + ## hx711.read() Read digital loadcell ADC value. @@ -32,14 +32,14 @@ Read digital loadcell ADC value. `hx711.read(mode)` #### Parameters -- `mode` ADC mode. This parameter is currently ignored and reserved to ensure backward compatability if support for additional modes is added. Currently only channel A @ 128 gain is supported. +`mode` ADC mode. This parameter is currently ignored and reserved to ensure backward compatability if support for additional modes is added. Currently only channel A @ 128 gain is supported. |mode | channel | gain | |-----|---------|------| | 0 | A | 128 | #### Returns -a number (24 bit signed ADC value extended to the machine int size.) +a number (24 bit signed ADC value extended to the machine int size) #### Example ```lua diff --git a/mkdocs.yml b/mkdocs.yml index 9bbd81df..58908090 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -36,7 +36,9 @@ pages: - 'enduser setup': 'en/modules/enduser-setup.md' - 'file': 'en/modules/file.md' - 'gpio': 'en/modules/gpio.md' + - 'hx711' : 'en/modules/hx711.md' - 'i2c' : 'en/modules/i2c.md' + - 'net': 'en/modules/net.md' - 'node': 'en/modules/node.md' - 'mqtt': 'en/modules/mqtt.md' - 'pwm' : 'en/modules/pwm.md'