README for Serial video display Preliminary Release 0.3, 30-Jan-2001 $Id: README,v 1.7 2001/01/31 07:25:31 eric Exp $ Copyright 2001 Eric Smith SERVID is a program for the Ubicom (formerly Scenix) SX microcontroller to act as a serial video display terminal (output only). Home page: http://www.brouhaha.com/~eric/ubicom/servid/ Features: * serial input at 1200 bps 8N1 (eight data bits, no parity, one stop bit), MSB ignored * monochrome displayo of four lines of twenty characaters * 1 volt peak-to-peak composite video ouptut into 75 ohm load * ASCII character set, 95 displayable characters * Subset of VT52 control characters and escape sequences * Automatic scrolling * no extra "4" characters when scrolling * interlaced or non-interlaced video selectable by conditional assembly * approximate NTSC timing (525/60) * approximate PAL timing (625/50) selectable by conditional assembly - maybe. PAL timing of an earlier version was only tested in a cursory fashion. Since then the line type table for PAL has been rewritten in an attempt to more closely meet PAL scanning specifications (e.g., 5 each equalization, vsync, equalization pulses per field). However, this newer code has not been tested in PAL mode at all. This is a preliminary release. As such, it basically works, but there are some known bugs (and probably a lot of unknown ones): * some escape sequences are acting a bit flaky Supported control codes: $00 Null $07 Bell $08 Backspace $0A Line Feed $0C Form Feed - clear display and home cursor $0D Carriage Return $1B Escape - introduce escape sequence $7F Delete - ignored All unrecognized control characters are ignored. Supported escape sequences: ESC A - Cursor Up - wraparound rather than scroll ESC B - Cursor Down - wraparound rather than scroll ESC C - Cursor Left ESC D - Cursor Right ESC H - Cursor Home ESC I - Reverse Line Feed - may scroll ESC J - Erase to End of Screen ESC K - Erase to End of Line ESC Y - Direct cursor addressing, col and row offset by 32 Customization: SERVID is designed such that user application code may be added to (or replace) the serial character processing. In this release of the code there are 919 words of program memory free for a user application, and 21 bytes of RAM free. The video generation is entirely interrupt driven, so the user application code can run at non-interrupt time without any critical timing constraints. Software Requirements: As written, SERVID will only assemble with the GPASM assembler, version 0.8.14 or newer. GPASM is Free Software: http://gpasm.sourceforge.net/ Hardware Requirements: SERVID requires a processor clock of 42.954545 MHz (12 times the NTSC color burst frequency). Note that future versions of SERVID may change to a clock frequency of 57.272727 MHz (16 times the NTSC color burst frequency). Digikey offers suitable Epson oscillators which they program to customer spec; a suitable 8-pin DIP footprint (4 actual pin) part is part number SG-8002DC-PHB-ND. SERVID uses an 8-bit D/A converter on port B to generate the video output. A simple R-2R resistor ladder will suffice. The serial input should be fed into port RA0. If a conventional EIA-232 receiver (MC1489, MAX232, or the like) is used, the variable ft_ser_noninv near the top of the servid.asm source file should be set to 0. For a non-inverting serial input (such as the crude resistor-only method, see the file SCHEMATIC), ft_ser_noninv should be set to 1. References _A Technical Introduction to Digital Video_ by Charles A. Poynton, published by John Wiley & Sons, 1996 ANSI/SMPTE 170M-1994 "SMPTE Standard for Television - Composite Analog Video Signal - NTSC for Studio Applications" ITU-R Reccomendation BT.470-6 "Conventional Television Systems" Acknowledgements Many thanks to Richard Ottosen for designing and building the hardware, helping debug the code, and providing numerous helpful suggestions. He also adapted my delay routines to the SX. Several years ago he wrote the original test pattern generator for the PIC16C5x, which inspired my PIC-PONG game, and now this program. http://www.rhoent.com/ Thanks to Richard Ottosen and Loren Blaney for supplying a better character generator font than the one I started to throw together. Thanks to James Newton for posting the challenge: http://www.sxlist.com/ Thanks to Ubicom for making fast yet inexpensive microcontrollers: http://www.ubicom.com/ Thanks to Loren Blaney for writing SXPROG, which allows the Parallax SX-Key programmer (Rev. C only, unfortunately) to be controlled from environments other than M$ Windows: http://www.brouhaha.com/~eric/scenix/sxprog/ License This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation. Note that permission is not granted to redistribute this program under the terms of any other version of the General Public License. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. NOTE: it is sometimes claimed that compliance with the GPL is awkward for commercial interests. Licenses for non-GPL use of this program may be negotiated with the author.