Jan 23

Friday Post: Javascript for Kids Review & iOS dev needed

Hey All!

So my 31st birthday was great.  Got a Gamecube controller adapter for the Wii U, had some 8 player smash battles, and my wife made me an awesome Pokemon cake!

IMG_4703

PiPlay iOS App

So one of the items I have been working on on the side for PiPlay is a remote controller option.  I have the backend working.  A daemon sits on the Pi as a virtual keyboard (using udev) waiting for a specific HTTP request which is then interpreted and issued a keypress.  It’s really cool to see in action, but ugly as all get out.

This is why I am asking if anyone has any iOS design / dev experience, I would love to chat with you and hopefully work together on this as an open source project.

10935506_10103804677807022_1324185694_o

My not so impressive mockup skills 🙂

Book Review: Javascript for Kids

Javascript For Kids is the next book in the “For Kids” series from No Starch Press.  When they originally sent me the Python For Kids book, I was really excited.  It was my first time reviewing a book, and it was an amazing text in its own right.  So when they told me Javascript For Kids was available, I jumped at the chance to review a copy.

I’m going to say this outright: I like Python For Kids better.

Javascript For Kids takes you from zero programming experience, all the way to programming graphics and mini games using the canvas tag.  Whereas Python For Kids was very easy to read and hard to put down, I find this book to be information dense, and a little overwhelming at parts.  The author knows his stuff, and the information is clear and well written, but I wish the book was paced a little slower.

That said the examples used are lots of fun, and the audience will probably enjoy writing and expanding on the included code.

No Starch landed a 10 / 10 on Python For Kids, which set the bar extremely high.  I’m giving Javascript For Kids a 7.5 out of 10.  It’s deserving of the For Kids title, and I eagerly await the next book in the series.

Have a good weekend all!

-Shea

Mar 27

PhoneGap 1.5.0 and iOS 5.1

Hey All,

Just posting here so I remember some fixes I had to do with the new release of PhoneGap 1.5 (also known as Cordova).

When you initially run your new xCode product, you will get a ton of “semantic” issues.  The fix is to go to Build Settings -> Objective-C  Automatic Reference Counting -> “NO”

I found this clarification from a comment posted by Alejandro Orduz at http://phonegap.com/2012/03/06/phonegap-1-5-released/ 

“ok, i manage to make it work, Cordova, under Xcode 4.3.1…. regarding the www stuff…

First of all, getting into this painful process(more of all because of my lack of knowledge of Xcode), i wen to the process to upgrade my iPhone to the latest iOS 5.1, then had to upgrade Xcode to 4.3.1 to support testing in this device, but also did an upgrade to the latest lion 10.7.3…. so it was a boring weekend of upgrading….

The first time you run a new phone gap project under Cordova, is not like old days, now when you run you get a scary 9 errors warnings about a Semantic Issue in some, NSAutoreleasePool well, for some of us, that is like speaking chinease… but it can be solved very easy… the new Xcode has some Automatic Reference Counting ON by default, so you just go to the project Build Settings, find Objective-C  Automatic Reference Counting and change it to “NO”, after that everything goes to normal…. then it can build, add the www, you get the normal iPhone simulator error, and then, like before, had to drag and drop the www folder into the project root….

Changes like this are very scary for people like me, that found phonegap an amazing tool to build mobile apps with our web development knowledge…. :-{  ”

Also! I finally got the camera example working.  I was receiving a weird “wait_fences: failed to receive reply: 10004003” when I used the Camera example code verbatim.  It would work, but I would only recieve a small blue box on my iPhone.

The issue is that the code on line 40:

smallImage.src = “data:image/jpeg;base64,” + imageData;

is wrong.  PhoneGap 1.5 / iOS 5 stores the taken photo in a temporary directory, so you dont get the base64 data anymore, you have the actual URI for the photo in imageData.  All you need to do is change line 40 to be:

smallImage.src =  imageData;

and it will work.

 

I hope this helps out some people.  It’s working for me, YMMV.

-Shea