split into files, added Makefile. Also added values for scaling raw register values.