From e981f1b2a7fddf2bfec563f67d19e435e25cbbc5 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Sun, 13 Sep 2015 00:37:44 +1000 Subject: [PATCH] README: add a short explanation on the architecture Signed-off-by: Peter Hutterer --- README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/README.md b/README.md index bcc63e27..12abba24 100644 --- a/README.md +++ b/README.md @@ -7,6 +7,22 @@ libratbag is a configuration library for gaming mice. It provides a generic way to access the various features exposed by these mice and abstracts away hardware-specific and kernel-specific quirks. +Architecture +------------ + +libratbag has two main components, the front-end API and wrapper code, and +the back-end HW-specific drivers: + + +-----+ +-----+ +-----------+ +----------+ + | app | -> | API | -> | hw-driver | -> | protocol | -> device + +-----+ +-----+ +-----------+ +----------+ + +The API layer is HW agnostic. Depend on the HW, the protocol may be part of +the driver implementation (e.g. etekcity) or a separate set of files +(HID++). Where the protocol is separate, the whole known protocol should be +implemented. The HW driver then only accesses the bits required for +libratbag. This allows us to optionally export the protocol as separate +library in the future, if other projects require it. License -------