Sometimes it is a real hassle to track down all the different arduino libraries so I have started to following list.

  1. Arduino DHCP Library v0.4

Custom Library Notes:

Passing a serial port to a class constructor dynamically.

#include

class SomeClass {
public:
SomeClass(HardwareSerial *serialToUse);
private:
HardwareSerial *_port;
}

SomeClass::SomeClass(HardwareSerial *serialToUse) {
// save the port in the class.
this->_port = serialToUse;
}

Share

0 Comments

Leave a Reply