First set of new FFI functionality

First chunk of changes for the new FFI. This should encompass all the functionality of the old FFI with some additional functionality.

        - First set of new FFI functionality
	- Updated libs to be compatible with new FFI
	- tweaked lib/console