Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933751AbZLOViT (ORCPT ); Tue, 15 Dec 2009 16:38:19 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932818AbZLOViR (ORCPT ); Tue, 15 Dec 2009 16:38:17 -0500 Received: from mail-pw0-f42.google.com ([209.85.160.42]:56808 "EHLO mail-pw0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932785AbZLOViP (ORCPT ); Tue, 15 Dec 2009 16:38:15 -0500 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=vsTltukxzFa58RvHPgG1S7m9qU7wzTyrqs77mTqTd59qzlO360tGPEYzvHcW4wlj+O XrTXY+CGynptDHkp8rTjRUwjGudwBGew1sZLoOFgyuCketj9MjWBcl7wBc9T/dj3s1ru UALoLHdkKXajQ2Uly2gpkJNjc6gEYY0n4v0LQ= MIME-Version: 1.0 In-Reply-To: <9e4733910912151245ne442a5dlcfee92609e364f70@mail.gmail.com> References: <9e4733910912060952h4aad49dake8e8486acb6566bc@mail.gmail.com> <4B24DABA.9040007@redhat.com> <20091215115011.GB1385@ucw.cz> <4B279017.3080303@redhat.com> <20091215195859.GI24406@elf.ucw.cz> <9e4733910912151214n68161fc7tca0ffbf34c2c4e4@mail.gmail.com> <20091215201933.GK24406@elf.ucw.cz> <9e4733910912151229o371ee017tf3640d8f85728011@mail.gmail.com> <20091215203300.GL24406@elf.ucw.cz> <9e4733910912151245ne442a5dlcfee92609e364f70@mail.gmail.com> Date: Tue, 15 Dec 2009 16:38:14 -0500 Message-ID: <9e4733910912151338n62b30af5i35f8d0963e6591c@mail.gmail.com> Subject: Re: [RFC] What are the goals for the architecture of an in-kernel IR system? From: Jon Smirl To: Pavel Machek Cc: Mauro Carvalho Chehab , Dmitry Torokhov , Krzysztof Halasa , hermann pitton , Christoph Bartelmus , awalls@radix.net, j@jannau.net, jarod@redhat.com, jarod@wilsonet.com, kraxel@redhat.com, linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, superm1@ubuntu.com Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2193 Lines: 47 On Tue, Dec 15, 2009 at 3:45 PM, Jon Smirl wrote: > On Tue, Dec 15, 2009 at 3:33 PM, Pavel Machek wrote: >> Untrue. Like ethernets and wifis, bluetooth devices have unique >> addresses. Communication is bidirectional. I read a little about how Bluetooth remotes work. Correct me if I get things wrong.... They create pairings between the remote and the device. Each of these pairings is assigned a device type. Multiple devices in the same room are handled by the remote remembering the pairings and sending directed packets instead of broadcast. That lets you have two TVs in the same room. Bluetooth devices need to advertise what profiles they support. So on the Linux box you'd run a command to load the Bluetooth profile for TV. This command would create an evdev subdevice, load the Bluetooth keymap for TV, and tell the networking stack to advertise TV support. Next you initiate the pairing from the Bluetooth remote and pick the Linux box. This causes a pairing established exchange which tells the Linux box to make the pairing persistent. I believe the Bluetooth remote profile is handled in user space by the BlueZ stack. BlueZ should be aware of the remote pairings. When it decodes a button press it would need to inject the scancode into the correct evdev subdevice. Evdev would translate it in the keymap and create the keyevent. This is the same mechanism LIRC is using. At a more general level we're missing a way for something like Myth to declare that it is a DVR device. Myth should load, say I'm a DVR, and then the remote control subsystem should automatically create a Bluetooth DVR profile, load an IR profile for Motorola DVR on a universal remote if the box has Bluetooth, IR or 802.15.4. The whole concept of a remote control subsystem seems like it needs more design work done. We keep coming up with big areas that no one has thought about. -- Jon Smirl jonsmirl@gmail.com -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/