Today’s Arduino lesson

To record my self-education in progress, I’m going to post what I learn as I go along.

Today’s lesson: programming an Arduino to flash LEDs.

There are so many tutorials on the Web (and on the Internet, too, of course) that I’m not here to teach the general reader the art/science of programming.

Instead, I’m going to record how I learn in order to help my future self should I suffer a debilitating mental setback and need information about how my brain used to work in case it assists me in rewiring my mental circuitry.

First of all, I’ll record the recent purchase of equipment from RadioShack (thanks to Tim at the Huntsville Commons location!) I added to my pile of stuff in the study/lab:

  • ARDX – the Experimenter’s Guide for Arduino (product number 276-252)
  • PIR Motion Sensor by Parallax Inc (product number 276-135)
  • RadioShack standard server (product number 2730766)
  • RadioShack micro server (product number 2730765)

For today’s lesson, I’ll only use the ARDX.

20131015_095947

 

Since I’ve already played with the Arduino lighting up a single LED, I’m jumping ahead in the ARDX to the second experiment — playing with eight LEDs!

Yes, I know this is too much fun for one person, let alone an Internet full of them!

Anyway, here’s the circuit diagram we’re going to use:

20131015_100225

 

Next order of business — getting the parts bags out so I can be ready to pull parts as needed:

20131015_103309

 

Okay, now’s it the old plug-n-pray that my big fumble fingers and half-blind eyes can see to place the parts in the right holes on the breadboard.

Do a visual double-check (and a triple-check of the double-check) and I’m ready for the software side of things:

20131015_105817

 

It’s off to the Arduino programming environment I go!

I grabbed the code for this experiment off the company’s website, http://ardx.org/CODE02, and pasted it into the Arduino coding section, naming the “sketch” CIRC02:

20131015_111222

I verified that the code is functional by compiling it — successful!:

20131015_112150

I then plugged the Arduino to my notebook PC via USB cable and let it boot up:

20131015_112412

Finally, I uploaded the code from the notebook PC to the Arduino:

20131015_112421

 

And here’s what the code produced.

On to the next task — figuring out what this code can do for my yard art sculpture!

Be Ready To Sail

Here’s that parody video I made for Claire Lynch and her bandmate, Mark Schatz, back in 2011.

 

Here’s Mark’s dance video that inspired my little viddy.

 

[Mark Schatz in action with other giants of bluegrass such as Bela Fleck and Jerry Douglas playing Chick Corea’s “Spain”.]

But don’t forget BOY DANCE PARTY!!!

How can I be in two places at once?

How can I 1) watch how well Jeff Gordon races in Charlotte and 2) dance to the music of Claire Lynch and friends at the same time?

Life is a series of happy dilemmas!

= = = = =

A special nod to Greg and Carolyn at Cook & Company; the friendly folks at L’Rancho Restaurant; Travis and cooks at Broken Clock Gastropub; whomever I’ve forgotten to mention lately in my rush through life.

In 2013…

So, now that the U.S. government has been (partially) shutdown, do you have a more clear picture of how government plays a role in your daily lives, helpful and/or intrusive?

What lesson(s) will you take with you into the future from this political wrangling?

How can you improve your life and those around you by turning the lessons into actionable plans?

Are you a proponent of the PDCA — plan/do/check/act — philosophy of business?

I wish us all luck in helping us make our lives as more comfortable, enjoyable and [im]practical as we wish.

How many spiders share a single web?

In the art of writing lives the thoughts of the writer — the philosophy, the biography, the culture (current and historical events, [un]written rules/laws), the imagination.

The genres of the written word reflect the writer in more or less ways — e.g., an engine construction manual is different than a political autobiography.

In my stories, I let my philosophy show through one or two characters but not all of them.

My talent agent and my editor frequently remind me not to tell people what I think because there’s no better downer/bummer for sales than a fiction writer breaking through the page with personal beliefs unless the writer is a bigger character than the ones written in the author’s books.

My beliefs are unimportant, anyway.  What I belief is not as important as what my behaviour shows.

However, if a person upholds and promotes a set of beliefs to which the person professes that behaviour will show, I will expect that person to do so.

For instance, what do you think about the concept of religion?  You know, how we package our emotional states and social rules into a commonly-shared narrative about the universe and our place in it.

Whatever you choose to call your religion, whether it’s one handed to you by family, discovered amongst your friends or developed on your own, is yours.  I will not condemn you for validating your lives, regardless of my inability to understand your behaviour or your explanation for such.

Recently, I watched a video by a person who recognised an honorific bestowed in his name — the Richard Dawkins Award — given at the Atheist Alliance of American convention to Steven Pinker.

i perfectly understand the reason behind the award and applause anyone who’s willing to make a hypothesis, test it and write about the results.

I am bothered by the video, though, especially the part that denigrates religious belief.

Am I wrong to think so?

Are most religions a form of hero worship, either of the indescribable essence of an infinite god or of the earthly equivalent, both attributed with our less-than-perfect traits?

That people misapply their behaviours based on their interpretations of their heroes’ intent is what history is about, no matter whether we apply the label of religious or sociopolitical to the behaviours and subsequent events/consequences.

Maybe because Richard Dawkins is an avowed atheist he feels it necessary to put down other people’s hero worship while congratulating himself in a sideways personal compliment aimed at a personal hero of his, the prize recipient, Steven Pinker.

I cannot change history — the facts of the interaction of sets of states of energy that occurred before this moment.

Is it right for me to condemn people for their beliefs, no matter how well or poorly they put them into action in the past, present or future?

I don’t know.

To hear Richard Dawkins say, in essence, that his subculture is the only one that’s right and let’s pat each other on the back for publicly patting each other puts sand in between my claws, making me flex my pointy bits and scratch the surface of what’s bothering me.

After all, rational science is not a benevolent application of our beliefs and behaviours.

A computer network doesn’t “care” how it’s used, whether as an open channel for remote robotic surgery, atheist award videos, Sunday sermons, drone strikes, government monitoring of citizens or online Ponzi schemes, yet computers and networks are the result of applying the scientific method that an atheist should award a public prize to.

I guess I am not an avowed atheist and should leave it at that.

I accept that we are all wired a little differently and what jolts one person into action may be similar to what jolts another but it’s not entirely the same.

If an avowed atheist and an avowed Christian/Hindu/Muslim/Jew/Buddhist/Taoist/humanist/spiritualist both come together to the aid of a child with severe injuries during a major natural disaster, then I am happy, because their actions rather than their beliefs achieved the same results.