[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Linked lists.

From: E. Weddington
Subject: Re: [avr-gcc-list] Linked lists.
Date: Mon, 09 Dec 2002 11:13:23 -0700

On 9 Dec 2002 at 16:57, Daniel Williamson wrote:

> Hi,
> I'm implementing a linked list of structures as part of a
> re-configurable state machine.  I can declare a pointer to the
> structures and it works fine. However If I increment the pointer as in
> pointer++; Then I start going off track.  I was rather hoping that
> incrementing the pointer in this way would jump to the next defined
> structure in my list.
> Maybe I've missed something glaringly obvious.



And download the pdf on the page


Barring that, here's a google search:

> Anyway does anyone have any thoughts, and also can anyone think of a
> better way to do a state machine. In the past I've used switch and
> case,  and also pointers to functions with each function being a state
> and it setting the next state to call.
> This time I'd like something a little more abstract and configurable
> so that I can change the state machine depending on the mode I'm in.

Also go to 
and search for "state machine" for different techniques to building a 
state machine in an embedded system.

avr-gcc-list at http://avr1.org

reply via email to

[Prev in Thread] Current Thread [Next in Thread]