Added flame finding to the master logic state machine

Also added dbg_printtf() over bluetooth.  The serial protocol can now
handle different types of payloads (i.e. 1: inputs & state info   2:
debug printf data)