LCD_Print_INT_formatted.txt for the -074
Warning: if you clip this code into your program, look out for possible html code slipping in.
REM Display an integer as decimal number. REM Places is the number of places to the right of DP to display REM Location is location of the last digit right of decimal point on LCD SUBROUTINE LCD_DP(arg AS INTEGER,places AS INTEGER, location AS INTEGER) LOCAL T1 AS INTEGER, T2 AS INTEGER REM print number from right to left one digit at a time T1 = arg\(10^places) T2 = arg/(10^places) DO LCD_COMMAND(0x80 + location + places) PRINT T1 \ 10 T1 = T1 / 10 places = places - 1 LOOP UNTIL places = 0 LCD_COMMAND(0x80 + location + 1) PRINT "." DO LCD_COMMAND(0x80 + location + places - 1) PRINT T2 \ 10 T2 = T2 / 10 places = places - 1 LOOP UNTIL T2=0 LCD_COMMAND(128 + location + places) IF arg<0 PRINT "-" ELSE PRINT "+" ENDIF END GLOBAL number AS INTEGER REM ***************** main routine ********************* PIPE PRINT LCD number = -1000 DO number = number + 1 LCD_DP(number,3,10) LOOP UNTIL number > 30000