Anyone have any example code for creating a custom logHandler?
I currently have Serial.println (for debugging with usb) and Particle.publish (which I have an IFTTT printing to dropbox file for when I’m not connected) throughout my code. Both have the same messages and I’d like to clean up/consolidate code by having single Log commands with two different handlers that I can switch between.
I’ve tried searching through the relevant source code:
But must admit my c++ knowledge is limited and I couldn’t really figure out how to implement my own handler. I couldn’t find anything in the docs except how to use SerialLogHandler.
Thanks in advance!