Shop OBEX P1 Docs P2 Docs Learn Events
another SHIFTOUT question — Parallax Forums

another SHIFTOUT question

ArchiverArchiver Posts: 46,084
edited 2003-12-17 23:32 in General Discussion
John Williams,

Is there any thought on making/updating the "shiftout"
function so that it shifts on an external clock?

Thanks
-Beau Schwabe

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2003-12-17 22:22
    Beahu:

    Are you suggesting the Stamp become a slave device? If yes, what data
    does the Stamp SHIFTOUT? What data type (how many bits)? When does the
    Stamp know when to quit and move to the next instruction?

    Of course I'm playing the devil's advocate -- it could be done in a
    future product but not without significant thought. How do you envision
    using such a feature?

    -- Jon Williams
    -- Applications Engineer, Parallax
    -- Dallas Office


    Original Message
    From: Beau Schwabe [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=ky10oMHtGuf5d2y-IGgC-qhS57zOgRSbWkohu-93Se5OrXWcJ-kHamOgBd0qoRikgbyxshMNnGVuVkqMKKM]bschwabe@a...[/url
    Sent: Wednesday, December 17, 2003 2:52 PM
    To: basicstamps@yahoogroups.com
    Subject: [noparse][[/noparse]basicstamps] another SHIFTOUT question


    John Williams,

    Is there any thought on making/updating the "shiftout"
    function so that it shifts on an external clock?

    Thanks
    -Beau Schwabe







    To UNSUBSCRIBE, just send mail to:
    basicstamps-unsubscribe@yahoogroups.com
    from the same email address that you subscribed. Text in the Subject
    and Body of the message will be ignored.


    Yahoo! Groups Links

    To visit your group on the web, go to:
    http://groups.yahoo.com/group/basicstamps/

    To unsubscribe from this group, send an email to:
    basicstamps-unsubscribe@yahoogroups.com

    Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/




    This message has been scanned by WebShield. Please report SPAM to
    abuse@p....
  • ArchiverArchiver Posts: 46,084
    edited 2003-12-17 23:32
    Jon Williams,
    Yes, the stamp would/could become a slave device with
    an inherent flow control. This is exactly what I had
    in mind. The command structure would be identical to
    the current command with the exception of a 'software
    mode switch' where you could specify the clock direction.
    (perhaps where MSB/LSB is specified). Of course you would
    need an optional 'timeout' built-in if it did not receive
    a clock within a reasonable amount of time.

    I have used this method more in PIC applications where
    RS232 was not reliable due to either varying clock speed
    applications or unreliable RC time bases due to temperature
    drift etc. On several occasions over the years I have
    come across applications where having this feature would
    have been very useful.


    example 1:
    SHIFTOUT Dpin, Cpin, Mode, [noparse][[/noparse]Variable{\Bits}{,Variable{\Bits}...}]

    Dpin - Same / 0-15
    Cpin - Same / 0-15
    Mode - Expanded / 0-1

    * Bit0 = msb/lsb first
    Bit1 = not used ; possible place holder for SHIFTIN
    compatibility in example below.
    Bit2 = Cpin direction internal/external
    Bit3 = enable/dissable timeout

    * = existing 1 Bit mode definition

    Variable - Same / valid Stamp variable
    Bits - Same / 1-16



    example 2:
    SHIFTIN Dpin, Cpin, Mode, [noparse][[/noparse]Variable{\Bits}{,Variable{\Bits}...}]

    Dpin - Same / 0-15
    Cpin - Same / 0-15
    Mode - Expanded / 0-3

    * Bit0 = msb/lsb first
    * Bit1 = data valid before/after clock pulse
    Bit2 = Cpin direction internal/external
    Bit3 = enable/dissable timeout

    * = existing 2 Bit mode definition

    Variable - Same / Byte or Word variable
    Bits - Same / 1-16



    Thanks!
    -Beau Schwabe


    >Beahu:
    >
    >Are you suggesting the Stamp become a slave device? If yes, what data
    >does the Stamp SHIFTOUT? What data type (how many bits)? When does the
    >Stamp know when to quit and move to the next instruction?
    >
    >Of course I'm playing the devil's advocate -- it could be done in a
    >future product but not without significant thought. How do you envision
    >using such a feature?
    >
    >-- Jon Williams
    >-- Applications Engineer, Parallax
    >-- Dallas Office
    >
    >
    >
    Original Message
    >From: Beau Schwabe [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=HmWMJdzUJgBZx0eOm4hd_Oof2fwIoA5P6oCMlz5PuFXexOwGU7szvvjIBocWuZG6Wnt77n2yb0bjhyVaMctiaNxd]bschwabe@a...[/url
    >Sent: Wednesday, December 17, 2003 2:52 PM
    >To: basicstamps@yahoogroups.com
    >Subject: [noparse][[/noparse]basicstamps] another SHIFTOUT question
    >
    >
    >John Williams,
    >
    > Is there any thought on making/updating the "shiftout"
    > function so that it shifts on an external clock?
    >
    >Thanks
    >-Beau Schwabe
Sign In or Register to comment.