Worked through the Google App Engine “Getting Started” introduction

April 8th, 2008

I just finished trying out the Google App EngineGetting Started” introduction. I haven’t programmed in Python for a very long time. The introduction was pretty cool.

Except for the problem with Windows in the static file CSS example. I found a discussion about the issue by Googling “App Engine InvalidAppConfigError”. They have a simple work-around to get the sample to work. But it looks like there will have to be fix in the API for the problem to be resolved.

But all in all, this is a pretty neat framework. I look forward to playing with the SDK some more.

(And being a pilot, I am a bit biased toward the App Engine logo. You can see it at the home page. It is a jet engine with wings and a vertical stabilizer. 🙂 )

My first Butterfly program… success!

April 7th, 2008

My first program, Blinky, from the “C Programming for Microcontrollers” book has been downloaded to my Butterfly ATMega169 and works. The program cycles through 8 LEDs, turning one LED on at a time. It looks like the Cylon robots (old school – or the newer Cylon Centurions from the new series) robots. (Or the original KITT from “Knight Rider”.)

I had a problem initially with downloading the “hex” file to the Butterfly. It appeared to be the serial port… ahhhh, serial ports. So, if you get the Butterfly++ Mini-Kit, you get a DB-9 female connector and some wire. The “Butterfly++ Mini-Kit Assembly Instructions”, and the book, instruct that you are to wire the DB-9 connector to certain holes on the Butterfly. The instructions indicate that you cross the transmit and receive lines from the Butterfly to the connector. Okay, all is good… so far.

It is very hard to find a serial cable now: USB rules. But I did find a USB-Serial adapter at Best Buy. One end is a USB connector and the other end is a DB-9 male connector. I installed the driver, for Windows XP, and installed the cable. It installed like a charm as “COM5”. I was able to use the terminal program provided on the CD with the book and use “COM5” and communicate with the built-in Butterfly program to set my name for the “name tag” function of the factory-programmed Butterfly.

But then when I used the provided AVR Studio to try and download the Blinky program to the Butterfly, AVR Studio couldn’t find a suitable device. Hmm. It appeared the AVR Studio provided on the book’s CD wasn’t working with the USB serial device. I even tried upgrading to the latest AVR Studio downloaded from the Atmel site. It still wouldn’t program.

I did have a “real” serial port on my computer, which is a DB-9 male connector. But I couldn’t find a DB-9 M-F connector in my collection of cables. I had null modem DB-9 F-F and DB-9 M-M (null modem cables have the transmit and receive links cross-linked). Then I thought, wait! The Butterfly has a DB-9 female connection and the computer has a DB-9 male connector; just hook them together. The problem is the Butterly DB-9 female connector is connected to the Butterfly with about 2.5 inches of wire. So it took a bunch of rearranging to get the Butterfly close enough to the serial port on the computer, which is in the back of the computer. But I was able to get the Butterfly, the power supply, and the breadboard with the LEDs for the Blinky project close enough. Now, with the Butterfly directly connected to “COM1”, the AVR Studio found the device. I was able to download and program the Blinky.hex file. After successfully downloading to the Butterfly and cycling the power to the Butterfly (and moving the joystick “up”), Blinky started up and blinked the LEDs, sweeping back and forth.

So it appears that I need a DB-9 M-F “straight through” serial cable. (I have seen this type of cable referred to as an “extension” serial cable too. No wonder everyone likes USB better-it just seems to work, but it is more complex at the signal and component level.) I was able to find at Cables for Less a six foot DB-9 male to female cable for $1.89. I ordered it. With shipping the total came to $8.48. Hopefully it will come soon so that I can get the Butterfly out from behind my computer. But at least I have successfully tested the ability to program the Butterfly.

(I think that there is some way to download the hex file using avrdude instead of the AVR Studio. This may allow the USB-Serial adapter cable to work on “COM5”. But I haven’t had a chance to try that yet.)

Butterfly++ WORKS!

April 5th, 2008

AVR ButterflyI had purchased a “Book + Butterfly + Projects Kit” from Smiley Micros some time ago. The AVR Butterfly is a demonstration board for a Atmel AVR ATmega169PV microcontroller. The package that I purchased included, in addition to the Butterfly, a book and some components in the “project kit” to execute the samples from the book. The first thing that you have to do is add a connector it the board so that you can add a serial port connection. The serial port connection is used to download code to the microcontroller. The kit includes some wires and a female DB-9 connector which you get to solder together. I did it (successfully). The kit also includes a battery pack that you get to mod to add an LED as a power indicator and some headers to solder to the Butterfly to make it easier to attach and reconfigure wires to the device.

After performing this preliminary soldering, I followed the test procedures to make sure that it works. I was able to power the Butterfly from the external battery source and download my name via the serial port to the Butterfly. (The Butterfly has a sample program that will display your name on its LCD display.)

Now that the preliminary work is done, I can try the samples from the book… (I am finally putting my EE degree to use!) and maybe write my own code. (Yeah, I do write code, like web applications, for a living. Not usually something as cool as making blinking LEDs!)

Akount “revision 11” released

March 29th, 2008

This update fixes the cookie used to track the type of authentication last used. Akount currently supports username/password and OpenID authentication. When you successfully authenticate, a cookie is used to track the type of authentication used so that the same authentication can be used by default the next time you need to authenticate.

Chumby works as SlimServer (SqueezeCenter) player

March 26th, 2008

I was able to get my Chumby to work as a client for the SlimServer (SqueezeCenter) tonight. My Chumby was updated to client version 1.5.0 this evening. SlimServer client support has been built in to Chumby since at least client version 1.4.0. And before there was a menu interface on Chumby, there were ways that you could make the Chuby work as a SlimServer client with a USB memory device loaded with some software.

The Chumby interface is pretty straight forward. In the main Chumby panel, there is a “Music” button. You select this and are presented with a list of different music sources. If you select the “SlimServer” source, you get a menu that lets you enter the IP address of your SlimServer. After entering the IP address, you can press the “Play” button and then the “Done” button. Momentarily, you should see the Chumby show up as a client in your SlimServer web interface on your computer. You can control the playback of music on the Chumby from the SlimServer web interface via your computer. (You don’t control it from the Chumby. If you have an Asus Eee PC like me, the Eee PC make a really convenient “remote”. Though an iPhone or iPod touch would probably be even cooler; use the built in web browser and wifi as a client of the SlimServer, controlling the playback of the music on your Chumby. 🙂 ) When the music is playing, the Chumby continues to play whatever “channel” you currently have active. For instance, my main channel rotates between a digital clock and a five day weather forecast.

I have the SlimServer running on a Wal-Mart Everex PC. I decided to try SlimServer when I learned that the Chumby could be a SlimServer client. I was quite impressed with the SlimServer. It makes it easy to play my music collection throughout the house. Up until now, though, I have used a laptop as a SlimServer client. But the Chumby as a client amps up the geek factor. 🙂

Akount “revision 10″ released

March 22nd, 2008

I released “revision 10” of my personal finance web application moments ago. This release provides a visible indication if a transaction is a future transaction. Future transactions have a gray background and are in italics. I also added a confirm dialog before deleting a transaction. (I accidentally deleted a transaction the other day. This wasn’t a problem before, but with the recent feature enhancement to allow transaction to be duplicated, there is now a link to duplicate a transaction right next to the link to delete a transaction. I accidentally clicked the delete instead of the duplicate link. Oops. This is now fixed.)

Akount “revision 8″ released

March 22nd, 2008

“Revision 8” of my personal finance application “akount” has been released.

This new release includes enhancements to the login process. The login process has for a while supported username and password authentication or OpenID authentication. The login form showed both forms for username/password authentication and OpenID authentication. Now, only one or the other forms is shown and you can toggle between the two forms. Once you successfully authenticate, a cookie is set to remember the type of authentication that you used. Then, the next time you access the application and have to log in, the form displayed will be the one that you last used.

The code was also cleaned up a bit, consolidating the username/password and OpenID authentication into one PHP controller. (I have tried to use a model-view-controller (MVC) pattern in developing akount.)

Akount “revision 7″ released

March 16th, 2008

“Revision 7” of akount has been released. (Productive evening–6 and 7 in one night.) In this update, transactions in the account transactions view can now be duplicated (copied). There is a “Duplicate” link that will open the “add transaction” view with the “Date” set to the current date and the “Description”, “Amount”, “Tag”, and “Transfer” duplicated from the original transaction. This feature will hopefully be helpful for entering recurring transactions that happen each month.

Akount “revision 6” released

March 16th, 2008

I just released “revision 6” of akount, my personal financial management web application that is in “limited beta”. (Okay, very limited beta. I am the only user. 🙂 )

This release added support for a user to configure how many “items per page” are displayed on the account transaction pages. Prior to this, the number of transactions shown per page was 10. Now a user can choose between 1 and 99 items per page in the “My Info” page available from the account summary page.

Project: virtlcd 1.0.0 released

March 10th, 2008

virtlcd logoVersion 1.0.0 of virtlcd has been released. This is the first virson of the Java Swing API. The components provide a virtual LCD display for use within a Swing app. A sample swing application which illustrates how to use the API. (The logo itself, “virtlcd”, there in the upper right, is an example of the display.)