Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to keep a bluetooth remote shutter awake programmatically?

I have a bluetooth remote shutter paired to my Android phone. The remote shutter acts like a bluetooth keyboard.

My app happily processes the keyboard events created by the remote shutter, but the remote shutter goes to sleep after 90 seconds, and requires one key press to wake it up before it sends the next key press.

I need a mechanism for keeping the remote shutter awake so that I don't lose that first key press. (Yes I understand the sleep mode is to conserve energy, but I need the low latency).

I have tried connecting to the device as both client and server, with the hope that I could send something on the OutputStream to the device. But I wasn't able to create a connection.

Is there anyway way to programmatically keep the remote shutter awake?

Based on the following answers I suspect not

  • https://stackoverflow.com/a/15164926/493682
  • https://stackoverflow.com/a/36384946/493682
  • https://stackoverflow.com/a/31299825/493682

Just for completeness the details of the paired device are:

  • name=AB Shutter3
  • MAC=Some_MAC_ADDRESS
  • btClass=2540
  • btType=1
  • UUIDs=[00001124-0000-1000-8000-00805f9b34fb, 00000000-0000-1000-8000-00805f9b34fb]
like image 239
William Avatar asked Sep 25 '17 09:09

William


2 Answers

Seems it totally depends on remote shutter firmware: if it goes to sleep after 90 sec after last key press - there is no way to wake it up programmatically (unless change its firmware). Easiest solution is to use remote shutter without sleep mode (or DIY bt/ble button). And anyway you can use external circuit (for example 555 timer based) powered from shutter battery and parallel connected with one of shutter buttons, which generates pulse every 90.1 sec to simulate first key press and wake up shutter.

like image 123
Andrii Omelchenko Avatar answered Oct 11 '22 17:10

Andrii Omelchenko


There is no programmatic way to get this done but you have 3 possible solution for your issue:

  1. Get a shutter that does not sleep
  2. Make your own shutter using Arduino or Raspberry Pi
  3. Modify the AB shutter by adding an additional circuit that enables your device every time it shuts down. For this purpose, you may take advantage from those links to know more about the circuit and how can you modify it: http://www.the-bridge.cc/ct137s15/?p=2647 and https://shkspr.mobi/blog/2016/02/cheap-bluetooth-buttons-and-linux/
like image 33
Mohamed Chaawa Avatar answered Oct 11 '22 17:10

Mohamed Chaawa