Monday, October 8, 2012

Source Code - Installment One

Edit 15-Oct-2012: Posted corrected code - missed a few typos. GpioPoller.c is now the multiplexed version. Edit to make HTML behave nicely.

I have been looking at this source code issue from the wrong perspective. I knew that I would be posting my source code here eventually, but I didn't think that it would be useful to that many people. That was when tunnel vision had me thinking of just this alarm system project.

The example code that I present here is really much more widely applicable. This is my main function, which implements a daemon process in C. Also included are my data structures and my method for using worker threads. Copious comments have been added to help clarify things.

Just wondering if you have updated the RPiHouse code since this last post.. Its been a while so I thought I would ask. I'm planning on using it for my garage/shop. Its overkill for what I need the the framework is there so that makes it easy for me ;-)

It's been over two years. I'm sure I have made many changes to the software in that time. However, it would all be things that likely wouldn't matter to you - things specific to my setup.Good luck with your project.

The Raspberry Pi Board

The Raspberry Pi is a credit card sized single-board computer developed in the UK by the Raspberry Pi Foundation and based on the Broadcom BCM2835 system on a chip. This US$35 board is intended to stimulate the teaching of basic computer science in schools. It's also a great item for hobbyists.

Announcement

Kindly supported by my employer

Follow by Email

About Me

I'm a long time electronics hobbyist with a great interest in the Arduino microcontroller and the Raspberry Pi single board computer. Both are great for teaching kids about electronics and computers, which is my other great hobby.
These blogs will be used to document and share my projects for students and fellow hobbyists.