Posted On: Saturday, 08 October 2016 by Rajiv Popat

There have been a lot of conversations around IoT lately. As someone who has done his major in accounting and as someone who builds business and financial applications for a living, I had a lot of excitement and some reservations about starting on my IoT journey. I mean I am just a regular nerd without any electronics background. Should I be playing with Microcontrollers and live current? After a few weeks, I’m happy to announce that the journey has been fun and I think it has been a journey worth sharing with you.

The basic underlying idea is to control things over the internet and hence the need for a programmable chip or a microcontroller - a small tiny independent board with a programmable chip that can run code in an infinite loop. The code controls the chip and the chip controls the devices or things it is connected to.

The “control” in the microcontroller can be as simple as turning a LED on / off or something as complex as building a smart home, with lights, fans, entertainment systems and water pumps controlled using your code.

Most articles and you-tube IoT examples out there are either way too complex involving complex circuits and code, or way too simplistic and impractical where someone shows you how to make a LED blink  with your code; which fortunately is a good start; but unfortunately does not allow you to anything practical with your microcontroller, which then puts your micro-controller in the same category as your gym membership - something you own but don’t actually use.

My goal with this series of posts, is to get started on IoT and provide enough insight on the topic to enable you to build something real and practical with it. The goal is also to take you to a point where IoT goes from yet another buzzword that electronics guys should be concerned about, to a practical, real, affordable and simple tool that you can use to build useful projects with.

In the first post we’ll cover some very basic concepts around the Arduino chipset (which is the micro-controller we are going to use for our IoT experiments) and write some basic code that runs on the chipset.

In the posts that follow we will attach some interesting modules to Arduino and write code to control these modules. Going ahead, we’ll get these modules and the microcontroller connected to your home Wifi and we’ll show you how you can control the microcontroller (and the modules connected to it) over the internet; and we’ll finally move on to working with real live electrical devices like, light bulbs and fans and control those with code.

All circuits we build in the process will be open sourced. All code we write in this process will also be on open sourced and  will be posted here on this blog for you to use.

When I started with my IoT journey a few weeks ago, I knew nothing about physics (or electronics) other than some basics I had picked up in high school, most of which I had never paid any attention to or had forgotten over time. Long story short, I’m just a regular nerd who writes business applications / CRUD screens for a living  and hence the series of these posts doesn’t require you to know physics or electronics to start. You will need to go out and buy a couple of cheap gadgets if you want to try some of these examples yourself but your overall investment will be less than 25 dollars.

And as a final disclaimer, I have never officially studied electronics so everything I write about here, is just a regular nerd trying to connect wires and have some fun. If something explodes (or if you cook a chipset or two) the responsibility is all yours!

Sounds good? Let's begin.

To start playing around with IoT we’re going to write code that controls devices so you’ll have to shell out some money and buy some basic devices. Even though there are platforms like the raspberry pi which make IoT much simpler, let’s start with buying a much cheaper micro controller which actually gets you a deeper understanding of the circuits you will be making, will make a smaller hole in your pocket and will help you stay away from having to run and entire Linux clone on your microprocessor like Raspberry Pi does.

Here are a few things you may want to go out and buy if you want to follow along:

  1. An Arduino UNO chipset - You can buy the original one or a cheap clone. I got one from amazon at about 7$.
  2. A Breadboard - so that you can connect wires and devices together without needing soldering equipment. I got mine from amazon at about 2$.
  3. Some jumper wires - so that you can connect devices on your Arduino and your breadboard. I picked up a neat set of male-to-male, male-to-female and female-to-female at Amazon. Cost of the whole kit? About 2$.
  4. A Few LEDs (and a few resistors) - which is the very first thing we will control with our code. You can also grab some resistors at 150 for just 1$ and a few LEDs for 3$.
  5. An ultrasonic transmitter - we will not be using it in the first demo, but we will need this in the third post, so it may be a good idea to get everything you will need in one shot. I picked up mine at 2$.
  6. A Wi-Fi module - that will eventually let you get connected to the internet over your home Wi-Fi connection and let you control the Arduino over an internet connection. Price? About 3$. Again, not something we will use in the first post, but something that we will use pretty soon.
  7. A Relay - that will let us control real live current / devices using our Arduino - we’re not going to use this for the next couple of posts but at 2$ a piece it’s something you may also want to order along with everything else mentioned above.

In under 25$ you have all you need to work on some meaningful IOT experiments and try out a few things.

We’ll get started with Arduino itself in this post and make it control a basic on-board LED light before we do some more interesting things with it. I do realize this example is highly non-practical but it is really simple, gets you used to the Arduino IDE and gets you familiar with the environment. So, let’s get started by making a LED blink, but before that lets begin by knowing our Microcontroller.

You can read article after after to understand the Arduino, but to start messing around with it, all you need to know is that is has 2 power output pins (using which connected devices can draw power) - one is a 3.3V power output pin, the other  a 5V power output pin. Apart from the power pins it also has ground pins labelled “GND” and all circuits that you make will usually end / complete with the ground pin. Put simply, your wiring will start with the power pin and end in the ground pin, and you will control everything else that’s in between (i.e. everything that’s connected to your IO pins).

Depending on the device you are connecting to your Arduino you can decide the power output you want to use. Most devices will have specs which will tell you how much power they expect. Exercise some common sense when you pick the power pin - for example, don’t connect your jumper wire to a 5V pin when the device you are connecting expects 3.3V - if you do there is a high chance you will cook your device.

Apart from the two power pins there are also some digital pins where you write a high or a low. Think of writing a “high” as turning a switch on and think of writing a “low” signal as turning the switch off. Out of all these pins, pin 13 is special because it has an in-built LED (light) attached to it that you can control with your code.

To write code we’re going to get the Arduino studio, which you can download from here and install using a simple installer. Once done, you connect your Arduino to the USB port of your laptop (which is one of the sources from which Arduino gets it’s power). Of course Arduino itself, can also work without a machine and you can hook it up with a battery or direct power, but for now since we will be uploading our code from our machine to the chip, it makes sense to have it connected with our laptop using the USB port.

Once connected go to your Arduino studio and pick the right port your Arduino is connected to. Usually the IDE automatically detects this but if it doesn’t you can try different ports and try to upload your code on each one till it succeeds. All code that typically runs on the microcontroller is referred to as a sketch and each sketch has a loop, which keeps on running as soon as the sketch is uploaded and the microcontroller is powered on.

An empty sketch looks like this.

Setup function is where you write code that runs only once. Anything you write in in “loop” runs in an infinite loop while the microcontroller is powered and on.

Now it’s time to connect the dots and assemble everything we’ve read thus far. Remember when we were talking about writing highs (which is same as turning the pin on) and lows(which is same as turning the pin off)? We know pin 13 has an in-built LED (light) and if we can write a high to pin 13, it should turn the switch on and the LED should glow. If we then write a low to the same pin the LED should shut off. If we do that in a loop function and wait 5 seconds between the on and the off, we should have an LED that keeps on blinking every five seconds the moment you power on the microcontroller. Simple enough? That’s exactly what we are doing in the code below:

int InBuiltLedPin = 13;

void setup() {
  // Let's set Pin 13 as Output Pin
  // Which means we will write high's and low's to it.
  pinMode(InBuiltLedPin, OUTPUT);
}

void loop() {
  // Turn on the Pin (and LED on board)
  digitalWrite(InBuiltLedPin, HIGH);
  // Wait for 5 Seconds
  delay (5000);
  // Turn off the Pin (and LED on board)
  digitalWrite(InBuiltLedPin, LOW);
  // Wait for another 5 seconds.
  delay (5000);
}

Verify your sketch (which is the same as compiling your code):

And once verified, upload your sketch on your Microcontroller:

And if all has gone fine you should see your Microcontroller LED blink on in five seconds (notice the Red LED next to pin 13 light up in the below picture):

And off in another five seconds:

Of course, this will continue in a loop till you switch off the microcontroller by pulling the USB cable off, or till you upload a new sketch.

And with that, you have just controlled an onboard LED with your code. In the next post, we will attach an external LED to the Arduino using a breadboard and try and change the same code slightly to make that LED blink. If you’ve never worked on electronics before the next post will introduce you to a lot of basic concepts like breadboards and resistors. And from there we’ll be ready to build some real life projects. So stay tuned for the next post.


Comment Section

Comments are closed.


Posted On: Sunday, 17 July 2016 by Rajiv Popat

I’m a nerd and I’ve never read anything about marketing other than books from Seth Godin. When I came across Contagious at my office library I was a little skeptical because it sounded like one of those books on social media which tries to teach you how you can spread your business or product. Contagious however, was both pleasantly surprising and analytical.

The book starts with logical and then goes into the illogical aspects beyond your control which decide how and why your products spread. For example the book describes how the sales of Mars candy shot up in mid-1997:

Back in mid-1997, the candy company Mars noticed an unexpected uptick in sales of its Mars bar. The company was surprised because it hadn’t changed its marketing in any way. It wasn’t spending additional money on advertising, it hadn’t changed its pricing, and it hadn’t run any special promotions. Yet sales had gone up. What had happened?

NASA had happened. Specifically, NASA’s Pathfinder mission.

The mission was designed to collect samples of atmosphere, climate, and soil from a nearby planet. The undertaking took years of preparation and millions of dollars in funding. When the lander finally touched down on the alien landscape, the entire world was rapt, and all news outlets featured NASA’s triumph.
Pathfinder’s destination? Mars.

Mars bars are named after the company’s founder, Franklin Mars, not the planet. But the media attention the planet received acted as a trigger that reminded people of the candy and increased sales. Perhaps the makers of Sunny Delight should encourage NASA to explore the sun.

Or how every Friday, millions of individuals are ‘triggered’ to listen to Rebecca Black’s Friday:

In 2011, Rebecca Black accomplished a momentous achievement. The thirteen-year-old released what many music critics dubbed the worst song ever.
Born in 1997, Rebecca was just a kid when she released her first full-length song. But this was far from her first foray into music. She had auditioned for shows, had attended music summer camp, and had sung publicly for a number of years. After hearing from a classmate who had turned to outside help for her music career, Rebecca's parents paid four thousand dollars to ARK Music Factory, a Los Angeles label, to write a song for their daughter to sing.

The result was decidedly, well, awful. Entitled "Friday," the tune was a whiny, overproduced number about teenage life and the joys of the weekend.

All in all, the piece sounds more like a monologue of the random thoughts going through an especially vacant teenager's head than a real song.

Yet this song was one of the most viral videos of 2011. It was viewed more than 300 million times on YouTube, and many millions more listened to it over other channels.

Why? The song was terrible, but lots of songs are terrible. So what made this one a success?
Take a look at the number of daily searches for "Rebecca Black" on YouTube in March 2011, soon after the song was first released. See if you notice a pattern.

Searches for "Rebecca Black" on YouTube March 2011

Notice the spike once every week? Look closer and you'll see that the spike happens on the same day every week. There was one on March 18, seven days later on March 25, and seven days later, on April 1.
The particular day of the week? You guessed it. Friday—just like the name of Rebecca Black's song.
So while the song was equally bad every day of the week, each Friday it received a strong trigger that contributed to its success.

The book talks about dozens of other triggers and techniques you can use in your products to make them contagious and tries to weave it all into a simple framework the authors call the STEPPS framework:

  1. Social Currency: We share things that make us look good.
  2. Triggers: Top of mind, tip of tongue.
  3. Emotion: When we care, we share.
  4. Public: Built to show, built to grow.
  5. Practical Value: News you can use.
  6. Stories: Information travels under the guise of idle chatter.

While the book did leave me with a deep understanding of what is contagious and what is not, it also left me wondering if the contagiousness of products is easy to analyze in the hindsight and much more difficult to plan ahead of time? Would the authors be able to look at an idea or a product before it’s inception and say with certainty if it would be contagious?

Every piece of information the book provided was something every marketing person should know about and yet the book did not convince me that adding all six elements of STEPPS consciously in your product guarantees that your product would be contagious. The book is a good read and provides a nice technical framework to describe contagiousness and maybe even some really pointers to help spread your work and make it more contagious but it didn’t change my overall belief that all you can do as an individual is just keep showing up and hope that the magic of contagiousness touches your work every once in a while.


Comment Section

Comments are closed.


Posted On: Saturday, 09 July 2016 by Rajiv Popat

I’ve been running for sometime now. Last year I finally took the plunge and ran two half marathons back to back. But even today when it comes to running I’m a complete amateur who is lured by the pull of distance running.

The flow and the meditative aspect of long runs is something every person has to experience for themselves and if there is one book that can bring out the true sprit of distance running, it is Born to Run.

To be honest I came across the book (and the barefoot running movement) when I was searching for way to avoid minor shin splints that had been nagging more for a couple of days. I never expected a book on running to blow me away but born to run did more than just blow me away.

The story telling, the writing style and the research – it’s one of those books where it all comes together to create reality that is much more magical than fiction.

This was one of the few book that was just impossible to put down. From the Mexican Tarahumaras to the real world characters like Caballo Blanco, Scott Jurek and Jenn Shelton every character in the book touches you, teaches you and becomes a part of your life.

Chris Mcdougall is a true collector of fascinating characters, research and amazing real stories. All I can say is, if you haven’t read this book, you’ve seriously missed one of the best books you’re going to read - ever. And that’s true even if you have nothing to do with running. This book deserves a five star – and respect.


Comment Section

Comments are closed.


Posted On: Monday, 06 June 2016 by Rajiv Popat

I’ve always been a fan of the Pomodoro Technique. It’s simple, it’s elegant and it works. You work for twenty five minutes, you focus on one thing and get it done. Then you allow yourself five minutes of distractions in a break and then you work for another twenty five minutes. You repeat this till your possibly can. There are physical twenty five minute timers you can buy for this.

But that’s just one aspect of Pomodoro. What if I told you that you could have a personalized Pomodoro instructor who would not just push you to work, but would demote you if you didn’t work hard enough. And he would even insult you and humiliate you with taunts if you were procrastinating. He would give you five minute breaks and once your breaks are over he would blow a loud whistle not just letting you, but your colleagues (who are hanging out with you) know that you now need to go back to work? Feels like an army trainer, doesn’t it?

I don’t know about you, but I like honest blatant truth. I mean if I can tell people to stop bitching and get back to work I don’t mind someone doing that to me. And I like tough instructors. No seriously; I do. One of the reasons I moved out of a gym and setup a gym at my home was because my gym instructor just wasn’t challenging me hard enough. And when it comes to work, I am also one of those people who don’t mind introspecting on questions like - Am I a Phony who hasn’t achieved much in life. The question (and the brutally honest answer I give myself) gets me down temporarily but pushes me forward in the long run.

So yeah, I love tough love - specially when I am dealing with myself.

And that is exactly why I love the Productivity Challenge Timer - which can be your personalized Pomodoro Instructor who has literally no feelings and is completely ruthless when it comes to getting you to work more.

The author of the application talks to you in first person and tells you how ruthless and unforgiving the application can be when it comes to getting you to work:

Work consistently and it promotes you and opens up new achievements for you which you can proudly flaunt. Cut some slack for yourself and the same app will not just humiliate you, but demote you with a loud sound so everyone around you at your workplace knows you were just demoted!

The app is humorous, it’s witty and the creepy part is, it’s addictive. And It makes you work! Folks around me now hear sounds and know when I am ready for a break. I am guessing they even know when I am promoted and when I am cutting slack or acting lazy or getting demoted. 

What’s even more amazing is that the app knows and understands the hard realities of distractions and meetings in the typical work environment. The other day, I worked for four hours completely meeting-and-distraction-free and the app not just gave me a promotion but told me in clear terms that ‘you worked for four hours today, which is rather rare in a typical office environment’ and it opened up an achievement for me.
I wasn’t able to work for four hours the next day because I had to interview four fresh candidates and the app wouldn’t listen to any of my excuses. It called me a ‘slacker’ and demoted me ruthlessly; leaving me with no options other than canceling some redundant meetings the next day and doing some more focused deep work.
There are very few apps that I literally use everyday of my life and Productivity Challenge Timer is one of them. I am not associated or affiliated with the app in any way; just a user who loves the app; and I would go so far as saying that if there is only one productivity application you are allowed to have on your phone, this should be that app! Especially if you like the idea of being tough to yourself and if you have a sense of humor.
Go download the free app and you’ll know exactly what I mean.
And… now if you will excuse me, I need to get back to work because Productivity Challenge Timer just started blowing the work whistle and I really don’t feel like getting demoted twice this week!


Comment Section

Comments are closed.


Posted On: Sunday, 24 April 2016 by Rajiv Popat

I first read about the elephant Rider analogy in the famous book, The Brain That Changes Itself, which happens to be one of my all time favorite books in the field of Neuropsychology. The basic premise of the elephant-rider analogy is that your brain has two distinct systems:

The Elephant: which constitutes pretty much all of the primitive and 'automatic' parts of your brain starting from the brain stem to the limbic system and The Rider: which constitutes the more modern and 'thinking' parts of your brain like the Prefrontal cortex.

The basic premise being that the 'elephant' is primitive, huge and very powerful (obviously because it's machinery has been fine-tuned over millions of years of evolution). The rider is small (because these brain parts developed relatively recently in the timeline of evolution), but more controlled and has the capability of driving the elephant.

Even though the rider has a capacity of controlling the elephant, any time there is a major disagreement between the Rider and the Elephant, the elephant wins hands down and the rider stands no chance - Remember the last time you promised you will workout but then decided to watch TV instead of going to the gym when the evening arrived? There was a disagreement between the rider and the elephant and the elephant obviously won.

Switch - How to Change Things When Change Is Hard - takes this analogy of Rider and Elephant and handles the delicate topic of understanding this relationship between the Rider and the Elephant so that you can help your rider guide your elephant towards changes that you really want to bring about - not just in your life but in organizations and large groups of people.

Switch begins by understanding and appreciating the fact that the elephant is much more powerful than the Rider and in case of a disagreement between the two the Rider stands no chance.

The book also recognizes that both the Elephant and the Rider have their own problems. The Elephant is wild, hard to control and driven by emotions while the Rider is often a victim of over thinking, analysis paralysis and procrastination.

The book is all about, different ways of not just motivating the rider, but 'herding' the Elephant and making both work as a team. The 1% Milk campaign described in the book is a classic example:

Two health researchers, Steve Booth-Butterfield and Bill Reger, professors at West Virginia University, were contemplating ways to persuade people to eat a healthier diet. From past research, they knew that people were more likely to change when the new behavior expected of them was crystal clear, but unfortunately,"eating a healthier diet" was anything but.

Where to begin? Which foods should people stop (or start) eating? Should they change their eating behavior at breakfast, lunch, or dinner? At home or in restaurants? The number of ways to "eat healthier" is limitless, especially given the starting place of the average American diet. This is exactly the kind of situation in which the Rider will spin his wheels, analyzing and agonizing and never moving forward.

As the two researchers brainstormed, their thoughts kept coming back to milk. Most Americans drink milk, and we all know that milk is a great source of calcium. But milk is also the single largest source of saturated fat in the typical American's diet. In fact, calculations showed something remarkable:

If Americans switched from whole milk to skim or 1 % milk, the average diet would immediately attain the USDA recommended levels of saturated fat.

How do you get Americans to start drinking low-fat milk? You make sure it shows up in their refrigerators. And that isn't an entirely facetious answer. People will drink whatever is around the house-a family will plow through low-fat milk as fast as whole milk. So, in essence, the problem was even easier than anticipated:

You don't need to change drinking behavior. You need to change purchasing behavior. Suddenly the intervention became razor-sharp. What behavior do we want to change? We want consumers to buy skim or 1 % milk. When? When they're shopping for groceries. Where? Duh. What else needs to change? Nothing (for now).

Reger and Booth-Butterfield launched a campaign in two communities in West Virginia, running spots on the local media outlets (Tv; newspaper, radio) for two weeks. In contrast to the bland messages of most public-health campaigns, the 1 % milk campaign was punchy and specific. One ad trumpeted the fact that one glass of whole milk has the same amount of saturated fat as five strips of bacon!

At a press conference, the researchers showed local reporters a tube full of fat-the equivalent of the amount found in a half-gallon of whole milk. (Notice the Elephant appeals: They're going for an "Oh, gross!" reaction.)

Reger and Booth-Butterfield monitored milk sales data at all eight stores in the intervention area. Before the campaign, the market share of low-fat milk was 18 percent. After the campaign, it was 41 percent. Six months later, it held at 35 percent.

The book is full of really smart ways of directing the Rider and motivating / herding the Elephant. From preventing child deaths in Vietnam, to getting people to work out and stopping  their black berry addiction the book is literally full of real, pragmatic and practical steps you can benefit from starting today and how you can bring about change where change is hard just because the Rider and the Elephant are disagreeing or falling prey to their respective weaknesses.

And if you find yourself giving excuses like, "I don't have the power" or "the rules in this place are too crippling" - this book is a must read because it literally has tons of real life examples of people who brought about huge changes at organizational (and even national) levels without being given any special power or authority to bring about change.

For example, there is the story of Jon Stegner who lands up in an manufacturing company where he brings down the purchasing cost of gloves in his organization by a magnitude of a billion dollars, not by making a PowerPoint slide show or calling meetings and inviting people who just didn't care; but by piling up a heap of 424 different kinds of gloves with different price tags on the board room table to shock and motivate the elephants of  the directors and board members to bring about change.

And then there is the story of how Paul Butler, saves the  St. Lucia Parrot, in Caribbean island of St. Lucia without being given any power or authority to do so. The book is full of amazing stories from real walks of life about how people herd elephants and motivate riders to bring about change that eventually touches hundreds of lives. And it's not just the stories which makes this book gripping, but the scientific and methodical dissection of the stories from the aspects of phycology that makes this book equally educational.

There are very few books on human brain that you find 'inspiring' but this book is one of those rare books and one of those rare books that I would not hesitate to rate a 5 on 5.  If there only a couple of books you are going to read this year, this book should be in your must read list for this year.


Comment Section

Comments are closed.


Posted On: Thursday, 24 March 2016 by Rajiv Popat

Millions of years of evolution has fine tuned the human brain to use it's most primitive parts to take decisions in split seconds. The limbic brain along with your emotions are hugely powerful when it comes to your decision making capabilities and probably the only reason why you are alive today reading this blog. When the lion roars or when a huge mass of iron and steel on wheels is moving towards you at 60 miles an hour, your limbic brain is what causes you to run and saves you from becoming lion lunch or the subject of a car accident. The emotional system of our brain is much more powerful at making decisions than what most of us realize and give it credit for. Countless books have been written on this topic but if there is one book that brings a lot of the research on the topic together it is How We Decide by Jonah Lehrer.

John Describes the power of how important intuitions can be:

Riley had been on duty since midnight. At 5:01 in the morning, just as the Allied ships began shelling Ash Shuaybah, he noticed a radar blip off the Kuwaiti coast. A quick calculation of its trajectory had it heading straight for the convoy. Although Riley had been staring at similar-looking blips all night long, there was something about this radar trace that immediately made him suspicious. He couldn't explain why, but the blinking green dot on the screen filled him with fear; his pulse started to race and his hands became clammy. He continued to observe the incoming blip for another forty seconds as it slowly honed in on the USS Missouri, an American battleship. With each sweep of the radar, the blip grew closer.

It was approaching the American ship at more than 550 miles per hour. If Riley was going to shoot down the target—if he was going to act on his fear—then he needed to respond right away. If that blip was a missile and Riley didn't move immediately, it would be too late. Hundreds of sailors would die. The USS Missouri would be sunk. And Riley would have stood by and watched it happen.

But Riley had a problem. The radar blip was located in airspace that was frequently traveled by American A-6 fighter jets, which the U.S. Navy was using to deliver laser-guided bombs to support the Marine ground invasion. After completing their sorties, the planes flew down the Kuwait coast, turned east toward the convoy, and landed on their aircraft carriers. Over the last few weeks, Riley had watched dozens of A-6s fly a route nearly identical to the one being followed by this unidentified radar blip. The blip was also traveling at the same speed as the fighter jets and had a similar surface area. It looked exactly like an A-6 on the radar screen.

The target was moving fast. The time for deliberation was over. Riley issued the order to fire; two Sea Dart surface-to-air missiles were launched into the sky. Seconds passed. Riley nervously stared at the radar screen, watching his missiles race toward the object at speeds approaching Mach 1. The blinking green blips appeared to be drawn to the target, like iron filings to a magnet. Riley waited for the interception.

The explosion echoed over the ocean. All of the blips immediately disappeared from the radar screen. Whatever had been flying toward the USS Missouri helplessly fell into the sea, just seven hundred yards in front of the American battleship. A few moments later, the captain of the HMS Gloucester entered the radar room. "Whose bird is it?" he asked Riley, wanting to know who was responsible for destroying the still unidentified target. "It was ours, sir," Riley responded.

The captain asked Riley how he could be sure he'd fired at an Iraqi missile and not at an American fighter jet. Riley said he just knew.

John in his book goes on to describe how an excruciating investigation later goes on to conclude that Riley had indeed taken the correct decision and how Gary Klein a cognitive psychologist, later dissects what was going on in Riley's head when he took the call of shooting down the missile:

Klein was intrigued. He had spent the last few decades studying decision-making in high-pressure situations, and he knew that intuition could often be astonishingly insightful, even if the origin of those insights was obscure. He was determined to find the source of Riley's fear, to figure out why this particular blip had felt so scary. So he went back to the radar tapes.

He soon realized that Riley had gotten used to seeing a very consistent blip pattern when the A-6s returned from their bombing sorties. Because Riley's naval radar could pick up signals only over water—after a signal went "wet feet" he was accustomed to seeing the fighter jets right as they flew off the Kuwaiti coast. The planes typically became visible after a single radar sweep.

Klein analyzed the radar tapes from the predawn missile attack. He replayed those fateful forty seconds over and over again, searching for any differences between Riley's experience of the A-6s returning from their sorties and his experience of the Silkworm blip.

That's when Klein suddenly saw the discrepancy. It was subtle, but crystal clear. He could finally explain Riley's intuitive insight. The secret was the timing. Unlike the A-6, the Silkworm didn't appear off the coast right away. Because it traveled at such a low altitude, nearly two thousand feet below an A-6's, the signal of the missile was initially masked by ground interference. As a result, it wasn't visible until the third radar sweep, which was eight seconds after an A-6 would have appeared. Riley was unconsciously evaluating the altitude of the blip, even if he didn't know he was doing it.

This is why Riley got the chills when he stared at the Iraqi missile on his radar screen. There was something strange about this radar blip. It didn't feel like an A-6. Although Riley couldn't explain why he felt so scared, he knew that something scary was happening. This blip needed to be shot down.

The book is a fascinating read not just because it showcases how powerful our emotions can be in taking decisions, it also showcases when our emotions can lead us astray and provides real pragmatic advice on how to balance the emotional with the thinking parts of our brains to come up with better decision making capabilities.

The book itself is one of the better books on the human brains that I've read and I personally loved the book.  However, what was disheartening was learning that the book has been withdrawn from the market by publishers after the discovery of the fact that Lehrer had fabricated quotes used in his books. I would have personally quoted this book left right and center in my discussions with people, had it not been for the nagging doubt I have about the authenticity of every minute detail the book goes into. The author has been found guilty of fabricating facts and plagiarism but that still doesn't take away the fact that the book is a nice read and provides valuable insights that I never had before. I give this book a 4 on 5 and would definitely recommend this book to anyone who is interested in a deeper insights on what our brain is doing when it's indulging in the act of taking decisions.


Comment Section

Comments are closed.


Posted On: Tuesday, 22 March 2016 by Rajiv Popat

When I finally patched together a couple of android applications with some custom code that would capture what I did with every minute of my awake time, push that information into a SQL database and then extract intelligent reports out of it, I was so darn excited that the first thing I did was show the system to my wife.

She smiles and thinks I am completely nuts and monitoring every minute of my life is a little too insane, even for a nerd like me. "Why would you want to monitor your time like that?" - she wonders. For me, as a geek though, the question isn't Why, the question is 'Why Not'. I love the idea of monitoring my time because:

  1. Now I can monitor how much time I spent getting ready to go to work, eating, working, watching TV, reading and even having fun. In the scheme of my life, time is one more dimension that I can now log into a system! How cool is that?
  2. I'm excited to find out what new insights and correlations about my life the data can provide me. For example, does the amount of time I spend in getting ready to get to work change based on when I wake up? If yes by exactly what percentage? What impact does that have on the amount of stress I experience when I start my day? What impact does that stress have on the number of productive pomodoro sessions I have for the rest of the day.
  3. I'm excited to find out how those insights will change me as a human being.

What can I say? I'm a typical nerd and I love my data.

My obsession with monitoring started with my very first endeavors with Fitness back in 2009 when an extremely skinny, underweight nerdy version of myself set a big hairy audacious goal of gaining 33 pounds of body weight in a year. It was about food and fitness logs back then. How much proteins was I taking in, how much cardio was I doing, how much strength training was I engaging in and how different combinations of cardio, strength, food and sleep were impacting my weight. I did eventually end up gaining 33 pounds in 11 months. Recently, when I started exceeding my BMI I used the same monitoring and lost 14 pounds in 2 months and have not gained the weight since. I discovered that as a nerd, what I can measure, dissect, read about, study and understand, I can improve.

My long life as a developer has taught me that big changes are all about profiling the right data and making small tweaks based on the insights the data provides. Almost every time you see a manager and a developer fighting over performance, the question to ask the developer is: Have you profiled your application? Do you know what's slowing down the system? OR are you just working on a hunch?

Hunches are great, when they lead you to an answer instantly. When they don't, they send you on a long trip to an infinite loop of random guesses. But collect enough data about your code, analyze it and you realize that the fix is usually a small change in a function which hits a database inside a for-loop or something really as simple as that. The fix itself isn't hard; gathering enough data about the issue and then deriving enough insights from that data that leads you to the fix, is.

For most Nerds, me included, it's the same thing when it comes to life.

Which is why when I started collecting data about my Finances and started recording every financial transaction in my life to the very last cent in a well designed system with apps and some basic reports I used on top of the data, my savings rate jumped by more than 50% in just 3 months.

Did my life style change significantly? Not really. We still eat out and we still spend money on things that matter to us. However, we realized that we were paying for over a hundred television channels me and my wife were never going to watch, that go-daddy was auto-renewing over 30 domains on my credit card that I never used and my bank was looting me by skimming off the interest rates of my investments. Well that and a dozen other holes that had been leaking hard earned money constantly for years.

They were all little things, but when the number totals up and you see those things add up to over 20% of your actual monthly savings, you have a reason to pick up the phone and cancel a few subscriptions. And when you do that and that results in considerable savings, you get the confidence to save more and then you defer buying that fancy new electronic toy that you don't really need by a few months - not because you can't afford it - but because it's not in your planned budget and you need to save up for it.

And then it gets exciting, because suddenly before you know it, you've added some new investment goals into the system and now you're tracking your progress towards those goals and your wife has also seen the data and is actively helping and supporting you in moving forward towards those goals, even when you are tempted to spend. That's what data does to you; especially if the insights the data gives you are clear and out in the open. 'I'm spending way too much on things I don't need' is nowhere close to as powerful as 'I'm spending x% of my income on things I don't need' especially when x is large.

Monitoring turns out to be so important that, Author Gretchen Rubin, has an entire chapter dedicated to monitoring in her book, "Better than before" (which happens to be book #3 of 52 books on my list this year) - where she explains the kind of impact monitoring can have on your behavior by giving her sister's example:

Elizabeth has type 1 diabetes, which means that her pancreas doesn't produce enough insulin. (In type 2 diabetes, which is far more common, the body produces insulin but doesn't react properly to it.) Without insulin, blood sugar can spike to dangerous, even life-threatening levels, so Elizabeth must give herself multiple daily insulin injections, and to inject herself correctly, she must know her blood sugar level.

For years, she'd tested her blood sugar by pricking her finger to check her blood, but she'd recently gotten a device inserted under her skin to monitor her blood sugar continuously. I wanted to know if she found the monitor effective.

"Monitoring is key," she said. "For years, I hated the idea of having a device attached to my stomach, but with diabetes, accurate tracking is so important that I finally caved. Now I can't imagine not having the monitor."

When she told me she was getting the device, I'd imagined that it might administer insulin directly, or tell her what she needed. Nope.

The monitor merely provides a continuous record of her blood sugar levels—but that information makes a big difference.

"Without a monitor, I might test my blood sugar ten times a day, but the monitor checks it constantly," she explained. "I know where my blood sugar is and where it's heading. Also, I know the effect of what I'm doing, so I can't kid myself. Like I was eating this frozen yogurt that claimed to be low-carb, but from the readings I got on my monitor, I know that can't be true."

"Even though the monitor doesn't actually do anything, seeing the numbers makes you behave differently?"

"For sure. Without a monitor, if I ate something questionable, I might unconsciously wait a few hours to test, so I'd get a better number, but that doesn't work with a monitor. I can't fool myself."

That's why the Strategy of Monitoring works so well: no more fooling ourselves. I decided to exploit it for my own habits. If I had a better handle on what I was doing, I could focus my habit-formation energy in the right place. I suspected that in certain areas, I was giving myself more credit for good habits than I deserved.

If you want to see the kind of impact real time monitoring can have, specially given the devices and the technology we have at our disposal today, take a look at Scott Hanselman's IoT demo on monitoring his sugar. Scott's excitement of the technology and the kind of insights that it can provide is a reflection of how any geek would react when he sees huge volumes of personal data analyzed to provide insights that you never had before.

As for my time monitoring system, I realized that the system still had a lot of manual entry points, which is why I wasn't consistent with it, but that failed attempt helped me monitor windows of my time that I really wanted to monitor and that in turn has actually made me a lot more productive than before. After all, some data is still better than none. And I am still working on a system that can monitor more and more of my time without me actively logging things.

The Point? Data collection on yourself and self monitoring isn't all about buying the hottest fitness band in market. It's about building systems which have the potential of providing you insights about yourself that you never had before. And then having the courage and conviction to change based on those insights.

In the posts to come in this series I'll try to document some of my efforts at monitoring my own life in near real time and showcase how I monitor aspects of my life, how I draw correlations between the data and how I tweak my life to bring about some of these changes.

Of course, in the larger scheme of things I'm just a data point of 1, I suck at Mathematics and I'm not even a social or a data scientist, but I hope these experiments inspire you to capture parts of your life that you feel are important and then tweak them ever so slightly to get huge benefits. That's what this series of posts is going to be about.

What aspects of your life are you monitoring actively with data? Of course if it's an area of your life that needs improvement you would know things are bad and if you know things are bad you can fix them, but sometimes, quantifying just 'how bad' things are is the nudge that we as nerds need to change things. And it can teach us things about ourselves that we thought we knew before, but we didn't.

After all, most of us aren't really as mindful as we think we are but we have the gift of data and of the many things data can do, one of the most powerful is brining you face to face with yourself.


Comment Section

Comments are closed.


Posted On: Tuesday, 08 March 2016 by Rajiv Popat

I was introduced to Transactional Analysis by the book - "I'm OK. You're OK." - and after reading the book I was hooked and hungry for more information on the topic. Which nerd would not be interested in a branch of science that refers to verbal and non-verbal communication between people as transactions and then uses objective ways of analyzing these communications?

Games People Play: The Basic Handbook of Transactional Analysis.">Games People Play takes off from where "I'm OK. You're OK." left off and is the natural "next read" of I'm-OK-You're-OK, specially if you're interested in Transactional Analysis as a topic.

Given the fact that  Eric Berne happens to be the father of Transactional Analysis, I had a lot of expectations from this book and this booked lived up to every single one of those expectations.

Apart from the concepts of the Parent Adult and Child (which I talked about in my previous post when talking about I-am-ok-you-are-ok) Eric covers the concept of pass-times that people indulge in and, as the title suggests, the games people play.

Games in TA are certain patterns of transactions (TA refers to both verbal and non-verbal communication between people as transactions) which recur repeatedly in every day life where the intentions of the transactions aren't very obvious.

Eric starts the book with an example of a game call NIGYSOB (Now I’ve Got You, You Son of a Bitch):

While his parents and their friends were drinking coffee at the kitchen table, Jonny, age five, ran in and out of the room, happily pulling his favorite truck behind. Suddenly, there was a crash in the living room, his mother found a glass vase knocked off the coffee table and shattered.

"Who did that?" she asked.

"Doggie," he replied.

Mother's neck reddened. She knew she had let the dog out five minutes before. Stepping forward she hit him saying, "I will not have a child who lies!"

It was obvious who broke the case. Consequently, Jonny's mother's question as to who broke the vase, while superficially an Adult request for information, was, at the psychological level, really an invitation for Jonny to lie - and he did.

As mother's neck reddened, she was switching ego states from Adult to Parent. Her payoff was a sudden surprise feeling of righteous wrath.

We would say that mother played the game of "Now I've Got You, You Son of a Bitch" (NIGYSOB). It should be noted, however, that she had not deliberately and consciously set out to "get" her son and to hit him.

On the contrary, she was quite distraught by the outcome. Jonny  for his part, played "Kick Me". If he had said, "I did it", there would have been no game.

The book goes on to describe not just dozens of games people play in every day life, but it gives each game an equally interesting name. The book makes you laugh, it makes you think and it makes you wonder about how predictable and similar we are as human beings. With every game Eric also talks about how you can choose not to play games and gives solid practical advice on building game-free relationships and eventually a game-free life.

While the book provides an entertaining insight into the games we play and even deeper insights into why we play them, it also nudges us to push the adult part of our brain to take control so that we can have a game-free mature existence.

All in all, a must read for anyone who is interested in becoming a better individual. A book that's much better than peppy self help books because it uses real life case-studies of people who have been given TA treatments to heal them and improve their relationships, personalities and life. If this was an Amazon Rating, I'd give this book a solid 4 out of 5.


Comment Section

Comments are closed.