Added documentation and refined gpio interface to uint16_t for pins