Commit Graph

20 Commits (6ee75bdb343d9bd778727ef4361300f6ceae7def)

Author SHA1 Message Date
Peter Hutterer 6ee75bdb34 README: drop the Note subheader
Not needed, just append it to the installation instructions
2018-01-30 08:57:28 +01:00
Benjamin Tissoires 04f25a0a38 drop .format(), switch to f{} everywhere
and change some double quotes into single quotes when encountering them.

It's a new project, so force use of Python 3.6 right now

Fixes #29
2018-01-29 21:18:06 +10:00
Peter Hutterer 6ad3851afd wacom: set the device time to UTC time on pairing
And let us handle the local time zone conversions in the client, because
having timestamps in localtime in the daemon is confusing and error-prone (how
is the client supposed to know what localtime was?)
2018-01-29 09:44:50 +01:00
Peter Hutterer ef8747f032 README: rename 'index' to 'timestamp' in GetJSONData 2018-01-29 08:23:25 +10:00
Peter Hutterer 3bc88bbbb6 config: store/load device drawing in the device's directory 2018-01-25 14:55:10 +10:00
Peter Hutterer 7a31a994fb dbus: return the drawings as array of timestamps
As we're planning to cache the data locally, the timestamps are a
unique-enough way that makes it possible to access a specific drawing.
And this way we can also delete some drawings without all other indices
shifting around.

Fixes #16
2018-01-25 14:55:10 +10:00
Peter Hutterer 3d516530c6 wacom: throw the exception (if any) to the "done" handler
Attach an errno to all exceptions, so we can bubble that up to the client
and display a message.

Fixes #24
2018-01-25 14:55:10 +10:00
Peter Hutterer cfa4aca2df dbus: limit StartSearch to one client only
Basically copied from the device's Listening approach.

While it's possible to have multiple clients searching at the same time it's a
niche case and the effort at fixing the race conditions that come from that is
likely not worth the effort.

Let's add multiple simultaneous clients when we have a real need for it.
2018-01-24 19:23:20 +10:00
Peter Hutterer 71dd70cc95 README: fix the API documentation, Pairing* is now Search* 2018-01-24 19:23:20 +10:00
Peter Hutterer daf2693927 Add setup.py
Fixes #17
2018-01-24 19:09:35 +10:00
Benjamin Tissoires 0e6d82dd14 README: document the new listening process
We need to be able to selectively enable/disable listening mode per
device, and the Listening property needs to be updated.

The current approach uses a Listening property as a public state, and the
StartListening()/StopListening() calls to start/stop. The ListeningStopped
signal is just there to carry error codes.

The current design only allows for a single client to trigger listening,
anyone else will see -EAGAIN and has to wait for the property to update.
2018-01-23 14:22:33 +10:00
Benjamin Tissoires 36b9b1cbb7 README: add note about the sensor orientation
The coordinates are provided from the top-left position, but the sensor
is effectively turned. So on the Spark and the Slate, X goes down, and
Y is reversed and goes left.
2018-01-20 12:37:50 +10:00
Peter Hutterer d4405cc1ef Hook up a ButtonPressRequired signal
When the nordic communication requires us to notify the user to press the
button, emit a signal and pass that up.
2018-01-19 13:40:26 +10:00
Peter Hutterer aa1a5e6689 Revamp the pairing process and rename to Search
The previous process had a problem: the device object didn't exist until after
pairing was complete. But to pair we need some user interaction (press button
on device) and thus the ability to send notifications from the device to the
dbus client at the right time. This wasn't possible with the previous
approach.

The new approach:
* renames Start/StopPairing to Start/StopSearch to indicate we're just
  searching, not pairing in the manager
* creates a org.freedesktop.tuhi1.Device object when a suitable device is
  found. That object is not in Manager.Devices, it's "hidden" unless you know
  the object path.
* Sends a PairableDevice signal with the new device's object path
* Requires the client to call Pair() on the device
* If the timeout expires without pairing, the device is removed again
2018-01-19 13:40:26 +10:00
Peter Hutterer 3871fc1d58 README: document the future pairing methods 2018-01-18 10:49:10 +10:00
Benjamin Tissoires f88a5b2222 wacom: disconnect when we have finished retrieving the data
There is no point keeping the connection alive just to drain the battery.
2018-01-17 13:41:35 +01:00
Peter Hutterer 2e716f2278 README: Bamboo Spark notes on how to get the connection dance happening
This device behaves differently depending on whether drawings are available or
not. Spell it out.
2018-01-15 11:24:17 +10:00
Peter Hutterer 8fa2f3503c README: three backticks is enough for code formatting 2018-01-15 11:20:58 +10:00
Peter Hutterer ffcad95337 README: format a bit better for readability 2018-01-12 20:37:22 +10:00
Peter Hutterer ea91eef4bc Add initial README for Tuhi 2018-01-12 07:45:56 +10:00