tttapa.github.io | Repository with web pages on Arduino Programming
kandi X-RAY | tttapa.github.io Summary
kandi X-RAY | tttapa.github.io Summary
Repository with web pages on Arduino, Programming, Mathematics, etc.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of tttapa.github.io
tttapa.github.io Key Features
tttapa.github.io Examples and Code Snippets
Community Discussions
Trending Discussions on tttapa.github.io
QUESTION
I'm working at learning how to effectively Separate my C++ code for a ESP8266 project and I'm running into some issues with pulling out the webserver functions and objects. I'm using the sample code from this tutorial as my base point.
I feel like I'm understanding the basics of how to build a class and header, but when trying to use another class within my class I'm getting errors...but only in some of the functions.
Here is my main.cpp:
...ANSWER
Answered 2019-Dec-30 at 03:48You are trying to pass a non-static member function to server.on("/", handleRoot);
which expects a callable of signature void()
(i.e. a callable that can be called without any arguments and returning void
).
A non-static member function however is not a function callable without any argument. It takes at least one argument, the implicit this
pointer to the class instance.
If you want the handler to call handleRoot
on the current class instance on which startRoutes
was called, then use a lambda to call the member and capture this
:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install tttapa.github.io
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page