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

MH-Z19C also works on firebeetle #7

Closed
2 tasks done
hanscees opened this issue Mar 5, 2023 · 2 comments · Fixed by #8
Closed
2 tasks done

MH-Z19C also works on firebeetle #7

hanscees opened this issue Mar 5, 2023 · 2 comments · Fixed by #8

Comments

@hanscees
Copy link

hanscees commented Mar 5, 2023

Board

dfrobot firebeetle esp32-e v1.0

Hardware setup

I have gotten it working using


#include <HardwareSerial.h>
HardwareSerial mhzSerial( 2 );
#define MHZ19B_TX_PIN        16
#define MHZ19B_RX_PIN        17

// Create MHZ19B object
ErriezMHZ19B mhz19b(&mhzSerial);

The firebeetle has 3 uart devices, but the first uses the same pins as the usb power port, the second is more complex to operate, so the third one is the simplest to use.

see
https://microcontrollerslab.com/esp32-uart-communication-pins-example/

Version

latest master (checkout manually)

IDE Name

arduino

Description

this is not a bug but a comment. Thank you for making this library, the libraries with pwm here and there I couldnt get to work.
I am using the winsen mh-z19C

If anything could be improved, you write that calibrating by hardware is undocumented.
For the mh-z19c is this not so, see

https://www.tinytronics.nl/shop/index.php?route=product/product/get_file&file=3109/MH-Z19C-DZ-terminal%20type%20CO2%20Manual(Ver1.21)-202103.pdf

Also the pins for the 19C are different.

In the section zero-calibration the hand-operated method is documented. Short out pin 1 for more than 7 second.
I have done so and that works fine.

Testcase

there's no problem, sorry

Sketch

no

Logs

n0

Checks

  • I understand that this library is maintained by volunteers in spare time. Response time may vary.

Export restrictions.

@Erriez Erriez changed the title also works on firebeetle MH-Z19C also works on firebeetle Mar 5, 2023
@Erriez
Copy link
Owner

Erriez commented Mar 5, 2023

@hanscees Thanks for your feedback. I'm glad to hear that your MH-Z19C works after changing the pins. I've updated this in #8. Do you think this is clear and sufficient?

Note: I do not own the MH-Z19C, but the datasheet is helpful.

Nogmaals bedankt een een fijne dag! (Thanks again and have a nice day)

@hanscees
Copy link
Author

hanscees commented Mar 5, 2023

It looks clear to me, but hard to read when not published for me

@Erriez Erriez closed this as completed in #8 Mar 5, 2023
Erriez added a commit that referenced this issue Mar 5, 2023
Update documentation MH-Z19C
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