Shop OBEX P1 Docs P2 Docs Learn Events
Is this possible ? — Parallax Forums

Is this possible ?

nestor73nestor73 Posts: 33
edited 2011-06-11 00:22 in Propeller 1
Hi All,

i'm fairly new to the propeller, i have chosen it because of the nice VGA output that i need
for a project. I tried the arduino but it was rather messy to get it working.

Now i have to add two timers to the vga screen, they need to fill half of the screen (one
above and one beneath) but my question is , can i change the font or how can i make my own ? I can't
even manage to get another screen resolution then 640x480 (aldo the setting is 512x480??) , and so
far i only managed to make some changes to the demo files (C3_VGA_Demo_010) to get anything on
my screen...

I have to say that the Spin language is not that easy ! but after one hour i can't expect much
i guess :-)

thanks in advance !

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2011-06-08 12:40
    There are a number of VGA drivers that either come with the Propeller Tool or can be found in the Propeller Object Exchange. Most of them are intended for text display with lots of text on the screen and changing the font size is not simple. The best way to do what you want is to use the Graphics driver that's included with the Propeller Tool. This uses a vector-based font and you can specify a scale factor. The main disadvantage is that the characters are drawn on top of whatever is already in the graphics buffer, so you have to explicitly clear the area under what you want to write. Look at the demo program included for examples.
  • nestor73nestor73 Posts: 33
    edited 2011-06-08 13:15
    Thanks allot Mike, i'm going to look into this. Too bad this graphics demo works with TV and not VGA; I don't really get the conversion :(
  • Mike GreenMike Green Posts: 23,101
    edited 2011-06-08 14:14
    The graphics demo comes configured for TV use, but also works with the VGA.spin driver for VGA. For plotting points and drawing text, this is another VGA bitmap driver that you can use.
  • nestor73nestor73 Posts: 33
    edited 2011-06-08 15:04
    Yes Mike,

    i was already trying to get that one working, but i must be doing something wrong. I have the C3 board but i don't get a picture on my vga screen. i'm trying
    to figure out where i'm going wrong
  • Mike GreenMike Green Posts: 23,101
    edited 2011-06-08 15:24
    There's a buffer on the VGA signals that's enabled by setting I/O pin 15 to high. This is described on page 27 of "Unleashing the Propeller C3". I forgot to mention it, sorry.

    Just add this to your program's initialization:

    outa[ 15 ] := 1
    dira[ 15 ] := 1
  • Duane DegnDuane Degn Posts: 10,588
    edited 2011-06-08 18:13
    I have a VGA monitor that doesn't work with the Propeller. You might want to try a different monitor. (If it still doesn't work with Mike's changes.) I don't think I've tried my problem monitor with the C3 so I don't know if the C3 would have the same problem as a Propeller Proto Board driving some monitors.
  • nestor73nestor73 Posts: 33
    edited 2011-06-09 05:34
    Thanks allot all for this information, i'm going to work on it this evening and i'll let you know if i can get it working ! thx again !
  • nestor73nestor73 Posts: 33
    edited 2011-06-09 10:48
    I got it working perfectly by adding this code :

    DIRA[15] := 1
    OUTA[15] := 0

    Thanks folks !!
  • nestor73nestor73 Posts: 33
    edited 2011-06-10 12:43
    I'm here again with a new 'problem'. Because i use a clock with the current time on my
    vga screen, i want to update it every second. Now, which is the most effecient way to
    refresh the screen (or the part where the clock is displayed) because if i don't refresh it
    the text is just put above eachother. If i have to redraw the whole screen, i get allot of
    flickering on the screen. And the more code he has to run into, the worse its getting...:(
  • Mike GreenMike Green Posts: 23,101
    edited 2011-06-10 12:57
    You have a couple of options:

    1) If you have enough memory, you could double buffer the display and draw the digits into the buffer, then copy the buffer to the active display buffer.

    2) Change the color of the foreground to the same as the background, then draw the old time to the display, effectively erasing the digits, then draw the new time. If the old digit is the same as the new digit, skip that digit.
  • nestor73nestor73 Posts: 33
    edited 2011-06-11 00:22
    Thanks Mike,

    that does sound easier said then done for me , haha. I'm going to try and find information about that.

    Next to that - i do get the feeling that all the demo's i see that can do what i want (graphical interface, big fonts etc..) are done trough the PAL output
    and not the VGA. It is possible that i use the composite output instead of the VGA, it doesn't really matter what type of monitor it is, it just needs to
    be seen from a nice distance. What are the downsides of using TV output ? (i think image quality is allot less ?)
Sign In or Register to comment.