ubuntu-phone team mailing list archive
-
ubuntu-phone team
-
Mailing list archive
-
Message #16047
Defining the form factor of an Ubuntu Touch device
Hey everyone,
while currently working on heading towards BlueZ 5.x in Ubuntu Touch I
came to the point where we need to expose what type of device we are
running on. When you start discovering other Bluetooth devices you
always get the so call "Class of Device" back which describes what kind
of device you've found (pc, smartphone, tablet, printer, ...) with some
further details. You can find more details about this in [1].
Until now we always say we're a "smartphone" which isn't really what we
should do when we're starting to support other form factors like
tablets. There are multiple ways to configure BlueZ which class of
device to use but we will determine that at runtime. For PCs there is
already the DMI interface to check which type of device we're running
on. Something similar isn't available for our Touch devices and also the
Android side doesn't expose anything valuable.
This kind of information is really something we need to include in the
device tarball and for this there are multiple ways. We can either add a
new property which exposes the form factor we're running on or add
another static file in some other location we can check at runtime. This
new information bit will then be read by BlueZ and runtime and the class
of device will be set accordingly.
Know I need your help to find the best place for this kind of
information. My current preferred place is a new property which is
exposed from the Android property system. Each target device then has to
make sure this new property is correctly configured and included in the
device tarball or we will fallback to a proper default value.
Any objections?
Is there a better place?
Do we already have this form factor information somewhere but I just
missed it?
regards,
Simon
[1]: https://www.bluetooth.org/en-us/specification/assigned-numbers/baseband
Follow ups