Convert bluetooth entities to interfaces and convert free functions to methods.

Also make all the type names unique and switch some arrays to sequences.