HSEROUT full 3 digit display of variable howto ?


Closed Thread
Results 1 to 4 of 4
  1. #1

    Default HSEROUT full 3 digit display of variable howto ?

    Hi PBPers

    I have a HSEROUT problem

    I have 2 AD converters where a want to sent the result to the serial port
    Which is working fine

    HSEROUT [DEC AD0," ",DEC AD1] or HSEROUT [#AD0," ",#AD1]

    As the software which receives the value's always expect 7 characters
    I'm having problems when the AD's value is less than 100, because
    then it sends "52 128" instead of "052 128"
    ofcourse the same with "0 0" instead of "000 000"

    anyone an idea how to solve this ?

    Thanks

  2. #2
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Read farther into the DEC modifiers in the book. You might find a little modifier of the modifier that'll give you those extra digits when the value doesn't give you enough digits.

  3. #3
    Join Date
    Aug 2006
    Location
    Omaha, Nebraska USA
    Posts
    263


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by RFsolution View Post

    As the software which receives the value's always expect 7 characters
    I'm having problems when the AD's value is less than 100, because
    then it sends "52 128" instead of "052 128"
    ofcourse the same with "0 0" instead of "000 000"

    anyone an idea how to solve this ?
    I think you can find the information you need for a solution 3 or 4 pages into SEROUT2. I had to highlight the forward reference under HSEROUT to remember it. (Sometimes the PBP manual isn't as "friendly" as it could be . . . )
    Russ
    N0EVC, xWB6ONT, xWN6ONT

    "Easy to use" is easy to say.

  4. #4


    Did you find this post helpful? Yes | No

    Default

    DEC3 is the answer

    Thanks to all !

    Topic closed !

Similar Threads

  1. Hdsp 21xx display
    By Original in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 7th June 2012, 20:07
  2. Single digit 7 Seg LED clock - PIC16F88
    By thirsty in forum Code Examples
    Replies: 4
    Last Post: - 17th July 2009, 08:42
  3. Replies: 14
    Last Post: - 26th September 2007, 05:41
  4. Controlling an 240x128 LCD Touchpanel Display
    By Vincent in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 7th June 2006, 23:36
  5. 7 segment digit problem (using Mister E's code)
    By jmgelba in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 9th September 2005, 20:25

Members who have read this thread : 0

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