Monthly Archives: June 2012

Project Euler 10

I put my old implementation of Project Euler 10 into my new implementation. I’m so glad I wrote in my old journal post about the printf formatting problem I had. It bit me again.

Posted in Uncategorized | Leave a comment

Project Euler 9

I did some lunch time coding to get my old Project Euler 9 solution put into the newer “all in one” program. “Stand alone” solution – http://chrislearnsc.blogspot.com/2011/09/project-euler-9-solution.html Integrated solution – https://github.com/cheydrick/Project-Euler I went over my PE10 implementation, and think I can integrate … Continue reading

Posted in Uncategorized | Leave a comment

How to read serial data from an Arduino in Linux with C: Part 4

Parts one, two, and three dealt with non-canonical reading of serial data coming from an Arduino. Part 4 is how to do it in canonical mode. I programmed the Arduino to wait until it receives a byte from the PC and … Continue reading

Posted in Hobbies, Programming | 9 Comments

Figured it out…

I figured it out. There were basically two subtle errors on my part that threw it into an in-deterministic state. I walked away from it for the afternoon and I picked out what was wrong almost immediately after I looked at it … Continue reading

Posted in Uncategorized | Leave a comment

More info on canonical serial transmission failure

This screenshot illustrates both problems: The first run shows problem 1: read returns 0. It shouldn’t do that in canonical mode…. right? Problem number 2 is that when it DOES return something, it’s gibberish. I modified the program to display … Continue reading

Posted in Uncategorized | Leave a comment

Canonical mode serial reading failure

Man, I just can’t get my head around this one. My Arduino is running a simple call/response program. If you sent it a byte, it will send back “Hello”. The Serial.read() is to pop off the byte in the buffer … Continue reading

Posted in Hobbies, Programming | Leave a comment

Ported fill and stroke Cairo drawing example on Zetcode.com to GTK+3

If you do any searching for Cairo or GTK+ tutorials, you’ll eventually wind up on zetcode.com. I’d be content with only a fraction of this guy’s talent for explaining difficult subject matters with such brevity and clarity. It’s not coincidence … Continue reading

Posted in Hobbies, Programming | Leave a comment