shawn's latest activity

  • S
    Note that this web server library doesn’t really use QNEthernet for its operation. It only uses the initialization and the included lwIP stack code.
  • S
    shawn replied to the thread Another newbee.
    This is correct C++: Pot *POTS[]{&PO1}; It’s the direct list initializer form and is my personal preference.
  • S
    Here’s a thread which contains some relevant info (even though you figured it out): https://forum.pjrc.com/index.php?threads/inherent-latency-in-ethernet-modbus-over-serial-with-teensy-4-1.74454/ I posted some links and also a new QNEthernet...
  • S
    shawn replied to the thread relay module with Teensy 4.1.
    You’ll need a level shifter because the Teensy 4 uses 3.3V.
  • S
    I’ll also point out a potential gotcha with optionals. If using them to hold booleans, it’s easy to confuse using the implicit presence-testing for accessing the value, if you’re not careful to use the accessor operators or functions. Instead...
  • S
    Indeed. See also C++23’s std::expected and C++11’s std::exception_ptr for some additional fun. Next, look up “monad”… I struggle with having/wanting to support these very old APIs. I have some thoughts on API layering so I don’t have to be...
  • S
    A few comments: 1. No need to use dynamic memory to create EthernetServer and EthernetUDP. Simply declare them like EthernetServer server{3260}; and EthernetUDP handle;. 2. For EthernetServer specifically, QNEthernet improves the Arduino-style...
  • S
    It’s possible to hook up a filesystem to your own definitions of _open(), _unlink(), etc. You’ll need your own filesystem, however. I use the “FS” filesystem interface that’s included with the Teensyduino core. You could plug in whatever...
  • S
    I’m curious, does initialization order matter? For example, if you initialize CAN first instead of Ethernet. Also, you need to account for millis() wraparound. Either compare with subtraction to a timeout value or use elapsedMillis instead...
  • S
    shawn replied to the thread Onboard LED.
    Also note that this pin is the same as the default SPI clock pin, so if one runs SPI, the LED will flicker, indicating clock activity.
  • S
    shawn replied to the thread Onboard LED.
    Also the LED_BUILTIN constant.
  • S
    You’re welcome. I cannot claim much PlatformIO work, however, other than some how-to posts about it and an EHEX PR in their repo. :) I did write the QNEthernet library, however.
  • S
    Here's how that server library is using the QNEthenet library: It uses the initialization code and the Ethernet ISR, but nothing else. It uses the lwIP API, otherwise, for its entire function (a slightly-modified copy is included with...
  • S
    I just added an option to flush after all write calls. Other than the issue of write() not actually sending all the bytes (eg. because of internal buffers and such), just setting this new option in qnethernet_opts.h should duct tape the original...
Back
Top