refactor to modularize

put resistor conversion functions in source file
use mstrtod to parse metric formated numbers
add header guards