Showing posts with label notifications. Show all posts
Showing posts with label notifications. Show all posts

Saturday, December 12, 2015

Control a Lifx Bulb using Flic and Tasker

This is documentation on how I made Flic[1] control a Lifx bulb[2] on my local network WITHOUT requiring an internet connection.

I don't want to expose my Lifx bulb to the internet. (That's a discussion for another time and place). but, I wanted to use the Flic button to control my bulb. Here's how I made it work

Hardware Pre-requisites:

  1. A Flic button [1]
  2. A Lifx bulb [2]

Requirements:

  1. Android 4.4 or newer device. (I'm using a Nexus 4)
  2. Tasker [3]
  3. Lifx Plugin for Tasker [4]

Why:

The built in method of making Flic control a Lifx bulb is the following.

Push button -> Talks to Flic app on phone -> Talks to Flic server -> Talks to Lifx Server -> Talks to your Lifx Bulb
This requires too much internet access for my comfort. I wanted something that did not depend on the Internet to work.

How to configure it

  1. Install the Lifx plugin for Tasker.
  2. It will give you a very simple app outside of Tasker that allows you to perform the basic operations to your bulb. Make sure this works before continuing. I spent quite a bit of time before I figured out this part.
  3. Create a Tasker - Task (I named this LIFX-ON)
    1. Choose plugin -> Lifx tasker plugin
    2. Setup whatever you want it to do. I configured it to turn on my bulb)
  4. Open the Flic app - DELETE any existing actions. (this is important, otherwise, the programmed action seems to take precedence over the notification to Tasker).
  5. Close the Flic app.
  6. Return to Tasker - create a new profile (credit: [5])
    1. Profile -> Context -> Event -> Plugin : Flic
    2. Choose the flic button, and choose your event. ( I selected ON).
  7. Done.

How it works

  1. Push the Flic button
  2. This talks to the Flic app over BLE
  3. The Flic app notifies Tasker that the button was pushed.
  4. Tasker executes your Lifx ON task
  5. Your bulb should now turn ON.

I've also created another event, this time for double click to Turn OFF the Lifx Bulb.

Hope this helps someone.

[1]Flic : https://flic.io/
[2]Lifx: https://www.lifx.com/
[3]Tasker : https://play.google.com/store/apps/details?id=net.dinglisch.android.taskerm&hl=en
[4] Lifx Plugin for Tasker: https://play.google.com/store/apps/details?id=org.timothyb89.lifx.tasker
[5] http://ideas.flic.io/forums/283403-flic-ideas/suggestions/7177881-integrated-with-tasker-the-automation-app

Saturday, June 08, 2013

Moving to Android: Part-2: Notifications, Emails and Flashlight mode

This is a series of posts where I look at my experiences in moving from a Nokia Symbian device to a Google Nexus 4 running Android 4.2 (Jelly Bean).

[Flashlight Mode] So every Nokia device to date has had some sort of flashlight option. I use this every night when I take a walk to my mailbox. So is there a flashlight mode/option/switch? Nope, but there's an app (or 200) for that. Ok, I went to the app store, and found one called "Simple Torch". Does what its supposed to do, no mess, no fuss. This is good.

[Email accounts] This was quite a breeze. Add account, give it the account type and credentials and about 5 minutes later, my Yahoo and my own domain hosted email accounts were synced. Great!
Wait, my domain hosted email would only partially sync ... every so often it would die with an "Unfortunately, email has stopped" notification. Looking online, I realized that this "has stopped" is Android terminology for the application has crashed. I've managed to crash my device 4 times in the first week?

[Missed call/text Notification] Oops, I got a text message back from a friend, but I didn't realize that she had sent me a text message. Strange, every Nokia device has had by default, some sort of flashing/blinking notification for missed calls/messages/emails. How do I set that up on this? You can't. Android doesn't have a way of notifying you without you turning on the screen.... except, wait, there's an app for that. There's an app called "Light Flow" that does allow you to make your phone's notification LED blink (in multiple colors!). Ok, this is good! I got Light Flow installed.