Return-Path: Message-ID: <514021F5.1040005@tieto.com> Date: Wed, 13 Mar 2013 07:51:33 +0100 From: Rymarkiewicz Waldemar MIME-Version: 1.0 To: Marcel Holtmann CC: "linux-bluetooth@vger.kernel.org" Subject: Re: [RFC] bloodpressure: Add Blood Pressure API References: <1360668097-28906-1-git-send-email-waldemar.rymarkiewicz@tieto.com> <5135D965.8020604@tieto.com> <513703AA.2090206@tieto.com> In-Reply-To: <513703AA.2090206@tieto.com> Content-Type: text/plain; charset="ISO-8859-1"; format=flowed List-ID: Hi, >>> +Interface org.bluez.BloodPressure1 >>> +Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX >>> + >>> +Methods RegisterWatcher(object watcher) >>> + >>> + Registers a watcher to monitor blood pressure >>> + measurements. This watcher will be notified about >>> + final pressure measurements. >>> + >>> + Possible Errors: org.bluez.Error.InvalidArguments >>> + >>> + UnregisterWatcher(object watcher) >>> + >>> + Unregisters a watcher. >>> + >>> + EnableIntermediateMeasurement(object watcher) >>> + >>> + Enables intermediate measurement notifications >>> + for this watcher. Intermediate measurements will >>> + be enabled only for devices which support it. >>> + >>> + Possible Errors: org.bluez.Error.InvalidArguments >>> + org.bluez.Error.NotSupported >>> + >>> + DisableIntermediateMeasurement(object watcher) >>> + >>> + Disables intermediate measurement notifications >>> + for this watcher. It will disable notifications in >>> + devices when the last watcher is removed for >>> + intermediate measurements. >>> + >>> + Possible Errors: org.bluez.Error.InvalidArguments >>> + org.bluez.Error.NotFound >> >> why don't we make these two methods parts of a dict for RegisterWatcher. Enabling them manually seems rather pointless. > > It's been done intentionally to be able to return "not supported" error > when intermediate measurement is not available. > > Having RegisterWatcher(object watcher, boolean intermediate) and > additionally Intermediate property [read only] is an another option. > > In this case app will check intermediate property and set intermediate > param to RegisterWatcher appropriately. > Any comments on this. /Waldek