Mercator Firmware Development

* Mercator firmware
* Changing some things like memcpy pointers to remove warnings from build
always declare at top of function.