Removes the need of an eventloop
Fixes typo
Removes err from success callback
Now uses pselect to check if the connection is closed or if input from
bluethooth has been received.
Fixes compilation errors