Book Review: BeagleBone Robotics Projects

I was asked by Packt Publishing if I would read and review this book. I’ve owned a BeagleBoneBlack for a little while now. My use case was not robotics. This book might shed some new light on my old Black, so I agreed to review it.

The book starts off very accessible. Chapter 1 covers just about everything I did with my BBB when I first received it, hooking it up like a PC, replacing the default distro, making sure I could SSH to it were all in there. The author, Richard Grimmett, goes a step further and installs XFCE gui and vncserver and walks through connecting from a Windows PC using vncclient. All in all, chapter 1 is a great super basic tour.

Chapter 2 dives into programming on the thing and introduces Python. It does it in a really weird (to me) way. It has the reader running emacs in a putty window remote connected to the device. This must just feel weird to me because I do a lot of remote programming and its never with emacs (I’m a vim guy) and its rarely remote. For a new user, it seems to me like it would have been simpler and more friendly to say “use an editor of your choice” and “here is notepad2 or sublime” along with “here is how you copy files to and from the device.” I think this is mostly my background causing me to see things differently. The emacs in putty walk-through is very adequate.

Its not a programming book, so this is really a nit pick, but technically some of the descriptions of python aren’t really true. For example, if __name__==”__main__”: does not “tell the program to begin its execution at this point.” Again I’m nit picking, but I do feel like a different phrase that isn’t so very false to someone who knows python could have been found. Still, its not a programming book. The beginning of the chapter does list many resources for learning python.

Ugh, and then the book moves on to C++ and has quotes like this, “C++ is the original language of Linux” I’ve used Linux for almost as long as I’ve programmed C, and I am very (perhaps overly?) sensitive to the difference between C and C++.

OMG what do you mean Speech Input and Output? Really?  Chapter 3 tackles it. Really. For real. Speech Input and Output on that tiny little board. I can make my own Siri! This is a really cool topic; espeek is something I’ve only played with a little bit prior to reading this. It looks fun.

Speech recognition is done with software I’ve never used before called PocketSphinx. It isn’t packaged and so one has to compile it. Pretty sweet BBB being able to compile stuff like that. (I’m thinking of iOS and Android where I’ve not seen a compiler run on device.) The demo walks through limiting the grammar of speech input so that you don’t have to train the recognizer.

I’m a programmer, so I’m going to nitpick programmer things. I really wish authors wouldn’t do this, “I like to make a copy of the current file into continuous.c.old, so I can always get back to the starting program if it is required.” I really do wish authors would just say “go read about version control systems.”

Whew, speech is fun. Next step is video. Hook up a webcam and let’s do some image recognition. The book walks through OpenCV and it is as this point that we are forced to do a bunch of Linux sysadmin stuff to make our SD have enough free space to have a dev environment. This really could have gone anywhere in the book. I kind of like that it put it off until it was necessary.

The python image tracking example using OpenCV looks pretty cool. It is a complete example without going too deep or going off in the weeds.

Making the Unit Mobile introduced me to mobile platforms. The Magician Chassis that the book shows first, I found online for under $20! I knew that this stuff was accessible, but this is downright cheap. I feel almost guilty NOT getting one and trying it out.

The motor controller tutorial looks very straightforward. I already have ideas for code changes. Immediately after the simple time based tutorial it goes into speech controlled movement, which is pretty sweet.

After the wheeled robot tutorial is a walking robot example. The author makes a compelling argument for this type of robot, and the Pulse Width Modulation servo motors are cool, but I have to admit, this type of robot just doesn’t excite me. The book also punts on the PWM, using a controller which interprets serial USB commands into the PWM for the servos. For beginners, this is certainly the right choice.

Incidentally, the –help output from UscCmd includes Version, Culture, PublicKeyToken values like a Mono program might. I wonder if it is written in C# and running via Mono. I’m going to assume it is. That is pretty sweet. Indeed the linked download page mentions C#. http://www.pololu.com/docs/0J40/3.b

The sonar sensors section is a straightforward and great introduction to the use of them. I never knew how those things worked or what kind of value they returned. Now I do. Mounting the sensor to a survo makes for a nice subsystem on the bot.

Next, a fully remote control system is built. I don’t know if I like the choice of using an LCD monitor. It seems like overkill, but depending on the particular robotic application it would be a good choice. For the applications I have in mind, I think I’ll skip it. A wireless usb keyboard and mouse makes for an obvious choice. At this point, I just keep thinking about bluetooth and using an extra Wiimote, mostly because I think it would be a more fun control.

Oh, a GPS receiver! This could be necessary for when I lose my robot in a parking lot or the woods. As with the LCD Monitor and KB chapter, I kind of feel like I know how to do this since I’ve looked into it before. It is great coverage and good intro to the topic.

Much of my day job is what would traditionally be called Systems Programming so Chapter 10 is kind of a duh to me. I’d have started there, but that is just how I think about coding these days. Its great to have this in a chapter to tie some things together. In other words, read this chapter!

Using the BBB in sea, air and submarine applications is an interesting idea. I don’t think it is for me yet, but the book gives introduction to some ideas on the topic. The introduction to feedback control is very welcome.

Overall this is a great book. It really gave me a lot of ideas. It also showed me how easy it is to get started, something which I’d been a little hesitant to do. I’m actually a little excited to dive in now. I’ll be doing a bunch of this stuff with my 6yo over the next few years.

CodeMash 2012 Changed Me

Every CodeMash has changed me.

This CodeMash was no different.

I’ve attended every codemash. Each is unique and special. I have memories from each that I can point to and say “This is when I realized…” and it is something significant that changed who I am or what I am doing or how I approach code and life.

This year I feel the focus of change was definitely softer. It was not some deep technical conversation that I had at the attendee party with someone able to explain to me something in a way which I can see applicability for myself like it has been in most years past. This year I didn’t focus on the mash part of CodeMash.

CodeMash, to me, has always been about learning from outside your normal circles. If you are a .NET person, go learn something about the ruby world. If you are a Ruby person, go learn something about Java (assuming you’ve never lived in that world). If you are a Java person, find a PHP or Perl session (there weren’t too many this year). ‘Mash not bash’ has always been the underlying philosophy that CodeMash has taught me to adopt.

I’m done mashing for a while. I’ve been doing C# for day work for 7 yrs. Of course, to me, mashing that also meant making sure things would run on Mono. I’ve explored Ruby and Rails for at least 6 years now. I pay attention to the Ruby world. In fact, I have more Ruby podcasts in my subscription than I do .NET (or any other). I watch the Java world (to not do so as a .NET dev is foolish IMO). I long for Akka in .NET (although I think Stact and MassTransit might get me there). I long for… Heroku. I long for.. I mash… I long for… many things.

This year I didn’t mash at CodeMash, and I didn’t miss it. Ok, sure, I did a javascript precompiler where I felt like I finally understand JS as a language. I finally grasp the deceptive simplicity of prototypical inheritance. But beyond that, I went to C# and .NET sessions. I loved seeing Bill Wagner and John Skeet present some deep inside and outside C# async. I loved seeing PhatBoyG present Stact.

During his keynote, I believe I heard Barry Hawkins say “Depth trumps breadth”. Its not that I don’t feel some depth in some areas in which I play, but I want more. I feel like I have enough breadth.

So I leave CodeMash, like I do every year, with new direction and a new sense of purpose which I hope to utilize to become a new person. I want to be a different person than I wanted to be a year ago… again.

I cannot overstate one influencing factor which has had a profound effect on me coming to the above determination. Leon Gersing. I met Leon 4 or so years ago at a Columbus Day of Dot Net event. Of course even then I thought, “What a cool guy.” But if you have known Leon for that long (and I don’t know him very well) you know that Leon too has changed over the years. At the GANG 10 yr anniversary event, I got to listen to Leon give a talk on the topic of “You”. It was similar to the short and less serious topic he gave as Pecha Kucha on “Love”. I think a lot of the underlying message is the same and so I’m walking away with that on my mind.

CodeMash 2012 was huge win. It was also HUGE! I know that there were people there, who I know, who I did not see the whole time! Scott and Gary are a couple guys I didn’t see until the after party! So if I missed you, lets hope we run into each other next year. I’ll be the guy who is a little different than last year.

Thanks for the great conference, CodeMash!

Fly places…

I first became aware of it when Meg McCain told her story on Thursday, November 11th. Google her name. I recommend you carefully listen to what she said. She has been called a liar, but after listening to her story there is no point that I can tell that she lied. She never said that she was felt up. She said that she would have been felt up. Watch the video, you see that she never was felt up.

I’m writing this because I was a little surprised when some people I know weren’t outraged or at least a little disturbed. But I draw the line at anyone saying that the TSA is doing a good job or that they are making us safer. They do neither. Here is a collection of links which suggest that they provide no security and do a poor job attempting to.

http://blogs.forbes.com/artcarden/2010/11/14/full-frontal-nudity-doesnt-make-us-safer-abolish-the-tsa/

http://fuckthetsa.com/

http://www.flyertalk.com/forum/travel-safety-security/1147551-flyer-san-says-no-grope-escorted-checkpoint-leo-threatened-suit.html
http://wewontfly.com/6-year-old-aggressively-patted-down

http://www.ourlittlechatterboxes.com/2010/11/tsa-sexual-assault.html 

 http://pajamasmedia.com/blog/why_have_67000_tsa_employees_l/

http://www.thestar.com/news/world/article/744199—israelification-high-security-little-bother

 http://www.theblaze.com/stories/cair-tsa-can-only-pat-down-muslim-women%E2%80%99s-head-neck/ 

 http://flywithdignity.org/ 

 http://johnnyedge.blogspot.com/2010/11/these-events-took-place-roughly-between.html 

 http://www.theatlantic.com/national/archive/2010/11/tsa-opt-out-day-now-with-a-superfantastic-new-twist/66545/

http://www.schneier.com/essay-303.html 

 http://www.flyertalk.com/forum/travel-safety-security/1147497-tso-saying-heads-up-got-cutie-you.html 
http://www.optoutday.com/ 

this is the most disturbing which I won’t even watch again : http://www.youtube.com/watch?v=2TCHSGvNwRY

http://gizmodo.com/5435675/president-obama-its-time-to-fire-the-tsa

nevermind that the x-ray scanners are a result of lobbying and not security descision : http://www.washingtonexaminer.com/politics/_Naked-scanners__-Lobbyists-join-the-war-on-terror-1540901-107548388.html

deadlier terrorism existed long before 9/11, but we were calmer and less panicky : http://www.salon.com/technology/ask_the_pilot/2010/11/10/airport_security/index.html

I don’t usually agree with Alex Jones, but I link you for completeness : http://wewontfly.com/tsa-fondles-women-children

http://www.nationalpost.com/news/Naked+scanners+airports+dangerous+scientists/3819955/story.html

http://www.theatlantic.com/national/archive/2010/11/body-searching-children-no-for-the-us-army-yes-for-the-tsa/66535/

 

 

lots of people sharing their experiences with this tyranny: http://views.washingtonpost.com/post-user-polls/2010/11/have-you-ever-been-subjected-to-an-airport-security-pat-down.html?hpid=talkbox1

The Israeli model is nice, but might not scale to US needs : http://www.schneier.com/blog/archives/2010/01/adopting_the_is.html

I’m all for a call to abolish the TSA : http://www.allamericanblogger.com/12818/dont-change-the-system-end-it-a-free-market-case-for-ending-the-tsa/

Absolute power corrupts absolutely:  http://www.huffingtonpost.com/fred-gevalt/airport-security-and-tsa_b_561156.html

They want to make it status quo so that you accept it everywhere : http://canadafreepress.com/index.php/article/29959

Awesome story of spreading truth and getting results : http://blog.izs.me/post/1591805056/tsa-success-story

Canada doesn’t like it : http://www.torontosun.com/comment/columnists/ezra_levant/2010/11/15/16158116.html

Great discussion comparing the Israeli model : http://roomfordebate.blogs.nytimes.com/2009/12/30/aviation-security-and-the-israeli-model/#more-27215

The TSA is apparently optional : http://www.washingtonexaminer.com/politics/Amid-airport-anger_-GOP-takes-aim-at-screening-1576602-108259869.html

Its a DHS decision : http://publicintelligence.net/wide-use-of-u-s-airport-body-scanners-depends-on-obama/

The images get leaked : http://gizmodo.com/5690749/

The TSA seeks retaliates by starting an investigation : http://www.signonsandiego.com/news/2010/nov/15/tsa-probe-scan-resistor/

I find it disgusting that the TSA keeps saying “there will be civil penalties” of up to $10,000 or $11,000. What penalties? WTF are they talking about?

Penn Jillette might be getting special treatment : http://www.pennandteller.com/03/coolstuff/penniphile/roadpennfederalvip.html

New Jersey Legislators take on the TSA: http://www.youtube.com/watch?v=9H9HNEtrvEE

Senate had a tiny useless hearing on the subject of TSA pat downs : http://news.cnet.com/8301-31921_3-20023038-281.html

TSA and America’s Culture of Zero Risk : http://seclists.org/isn/2010/Nov/50

You could use the XRays to send messages to the TSA, but you are still subjecting yourself to unnecessary radiation : http://jstogdill.posterous.com/send-the-tsa-a-message-it-will-be-fun

Ron Paul responds well : http://www.youtube.com/watch?v=d-N5adYM7Kw

oh, there is a higher quality version of that same thing here: http://www.youtube.com/watch?v=Qwsdq69AHnw

An airport opts out : http://wdbo.com/localnews/2010/11/sanford-airport-to-opt-out-of.html

http://www.examiner.com/libertarian-in-national/florida-airport-to-opt-out-of-tsa-screening

Ron Paul writes about it too: http://paul.house.gov/index.php?option=com_content&task=view&id=1796&Itemid=60

A very good op-ed on Milgram’s obedience experiments : http://elusis.livejournal.com/2141915.html

Audio of a TSA Integration: http://www.youtube.com/watch?v=tEJpzVPmih0

Seaport airlines – no lines, no rubber gloves, no TSA : http://www.seaportair.com/

Compilation of TSA issues  : http://www.youtube.com/watch?v=RhkQoiaf7Uc

first hand account of getting on a plane with guns but not nail clippers: http://www.redstate.com/erick/2010/11/18/another-tsa-outrage/

EFF has good advise on dealing with the TSA : http://www.eff.org/deeplinks/2010/11/stand-against-tsa-invasive-security-procedures

Bruce is summarizing and commenting : http://www.schneier.com/blog/archives/2010/11/tsa_backscatter.html

It looks like Future Speaker of the House Boehner would change his behavior if the bill proposed by Ron Paul above were passed : http://thecaucus.blogs.nytimes.com/2010/11/19/no-security-pat-downs-for-boehner/?hp

</P?

Real IPv6, Here I Come

For a few months now, my entire home has been on the ipv6 internet via Hurricane Electric’s free tunnel service. It has been very cool and I’ve learned a bit about IPv6 in the process.

Today I was happy to see an email from Comcast about their IPv6 trial program. I don’t have direct IPv6 just yet, but this was the first time I had to agree to Terms of Service.

Confidentiality.  While the conduct of the Trial, the nature and quality of the Trial Service and any Trial Equipment you receive constitute Comcast confidential information, one of Comcast’s objectives is to assist the general Internet community in preparing for IPv6 and to encourage widespread IPv6 deployment across the entire Internet.  Thus, you are authorized to discuss details of the trial with non-participants, such as members of the Internet Engineering Task Force, and to post information about your participation on web-based forums, email discussion lists, social media networks, etc. However, you agree not participate in any media interviews that involves disclosure or discussion of any details of the Trial with media representatives, including but not limited to professional bloggers, print media, online newspapers and magazines, radio, and television, without the prior written approval of Comcast.

I have to admit, these terms aren’t too bad. I can blog about it, tweet about it, talk about it all I want. I can be as mean or as nice as I want. But… “no interviews” 🙂

TechEd 2009

I’m leaving tomorrow to go to TechEd 2009. I’ll be working the C# and F# “Ask The Experts” booths for half of the day each day Monday through Thursday. When I’m not there, I’ll be catching sessions and pretending to be an open sourcer by hanging in the Mono booth.

If you want to meet, or just say hi, stop by and do so!

Updated Life Goals

I was tagged regarding annual goals. I’ll just call them life goals, since I am not going to tie them to a specific year. If I do them right, they will change my life permanently. Of course a goal needs a timetable, so knowing how hectic my Decembers are, I’ll say these should be done 10.5 months from now.

  1. Create More
    I consume a lot of content. Some things will remain strictly consumable for me. Music, television and movies are not something I’m willing to create. Books, articles, blog posts and other forms of writing are something I should create more. I consume them greatly. I probably read too many blog posts, but I’m ok with that. Code is something I should definitely be creating. Sending patches to my favorite open source projects or trying to port them to Win32 are my goals.
  2. Watch Less Television
    I’m a Law and Order addict. I never watched it when it was new. I still don’t watch the original. Criminal Intent and Special Victims Unit are always on and I’ve never seen them. Its 10+season of episodes that always waste my time. I’ll probably also watch less sports too.
  3. Trash ten pounds
    I lost the twenty pounds I gained while my wife was pregnant, but the twenty I gained throughout my 20s are still with me. I’d like to keep some of the weight as muscle and shed the fat, but I think I’d be better at 165 pounds instead of 175 pounds.
  4. Get Out of Debt
    I hate debt. I’ve got the debt-free bug. I want out. I want to owe no one. My family religion even calls debt slavery. "The rich rule over the poor, and the borrower is slave to the lender." (Proverbs 22:7)
    Last year my wife and I paid off the last of our non-housing debt. The ambitious goal this year is to pay off our mortgage. Its a huge goal, but it is one that I am passionate about. Think your house is an investment? Maybe yours is. Mine will never be. Think a house is a good investment? Well, consider you bought in 2003? How is that “good investment” performing for you?

I’m not calling anybody else out. If you read this, consider yourself called. What areas of your life are you currently working to improve?

MVP For Me

A week ago, on Tuesday, July 1st, I received a strange email. I should have known it was going to be a strange day. I was wearing my Ohio Linux Fest 2006 t-shirt. I had just listened to Java Posse podcast and was listening to Mac Break Weekly. Since I don’t write java code and I don’t own a mac, I should have know I was playing with fate.

This email might have been a joke. It was short and to the point, exactly the opposite I would expect for an email of this subject matter. It should have been some crazy HTML formatted table of disgustingness which I would have initially dismissed as spam. It should have had embedded images and fancy fonts. It had none of these things.

The email subject said very simply and plainly, “Congratulations! you have received the Microsoft MVP Award”. Surely someone was playing a trick on me. It was probably one of my old Linux buddies making fun of me for using so much Microsoft software these days.

I opened the message to read, “Congratulations! We are pleased to present you with the 2008 Microsoft® MVP Award! The MVP Award is our way to say thank you for promoting the spirit of community and improving people’s lives and the industry’s success every day. We appreciate your extraordinary efforts in Visual C# technical communities during the past year….”

It looks legit. I don’t know what I did to deserve such an award, but I’m grateful for it. I plan on continuing doing whatever it I’ve been doing.

Who knew that an perl loving, linux loving, python loving, linux kernel hacking, mono loving, C# loving, boo loving, F# loving, wife loving baby loving insane hacker could be a C# MVP. I sure didn’t.

Thanks to anyone who put in a good word about me.