Random

The one you feed

Read this in the book “The One Thing”, by Gary Keller. It was interesting in the context of where my life is presently.

One evening an elder Cherokee told his grandson about a battle that goes on inside all people.

He said, “My son, the battle is between two wolves inside us. One is Fear. It carries anxiety, concern, uncertainty, hesitancy, indecision and inaction. The other is Faith. It brings calm, conviction, confidence, enthusiasm, decisiveness, excitement and action.”

The grandson thought about it for a moment and then meekly asked his grandfather: “Which wolf wins?”

The old Cherokee replied, “The one you feed.”

Clear Air

It has now been almost two months since leaving Tatts. Plenty has happened since, I walked the Overland Track, went on a cruise, and am now 10 days into our Singapore/Japan trip.

One of my goals while on this trip was to spend some time working through IFRS16. Whilst that may seem an odd pursuit for a holiday, this is more of a working holiday! I believe there is an opportunity in the market for a model to churn out the IFRS16 Right of Use Asset and Liability numbers, given inputs.

Each time I mention it to an accountant, it is clear it is an issue for them. The standard is a 167 page beast and it comes in on 1 January 2019, but few have solved the issue for their company. Yet, whenever I mention it to someone who doesn’t have responsibility for statutory accounting, their response is often, “Why can’t they just figure it out for themselves.”

They probably could, but for one thing: Clear Air.

Having now spent many hours reading through the IFRS16 standard and associated commentary, one thing has struck me about this task. How little time I had over the last 5 years to sit down and concentrate on one thing for an extended period of time, uninterrupted.

That clear air just wasn’t available. It is nice to have a little bit of it now.

Oh, and Kyoto is really nice. Maybe for the next blog.

Internet Button – How to set it up

Recently, one of my colleagues and I bought an internet button from Particle.io. I thought it would be fun to play around with. After spending a few (frustrating) hours trying to get it to work as I wanted, I thought it might be helpful if I gave an overview of how I got it running. If you’re a whiz developer, you probably don’t need to read this. However, if you’re not a programer and thought that you’d buy an internet button to play around with, this guide is going to save you a serious amount of time.

What are we going to learn?

In the first instance, the plan was to enable you to hit the button to send an email. Fundamentally, we will get the button up and running and connect it to IFTTT.

Why is this guide needed?

Fundamentally, this guide is needed because all of the instructions seem to be old and don’t work. Also, the code repos that they recommend you download into your IDE also seem to be old and don’t work. So rather than you try and figure it out, I am going to give you the TL;DR.

You’re not a developer, but you got it to work. How?

This question is simply an excuse for me to insert my new favourite meme (thanks Shaw!), which pretty much sums up all of my development efforts. I laugh, because it is true (mostly).

Pasted image at 2016_08_19 08_46 PM

Cale is not a developer

 Ok, what needs to be done

Well, once the button arrives you need to follow the instructions to set it up. When the instructions get to a part about “flashing” the memory of the button from the console, this is where it gets tricky. Rather than muck about, here is code that is guaranteed to work (well, it worked for me):

#include "InternetButton/InternetButton.h"

// Create a Button named b. It will be your friend, and you two will spend lots of time together.
// You may be wondering about those two slashes and this gray text- they're called comments, and
// don't affect the code. Think of this as the voice of the narrator.
InternetButton b = InternetButton();

// The code in setup() runs once when the device is powered on or reset. Used for setting up states, modes, etc
void setup() {
// Tell b to get everything ready to go
// Use b.begin(1); if you have the original SparkButton, which does not have a buzzer or a plastic enclosure
// to use, just add a '1' between the parentheses in the code below.
b.begin();
}
void loop() {
if(b.buttonOn(2)){
Particle.publish("allbuttons","Tim", 1, PRIVATE);
delay(1000);
} 

else {
b.allLedsOn(0,165,0);
}
}

You simply have to copy and paste the above code into the IDE, hit the Verify button at the top left (the tick), and then flash the code to your internet button (press the button above – it looks like a lightning bolt).

Now, log into your console and click on your device. When you press the button, it should come through with “Tim” to the log. If that’s the case, you can now connect IFTTT to listen for “Tim” and you are away… the world is your internet button oyster.

Why Tim?
Long story.