From: Dave Hylands <dhylands@gm...> - 2008-02-01 00:08:41
> I noticed in the i2c-io code it uses Log(); What is the difference of Log()
> and printf()?
Generally speaking, all of my code uses Log. This allows me to
implement Log however I like. Sometimes I'll do printf, sometimes I'll
print into a file. On the robostix, I might send the output to a UART
or an LCD. Sometimes I'll make Log configurable (i.e. depend on the
contents of a variable).
By making everything use Log it gives flexibility to the user.
If you really want to use printf, you could provide a Log.h that does a simple
#define Log printf
Vancouver, BC, Canada