So far I'm using the Parallax TV driver by Chip Gracey that uses the Propeller ROM fonts because those appear slightly larger than the other default TV drivers.
I did a TV driver that mixes really big numbers with ROM font via a set of 8x8 user defined characters, which I posted to the forums some time ago but I didn't bother putting it in the obex because of the collective yawn.
Roger: I'm already using your program. It works great for larger numbers and has a lot of good applications for numbers, especially on the smaller TVs. But I need big text too.
Rayman: Thanks for that idea, I'll give the graphics program a try for large characters.
TV_text can produce huge characters. You just need to specify the number of rows and columns, and it will scale the characters accordingly to fill the screen.
Kye's implementation of the BMP4TXTEngine.spin works well, albeit slow.
I think I can trick it with buffering and get the result I need, I don't think I have
the chops (in pasm) for the assembler mods to Chip's (rather undocumented) base code yet.
It is pretty, even when scaled 4X.
I'm using it for a CNC VGA display from a PC serial port,
used for a remote display of CNC coordinates in manual mode.
I guess what we really need to know is how big is "Really BIG" letters and numbers?
I know that a couple of Doug's text drivers support nice 40 column and 20 column characters.
(20 column would likely be visible on the screen that you are using. Naturally, there is a trade off. )
TV_text can produce huge characters. You just need to specify the number of rows and columns, and it will scale the characters accordingly to fill the screen. -Phil
Thanks for the idea Phil. However, no matter what value is used for cols or rows, the resulting screen characters are not scaled. Can this program actually scale the ROM fonts up or down?
''***************************************
''* TV Text 40x13 v1.0 *
''* Author: Chip Gracey *
''* Copyright (c) 2006 Parallax, Inc. *
''* See end of file for terms of use. *
''***************************************
CON
cols = 40
rows = 13
screensize = cols * rows
lastrow = screensize - cols
tv_count = 14
I guess what we really need to know is how big is "Really BIG" letters and numbers? I know that a couple of Doug's text drivers support nice 40 column and 20 column characters. (20 column would likely be visible on the screen that you are using. Naturally, there is a trade off. ) OBC
Thanks OBC, since 40 x 13 is way too small for lower case letters (a single character will blur on the screen) and caps are the minimum size, I would be interested in trying 20 characters to a line. Do you have a link to one of Doug's screen objects that may scale for my app (if yes, need link)?
Take a look at the monitor firmware for the Prop Backpack for an example of how to make the characters bigger. The ROM font is scaled, but not smoothly. Individual pixels turn into 2x2 blocks, 3x3 blocks, etc. But the text is still quite readable.
Thanks OBC, since 40 x 13 is way too small for lower case letters (a single character will blur on the screen) and caps are the minimum size, I would be interested in trying 20 characters to a line. Do you have a link to one of Doug's screen objects that may scale for my app (if yes, need link)?
Retrotext should do what you need. We've been using it for gaming, but IIRC there is 20 characters per line.
Thanks for the idea Phil. However, no matter what value is used for cols or rows, the resulting screen characters are not scaled. Can this program actually scale the ROM fonts up or down?
''***************************************
''* TV Text 40x13 v1.0 *
''* Author: Chip Gracey *
''* Copyright (c) 2006 Parallax, Inc. *
''* See end of file for terms of use. *
''***************************************
CON
cols = 40
rows = 13
screensize = cols * rows
lastrow = screensize - cols
tv_count = 14
You can scale the pixels with the 2 parametrs hx and vx in the DAT section (tv_params). Make theme 2 times higher and half the cols and rows tiles.
"1 to 4 Color Flexible VGA Bitmap Driver Terminal"
buried in the obex.
like I said, slow but pretty.
I might have bonked the whole thing but it's working.
colors are a bit limited in depth, but I'm hoping for
B&W so I'm easy.
If you don't want smaller characters in the mix, you can get TV_TEXT to display 4 lines of 20 to 30 characters pretty easily, but it requires manipulating vx and hx in the constants and staying in certain constraints. I've done it for several projects, and if humanoido is interested in doing it this way I can post specifics once I get back to work and grab a few files.
With TV, you can basically get 12, 6, 4, or 2 lines. You've got a bit more leeway on horizontal expansion and I've done 20 to 28 characters with more or less being possible. The VGA driver has the same hx and vx parameters but is much more limited because of timing and line count restraints; you can basically have 13 or 7 rows, take your pick. You can get finer grained horizontal characters but it requires modding the pixel clock which is nontrivial.
Graphics.spin wil produce really BIG characters, you just need to know how to adjust the parameters.
I use 8bit Color graphics because the memory is linear but the standard Graphics.spin should produce similar results.
This gives 16 chars by 6 lines
128 dots x 96 rows
CON
x_tiles = 8
y_tiles = 6
.
.
.
VAR
long tv_status '0/1/2 = off/invisible/visible read-only
long tv_enable '0/? = off/on write-only
long tv_pins '%pppmmmm = pin group, pin group mode write-only
long tv_mode '%ccip = chroma,interlace,ntsc/pal write-only
long tv_screen 'pointer to screen write-only
long tv_color 'pointer to porch color write-only
long tv_ht 'horizontal tiles write-only
long tv_vt 'vertical tiles write-only
long tv_hx 'horizontal tile expansion write-only
long tv_vx 'vertical tile expansion write-only
long tv_ho 'horizontal offset write-only
long tv_vo 'vertical offset write-only
long tv_broadcast 'broadcast frequency (Hz) write-only
long tv_auralcog 'aural fm cog write-only
byte edgecolor
word line_base[96]
.
.
OBJ
tv : "8bc_TV"
gr : "8bc_Graphics"
PUB
.
.
.
BlankBuffers
gr.start
edgecolor := $02
gr.setup(x_tiles, y_tiles, 64, 48, bitmap_base, @line_base)
tv_enable := 1
tv_pins := %001_0101 ' for demo board, pin 12
tv_mode := 0
tv_screen := display_base
tv_color := @edgecolor
tv_ht := x_tiles
tv_vt := y_tiles
tv_hx := 20 '<<<<<<<<<<<< these are the tricky
tv_vx := 2 ' <<<<<<<<<<<< ones to adjust
tv.start(@tv_status)
.
.
gr.text(0,0,string("Hello")) ' place text in middle of screen
If you don't want smaller characters in the mix, you can get TV_TEXT to display 4 lines of 20 to 30 characters pretty easily, but it requires manipulating vx and hx in the constants and staying in certain constraints. I've done it for several projects, and if humanoido is interested in doing it this way I can post specifics once I get back to work and grab a few files.
Roger, thanks! This sounds like a good path to take. 4 or 6 lines of 20 characters to a line could be perfect.
Graphics.spin wil produce really BIG characters, you just need to know how to adjust the parameters.
I use 8bit Color graphics because the memory is linear but the standard Graphics.spin should produce similar results. This gives 16 chars by 6 lines..
Thanks Perry. I look forward to trying this tonight!
Humanoido,
"1 to 4 Color Flexible VGA Bitmap Driver Terminal"
buried in the obex.
like I said, slow but pretty.
I might have bonked the whole thing but it's working.
colors are a bit limited in depth, but I'm hoping for
B&W so I'm easy.
jack
It sounds very interesting but I need a TV driver instead of VGA. Can you convert it?
You can scale the pixels with the 2 parametrs hx and vx in the DAT section (tv_params). Make theme 2 times higher and half the cols and rows tiles. Andy
Andy, thanks much! This is the info I need to know. I'll try this asap.
OBC, thank you very much but you had better change the name from Retrotext to NanoText. It's just about the smallest fly speck I've ever seen on this 3.5-inch display. I must add, however, this is a very clear and stable driver, quite remarkable, and even the text although very tiny, is somehow tac-clear, you can read it (no smearing of characters). Well, it's a job well accomplished! Thanks for sharing! But I still need characters 4x larger.
You can scale the pixels with the 2 parametrs hx and vx in the DAT section (tv_params). Make theme 2 times higher and half the cols and rows tiles. Andy
Andy, so 2 and 2? I tried it and kept the first line in the demo, but it just flashes a screen with no characters.. what is missing?
Perry, I don't know where the old code should end and the new code should begin or which code to run as a demo. Can you just paste it into the code and post a new folder of files? If it works, it will be a miracle. I worked most of the night on this but no luck so far.
Perry, I don't know where the old code should end and the new code should begin or which code to run as a demo. Can you just paste it into the code and post a new folder of files? If it works, it will be a miracle. I worked most of the night on this but no luck so far.
This code works with standard graphics.spin and tv.spin
"Hello World" is in center of screen
also attached is BIGterminal (21 columns by 7 lines)
CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
_stack = ($3000 + $3000 + 100) >> 2 'accomodate display memory and stack
x_tiles = 8 ' 16
y_tiles = 6 ' 12
paramcount = 14
bitmap_base = $2000
display_base = $5000
lines = 5
thickness = 2
basepin = 12
VAR
long mousex, mousey
long tv_status '0/1/2 = off/visible/invisible read-only
long tv_enable '0/? = off/on write-only
long tv_pins '%ppmmm = pins write-only
long tv_mode '%ccinp = chroma,interlace,ntsc/pal,swap write-only
long tv_screen 'pointer to screen (words) write-only
long tv_colors 'pointer to colors (longs) write-only
long tv_hc 'horizontal cells write-only
long tv_vc 'vertical cells write-only
long tv_hx 'horizontal cell expansion write-only
long tv_vx 'vertical cell expansion write-only
long tv_ho 'horizontal offset write-only
long tv_vo 'vertical offset write-only
long tv_broadcast 'broadcast frequency (Hz) write-only
long tv_auralcog 'aural fm cog write-only
word screen[x_tiles * y_tiles]
long colors[64]
OBJ
tv : "tv"
gr : "graphics"
PUB start | i, j, k, kk, dx, dy
'start tv
longmove(@tv_status, @tvparams, paramcount)
tv_screen := @screen
tv_colors := @colors
tv_hc := x_tiles
tv_vc := y_tiles
tv_hx := 20 '<<<<<<<<<<<< these are the tricky
tv_vx := 2 ' <<<<<<<<<<<< ones to adjust
tv_pins := (basepin & $38) << 1 | (basepin & 4 == 4) & %0101
tv.start(@tv_status)
'init colors
repeat i from 0 to 64
colors[i] := $00001010 * (i+4) & $F + $2B060C02
'init tile screen
repeat dx from 0 to tv_hc - 1
repeat dy from 0 to tv_vc - 1
screen[dy * tv_hc + dx] := display_base >> 6 + dy + dx * tv_vc + ((dy & $3F) << 10)
'start and setup graphics
gr.start
gr.setup(x_tiles,y_tiles, 64, 48, bitmap_base)
repeat
'clear bitmap
gr.clear
'draw text
gr.textmode(1,1,7,5)
gr.colorwidth(1,0)
gr.text(0,0,string("Hello World"))
'copy bitmap to display
gr.copy(display_base)
DAT
tvparams long 0 'status
long 1 'enable
long %001_0101 'pins
long %0000 'mode
long 0 'screen
long 0 'colors
long x_tiles 'hc
long y_tiles 'vc
long 10 'hx
long 1 'vx
long 0 'ho
long 0 'vo
long 0 'broadcast
long 0 'auralcog
Andy, so 2 and 2? I tried it and kept the first line in the demo, but it just flashes a screen with no characters.. what is missing?
Set cols and rows at begin in the CON section of TV_Text like that:
''***************************************
''* TV Text 40x13 v1.0 *
''* Author: Chip Gracey *
''* Copyright (c) 2006 Parallax, Inc. *
''* See end of file for terms of use. *
''***************************************
CON
cols = 20 '40
rows = 6 '13
screensize = cols * rows
Then set in the DAT section the hx and vx parameters to:
long 8 '4 'hx
long 2 '1 'vx
You have now a TV_Text object with 20x6 characters. You can also try it with 7 rows.
Andy, this worked exceptionally! Thank you.
I adjusted the screen for 16 characters by 10 rows.
This produces the sharpest and most clear characters
I have ever seen on this small screen.
cols = 17 '40
rows = 11 '13
long 8 'hx 4
long 1 'vx 1
Perry, thank you for this great working solution! It scales well and the characters are very interesting.
The sharpness of the characters is nothing like the text driver that Andy talked about. I'm wondering if this is true of most TVs or if it happens only on my small TV. There is a blur line below the characters. Some characters seem like they were "stamped double." Do you know anything about this?
Perry, thank you for this great working solution! It scales well and the characters are very interesting.
The sharpness of the characters is nothing like the text driver that Andy talked about. I'm wondering if this is true of most TVs or if it happens only on my small TV. There is a blur line below the characters. Some characters seem like they were "stamped double." Do you know anything about this?
I suspect it has something to do with interlace. My display is a B/W tv, don't have an LCD. Parallax does not seem to supply that little 3.5 inch any more. Need to know the exact horz/vert pixels.
Comments
OBC
http://forums.parallax.com/showthread.php?113018-Low-Resolution-Graphics-mixed-with-ROM-font-text
Rayman: Thanks for that idea, I'll give the graphics program a try for large characters.
-Phil
I think I can trick it with buffering and get the result I need, I don't think I have
the chops (in pasm) for the assembler mods to Chip's (rather undocumented) base code yet.
It is pretty, even when scaled 4X.
I'm using it for a CNC VGA display from a PC serial port,
used for a remote display of CNC coordinates in manual mode.
jr
I know that a couple of Doug's text drivers support nice 40 column and 20 column characters.
(20 column would likely be visible on the screen that you are using. Naturally, there is a trade off.
OBC
-Phil
Retrotext should do what you need. We've been using it for gaming, but IIRC there is 20 characters per line.
http://www.savagecircuits.com/forums/showthread.php?444-Retrotext-Text-Driver-for-gaming
OBC
You can scale the pixels with the 2 parametrs hx and vx in the DAT section (tv_params). Make theme 2 times higher and half the cols and rows tiles.
Andy
"1 to 4 Color Flexible VGA Bitmap Driver Terminal"
buried in the obex.
like I said, slow but pretty.
I might have bonked the whole thing but it's working.
colors are a bit limited in depth, but I'm hoping for
B&W so I'm easy.
jack
With TV, you can basically get 12, 6, 4, or 2 lines. You've got a bit more leeway on horizontal expansion and I've done 20 to 28 characters with more or less being possible. The VGA driver has the same hx and vx parameters but is much more limited because of timing and line count restraints; you can basically have 13 or 7 rows, take your pick. You can get finer grained horizontal characters but it requires modding the pixel clock which is nontrivial.
I use 8bit Color graphics because the memory is linear but the standard Graphics.spin should produce similar results.
This gives 16 chars by 6 lines
128 dots x 96 rows
This code works with standard graphics.spin and tv.spin
"Hello World" is in center of screen
also attached is BIGterminal (21 columns by 7 lines)
Set cols and rows at begin in the CON section of TV_Text like that:
Then set in the DAT section the hx and vx parameters to: You have now a TV_Text object with 20x6 characters. You can also try it with 7 rows.
Andy
I adjusted the screen for 16 characters by 10 rows.
This produces the sharpest and most clear characters
I have ever seen on this small screen.
The sharpness of the characters is nothing like the text driver that Andy talked about. I'm wondering if this is true of most TVs or if it happens only on my small TV. There is a blur line below the characters. Some characters seem like they were "stamped double." Do you know anything about this?
I suspect it has something to do with interlace. My display is a B/W tv, don't have an LCD. Parallax does not seem to supply that little 3.5 inch any more. Need to know the exact horz/vert pixels.
Try changing near the top of tvBIGterminal.spin