Finally integrated with Beaglebone. Time for major refactor from this dirty state