-
-
Notifications
You must be signed in to change notification settings - Fork 24
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
RawFrameMonitor example seems to be missing something... #33
Comments
Thank you for your question. That configuration macro must be defined when compiling all the files. In general, all the configuration macros need to be set at the project level because they usually affect more than one file. It's a lot easier to do if you don't use the Arduino IDE. For example, just add to I just did a search for how to do this with the Arduino IDE and came up with this: I know it's not the most convenient answer, but the Arduino IDE, while simple, is a little more difficult to use for more complex projects. One of the reasons I decided to exclude the option by default is that it adds code size to projects that don't use it, and I'm assuming the majority of projects don't. |
Here's another link about modifying platform.txt or platform.local.txt: |
Okay, I figured it out. Teensyduino doesn't support those "extra_flags" options in its platform.txt file. So I did this:
On my system, platform.txt can be found here: I attached my modified platform.txt to this comment. I also attached the diff. Another reference link: |
I just made a post over in the Teensy forum to request a fix: |
Wow... I left to get my kids and make dinner, and you've already advanced the state of Teensy development. I hope the people around you appreciate you nearly as much as you deserve. |
I also updated the RawFrameMonitor example commants: // In order to use this example, define the QNETHERNET_ENABLE_RAW_FRAME_SUPPORT
// macro in the project build options. |
Turns out you need both these lines, per my setup:
|
You were right though; it was simpler in PlatformIO. I also appreciate that it's more apparent what's going on in PlatformIO than in the Arduino IDE. For example, I hadn't realized that the "libraries" were actually just source code. If the Arduino IDE had bothered to mention that it was compiling QNEthernetFrame.cpp, it would have been a powerful clue that simply defining the macro before the include statement was insufficient. |
It wouldn’t have been sufficient because more than one file looks at the option. You’d have to set it in all those places, and that’s subject to change. |
@Pragmataraxia Would you consider this issue closed? |
I sure would. Thanks! |
I added a qnethernet_opts.h file where you can configure the QNETHERNET_* options instead of the platform.local.txt approach. |
Would it not make more sense to put
#define QNETHERNET_ENABLE_RAW_FRAME_SUPPORT
at the top of the file rather than saying to do so in the header?Regardless, after defining this macro, the linker still can't find the implementation for EthernetFrameClass::parseFrame(). Maybe some cpp file didn't get checked in?
The text was updated successfully, but these errors were encountered: