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

Fix #if in AnalogOutputFirmata.h #174

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Noorquacker
Copy link

The void internalReset(); private member function of the AnalogOutputFirmata class is intended to only be defined if compiling on ESP32.

No other code in this library uses #if ESP32, they all use #ifdef ESP32. When changing this to use #ifdef, this successfully compiles in Arduino IDE 2.3.2. Previously, when using #if, this wasn't compiling and the compiler complained about there being no member function defined for the class.

Hopefully this works in other situations and doesn't break anything else.

The `void internalReset();` private member function of the AnalogOutputFirmata class is intended to only be defined if compiling on ESP32.

No other code in this library uses `#if ESP32`, they all use `#ifdef ESP32`. When changing this to use `#ifdef`, this successfully compiles in Arduino IDE 2.3.2. Previously, when using `#if`, this wasn't compiling and the compiler complained about there being no member function defined for the class.

Hopefully this works in other situations and doesn't break anything else.
@pgrawehr
Copy link
Contributor

Thanks a lot for the suggested fix. Coincidentaly, a similar patch for this issue already had a PR open at #170 which is now merged.

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 this pull request may close these issues.

2 participants