Shop OBEX P1 Docs P2 Docs Learn Events
Shiftin - Shiftout — Parallax Forums

Shiftin - Shiftout

ArchiverArchiver Posts: 46,084
edited 2003-04-25 03:18 in General Discussion
Gentlemen,
I am brand new to the robotics hobby,the basicstamp and might as
well be new to programing as my only programing exposure was RPG and
FORTRAN back in the early seventies.
My first robotic project is an autonomous lawn mower that follows
the edge of previous cut grass in either direction as opposed to the
free roaming units offered commercially.
My edge detection system is a row of 16 lightweight hanging paddels
that operate 16 optical flag switches. The flag switches are
connected to a 16 bit parallel in / serial out (74F676 )shift
register. This will be read into the BS2 as a word and then examined
to determine the edge of the cut grass and then branch to the
necessary steering subroutine. My question is regarding the
shiftin / shiftout commands for the BS2. My reading of the command
reference indicates that this is about the most efficient command
for capuring this type of input and of course uses the fewest pins
on the stamp. I would appreciate any feedback regarding this
approach. Is there a better way?
Thanks,
Dave

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2003-04-25 03:18
    Dave:

    I think you're on the right track. I used shift registers all the time for
    simple IO expansion.

    -- Jon Williams
    -- Parallax


    In a message dated 4/24/2003 8:36:13 PM Central Standard Time, dddaly@x...
    writes:

    > Gentlemen,
    > I am brand new to the robotics hobby,the basicstamp and might as
    > well be new to programing as my only programing exposure was RPG and
    > FORTRAN back in the early seventies.
    > My first robotic project is an autonomous lawn mower that follows
    > the edge of previous cut grass in either direction as opposed to the
    > free roaming units offered commercially.
    > My edge detection system is a row of 16 lightweight hanging paddels
    > that operate 16 optical flag switches. The flag switches are
    > connected to a 16 bit parallel in / serial out (74F676 )shift
    > register. This will be read into the BS2 as a word and then examined
    > to determine the edge of the cut grass and then branch to the
    > necessary steering subroutine. My question is regarding the
    > shiftin / shiftout commands for the BS2. My reading of the command
    > reference indicates that this is about the most efficient command
    > for capuring this type of input and of course uses the fewest pins
    > on the stamp. I would appreciate any feedback regarding this
    > approach. Is there a better way?
    > Thanks,
    > Dave



    [noparse][[/noparse]Non-text portions of this message have been removed]
Sign In or Register to comment.