Shiftout "The bits that are shifted out are always the low order bits regardless...


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2005
    Location
    Palmdale, CA
    Posts
    37

    Default Shiftout "The bits that are shifted out are always the low order bits regardless...

    In the PBP3 manual description of the shiftout command, it says "The bits shifted out are always the low order bits, regardless of the mode used, LSB or MSB". What does this mean?
    If I do not use the /XX option for bits and therefore shift out 8 bits (default) selecting MSB first, are my bits shifted out MSB first? Or the lowest order bits shifted out forst (LSB)?

  2. #2
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default Re: Shiftout "The bits that are shifted out are always the low order bits regardless

    The bits are always shifted out according to the MODE (MSBFIRST or LSBFIRST).

    What that statement is saying, is that when using the \Bits modifier ... only the low order bits are sent.
    If you have 8-bits in a BYTE and use \5, only bits 0-4 are sent.
    Those 5 bits can go out MSBFIRST or LSBFIRST according to the mode.

    Some people would think that if using MSBFIRST ... bits 3-7 would be sent since they are the MSb's ... but that is not the case.
    DT

  3. #3
    Join Date
    Jul 2005
    Location
    Palmdale, CA
    Posts
    37


    Did you find this post helpful? Yes | No

    Default Re: Shiftout "The bits that are shifted out are always the low order bits regardless

    Thanks. That makes perfect sense when phrased that way.

Similar Threads

  1. save and load "bits" in eeprom...
    By martintorres in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 22nd September 2012, 19:28
  2. How to Correctly define Shiftout bits
    By BrianS in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 19th May 2011, 13:09
  3. DT_INTS-14 /interrupts enable bits / flag bits
    By bogdan in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 16th May 2009, 18:42
  4. Count Bits, Choose High or Low?
    By kevj in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 2nd January 2009, 19:17
  5. Replies: 3
    Last Post: - 13th August 2006, 05:16

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts