Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tare via physical switch (ESP8266), experiment.. #20

Open
ClausTonnesen opened this issue Apr 21, 2021 · 0 comments
Open

Tare via physical switch (ESP8266), experiment.. #20

ClausTonnesen opened this issue Apr 21, 2021 · 0 comments

Comments

@ClausTonnesen
Copy link

I have added a physical switch to Tare the load cells when using the CG-Scale stand alone.
Simple, apart from the limited amount of GPIO pins on the ESP8266, actually close to none free when using 3 load cells.

Simple, hook up to D8 (GPIO15), but that doesn't work for input.. back to reading the manual :(
After reading a bit, I figured that the RX (GPIO3) could be used as input.
It breaks the USB/Serial functionality, but when up and running and everything available via the Web GUI, I can live with that.

I haven't tested GPIO9/10 as my wire was to short, and no jumper around (and running out of time for today).

Anyway.. got it running like this
In .h
// Enable pull up on Tare input pin
#ifdef PIN_TARE_BUTTON
pinMode(PIN_TARE_BUTTON, INPUT_PULLUP);
#endif

In setup
// use the RX pin for tare button input, BREAKS the USB/Serial interface, comment out for acces via USB!!
#define PIN_TARE_BUTTON RX

Thoughts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant