Video Problems !
Hello !
Can some tell me what the problem is with this code?
In The VideDisplay row wen it will start and intitialize objekt, i get a error and it says "Expected "(" "
se marked row..in red
Regards Johan
CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
NewLine = 13
Out = %1
In = %0
'
VAR
Word Value
'
OBJ
VideoDisplay: "Tv_terminal"
PUB Start
VideoDisplay.Start ' in this line i get the Error Msg........ get a error and it says "Expected "(" "
SetScreenToWhiteOnDarkBlue
DirA := In
' Display value as Decimal
Value := 500
VideoDisplay.Dec(Value) 'Display decimal value
'Output on the video monitor :
'500
VideoDisplay.Out(NewLine)
'
'Displays Value as hex
Value := $FF
VideoDisplay.Hex(Value,2) 'Displays a hex value 2 digits
'Output on the video monitor:
'FF
VideoDisplay.Out(NewLine)
'
'Displays Value as Binary
Value := %0001_0001
VideoDisplay.Bin(Value,8) 'Displays a binary using 8 digits
'Outpu on the video display monitor:
'00010001
VideoDisplay.Out(NewLine)
'
WaitCnt(1_000_000_000 + Cnt) 'Kepps output on the screen for 10 seconds.
'
'Monitors Pin A1
Repeat
VideoDisplay.Bin(InA,1)
VideoDisplay.Out(NewLine)
'Output on the video monitor:
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'...
'
PRI SetScreenToWhiteOnDarkblue
VideoDisplay.out(3)
VideoDisplay.out(5)
'
'
Can some tell me what the problem is with this code?
In The VideDisplay row wen it will start and intitialize objekt, i get a error and it says "Expected "(" "
se marked row..in red
Regards Johan
CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
NewLine = 13
Out = %1
In = %0
'
VAR
Word Value
'
OBJ
VideoDisplay: "Tv_terminal"
PUB Start
VideoDisplay.Start ' in this line i get the Error Msg........ get a error and it says "Expected "(" "
SetScreenToWhiteOnDarkBlue
DirA := In
' Display value as Decimal
Value := 500
VideoDisplay.Dec(Value) 'Display decimal value
'Output on the video monitor :
'500
VideoDisplay.Out(NewLine)
'
'Displays Value as hex
Value := $FF
VideoDisplay.Hex(Value,2) 'Displays a hex value 2 digits
'Output on the video monitor:
'FF
VideoDisplay.Out(NewLine)
'
'Displays Value as Binary
Value := %0001_0001
VideoDisplay.Bin(Value,8) 'Displays a binary using 8 digits
'Outpu on the video display monitor:
'00010001
VideoDisplay.Out(NewLine)
'
WaitCnt(1_000_000_000 + Cnt) 'Kepps output on the screen for 10 seconds.
'
'Monitors Pin A1
Repeat
VideoDisplay.Bin(InA,1)
VideoDisplay.Out(NewLine)
'Output on the video monitor:
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'0 or 1 depending on input state at pin A1
'...
'
PRI SetScreenToWhiteOnDarkblue
VideoDisplay.out(3)
VideoDisplay.out(5)
'
'
Comments
JOhan
Johan
Open up the Propeller Library Demo "tv_text_demo.spin" or something like that to see how to use this object.
--Chuck
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
E3 = Thought
http://folding.stanford.edu/·- Donating some CPU/GPU downtime just might lead to a cure for cancer! My team stats.
it works. Thanks. your help is a good way.
Regards Johan