[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [N8VEM-S100:6544] Re: Propeller console IO board

Hi Harold,

Well, in this instance.... I follow it to state 2, where the program then recognizes the digit 1, 4 or 5 as the first argument (a0).
It stays in state 2 unless a semicolon leads us to fetch the second argument.  If the next character is neither another digit, nor the semicolon, it falls through in state 2 to execute "ansi(c).... so now lets look at ansi(c)....
Ahh, there in the ansi subroutine... I see for "m" ...

    if a1 <> -1

So, it calls the "SetInv" routine....   there... if the arg is 1, it executes text.setinv(1)  else it executes text.setinv(0)

So, let's see what the "SetInv" routine does in the VGA_1024 module.... oh, btw, this is very poor programming practice to name a local subroutine with the same name as in another module... that makes it very confusing imho.

Ok, so the next routine does this...
    inverse := c

So.... how's inverse used??  let's search for that.

putc(pos, c)
    if inverse
        c |= $80
    screen[pos] := c

There! it's used in the putc routine.  if inverse is not zero, then the character is OR'd with 80, to set the msb.

So,  it would appear that esc[1m only inverts the video, the other esc[4m and esc[5m undo the invert video.

Before we can code these features, "BOLD", "UNDERLINE" and "BLINKING", we will need to figure out if the video generator can produce these effects.  I'm taking a look at the VGA_HRes_Text.spin file... that's the program that creates the video...  it's written in assembler, which makes sense, because C is not powerful enough to do the job.  Sorry if that offends any C programmers, but the fact is, some jobs can only be done in assembler, especially when speed and timing are critical.  At this point in the game, I'm stuck because I don't know the propeller chip or the instruction set.  But it would definitely be something I'd like to learn some day.


Date: Sun, 15 Mar 2015 13:47:57 -0700
From: n8vem...@googlegroups.com
To: n8vem...@googlegroups.com
Subject: [N8VEM-S100:6544] Re: Propeller console IO board

Thanks Josh,

I made up a simple MBASIC routine to evaluate some of the VT100 codes.  For example to print a character in BOLD you issue the command ESC[1m. In BASIC this is
PRINT CHR$(27);"[";"1";"m"; : PRINT "BOLD"

When I try this I don't get a bold character but reverse video!  I am basing this result on the fact that I can run a terminal program also, so I have two screen outputs to look at. My terminal program is TeraTerm set to VT100.  Also I looked online for the VT100 codes. The codes that I am trying to get are:
ESC[1m   bold
ESC[4m   underline
ESC[5m   blinking

I can actually follow the state sequence in VT100_Emulator-2.spin, but I get lost after state 4 and can't find where the final character "m" leads to.

Any help would be great


On Friday, March 13, 2015 at 11:07:38 AM UTC-4, hl...@aol.com wrote:
Hi all,

Just finished the propeller console IO board and I have it running with the 8080A CPU board with Josh's rev 2.4 ROM. I downloaded the firmware to run the screen and keyboard as a VT100 terminal. That works pretty well but some of the ESC codes for screen control don't work. Has anyone done any more programming through Parallax on the .spin programs?

Just curious.


You received this message because you are subscribed to the Google Groups "N8VEM-S100" group.
To unsubscribe from this group and stop receiving emails from it, send an email to n8vem-s100+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.