Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Can a HardwareSerial::onReceive() callback identify the caller? #7836

Unanswered
Miq1 asked this question in Q&A
Discussion options

I am looking for a way to use the onReceive() callbacks for up to three instances of a class, that each have a dedicated HardwareSerial attached to it.

onReceive() will only accept a static class member function, so it will be identical for all instances. I need to know which HardwareSerial called the callback to have the proper instance react accordingly.

Is there a way identifying the calling HardwareSerial while in the callback function? Or, alternatively, get notice about FIFO buffer full or FIFO timeout without the callbacks?

You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /