Browse Source

first commit

master
Dashie der otter 1 month ago
commit
79adcab727
Signed by: dashie <rhaamo@leloop.org> GPG Key ID: C2D57B325840B755
11 changed files with 831 additions and 0 deletions
  1. +4
    -0
      .vscode/settings.json
  2. +15
    -0
      README.md
  3. +78
    -0
      VP1.pal
  4. +165
    -0
      VP2.pal
  5. +107
    -0
      VP3.pal
  6. +99
    -0
      VP4.pal
  7. +98
    -0
      VP5.pal
  8. +85
    -0
      VP6.pal
  9. +97
    -0
      VP7.pal
  10. +83
    -0
      VP8.pal
  11. BIN
      Video Controller.pdf

+ 4
- 0
.vscode/settings.json View File

@@ -0,0 +1,4 @@
{
"files.eol": "\r\n",
"editor.wordBasedSuggestions": false
}

+ 15
- 0
README.md View File

@@ -0,0 +1,15 @@
Implementing a Video Controller Using Programmable Array Logic
--------------------------------------------------------------

By Ehud "Udi" Gordon.

Published in "PAL Programmable Array Logic Handbook" Third Ed. By Monolithic Memories.

VP1: DOT GENERATOR
VP2: CHAR/CURS GENERATOR
VP3: SCAN/LINE GENERATOR
VP4: LINES/SCROL GENERATOR
VP5: COMPOSITE VIDEO/BAUD RATE GENERATOR
VP6: UART SHIFT REGISTER AND CONTROL KEY DETECT
VP7: UART CONTROL
VP8: RAM CONTROL

+ 78
- 0
VP1.pal View File

@@ -0,0 +1,78 @@
PAL20X8 PAL DESIGN SPECIFICATION
VP1 BIRKNER/KAMZI/UDI 7/7/81
DOT GENERATOR
MMI SUNNYVALE, CALIFORNIA
CKIN /D0 /D1 /D2 /D3 /D4 /HBLANK /INITS /SCAN3 /LINE4 OSCIN GND
/OC OSCOUT /DTCNT2 /DTCNT1 /DTCNT0 /DOT4 /DOT3 /DOT2 /DOT1 /DOT0
CKOUT VCC


IF (VCC) /CKOUT = /OSCOUT

DOT0 := /HBLANK*/LINE4*/SCAN3*DTCNT2*DTCNT1*DTCNT0*D0 ; LOAD

DOT1 := /HBLANK*/LINE4*/SCAN3*DTCNT2*DTCNT1*DTCNT0*D1 ; LOAD
+ /HBLANK*/LINE4*/SCAN3*/DTCNT2*DOT0 ; SHIFT

DOT2 := /HBLANK*/LINE4*/SCAN3*DTCNT2*DTCNT1*DTCNT0*D2 ; LOAD
+ /HBLANK*/LINE4*/SCAN3*/DTCNT2*DOT1 ; SHIFT

DOT3 := /HBLANK*/LINE4*/SCAN3*DTCNT2*DTCNT1*DTCNT0*D3 ; LOAD
+ /HBLANK*/LINE4*/SCAN3*/DTCNT2*DOT2 ; SHIFT

DOT4 := /HBLANK*/LINE4*/SCAN3*DTCNT2*DTCNT1*DTCNT0*D4 ; LOAD
+ /HBLANK*/LINE4*/SCAN3*/DTCNT2*DOT3 ; SHIFT

DTCNT0 := /INITS*DTCNT0 ; HOLD
+ /INITS*DTCNT0 ; EXTEND
:+: /INITS ; INC

DTCNT1 := /INITS*DTCNT1 ; HOLD
+ /INITS*DTCNT1 ; EXTEND
:+: /INITS*DTCNT0 ; INC

DTCNT2 := /INITS*DTCNT2 ; HOLD
+ /INITS*DTCNT2 ; EXTEND
:+: /INITS*DTCNT0*DTCNT1 ; INC

IF (VCC) /OSCOUT = OSCIN

FUNCTION TABLE

CKIN D4 D3 D2 D1 D0 HBLANK INITS SCAN3 LINE4 OSCIN /OC OSCOUT DTCNT2
DTCNT1 DTCNT0 DOT4 DOT3 DOT2 DOT1 DOT0 CKOUT

; H O
; B I S L O S C
; C L N C I S C K
; K A I A N C / O O
; I DATA IN N T N E I O U DTCNT DOT U
; N D4---D0 K S 3 4 N C T 210 43210 T COMMENTS
-----------------------------------------------------------------
C XXXXX X H X X X L X LLL XXXXX X INITIALIZE DTCNT
C XXXXX X L X X X L X LLH XXXXX X INC DTCNT
C XXXXX X L X X X L X LHL XXXXX X INC DTCNT
C XXXXX X L X X L L H LHH XXXXX H INC DTCNT, OSCILIN = L
C XXXXX X L X X H L L HLL XXXXX L INC DTCNT, OSCILIN = H
C XXXXX X L X X X L X HLH XXXXX X INC DTCNT
C XXXXX X L X X X L X HHL XXXXX X INC DTCNT
C XXXXX X L X X X L X HHH XXXXX X INC DTCNT
C LHLHL L L L L X L X LLL LHLHL X DATA IS LOADED
C XXXXX L L L L X L X LLH HLHLL X OUTPUT TO SCREEN = H
C XXXXX L L L L X L X LHL LHLLL X OUTPUT TO SCREEN = L
C XXXXX L L L L X L X LHH HLLLL X OUTPUT TO SCREEN = H
C XXXXX L L L L X L X HLL LLLLL X OUTPUT TO SCREEN = L
C XXXXX L L L L X L X HLH LLLLL X SEND BLANK TO SCREEN
C XXXXX L L L L X L X HHL LLLLL X SEND BLANK TO SCREEN
C XXXXX L L L L X L X HHH LLLLL X SEND BLANK TO SCREEN
C HLHLH L L L L X L X LLL HLHLH X NEW DATA IS LOADED
C XXXXX L L L L X L X LLH LHLHL X OUTPUT TO SCREEN = L
-----------------------------------------------------------------

DESCRIPTION
THE DOT GENERATOR PROVIDES THE OSCILLATOR/CLOCK DRIVER, THE DOT SHIFT
REGISTER AND THE 3-BIT DOT COUNTER. IT IS LOADED WITH THE 5 DOTS
GENERATED BY THE CHARACTER GENERATOR. THESE DOTS ARE SHIFTED OUT THROUGH
A SHIFT REGISTER, ONE DOT AT A TIME AND DISPLAYED ON THE SCREEN. "DTCNT"
COUNTS UNTIL 8: 5 COUNTS FOR THE CHARACTER AND 3 COUNTS FOR SPACE
BETWEEN CHARACTERS.

+ 165
- 0
VP2.pal View File

@@ -0,0 +1,165 @@
PAL20X10 PAL DESIGN SPECIFICATION
VP2 BIRKNER/KAMZI/UDI 7/9/81
CHAR/CURS GENERATOR
MMI SUNNYVALE, CALIFORNIA
CK /DTCNT0 /DTCNT1 /DTCNT2 /INITS /SWAPC /CHAR0 /CURS0 /BS /WRITE /INCSCR GND
/OC /CURS1 /CHAR1 /CURS2 /CHAR2 /CURS3 /CHAR3 /CURS4 /CHAR4 /CURS5 /CHAR5 VCC

CHAR1 := SWAPC*/INITS*CURS1 ;SWAP WITH CURS
+ /SWAPC*/INITS*DTCNT0*DTCNT1*DTCNT2*CHAR0 ;INC
:+:/SWAPC*/INITS*CHAR1 ;HOLD

CHAR2 := SWAPC*/INITS*CURS2 ;SWAP WITH CURS
+ /SWAPC*/INITS*DTCNT0*DTCNT1*DTCNT2 ;INC
* CHAR0*CHAR1
:+:/SWAPC*/INITS*CHAR2 ;HOLD

CHAR3 := SWAPC*/INITS*CURS3 ;SWAP WITH CURS
+ /SWAPC*/INITS*DTCNT0*DTCNT1*DTCNT2 ;INC
* CHAR0*CHAR1*CHAR2
:+:/SWAPC*/INITS*CHAR3 ;HOLD

CHAR4 := SWAPC*/INITS*CURS4 ;SWAP WITH CURS
+ /SWAPC*/INITS*DTCNT0*DTCNT1*DTCNT2 ;INC
* CHAR0*CHAR1*CHAR2*CHAR3
:+:/SWAPC*/INITS*CHAR4 ;HOLD

CHAR5 := SWAPC*/INITS/CURS5 ;SWAP WITH CURS
+ /SWAPC*/INITS*DTCNT0*DTCNT1*DTCNT2 ;INC
* CHAR0*CHAR1*CHAR2*CHAR3*CHAR4
:+:/SWAPC*/INITS*CHAR5 ;HOLD

CURS1 := SWAPC*/INITS*/INCSCR*CHAR1 ;SWAP WITH CHAR
+ /SWAPC*/INITS*/INCSCR*CURS1 ;HOLD
:+:/SWAPC*/INITS*/INCSCR ;INC
* WRITE* DTCNT2*DTCNT1*/DTCNT0*CURS0

CURS2 := SWAPC*/INITS*/INCSCR*CHAR2 ;SWAP WITH CHAR
+ /SWAPC*/INITS*/INCSCR*CURS2 ;HOLD
:+:/SWAPC*/INITS*/INCSCR ;INC
* WRITE* DTCNT2*DTCNT1*/DTCNT0
* CURS0* CURS1

CURS3 := SWAPC*/INITS*/INCSCR*CHAR3 ;SWAP WITH CHAR
+ /SWAPC*/INITS*/INCSCR*CURS3 ;HOLD
:+:/SWAPC*/INITS*/INCSCR ;INC
* WRITE* DTCNT2*DTCNT1*/DTCNT0
* CURS0* CURS1*CURS2

CURS4 := SWAPC*/INITS*/INCSCR*CHAR4 ;SWAP WITH CHAR
+ /SWAPC*/INITS*/INCSCR*CURS4 ;HOLD
:+:/SWAPC*/INITS*/INCSCR ;INC
* WRITE* DTCNT2*DTCNT1*/DTCNT0
* CURS0* CURS1*CURS2*CURS3

CURS5 := SWAPC*/INITS*/INCSCR*CHAR5 ;SWAP WITH CHAR
+ /SWAPC*/INITS*/INCSCR*CURS5 ;HOLD
:+:/SWAPC*/INITS*/INCSCR ;INC
* WRITE* DTCNT2*DTCNT1*/DTCNT0
* CURS0* CURS1*CURS2*CURS3*CURS4

FUNCTION TABLE
CK DTCNT2 DTCNT1 DTCNT0 INITS SWAPC BS WRITE INCSCR /OC CURS5 CURS4
CURS3 CURS2 CURS1 CURS0 CHAR5 CHAR4 CHAR3 CHAR2 CHAR1 CHAR0

; I
; I S W N
; N W R C
; I A I S /
; C DTCNT T P B T C O CURS CHAR
; K 210 S C S E R C 54321 0 54321 0 COMMENTS
---------------------------------------------------------------------
C XXX H X X X X L LLLLL L LLLLL L INITIALIZE CHAR AND CURS
C LLL L L X X L L LLLLL L LLLLL H INCREMENT CHAR, HOLD CURS
C LLH L L X X L L LLLLL L LLLLL H HOLD CHAR AND CURS
C LHL L L X X L L LLLLL L LLLLL H HOLD CHAR AND CURS
C LHH L L X X L L LLLLL L LLLLL H HOLD CHAR AND CURS
C HLL L L X X L L LLLLL L LLLLL H HOLD CHAR AND CURS
C HLH L L X X L L LLLLL L LLLLL H HOLD CHAR AND CURS
C HHL L L X X L L LLLLL L LLLLL H HOLD CHAR AND CURS
C HHH L L X X L L LLLLL L LLLLH H INCREMENT CHAR
C LLL L L X X L L LLLLL L LLLLH L HOLD CHAR AND CURS
C LLH L L X X L L LLLLL L LLLLH L HOLD CHAR AND CURS
C HHH L L X X L L LLLLL L LLLLH L INCREMENT CHAR
C LLL L L X X L L LLLLL L LLLLH H CHAR = 3
C LLH L L X X L L LLLLL L LLLLH H HOLD CHAR AND CURS
C LHL L L X X L L LLLLL L LLLLH H HOLD CHAR AND CURS
C LHH L H X X L L LLLLH H LLLLL L SWAP CHAR AND CURS
C HLL L L X X L L LLLLH H LLLLL H SET CHAR0
C HHH L L X X L L LLLLH H LLLLH H INCREMENT CHAR TO 3
C HHH L L X X L L LLLLH H LLLHL H INCREMENT CHAR, HOLD CURS
C LLL L L X X L L LLLLH H LLLHL L CHAR = 4
C HHL L L X L L L LLLLH H LLLHL L HOLD CHAR AND CURS
C HHH L L X X L L LLLLH H LLLHL L INCREMENT CHAR
C LLL L L X X L L LLLLH H LLLHL H CHAR = 5
C HHH L L X X L L LLLLH H LLLHH H INCREMENT CHAR
C LLL L L X X L L LLLLH H LLLHH L CHAR = 6
C LLL L L X X L L LLLLH H LLLHH H CHAR = 7
C HHH L L X X L L LLLLH H LLHLL H INCREMENT CHAR
C HHH L L X X L L LLLLH H LLHLL L CHAR = 8
C HHH L L X X L L LLLLH H LLHLH H INCREMENT CHAR TO 11
C LLL L L X X L L LLLLH H LLHLH H CHAR = 11
C HHH L L X X L L LLLLH H LLHHL H SET CHAR0, INC CHAR BY 2
C HHH L L X X L L LLLLH H LLHHH H CHAR = 15
C HHH L L X X L L LLLLH H LHLLL H CHAR = 17
C HHL L L X H L L LLLHL H LHLLL H INCREMENT CURS
C HHH L L X X L L LLLHL L LHLLH H CHAR = 19, CURS = 4
C HHL L L X H L L LLLHH H LHLLH H CURS = 7
C HHH L L X X L L LLLHH H LHLHL H CHAR = 21
C HHL L L X H L L LLHLL H LHLHL H CURS = 9
C HHH L L X X L L LLHLL H LHLHH H CHAR = 23
C HHL L L X H L L LLHLH H LHLHH H CURS = 11
C HHH L L X X L L LLHLH H LHHLL H CHAR = 23
C HHL L L X H L L LLHHL H LHHLL H CURS = 13
C HHH L L X X L L LLHHL H LHHLH H CHAR = 27
C HHL L L X H L L LLHHH H LHHLH H CURS = 15
C HHH L L X X L L LLHHH H LHHHL H CHAR = 29
C HHH L L X X L L LLHHH H LHHHH H CHAR = 31
C HHH L L X X L L LLHHH H HLLLL H CHAR = 33
C HHH L L X X L L LLHHH H HLLLH H CHAR = 35
C HHH L L X X L L LLHHH H HLLHL H CHAR = 37
C HHH L L X X L L LLHHH H HLLHH H CHAR = 39
C HHH L L X X L L LLHHH H HLHLL H CHAR = 41
C HHH L L X X L L LLHHH H HLHLH H CHAR = 43
C HHH L L X X L L LLHHH H HLHHL H CHAR = 45
C HHH L L X X L L LLHHH H HLHHH H CHAR = 47
C HHH L L X X L L LLHHH H HHLLL H CHAR = 49
C HHH L L X X L L LLHHH H HHLLH H CHAR = 51
C HHH L L X X L L LLHHH H HHLHL H CHAR = 53
C HHH L L X X L L LLHHH H HHLHH H CHAR = 55
C HHH L L X X L L LLHHH H HHHLL H CHAR = 57
C HHH L L X X L L LLHHH H HHHLH H CHAR = 59
C HHH L L X X L L LLHHH H HHHHL H CHAR = 61
C HHH L L X X L L LLHHH H HHHHH H CHAR = 63
C LLL L L X X L L LLHHH H HHHHH H CHAR = 63, DTCNT = 0
C LLH L L X X L L LLHHH H HHHHH H CHAR = 63, DTCNT = 1
C LHL L L X X L L LLHHH H HHHHH H CHAR = 63, DTCNT = 2
C LHH L L X X L L LLHHH H HHHHH H CHAR = 63, DTCNT = 3
C HLL L L X X L L LLHHH H HHHHH H CHAR = 63, DTCNT = 4
C HLH L L X X L L LLHHH H HHHHH H CHAR = 63, DTCNT = 5
C HHL L L X H L L LHLLL H HHHHH H INCREMENT CURS
C HHH L L X X L L LHLLL L LLLLL H CURS = 14, INCREMENT CHAR
C HHH L L X X L L LHLLL L LLLLL L CURS = 14, CHAR = 0
----------------------------------------------------------------------

DESCRIPTION
"CHAR" AND "CURS" COUNT THE NUMBER OF CHARACTERS PER LINE. THEY ARE ALSO USED
AS POINTERS TO THE RAM. "CURS" IS USED WHEN A CHARACTER IS WRITTEN INTO THE
RAM AND "CHAR" WHEN A CHARACTER IS READ FROM THE RAM. "CURS" IS ALWAYS
POINTED TO THE NEXT AVAILABLE LOCATION IN THE RAM WHERE A NEW CHARACTER
CAN BE STORED.

"CHAR" IS INCREMENTED AT THE END OF 8 PIXELS MEANING IT COUNTS AFTER EACH
CHARACTER. IT COUNTS FROM 0 TO 63 ALTHOUGH ONLY 48 CHARACTERS ARE VISIBLE.
THE HORIZONTAL SYNC PULSE IS GIVEN BETWEEN ECHARACTERS 56 AND 59. DURING
THE COUNTS OF CHAR FROM 48 TO 63, BLACK SIGNALS ARE TRANSMITTED TO THE SCREEN.
"CURS" IS INCREMENTED FOR ANY OPERATION ONT THE KEY BPARD. THE TWO POINTERS
USE THE RAM IN THE INTERLIVED FASHION. READ IS DONE EVERY CYCLE, BUT WRITE
IS DONE ONLY WHEN A WRITE SIGNAL IS GIVEN. THE WRITE SIGNAL IS SET
WHEN A NEW CHARACTER ENTERS THE SYSTEM THROUGH THE RS232 PORT.

THE FUNCTION TABLE ABOVE DESCRIBES OPERATIONS OF READ AND WRITE FOR A
CERTAIN LINE. WHEN THIS LINE WAS PRINTED, 64 CHARACTERS WHERE READ AND
15 CHARACTERS WERE WRITTEN.

SIGNALS CHAR0, CURS0, SWAPC, WRITE AND INCSCR ARE DERIVED IN PAL VP8.

+ 107
- 0
VP3.pal View File

@@ -0,0 +1,107 @@
PAL20X10 PAL DESIGN SPECIFICATION
VP3 BIRKNER/KAMZI/UDI 7/9/81
SCAN/LINE GENERATOR
MMI SUNNYVALE, CALIFORNIA
CK /CHAR5 /CHAR4 /CHAR3 /CHAR2 /INITS /H255 /WRITE /TSYNC /CHAR1 /CHAR0 GND
/OC /LINE4 /LINE3 /SYNC /SCAN3 SCAN2 SCAN1 SCAN0 /LINE2 /LINE1 /LINE0 VCC

/SCAN0 := INITS ;INITIALIZE
+ /INITS*/SCAN0 ;HOLD
:+:/INITS*H255 ;INCREMENT
/SCAN1 := INITS ;INITIALIZE
+ /INITS*/SCAN1 ;HOLD
:+:/INITS*H255*SCAN0 ;INCREMENT

/SCAN2 := INITS ;INITIALIZE
+ /INITS*/SCAN2 ;HOLD
:+:/INITS*H255*SCAN0*SCAN1*/SCAN3 ;INC IN MODULUS 12

SCAN3 := /INITS*SCAN3 ;HOLD
+ /INITS*H255*LINE4*LINE2*LINE0 ;DETECT SCAN LINE 260
*SCAN2*SCAN1*SCAN0 ;FOR VERTICAL RETRACE
:+:/INITS*H255*SCAN0*SCAN1*SCAN2 ;INCREMENT
+ /INITS*H255*SCAN3*SCAN1*SCAN0 ;MODULE 12 CORRECTION
;INITIAL WHEN INITS=H
LINE0 := /INITS*LINE0 ;HOLD
+ /TSYNC ;TEST SYNC
:+:/INITS*H255*SCAN3*SCAN1*SCAN0 ;INCREMENT
+ /INITS*H255*LINE4*LINE2*LINE0 ;DETECT LINE 21 7/12
*SCAN2*SCAN1*SCAN0 ;FOR VERTICAL RETRACE

LINE1 := /INITS*LINE1 ;HOLD
+ /TSYNC ;TEST SYNC
:+:/INITS*H255*SCAN3*SCAN1*SCAN0*LINE0 ;INCREMENT

LINE2 := /INITS*LINE2 ;HOLD
+ /INITS*LINE2 ;EXTEND
:+:/INITS*H255*SCAN3*SCAN1*SCAN0*LINE0*LINE1 ;INCREMENT
*SCAN2*SCAN1*SCAN0 ;FOR VERTICAL RETRACE

LINE3 := /INITS*LINE3 ;HOLD
+ /INITS*LINE3 ;EXTEND
:+:/INITS*H255*SCAN3*SCAN1*SCAN0 ;INCREMENT
*LINE2*LINE1*LINE0

LINE4 := /INITS*LINE4 ;HOLD
+ /TSYNC ;TEST SYNC
:+:/INITS*H255*SCAN3*SCAN1*SCAN0 ;INCREMENT
*LINE3*LINE2*LINE1*LINE0
+ /INITS*H255*LINE4*LINE2*LINE0 ;DETECT LINE 21 7/12
*SCAN2*SCAN1*SCAN0 ;FOR VERTICAL RETRACE

SYNC := CHAR5*CHAR4*/CHAR3*CHAR2*/WRITE ;CHAR 52-55 HORIZ SYNC
+ LINE0*LINE1*/LINE2*LINE4*/SCAN2*/SCAN3*SYNC ;VERTICAL SYNC
:+: LINE0*LINE1*/LINE2*LINE4*/SCAN2*/SCAN3*SYNC ;WHEN LINE=19 SCAN 0-3
*CHAR5*CHAR4*/CHAR3*/CHAR2 ;AND CHAR 48-51

FUNCTION TABLE
CK CHARS CHAR4 CHAR3 CHAR2 CHAR1 CHAR0 TSYNC INITS H255 WRITE
/OC LINE4 LINE3 LINE2 LINE1 LINE0 SYNC SCAN3 SCAN2 SCAN1 SCAN0

; T I W
; S N H R S
; Y I 2 I / Y
; C CHAR N T 5 T O LINE N SCAN
; K 543210 C S 5 E C 43210 C 3210 COMMENTS
------------------------------------------------------------------------
C XXXXXX H H X X L LLLLL X LLLL INITIALIZE COUNTERS
C XXXXXX H L H X L LLLLL X LLLH INC SCAN
C XXXXXX H L H X L LLLLL X LLHL INC SYNC
C XXXXXX H L H X L LLLLL X LLHH INC SYNC
C XXXXXX H L H X L LLLLL X LHLL INC SCAN
C XXXXXX H L H X L LLLLL X LHLH INC SCAN
C XXXXXX H L H X L LLLLL X LHHL INC SCAN
C XXXXXX H L H X L LLLLL X LHHH INC SCAN
C XXXXXX H L H X L LLLLL X HLLL INC SCAN
C XXXXXX H L H X L LLLLL X HLLH INC SCAN
C XXXXXX H L H X L LLLLL X HLHL INC SCAN
C XXXXXX H L H X L LLLLL X HLHH INC SCAN
C XXXXXX H L H X L LLLLH X LLLL INC LINE, INC SCAN MODULE 12
C XXXXXX H L H X L LLLLH X LLLH LINE = 1, INC SCAN
C XXXXXX H L H X L LLLLH X LLHL LINE = 1, INC SCAN
C XXXXXX H L H X L LLLLH X LLHH LINE = 1, INC SCAN
C XXXXXX H H X X L LLLLL X LLLL INITIALIZE COUNTERS
C HHLLXX L L L X L HLLHH L LLLL LINE = 19, FOR TESTING VERTIC SYNC
C HHLLXX H L H X L HLLHH L LLLH VERTICAL SYNC
C HHLLXX H L H X L HLLHH L LLHL VERTICAL SYNC
C HHLLXX H L H X L HLLHH L LLHH VERTICAL SYNC
C HHLLXX H L H X L HLLHH L LHLL INC SCAN
C HHLLXX H L H X L HLLHH L LHLH INC SCAN
C HHLHXX H L L L L XXXXX H XXXX HORIZONTAL SYNC
------------------------------------------------------------------------

DESCRIPTION
EACH CHARACTER ON THE SCREEN CONSISTS OF 12 DOT LINES: 7 LINES FOR THE
CHARACTER AND 5 LINES FOR SPACE BETWEEN CHARACTERS.

"SCAN" IS A MODULE 12 COUNTER THAT COUNTS THE NUMBER OF THE DOT LINES FOR
EACH CHARACTER.

"LINE" COUNTS THE NUMBER OF THE CHARACTER LINES. EACH CHARACTER LINE IS
12 SCAN LINES. THE COUNTER COUNTS UNTIL 21 ALTHOUGH ONLY 16 LINES ARE
VISIBLE ON THE SCREEN.

THE HORIZONTAL SYNC PULSES ARE GIVEN IN EVERY SCANNED LINE BETWEEN
CHAR 52 AND 55. THE VERTICAL SYNC PULSE IS GIVEN WHEN THE LINE COUNT IS 19,
SCAN IS BETWEEN 0 AND 3, AND CHAR IS BETWEEN 48 AND 51.

+ 99
- 0
VP4.pal View File

@@ -0,0 +1,99 @@
PAL20X10 PAL DESIGN SPECIFICATION
VP4 BIRKNER/KAMZI/UDI 7/14/81
LINES/SCROL GENERATOR
MMI SUNNYVALE, CALIFORNIA
CK /SWAP SCAN0 SCAN1 /INIT /SCAN3 /H255 NC /WRITE /LINE4
/INCSCR GND /OC /SCROL0 /LINES0 /SCROL1 /LINES1 /SCROL2 /LINES2 /SCROL3
/LINES3 /INITS /OE VCC

LINES0 := /SWAP*/INITS*LINES0 ;HOLD
+ SWAP*/INITS*SCROL0 ;SWAP WITH SCROL
:+: /SWAP*/INITS*H255*/LINE4 ;INC (12 DOT LINES)
* SCAN3*SCAN1*SCAN0
+ /SWAP*/INITS*INCSCR ;INC (LF)

SCROL0 := /SWAP*/INITS*SCROL0 ;HOLD
+ SWAP*/INITS*LINES0 ;SWAP WITH LINES
:+: /SWAP*/INITS*INCSCR ;INC (LF OR CHAR = 47)
+ INITS ;INITIALIZE

LINES1 := /SWAP*/INITS*LINES1 ;HOLD
+ SWAP*/INITS*SCROL1 ;SWAP WITH SCROL
:+: /SWAP*/INITS*H255*/LINE4 ;INC (12 DOT LINES)
* SCAN3*SCAN1*SCAN0*LINES0
+ /SWAP* /INITS*INCSCR*LINES0 ;INC (LF)

SCROL1 := /SWAP*/INITS*SCROL1 ;HOLD
+ SWAP*/INITS*LINES1 ;SWAP WITH LINES
:+: /SWAP*/INITS*INCSCR*SCROL0 ;INC (LF OR CHAR = 47)
+ INITS ;INITIALIZE

LINES2 := /SWAP*/INITS*LINES2 ;HOLD
+ SWAP*/INITS*SCROL2 ;SWAP WITH SCROL
:+: /SWAP*/INITS*H255*/LINE4 ;INC (12 DOT LINES)
* SCAN3*SCAN1*SCAN0
*LINES1*LINES0
+ /SWAP*/INITS*INCSCR ;INC (LF)
*LINES1*LINES0

SCROL2 := /SWAP*/INITS*SCROL2 ;HOLD
+ SWAP*/INITS*LINES2 ;SWAP WITH LINES
:+: /SWAP*/INITS*INCSCR*SCROL0*SCROL1 ;INC (LF OR CHAR = 47)
+ INITS ;INITIALIZE

LINES3 := /SWAP*/INITS*LINES3 ;HOLD
+ SWAP*/INITS*SCROL3 ;SWAP WITH SCROL
:+: /SWAP*/INITS*H255*/LINE4 ;INC (12 DOT LINES)
* SCAN3*SCAN1*SCAN0
*LINES2*LINES1*LINES0
+ /SWAP* /INITS*INCSCR ;INC (LF)
*LINES2*LINES1*LINES0

SCROL3 := /SWAP*/INITS*SCROL3 ;HOLD
+ SWAP*/INITS*LINES3 ;SWAP WITH LINES
:+: /SWAP*/INITS*INCSCR ;INC (LF OR CHAR = 47)
*SCROL2*SCROL1*SCROL0
+ INITS ;INITIALIZE

INITS := INIT*H255 ;INITIALIZATION SIGNAL

OE := /WRITE ;ENABLE THREE STATE OF RAM


FUNCTION TABLE

CK SWAP SCAN3 SCAN1 SCAN0 INIT H255 WRITE LINE4 INCSCR /OC
SCROL3 SCROL2 SCROL1 SCROL0 LINES3 LINES2 LINES1 LINES0 INITS OE

; I
; W L N I
; S I H R I C N
; W N 2 I N S / I
; C A SCAN I 5 T E C O SCROL LINES T O
; K P 310 T 5 E 4 R C 3210 3210 S E COMMENTS
---------------------------------------------------------------------------
C X XXX H H X X X L XXXX XXXX H X SET INITIALIZE BIT
C X XXX L X X X X L HHHH LLLL L X INITIALIZE COUNTERS
C L XXX L L X X L L HHHH LLLL L X INITS = L
C L HHH L H X L L L HHHH LLLH L X INC LINES, HOLD SCROL
C L HHH L H X L L L HHHH LLHL L X INC LINES, HOLD SCROL
C L HHH L H X L L L HHHH LLHH L X INC LINES, SCAN = 11
C L HHH L H X L L L HHHH LHLL L X INC LINES, SCAN = 11
C L XXX L H X X H L LLLL LHLH L X INC LINES & SCROL: LF
C L XXX L X X X H L LLLH LHHL L X INC LINES & SCROL: LF
C L XXX L L X X L L LLLH LHHL L X HOLD LINES & SCROL
C H XXX L L X X L L LHHL LLLH L X SWAP LINES & SCROL
C L XXX L X X X H L LHHH LLHL L X INC LINES & SCROL
C X XXX X X L X X L XXXX XXXX X H SET OE
C X XXX X X H X X L XXXX XXXX X L CLEAR OE
---------------------------------------------------------------------------

DESCRIPTION

"SCROL" AND "LINES" ARE COUNTERS AND POINTERS TO THE RAM. "LINES" IS A
POINTER TO THE LINE THAT IS READ FROM THE RAM. "SCROL" IS A POINTER
TO THE LOCATION IN THE RAM WHERE A NEW LINE CAN BE STORED. BOTH OF THEM
COUNT UP TO A MAXIMUM OF 16 LINES.

THE BIT "SWAP" ENABLES THE TWO COUNTERS TO TALK TO THE SAME ADDRESS LINES
OF THE RAM.

+ 98
- 0
VP5.pal View File

@@ -0,0 +1,98 @@
PAL20X8 PAL DESIGN SPECIFICATION
VP5 BIRKNER/KAMZI/UDI 7/14/81
COMPOSITE VIDEO/BAUD RATE GENERATOR
MMI SUNNYVALE, CALIFORNIA
CK /DOT4 /SYNC NC NC NC INT /WRITE /DTCNT0 /DTCNT1 /DTCNT2 GND
/OC /SYNOUT /UEN /9600X8 /BAUD3 /BAUD2 /BAUD1 /BAUD0 NC NC VIDEO VCC

IF( SYNC ) SYNOUT = SYNC ;SYNC PULSE

IF( /DOT4 ) /VIDEO = /DOT4 ;PIXEL TO THE SCREEN

9600X8 := INT ;TO INITIALIZE COUNTER BAUD
+ BAUD3*BAUD2*DTCNT2*DTCNT1*/DTCNT0 ;104/8 = 13, MODULE 102
;COUNTS 103 = 12 6/8

BAUD0 := /9600X8*BAUD0 ;HOLD
+ /9600X8*BAUD0 ;EXTEND
:+: /9600X8*DTCNT2*DTCNT1*DTCNT0 ;INC

BAUD1 := /9600X8*BAUD1 ;HOLD
+ /9600X8*BAUD1 ;EXTEND
:+: /9600X8*DTCNT2*DTCNT1*DTCNT0*BAUD0 ;INC

BAUD2 := /9600X8*BAUD2 ;HOLD
+ /9600X8*BAUD2 ;EXTEND
:+: /9600X8*DTCNT2*DTCNT1*DTCNT0 ;INC
*BAUD1*BAUD0

BAUD3 := /9600X8*BAUD3 ;HOLD
+ /9600X8*BAUD3 ;EXTEND
:+: /9600X8*DTCNT2*DTCNT1*DTCNT0 ;INC
*BAUD2*BAUD1*BAUD0

UEN := WRITE*/DTCNT2*DTCNT1 ;DTCNT = 2,3
+ WRITE* DTCNT2*/DTCNT1*/DTCNT0 ;DTCNT = 4

FUNCTION TABLE
CK DOT4 SYNC INT WRITE DTCNT2 DTCNT1 DTCNT0 /OC SYNOUT UEN
9600X8 BAUD3 BAUD2 BAUD1 BAUD0 VIDEO

; S 9
; W Y 6 V
; D S R N 0 I
; O Y I I / O U 0 D
; C T N N T DTCNT E U E X BAUD E
; K 4 C T E 210 N T N 8 3210 O COMMENTS
----------------------------------------------------------------------
L X H X X XXX L H X X XXXX X CHECK SYNOUT FOR H
L X L X X XXX L L X X XXXX X CHECK SYNOUT FOR L
L L X X X XXX L X X X XXXX L VIDEO = L
L H X X X XXX L X X X XXXX H VIDEO = B
C X X H X LLL L X X H XXXX X SET 9600X8
C X X L X LLL L X X L LLLL X INITIALIZE BAUD COUNTER
C X X L X HHH L X X L LLLH X INC BAUD
C X X L X HHH L X X L LLHL X INC BAUD
C X X L X HHH L X X L LLHH X INC BAUD
C X X L X HHH L X X L LHLL X INC BAUD
C X X L X HLH L X X L LHLL X HOLD BAUD: DTCNT NEQ HHH
C X X L X HHH L X X L LHLH X INC BAUD
C X X L X HHH L X X L LHHL X INC BAUD
C X X L X HHH L X X L LHHH X INC BAUD
C X X L X HHH L X X L HLLL X INC BAUD
C X X L X HHH L X X L HLLH X INC BAUD
C X X L X HHH L X X L HLHL X INC BAUD
C X X L X HHH L X X L HLHH X INC BAUD
C X X L X HHH L X X L HHLL X INC BAUD
C X X L H LLL L X L L HHLL X HOLD BAUD
C X X L H LLH L X L L HHLL X HOLD BAUD
C X X L H LHL L X H L HHLL X HOLD BAUD, SET UEN
C X X L H LHH L X H L HHLL X HOLD BAUD, SET UEN
C X X L H HLL L X H L HHLL X HOLD BAUD, SET UEN
C X X L H HLH L X L L HHLL X HOLD BAUD
C X X L H HHL L X L H HHLL X SET 9600X8, HOLD BAUD
C X X L H HHH L X L L LLLL X INITIALIZE BAUD
----------------------------------------------------------------------

DESCRIPTION

THIS PAL GENERATES THE BAUD RATE, THE VIDEO AND THE SYNC SIGNALS WITH CARE
COMBINED AT THE OUTPUTS TO FORM THE COMPOSITE VIDEO SIGNAL, AND THE "UEN"
SIGNAL WICH ENABLE THE "URT".

EVERY CHARACTER CONSISTS OF 10 BITS: 1 START BIT, 7 ASCII CODE BITS, 1
PARITY BIT, AND 1 STOP BIT. THE CHARACTER RATE IS 9600 HZ. EACH BIT IS
DIVIDED INTO 8 SMALL BITS SO THE NUMBER OF BITS PER SECOND REQUIRED
FOR OUR SYSTEM IS 9600*8 = 76800 OR 7600 HZ.

T = 1/7680 = 13 MICROSECOND
THE CLOCK FREQUENCY IS 8000000 HZ.
WE NEED TO DIVIDE THE CLOCK FREQUENCY BY 104 TO GENERATE A FREQUENCY
OF 76800 HZ.

8000000/76800 = 104 = 13*8

"DTCNT" COUNTS 8, AND "BAUD" COUNTS 13. TO GET 104 COUNTS WE NEED TO
COUNT FROM 0 TO 103. BECAUSE THERE IS ONE CLOCK CYCLE DELAY UNTIL THE
DATA IS AVAILABLE ON THE OUTPUT PINS (REGISTERED PAL), MODULE 104 IS
DETECTED BY COUNT 102 WHICH IS EQUAL TO 102/8 = 12 6/8.

+ 85
- 0
VP6.pal View File

@@ -0,0 +1,85 @@
PAL20X10 PAL DESIGN SPECIFICATION
VP6 BIRKNER/UDI 21/7/81
UART SHIFT REGISTER AND CONTROL KEY DETECT
MMI SUNNYVALE, CALIFORNIA
CK /SAMPLE RXD /CLRLIN /WRITE INIT NC NC NC NC NC GND
/UEN /BS /SPACE D6 D5 D4 D3 D2 D1 D0 /LF VCC

/D0 := /D0*/SAMPLE ;HOLD
+ SPACE ;SET SPACE CODE
:+:/D1* SAMPLE ;SHIFT

/D1 := /D1*/SAMPLE ;HOLD
+ SPACE ;SET SPACE CODE
:+:/D2* SAMPLE ;SHIFT

/D2 := /D2*/SAMPLE ;HOLD
+ SPACE ;SET SPACE CODE
:+:/D3* SAMPLE ;SHIFT

/D3 := /D3*/SAMPLE ;HOLD
+ SPACE ;SET SPACE CODE
:+:/D4* SAMPLE ;SHIFT

/D4 := /D4*/SAMPLE ;HOLD
+ SPACE ;SET SPACE CODE
:+:/D5* SAMPLE ;SHIFT

/D5 := /INIT*/D5*/SAMPLE*/SPACE ;SET SPACE CODE INSTEAD
+ /D5*/SAMPLE*/SPACE ;OF ANY CONTROL CODE
:+:/INIT*/D6*SAMPLE*/SPACE ;SHIFT

/D6 := /INIT*/D6*/SAMPLE ;HOLD
+ SPACE ;SET SPACE CODE
:+:/INIT* RXD*SAMPLE ;DATA IS SHIFTED IN

SPACE := WRITE*/D6*/D5 ;DETECT CTRL CHAR
+ CLRLIN ;AND CLEAR LINE

LF := /D6*/D5*/D4*D3*/D2*D1*/D0 ;LINE FEED = HEX 0A
*WRITE ;LATCH ON WRITE
+ LF*WRITE ;HOLD DURING WRITE


FUNCTION TABLE

CK SAMPLE RXD CLRLIN WRITE INIT /UEN /BS SPACE D6 D5 D4 D3 D2 D1 D0 LF

; S C
; A L W S
; M R R I / P
; P R L I N U / A
; C L X I T I E B C DATA OUT L
; K E D N E T N S E D6-----D0 F COMMENTS
-------------------------------------------------------------------------------
C X X L L L L X L XXXXXXX X INITIALIZE "SPACE"
C H X L L H L X L HHXXXXX X INITIALIZE D6 AND D5
C X X L L L L X L XXXXXXX X HOLD "SPACE" LO
C H L L X L L X L HXXXXXX X SHIFT IN 1'ST BIT OF "U" CODE
C H H L X L L X L LHXXXXX X SHIFT IN 2'ND BIT OF "U" CODE
C H L L X L L X L HLHXXXX X SHIFT IN 3'RD BIT OF "U" CODE
C H H L X L L X L LHLHXXX X SHIFT IN 4'TH BIT OF "U" CODE
C H L L X L L X L HLHLHXX X SHIFT IN 5'TH BIT OF "U" CODE
C H H L X L L X L LHLHLHX X SHIFT IN 6'TH BIT OF "U" CODE
C H L L X L L X L HLHLHLH X OUTPUT "U" CODE, STORE IN RAM
C H H L X L L X L LHLHLHL X SHIFT IN 1'ST BIT OF "LF" CODE
C H L L X L L X L HLHLHLH X SHIFT IN 2'ND BIT OF "LF" CODE
C H H L X L L X L LHLHLHL X SHIFT IN 3'RD BIT OF "LF" CODE
C H L L X L L X L HLHLHLH X SHIFT IN 4'TH BIT OF "LF" CODE
C H H L X L L X L LHLHLHL X SHIFT IN 5'TH BIT OF "LF" CODE
C H H L X L L X L LLHLHLH X SHIFT IN 6'TH BIT OF "LF" CODE
C H H L L L L X L LLLHLHL X DETECT "LF" CODE
C L X L H L L X H LLLHLHL H HOLD DURING WRITE
C L X L L L L X L LHLLLLL X WRITE "SPACE" CODE INTO RAM
-------------------------------------------------------------------------------

DESCRIPTION

THE "UART" SHIFT REGISTER IS A SEVEN BIT REGISTER FOR THE SEVEN BIT ASCII
CODE. THE INFORMATION ENTERS THE SHIFT REGISTER IN D6, ONE BIT AT A TIME.
IT COMES THROUGH RXD PIN WHICH IS THE TRANSMIT OR THE RECEIVE LINE OF THE
RS232. THE OUTPUTS ARE TRANSFERED IN PARALLEL TO THE RAM. "UEN" ENABLES THE
THREE STATE FOR THESE OUTPUTS. WHEN BITS D6 AND D5 TOGETHER IN THE ASCII
CODE ARE ZEROES OR WHE THE "CLRLIN" BIT IS SET, A "SPACE" CODE IS SHIFTED
INTO THE "UART" REGISTER. THE SPACE CODE PRINTS A BLANK SPACE ON THE SCREEN.
"SPACE" IN ASCII CODE IS 0100000 = 20 HEX.

+ 97
- 0
VP7.pal View File

@@ -0,0 +1,97 @@
PAL20X10 PAL DESIGN SPECIFICATION
VP7 BIRKNER/UDI 7/28/81
UART CONTROL
MMI SUNNYVALE, CALIFORNIA
CK /9600X8 RXD /WE /INIT /SETBC2 /SETBC1 /SETBC0 NC NC EC GND
/OC /READY /SAMPLE /BC3 /BC2 /BC1 /BC0 /DET2 /DET1 /DET0 /START VCC

START := /READY*START s HOLD
+ /READY*RXD sDETECT START BIT
:+: /READY*START*BC3*BC2*BC1*BCO sFILTER FALSE START
* /DET2* /DET1*DET0* /RXD sCANCEL START IF NO RXD
DET0 := START*DET0 s HOLD
+ START*DET0 : EXTEND
s+3START*9600X8 * CARRY
DET1 := START*DET1 : HOLD
+ START*DET1 s EXTEND
2+: START*9600X8*DET0 2s CARRY
DET2 := START*DET2 s HOLD
+ START*DET2 s EXTEND
:+: START*9600X8*DET0*DET1 s CARRY
BCO := /SETBC0*BCO * HOLD
+ /SETBC0* READY °SET BC TO -l1 ON READY
:+: /SETBC0*START*9600X8 *DET0*DET1*DET2 > CARRY
+ SETBC0 SET BC TO 7 FOR TESTING
BCl := /SETBC1*BC1l : HOLD
+ /SETBC1*READY sSET BC TO ~1 ON READY
:+: /SETBC1*START*9600X8*DET0*DET1*DET2 » CARRY
*BCO
+ SETBC1 sSET BC TO 7 FOR TESTING
BC2 := /SETBC2*BC2 s HOLD
+ /SETBC2* READY SET BC TO -1 ON READY
3+: /SETBC2*START*9600X8*DET0*DET1*DET2 s CARRY
*BCO*BC1
+ SETBC2 :SET BC TO 7 FOR TESTING
BC3 := BC3 * HOLD
+ READY :SET BC TO -1 ON READY
s+:START*9600X8 *DET0 *DET1*DET2 s CARRY
*BCO*BC1*BC2
SAMPLE := START*9600X8* /DET2*DET1* /DET0*/BC3 sDET=2 & BC=0..7
+ START*9600X8* /DET2*DET1* /DET0* /BC3 : EXTEND
:+: START*9600X8* /DET2*DET1* /DET0 sCANCEL BC = 7
* /BC3*BC2*BC1*BCO
READY := /INIT*/WE* READY s HOLD
+ /INIT*/WE*START*BC3* /BC2* /BC1* /BCO SET ON BC=8
s+: INIT INITIAL READY, START & BC

FUNCTION TABLE
CK 9600X8 RXD /WE INIT SETBC2 SETBCl SETBC0 /OC READY
SAMPLE BC3 BC2 BCl BCO ODET2 DETl DET0 £START
? 9 S
: 6 R A S
; 0 I E M T
; OR /N J AP A
>C X X W I SETBC O DL BC DET R
> K 8 D E T 210 C YY E 3210 210 T COMMENTS
c X X X H XXX L 8H X XXXX XXX X £INITIAL READY
c X L 8H L XXX OL #8 X HHHH XXX L CLEAR START & INITIAL BC
c Xx L LG xXxX OL L X HHHH LLL L_ INITIAL DET & CLEAR READY
Cc X H L LG XXX OL L X BHHH LLL H_ SET START
C H LLL Lot L LL L HASH LLA #_ NO RXD, DETECT FALSE START
Cc H LLL LoL LL L SaaR LAL & CLEAR START (NOISE ON RXD)
C H H LL Lb L L L HASH LLL #8 INITIALIZE DET
C H H LL Leo L L L HaaH LLA HH NOW IT IS A REAL SIGNAL
C H H L LG Lb L L L HASH LHL F_ INC DET, NO SAMPLING
C H H L BL Len Lb L L HHAH LAA HAH NO SAMPLE, START BIT OF INFO
C H H LL&L Leb L UL L HASH BLL #_ INC DET, NO SAMPLING
C H H LG Lub Lb L L HABR HLA H_ INC DET, NO SAMPLING
C H H LL Lb L L L HASH HHL H_ INC DET, NO SAMPLING
C H H LL LoL L L L HAA HHH H_ INC DET, NO SAMPLING
C H H L LG Lb Lb LB LBL LLL LLL &£ INC DET AND BIT COUNTER
C H H L LB Loe LL L LLL LLa A 1's? BIT OF ASCII CODE
C H H L LG Loe LL L LLL LAL 8 INC DET
C H H L L Lu LL #8 LLLL LAB H_ SAMPLE THE 1'ST INFO BIT
C H H L BG Loo L &b L LLL BLL #H_ INC DET
C H H L LG Loe L LBL L LLL ALA #_ INC DET
C H H L LG Leet Lb L L LLL BHO #8 INC DET
C H H LL Loe LL L Lee eH #H_ INC DET
C H H LB & Leb Lb L L LLLea LLL FA sINC DET AND BIT COUNTER
C H H L LG Loe Lb L L LLL LLa #A-~ 2'ND BIT OF ASCII CODE
C H H LL LL Lb L L LELea LAL #8 INC DET 4
C H H LL Lb oo L #H LLL LAH #8 SAMPLE 2'ND BIT OF INFO
Cc H H L LG Le LL tL Leno BLL 8 sINC DET
C H H LB LG be Lb Lt tL LELea BLA 8 INC DET
C H H L LG Leb L tL L LLLe BaL A INC DET
C H H L LG Lb. LL L LLL BAA #H_ INC DET
C H H L BG 8LH LL L LAS LLL HAH _ SET BIT COUNTER TO 7
C H H L & LLL b&b L L LAB LEA 8H 7'TH BIT OF ASCII CODE
C H H LLG LL L Lt L LABH LAL #8 INC DET
C H H LL Lb L& L LL LASH LAH #H_ NO SAMPLE 7'TH BIT ALWAYS 0
C H H L LG Len L L L LBaR ALL A INC DET
C H H L LG Lot L L LL LAS ALA #8_ INC DET
Cc H H L L LLL Lb & L LBB HHL #H_ INC DET
C H H LB L Loe LL L LAB BAH H_ INC DET
C H H L L Lbt LL L BLL LLL 8 INC DET AND BIT COUNTER
C H H H L LLL Lb #H L BLLL LLB 8 SET THE READY SIGNAL
C H H L L Lo L L L HABA LHL L_ SET START BIT & INITIAL BC
C H H L LG Lb L L L H8HS8 LLL A- REPEATE FOR NEXT CHARACTER

+ 83
- 0
VP8.pal View File

@@ -0,0 +1,83 @@
PAL20X10 PAL DESIGN SPECIFICATION
VPs BIRKNER/UDI 7/29/81
RAM CONTROL
MMI SUNNYVALE, CALIFORNIA
CK /DICNTO /DTCNT1 /DTCNT2 /CHAR1 /CHAR2 /CHAR3 /CHAR4 /CHARS /READY /LF GND
/OC /H255 /CHARO /INCSCR /CLRLIN /SWAPC /WE /HBLANK /SWAP /CURSO /WRITE VCC
WRITE : =READY* /DTCNT2* /DTCNT1 * /DTCNTO*/H255 >SET WHEN DTCNT=0
*CHARS *CHAR4 *CHAR3 *CHAR2 *CHARI *CHARO 2& CHAR=63
+ WRITE*/DTCNT2*/H255 sHOLD AT 0,1,2,3
:+:WRITE* DTCNT2*/DTCNT1*/H255 sHOLD AT 4,5
+ CLRLIN* /DTCNT2* /DTCNT1* /DTCNTO SET AT DTCNT=0
SWAP := WRITE* /DTCNT2*/DTCNT1*DTCNTO ;SWAP AT DTCNT=1
+ WRITE* DTCNT2*/DTCNT1* /DTCNTO SWAP BACK AT 4
SWAPC:= WRITE* /DTCNT2*/DTCNT1*DTCNTO* /CLRLIN ;SWAP AT DICNT=1
+ WRITE* DTCNT2* /DTCNT1*/DTCNTO* /CLRLIN sSWAP BACK AT 4
:+:CHARS*CHAR4* /CHAR3*LF TEST CONDITION
WE := WRITE* /DTCNT2*DTCNT1*DTCNTO | *ENABLE WRITE
INCSCR := WRITE*DTCNT2*/DTCNTL*DTCNTO*/CLRLIN*/H255*LF §;DETECT LINEFEED
+ WRITE* CHAR5S*/CHAR4*CHAR3*CHAR2*CHARI *CHARO sCURS=47, LAST
* /CLRLIN*/H255 . :VISIBLE CHAR ON
* DICNT2* /DTCNT1*DTCNTO - gLINE. DTCNT=5 | |
:+:CHAR5*CHAR4* /CHAR3*LF | TEST CONDITION
H255 § :=_CHAR5*CHAR4*CHAR3*CHAR2*CHARL *CHARO | ;END OF LINE
*DTCNT2*DTCNT1* /DTCNTO : s DTCNT=6
CLRLIN := INCSCR ;SET ON LINE END
+ CLRLIN*CHARS *CHAR4 *CHAR3 *CHAR2*CHARI*CHARO :HOLD THIS WRITE
2+:CLRLIN*/CHARS | sHOLD, CHAR=0-31
+ CLRLIN*/CHAR4 sHOLD, CHAR=32-47
HBLANK := CHARS*CHAR4 *CHAR=48-63
+ CHARS*CHAR4 : EXTEND
:+: CHARS *CHAR4* /CHAR3* /CHAR2*/CHAR1* /CHARO*/DTCNT2 ;CANCEL 48-48.5
+ CHAR5*CHAR4* /CHAR3* /CHAR2* /CHARL*/CHARO*/DTCNT1 ;CANCEL 48.5-48.75
CHARO := SWAPC*CURSO SWAP WITH CURS
+ /SWAPC*CHARO > HOLD
2+: /SWAPC*DTCNTO*DTCNT1*DTCNT2 2 INC
CURSO := SWAPC*/INCSCR*CHARO SWAP WITH CHAR
+ /SWAPC* /INCSCR*CURSO > HOLD
:+: /SWAPC* /INCSCR*WRITE* /CLRLIN*DTCNT2*DTCNT1L*/DTCNTO ;INC

FUNCTION TABLE
CK DTCNT2 DTCNT1 DTCNTO CHARS CHAR4 CHAR3 CHAR2 CHAR] CHARO READY
LF /OC #8255 INCSCR CLRLIN SWAPC /WE HBLANK SWAP CURSO WRITE
; Ic H
; R N L Ss B Cc W
; E H Cc RW L S U R
; A f/ 28 LA /SAWR I
; Cc DITCNT CHAR D4LoO5cCHIPWNAS Tf
> K 210 543210 ¥y FC 5 RN C E K P O E_— COMMENTS

C LLL HALXX X X H Lb X¥ H X H X X X X X_ SET INCSCR,SWAPC
C HHL #HHLXX X X H LX H BH H X X X L X _ CLRLIN=H,CURS=L
C LLL #HHLXX X X H LL #H A HX X X L A SET WRITE |
C “LH LLLXxX X X X L&BLoL X¥ X X¥ L # . INCSCS,CLRLIN=L
C HHL LLXXxxX X LX LLLoLo x X X X L _ SWAP CURSO,CHARO
C HBL #HLXX X X H L X H X H X X X X X_~ SET INCSCR,CWAPC
C HHL #HALXX X X H BL X¥ H H BH X X X L X_ CLRLIN=H
C LLL HHLXX X X H LL #H #H H X X X X #_. SET WRITE SIGNAL
C LLH XXxXxXxxX X LX Lb xX X X X X X X HF HOLD WRITE
C LHL XXXxXxX X L X¥ L LX X X H X X X H_ HOLD WRITE
C LHH xXXXxXxX X LX LLB X X¥ X L X X X 4 ENABLE WRITE
C ALL XXXXX X L X L b&b xX X X H X X X 4H _ HOLD WRITE
C HLH XXXXX X L X LB xX X X X X X X HF HOLD WRITE
C HHL XXXXX X L X LL X¥ X L X X X X L_ CLEAR WRITE SIGNAL
C HHH XXXXXH L X LL LX L X X X X L_ CHARO=H, INCSCR=L
C LLL XXX¥XH L X LLL X Bb xX X X X LL. HOLD
C LLH xXXXXXH L X LLL xX Lb xX X X X L_ HOLD
C LHL XXXXXH LX LLL XxX LG xX X X X L_ HOLD
C LAH xXXXXX H L X LL&L xX Lb xX X X X L- HOLD
C HLL XXXXXH Lb X LL&L xXx Bb X X X X L_ HOLD
C HLA XXXXXH L X LLL xX Bb xX X X X L- HOLD
C HHL HHHHHH Lb X L AHLxX LX X X X X_ END OF LINE
C HHH #HHLXXL L LLL &Looe xX X X X X ~~ CLEAR CLRLIN & H255
C LLL HHAXXL H LL LLbo ox 8 X X L_. SET HBLANK
C HHH HHLXXH LL L&GLL iG X 8H X L L_ SET CURSO LO ra
C LLL HHLLLA H GL LGbL6L Gb XxX A X L X ~ SBLANK=L
C -LHH #HHLXXH LL L&Lnoeon xX X L L L_ HOLD
C HHL HHEXX H L HL LHL S#H xX X LL L_ SET INCSCR
C XXX HHLXXL LL L&boL.hsaAaxX ¥ X X¥ L L_ SET CLRLIN
C LLL LLxXxxXL L L LLL HR xX X X¥ X L #_ HOLD CLRLIN,SET WRITE
C LLL LLExxxXL L LLL GH X¥ X X X L L_ CLR WRITE,HOLD CLRLIN
C LLL HALXXL L L LLL L xX X X X L #H_ CLEAR CLRLIN
C LLH XXXXXL L LLLLoL. aH xX X #& L &F_ SET SWAP & SWAPC


BIN
Video Controller.pdf View File


Loading…
Cancel
Save