PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Bascom Verständninsproblem



ReVenGer
25.08.2007, 15:46
Hi zusammen,
habe nen kleines Programm in Bascom geschrieben und hätte dazu mal zwei Fragen.


$regfile = "m163def.dat" ' specify the used micro
$crystal = 1000000 ' used crystal frequency
$baud = 19200 ' use baud rate
$hwstack = 32 ' default use 32 for the hardware stack
$swstack = 10 ' default use 10 for the SW stack
$framesize = 40 ' default use 40 for the frame space

Config Portd = Input
$lib "glcdKS108.lbx"
$include "font8x8.font"


Config Graphlcd = 128 * 64sed , Dataport = Porta , Controlport = Portc , Ce = 1 , Ce2 = 2 , Cd = 5 , Rd = 4 , Reset = 0 , Enable = 3


Cls
Setfont Font8x8
Showpic 0 , 0 , Intro
Lcdat 8 , 1 , "<<<"
Lcdat 8 , 107 , ">>>"
Lcdat 8 , 48 , "Enter"
Do
Debounce Pind.0 , 0 , Intense , Sub
Debounce Pind.1 , 0 , Intense , Sub
Debounce Pind.2 , 0 , Intense , Sub
Loop
End

Intense:
Cls
Lcdat 1 , 18 , "Config Menue"
Lcdat 3 , 28 , "-Intense-"
Lcdat 8 , 1 , "<<<"
Lcdat 8 , 107 , ">>>"
Lcdat 8 , 48 , "Enter"
Return



Intro:
$bgf "intro.bgf"

1. Wenn ich in der DO/LOOP Schleife ne Subroutine aufrufe, und diese mit Return beende, geht er dann wieder in die DO/LOOP Schleife?

2. Wie kann ich einen LCD Statusbalken mit Prozent Anzeige realisieren? Bereich Invertieren? Oder doch besser ascii char?

Besten Dank im voraus.


Gruß
RVG

PicNick
25.08.2007, 16:37
Ad 1) jupp
Ad 2) inverses Leerzeichen sieht recht gut aus

BASTIUniversal
26.08.2007, 09:12
Hi!
Ich habe deinen Thread ins Bascom Forum verschoben.

MfG
Basti