LCDout $FE,2, dec Days - What is dec ?


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    May 2009
    Posts
    5

    Default LCDout $FE,2, dec Days - What is dec ?

    I am trying to implement Darryl Taylors interrupt driven timer code.

    http://www.picbasic.co.uk/forum/showthread.php?t=190

    I have changed the code so it counts the time in milliseconds between 2 inputs instead of days/hours/mins/secs - also the corrosponding lines as well.

    LCD output lines....

    Original code
    LCDout $FE,2, dec Days,"d-",dec2 Hours,":",dec2 Minutes,":",dec2 Seconds

    Myline
    LCDout $FE,2, dec Ticks," ms"

    Ticks now counts 1000/second up to 5000 max - 5secs

    The problem I have is with the LCD output. If Ticks value is say 1100, then LCD will only show '11 ms' zeros are always missing. An ouput from other values, for example, 2875 reads fine, ie '2875 ms'

    I have tried dec2, dec3, dec4 etc but I'm not 100% sure what dec means and why the zeros are not displayed. There is probably a very simple solution - I hope

    Cheers
    Adam

  2. #2
    Join Date
    May 2009
    Posts
    5


    Did you find this post helpful? Yes | No

    Default

    Well I just used the normal # command for the LCDOUT and that works, still not sure about DEC though, can't find a reference to it anywhere ?

    LCDout $FE,$C0, "Rider Time :",#Ticks,"ms"

    Cheers
    Adam

  3. #3
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by merc07 View Post
    still not sure about DEC though, can't find a reference to it anywhere ?
    Have you tried looking in the manual under LCDOUT or under SERIN2 or SEROUT2?
    Dave
    Always wear safety glasses while programming.

Similar Threads

  1. Timer + rc5
    By naga in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 19th November 2009, 08:56
  2. PBPL 2.50 observations
    By BrianT in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 18th September 2007, 00:58
  3. Help GPS read with serin
    By leinske in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 5th September 2007, 03:33
  4. Crystalfontz LCD
    By jman12 in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 9th February 2007, 16:04
  5. having problems with Hantronix 20x4 lcd
    By Rhatidbwoy in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 22nd December 2005, 13:22

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