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

"node-esp8266-generic" fails to compile #31

Closed
thehi1 opened this issue May 2, 2021 · 3 comments · Fixed by #34
Closed

"node-esp8266-generic" fails to compile #31

thehi1 opened this issue May 2, 2021 · 3 comments · Fixed by #34

Comments

@thehi1
Copy link

thehi1 commented May 2, 2021

I am trying to compile the file "node-esp8266-generic".

Neither under Atom nor with the latest version of the Arduino IDE can the scatch be compiled.
It concerns HX711. When doing #define WEIGHT false, then it works.
In the meantime I have tried 3 different libraries. Unfortunately without success.

Message from Compiler:

exit status 1
no matching function for call to 'HX711::HX711(const uint8_t&, const uint8_t&)'
What could be the cause?
@amotl
Copy link
Member

amotl commented May 2, 2021

Hi @thehi1,

thank you for writing in.

no matching function for call to 'HX711::HX711(const uint8_t&, const uint8_t&)'

This indicates that we will probably have to update the code to use the most recent version of the HX711 library. We changed its constructor method with bogde/HX711#123 in order to make it compatible with more devices and apparently haven't updated this program ever since. Apologies.

Edit: See also #26 ;].

In the meantime I have tried 3 different libraries.

The canonical HX711 library [1,2] by Bogdan is the right one we are using all across the board.

With kind regards,
Andreas.

cc @ClemensGruber

[1] https://github.com/bogde/HX711
[2] https://platformio.org/lib/show/1100/HX711

@amotl amotl changed the title "node-esp8266-generic" "node-esp8266-generic" fails to compile May 2, 2021
@amotl
Copy link
Member

amotl commented May 2, 2021

Hi @thehi1,

similar to #33, #34 will bring a build environment based on PlatformIO to this program. In order to run the build, just invoke make in the respective program folder. Along the lines, this patch also adjusts the program to use the most recent library versions and will mitigate the hiccup you observed with the HX711.

Please let us know about the outcome.

With kind regards,
Andreas.

@amotl amotl closed this as completed in #34 May 2, 2021
@amotl
Copy link
Member

amotl commented May 27, 2021

Hi @thehi1,

please make sure to use the most recent version of Bogdans HX711 library and use respective code to control it, like [1]. The key is that you should use the new initialization method like

HX711 scale;
scale.begin(LOADCELL_DOUT_PIN, LOADCELL_SCK_PIN);

I am trying to compile the file "node-esp8266-generic".

You probably used the outdated version [2]. When you will look again at [3], you will receive the modernized version. The corresponding patch to get things straight was c4da975a11.

Thank you very much for notifying us about this problem. Please let us know if this works for you.

With kind regards,
Andreas.

[1] https://github.com/bogde/HX711/blob/master/examples/HX711_basic_example/HX711_basic_example.ino
[2] https://github.com/hiveeyes/arduino/blob/27524ff41d44fcd317fa585664e72fea9f7a7421/node-esp8266-generic/node-esp8266-generic.ino
[3] https://github.com/hiveeyes/arduino/blob/master/node-esp8266-generic/node-esp8266-generic.ino

@amotl amotl reopened this May 27, 2021
@amotl amotl closed this as completed Nov 9, 2021
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

Successfully merging a pull request may close this issue.

2 participants