Stop Bugging Me – A Post for the Truly Distracted

If your from Seattle this is not an advertisement for a local pest control company (Stop Bugging Me) we have all come to love or despise (sorry Marshawn Lynch,  I promise I am in the first category). This is about constant interruption that now plagues our ability to think. While I admit I am part of this problem as I blog and tweet my way into your phone, inbox or desktop, this is about how I plan to change and lead a more focused life.

Why this revelation you may ask? Well I am glad you asked (I actually know your not really asking). There are really two reasons I have come to this cross roads in my life. I am endeavoring to learn a new complex skill(programming) and secondly just to lead a more fulfilling work life . Even though I have given into a distracted life style I have some how made progress with my new skill although the pace of improvement seems awkwardly slow. My work life however generally feels unfulfilling and not because of my job but because of this struggle between being super connected and actually getting stuff done. In my mind things like meetings, email and messages don’t feel like really getting stuff done although they can be important for sure. The difference between me responding right now and in a couple of hours, lets just say its not as big of a deal as I would have myself believe.

My Typical Day

My general day consists of waking in the morning and before getting out of bed checking my email from my phone. I am a remote worker (and of late a road warrior) so I get breakfast and head straight to my home office to check more email for follow up and also my messaging app’s for more messages and chatter. I may also check Twitter for some more chatter and tweet a few invaluable thoughts. Through out the day I find my self slave to pop up notifications from email and messaging apps. Not that this is the fault of the applications, its just the habit I have formed from years of living inside those types of applications.  This is my day doing work being constantly interrupted by emails and messages while trying to learn complex systems and architectures to be prepared as a engineer.

Oh, I forgot to mention the meetings. Lots of meetings. The value of all those meetings well that’s a whole other blog post. Admittedly I work in sales (but of course I don’t like the sales tag as an engineer) so I am expected to be somewhat responsive and at meetings. I can’t go days without checking in so to speak, I would get fired. What this all ends up being is an extremely fragmented day. In all of this fragmentation none of it typically takes much real deep thought.To me it feels… kind of empty. I have no way to measure my own personal productivity. What do I tell myself ? Good job, you answered 40 emails today and attended 4 meetings.

Like I said earlier I don’t blame the technology for my own issues and I do attempt to wrangle its behavior. Filters on email, teams in messaging apps but I am a slave to my own success as a knowledge worker caught in notification hell and extremely easy to distract. Even once I walk away from my computer anything and everything can distract me. To the point where if I give myself a simple task such as unload the dishwasher I cannot actually get it done without getting side tracked. It also affects my love of golf where the simplest things distract my attention. At least when I play golf I do commit to putting my phone away but my focus is rarely optimal.

Tools of Distraction

Email, business messaging app’s and the like it would be easy for me to point my finger at those things and lay blame. But its not their fault. I finally understand the business messaging app presence liar (pick your tool Jabber, Skype etc.). You know that annoying person that is always set to away, do not disturb or worse yet offline but you know they stalk your own presence for you to turn green. You know that’s how their conversations start “I have a qq”. All the meanwhile your thinking why is your presence still saying away when your pinging me. They stalk and message all the while rejecting the norm to go “online”. I don’t blame them, these liars of technology. Polluting my notification space in the top right hand corner of my desktop screen. I want to be one of them. But my own set of personal ethics wont let me. If I am honest and trusting and I use these tools I should show my true presence. Yes I am “online”, damn it.

Then there is the multitude of tools. I have tried to limit this down to two main tools, neither of which now carry the traditional presence people are used to in typical Unified Communications products. Email and Cisco Spark. That’s right I am rejecting presence, I don’t want people to know I am online (even though Spark has this its much more subtle. Its not a big green dot). I want to control how, when and with whom I communicate. I don’t mind if people know I have read their communication but I want better control on when that happens. I feel like Spark has given me back that control and with new notification settings I have a better handle on what grabs my attention. How I made this transition to Spark I will outline a little later.

Getting Past Being a Whiny Little B….

So far this has been a pretty whiny post. I just needed to get that first part off my chest. How did I get here? My first revelation was a blog post I read by a programmer. If you don’t go read it here is the short version. Learning to program isn’t hard, deep thought/work is and to learn programming takes a lot of deep thought. Deep thought is uninterrupted (90 minutes or more) thought on one particular subject typically without distractions. In this post he mentions a book, Deep Work by Cal Newport.This is an excellent book. If you have ever caught your self in the same situation I have this book is worth a look. At least go read the free pages on Amazon and I guarantee you will end up making a purchase. Cal explores many of the techniques of the great thinkers of our time and how they managed to do what they do. Many of modern day thinkers for instance reject our easy access society which means no or limited email and especially no social media. I obviously don’t want to go that far but changes need to be made.

Not sure why it took reading an article and reading a book to realize my problem but sometimes that is what it takes. My wife takes quite delight in pointing out its obvious, “you needed a book to tell you that!”. Well, yeah.

The Plan

I have a plan. Its quite honestly still evolving in my mind right now but I know if I blog about it I will be forced to commit to something. I do have some first steps which I have already implemented to the displeasure of some of my coworkers and the delight of others. My action items I have identified start the moment I arise in the morning. 

Don’t put the phone beside the bed, have Alexa wake me instead – Less sleep interruptions from flashing screens and less chance to look at notifications first thing. Alexa can wake me with the gentle sounds of the sea in a relaxed state of mind. I have become quite fond of Amazon Alexa and the echo in my office. My Echo purchase for the bedroom is arriving today!

Deep work in the morning – This can be both from a reading and activity standpoint as long as the interruptions  are zero and I focus on a single topic. The act of programming is a deep work activity for sure. Seems like a lot of meetings I need to attend happen in this period so this may alter to more flexible scheduling but my hope is 90 minutes in the morning.

Resuming regular blogging- While I do not consider most blogging activity deep work, this has a two fold benefit. Its good practice on a light activity that does require some focus and it will help me get back to something I enjoy. 60-90 minute blocks of activity to help me get back on track should work. The plan is to blog at least twice a month but if more should happen that’s great. I don’t plan it to be some bullshit blog posts either. Deep technical thinking the kind of stuff that I started with.

Use Alexa for reminders of up coming meetings – Like I mentioned earlier Alexa has proven to be very valuable. The ability to set easy reminders has already helped me to stay on course for up coming meetings but now I can use Alexa and my Echo to help coordinate my focus time and still make my meetings. A voice enabled electronic assistant can prove to be very helpful and fun.

Breaking Free of Presence –  No more presence liars and no more being “online”. I built a Cisco Spark/Jabber bot about 6 months ago that allowed me to move away from a presence client (jabber) as an experiment, little did I know at the time how it would help enable me to change my behavior. Originally it was to help limit me down to just one messaging client but unknowingly it was helping me move away from presence stalkers. The code I built for my bot is not something I have released on Github but if your interested please let me know and I can share the code. Its written in Nodejs and is a pretty simple bot. I am not sure whether I will add more capabilities to the bot yet but I have been incrementally improving its stability at least. Building bots is a great way to learn programming BTW. Another topic for another post.

Filter email for everything – I do already do some filtering of email distribution lists, which I rarely read already but I am taking this one step further. I am filtering all cc’d emails to their own folder. This makes only email’s that have me in the to field notification worthy. Not sure if I can stick to this. I notice a lot of people put me in the cc field but still expect me to do something. But the plan is to check only cc emails once a day. I have also noticed that I now keep checking the cc folder. So this one might be a bit of a failure.

Sundays are screen free days – No screens at all. No TV, no iPad, no phone App usage. This is plan but I feel okay with allowing a little TV time Sunday night. I do have shows I enjoy like GoT but my days should be mostly screen free except for phones calls. I still need some accessibility.

Fridays are focus days - Deep work on important topics, new projects and concepts such as programming. Although meetings will break this up I am doing my best to keep this as a true work day not a meeting/email day.

Break email and business messaging app checking into blocks – This means less of allowing these applications to be a constant interruption. The plan is to set aside time to address this type of work and when the time is up move to the next work block. I have found when I am in a meeting I keep sliding into the typical fading focus as email and messages grab my attention. This is not a great behavior and if a meeting is that unimportant to me I shouldn’t be there. So if I make the effort to attend that means being there in mentally as well.

Rate my focus performance to help track improvement with a moving schedule – I need a system to rate my focus time to ensure I make progress on focusing. The scale is A-F. A being the best for awesome and F being the worst for fucking wasting my time. The focus time is rated on ignoring interruptions, staying on track and quality of work completed in that time set. Initially I had set amount of work, but that’s not a good measure, I want quality not quantity.

I am also scheduling every minute of the day to activities but on a moving schedule as work allows. So if a meeting goes long I adjust as it happens. This reminds me of Whiterose from My Robot. All we have in the end is time! I am sure she said that.

Establish shutdown process – No new work email after 5pm will be processed and by 5:30pm I should be done with the days work till the next day. There will be exceptions to this of course like when I travel or time zone issues but for most part I think this is achievable. This has been hard to stick to I have noticed but I am working at it.

Write my rules on a whiteboard – I need to live and breath these rules till they become habit. I am not going to enforce these rules with obsession but its about changing for the better but still able to make exceptions when I need to.

My experience so far

This is by far one of the most challenging endeavors I have ever undertaken. Making life style changes no matter what are always difficult. Exercise, giving up smoking, eating better are life style changes that seem obvious to make but changing your digital lifestyle doesn’t seem so obvious especially when we don’t understand the effect it is really having on us. Cal’s book really helped me but even he points out that there are those that disagree with his and other points of view on the effects of social media etc.

On thing I have found to be true as the day moves a long your will power drains from you like power from a battery. My focus quality also significantly lowers as well in the afternoon but I noticed it improves again in the evening. This was previously less obvious because of the constant flow of distractions. Unplugging from the constant stream of notifications is something I had never believed was hard to do but when in front a computer and you know the internet is just a click away its very hard to resist. Constantly looking at the time for when my focus block will be over. Its so easy to give in to those distracts.

I have completed my first Sunday with no screen, well mostly. I did in the evening spend 30 minutes watching TV but aside from that there was very little compromise in my commitment. I was surprised by the amount of stuff I was able to do by not watching TV which is my usual Sunday.  According to Cal’s book the average male adult aged 25-35 spends somewhere between 15-28 hours a week watching TV. I fit into that category so I am making a strong effort to change.

My first focus session was pretty much a failure, I was never comfortable, my mind kept wondering to an earlier notification I had seen on my phone and I was constantly thinking it must be close to an hour. At best it was 20 minutes of focus out of an hour of twitching and mind wandering. I give myself a C- and that was being generous. The fact I could only go 20 minutes of true focus was a little surprising but so far it seems to be my limit. I have the focus of a three year old. Fuck me. But I am trying and it does seem to be improving.

Engagement seems to be a big factor in maintaining that focus. The more engaged in an activity I can get the more focus and for a longer period. So reading and absorbing programming right now seems a struggle if just reading from a book. Combining it with actually programming makes it much more engaging but I fear by engaging with the MAC it lowers my focus opening me to distractions.

Overall I must admit that even though I am only at the beginning of my lifestyle change I see encouraging signs. Thoughts are clearer, focus is improving even only after a week and my energy is higher than its been in a long time.  I feel like I can accomplish more with my day and I am stretching my mind further than I have in a long time.

Sorry if this post was all about me but if you read this far there must be something you relate to. If not than why are you letting me distract you, get back to focusing fool….

VoIPNorm

Cisco Spark JavaScript SDK Updated with more ES5 Examples

Last week the official  Cisco Spark JavaScript SDK went though a version update to 0.6.3. This included bug fixes with some new ES5 examples added to the readme incase you haven’t seen it yet. NPM has updated the package description and when you update the Node module the new readme contains all the updated examples. See an example from the readme below for creating a room and posting a message.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
'use strict';

var assert = require('assert');
var ciscospark = require('ciscospark');

var message1, message2, room;
return ciscospark.rooms.create({title: 'Messages Example'})
  .then(function(r) {
    room = r;
    return ciscospark.messages.create({
      text: 'Howdy!',
      roomId: room.id
    });
  })
  .then(function(m) {
    message1 = m;
    return ciscospark.messages.create({
      text: 'How are you?',
      roomId: room.id
    });
  })
  .then(function(m) {
    message2 = m;
    return ciscospark.messages.list({roomId: room.id});
  })
  .then(function(messages) {
    assert.equal(messages.length, 2);
    assert.equal(messages.items[0].id, message2.id);
    assert.equal(messages.items[1].id, message1.id);
  });

VoIPNorm

Cisco Spark API with NodeJS: Getting Started

Last post I talked about getting started with Tropo’s NodeJS module. What I failed to mention is that there is also a Spark NodeJS Module. Using Spark with NodeJS is just as easy to work with and opens up a great deal of opportunities to integrate your work processes into communication channels in Spark.

But before we jump into code the best place to start is with the Spark Developer site. https://developer.ciscospark.com/.

There are a couple of reasons to visit the developer site besides the documentation for the various Spark API’s. Its also an easy way to grab your Spark access token so we can do some simple code examples without getting to hot and heavy with authentication. Once you login to the site on the far right click on your avatar to get your access token which we will need to do our first code samples.

image

Pretty simple so far. Now to make use of access token probably the easiest way is to set an environmental variable when you start your Node application from the terminal or cmd prompt. Below is the command to use to start you node app with your access token.

$CISCOSPARK_ACCESS_TOKEN=<your developer portal token> node ./server.js

Also don’t forget to install the NodeJS Cisco Spark Module. Check it out here https://www.npmjs.com/package/ciscospark. To install using npm:

$npm install ciscospark –save

One of the most basic examples is to request a list of rooms. I recently integrated an application I was building to log error output to a test Spark room but before I could do that I had to find out the room ID.  This simple example is a great way to do that.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
// Fetch your 5 most recently created rooms
//
// Run with
// CISCOSPARK_ACCESS_TOKEN=<your developer portal token> node ./1-access-token.js

var ciscospark = require('ciscospark');
ciscospark.rooms.list({max: 5})
  .then(function(rooms) {
    console.log(rooms);
  })
  .catch(function(reason) {
    console.error(reason);
    process.exit(1);
  });

Using lodash we can then find the rooms you are after. In the example below we are call the Spark API to list our rooms and using using lodash to sort the JSON response to console log one room. If you haven't noticed yet the Spark Node SDK is making use of promises. Our examples are being kept pretty simple promises make working with the API a lot easier versus using callbacks.Also note our example uses a process.argv to access the command line and room name you enter when starting your node process. Also don’t forget your access token if you not authenticating using another method.

$CISCOSPARK_ACCESS_TOKEN=<your developer portal token> node ./server.js <room name>

If you

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Fetch your five most recently created rooms and log the first one with the title specified on the command line
//
// 1. Run npm install --save lodash
// 2. Run with
// node ./server.js <room name>

var lodash = require('lodash');

if (process.env.NODE_ENV !== 'production') {
  require('dotenv').config();
}

var ciscospark = require('ciscospark');
ciscospark.rooms.list({max: 5})
  .then(function(rooms) {
    var room = _.find(rooms, {title: process.argv[2]});
    console.log(room);
  })
  .catch(function(reason) {
    console.error(reason);
    process.exit(1);
  });

Our last example fetches the five last created rooms. Lets pause here for moment to cover that a little better. When you use the list rooms it calls your last created rooms not your last updated. Its an important distinction to make as you may have to pull a much larger list of rooms to get the room you require. Once we get our rooms we list the messages of the room with specified title.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// Fetch your five most recently created rooms and list the messages for the first room with the specified title
//
// Run with
// node ./server.js <room name>

var lodash = require('lodash');

if (process.env.NODE_ENV !== 'production') {
  require('dotenv').config();
}

var ciscospark = require('ciscospark');
ciscospark.rooms.list({max: 5})
  .then(function(rooms) {
    var room = _.find(rooms, {title: process.argv[2]});
    return ciscospark.messages.list({roomId: room.id});
  })
  .then(function(messages) {
    console.log(messages);
  })
  .catch(function(reason) {
    console.error(reason);
    process.exit(1);
  });

I hope you enjoyed our first look at the Spark SDK. Thanks to Ian Remmel for supplying the examples listed. Over the next few weeks and months I will be posting more examples of working with both Tropo and Spark SDK’s and API’s.

If you have built a Spark application let me know about it. I am excited to see what people are building in this exciting new era of communication API’s.

VoIPNorm

Going tropo with Cisco Tropo and NodeJS!

I have been working on a number of projects lately that have put me deep into API’s. Over the next few blog posts I am going to start sharing some of the stuff I have been up to with the new Spark API’s and also Tropo which has been around much longer. Both platforms are incredibly fun to work on experimenting with. While I make no claim as a software developer I will post code I have written hopefully not offending any real software developers out there.

For the last year or so I have been down the learning path of gaining some software development skills. This has not been easy. My purpose for these new skills is to be able to build prototypes and demonstrations for the use of Cisco’s API stack. Programming is a skill I have long thought I should have at least some ability in but to my dismay I never really knew where to start. So I took the traditional path of going to college. I won’t say it was a complete waste of time but after three or four programming classes I came to the realization that the University of Phoenix is not the right environment to learn programming. I can read a book and create crappy applications without paying $2K dollars a course on my own without UoP.

So after a lack lust UoP experience I was not sure what direction to head. I did have some web design skills but on the backend I was pretty sure learning another language outside of JavaScript was not what I was after. Luckily I have a peer that actually has extensive programming knowledge that suggested I take a look at NodeJS. He had been pushing me that way for a while but I was so engrossed in learning Java at the time I just never got around to it.

While I am not going to give a lesson on Node (there is already a ton of info on Node out there) most of the JavaScript code I have written or examples I will post on VoIPNorm are written for the Node framework. But before we head down that road let’s review:

What is Tropo?

From the FAQ on the website”":

With Tropo you can build nearly any voice application you can imagine, including speech-driven IVR, VoIP solutions and voice mashups. The code you write also works over text messaging. Check out our documentation and sample apps at: http://tropo.com/docs.

What to do first?

To get up and running in Tropo to develop your first app you will need to sign up for a developer account. Its pretty simple and painless. From there you can start either using the scripting engine to write some applications or dive right into using the WebAPI which once through the initial setup is a very powerful tool.

image

Topo has of course a bunch of examples in Node for use with the WebAPI (and other frameworks such as Ruby) on it documentation website. Some are a little dated but generally they all still function. Below is a basic answering a call on NodeJS using Tropo.


 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
var http = require('http');
var tropo_webapi = require('tropo-webapi');

var server = http.createServer(function (request, response) {
	
	var tropo = new TropoWebAPI();

	tropo.say("Welcome to Tropo!");
	
	response.end(TropoJSON(tropo));

}).listen(8000); 

To have this function you either need a working node server or some form of cloud container running Node. To make things easy Tropo does have its own NodeJS module that is available on NPM and examples on GitHub. If you are familiar with NPM its pretty simple to grab the module to install in your project:

~$ npm install tropo-webapi

If you plan to develop in Cloud9 to run your application from the cloud you will need a URL for your Tropo WebAPI app. Cloud9 gives you this which makes using Cloud9 a great way to develop Tropo applications. The Node workspace in Cloud9 uses the Express framework which is best to stick with the default template and strip out what you don’t need like SocketIO.

I am becoming a big fan of Cloud9 even though I still have NodeJS and Webstorm installed locally.

If you are looking to give Tropo a spin and are just after some simple demos using the Tropo Scripting API is a good place to start. The Scripting API is almost always where everyone starts out.

1
say("Welcome to Tropo!");

The JavaScript Tropo script example above produces the exact same results as the previous NodeJS example but of course you lose the flexibility of importing modules to extend Nodes functionality.

Tropo Scripting API versus WebAPI

Using the Scripting API is a great starting point but inevitably you will want to do more and link you application to other services such as Google, Box, Spark  and dare I say Slack or any other platform with API’s out there. The great thing is the Tropo WebAPI allows you to do that but it comes with doing more work to get a environment setup to start developing, but its worth it.

My environment for NodeJS with Tropo

I am using the following components/tools to develop with Tropo and NodeJS:

  • Cloud9 IDE using the NodeJS Express template. This is a great development environment with very little setup required. Each workspace you create in Cloud9 has its own unique URL which works well with Tropo.
  • Tropo WebAPI that is enabled for voice and SMS. To be enabled for outbound SMS Tropo requires you to lodge a ticket with their help desk. Just follow the process on the website.
  • Locally installed Webstorm IDE and NodeJS for quick development of utilities like a Google Places search or a ZIP code look up tool that you can embed in your Tropo application as you need them. Although Cloud9 is a great tool, sometimes you just need to build a small piece of code you will embed in a larger app later. I like using a local environment to do this.
  • Sublime Text is another handy tool I like to use although I am not an expert at using it. I know a lot of developers that like to work with Sublime instead of an IDE like WebStorm.

Of course my intent is not to build production like code (although in the future who knows) so your tools may vary but this is the tool set that got me working the fastest with NodeJS and Tropo. There are endless options though and I just noticed Visual Studio has a text editor that works with Node. So use what ever works for you if you already have some preferences.

I know with the explosion of API’s that are coming from Cisco and others in the industry that getting up to speed will be a steep learning curve. It was and still is for me which is why I am posting these lets get you started blog posts. I recognize that I am not a expert developer by any standard, I just stand on the shoulders of other that are. In saying that there are ways to do cool and fun projects without being a total dev geek. This is what I will be covering in follow up posts as I explore this myself. Feel free to post comments on code, tools or other things you find fun in the API space because there is a lot to learn and a million ways to do basically anything you can dream of.

VoIPNorm