Home

KIM Hints - Bryan`s Old Computers

image

Contents

1. MICROCOMPUTERS KIM HINTS Since you and your KIM 1 are relative strangers we d like to help you get better acquainted The material in this pamphlet will answer questions that are frequently asked by a new KIM 1 user 1 ISIT POSSIBLE TO OUTPUT DIGITS OTHER THAN HEX TO THE 6 OUTPUT LED S Since the 6502 is doing all segment decode and multi plex it is possible to display data other than hex on a 7 segment readout A pseudo alphabet has been devel oped and is displayed in the 7 segment display of the KIM in a scrolling manner 2 WHEN HANDLING THE BOARD WOULD THE STATIC HAZARD BE RELIEVED IF ALL EDGE CONNECTORS WERE SHORTED TOGETHER The static problems are not as serious once the devices are installed in the P C board Just be sure to use grounded tools and to discharge yourself to ground before touching KIM or the connected circuits 3 WHAT TYPE OF LED READOUT IS USED ON 1 FOR U18 etc GENERAL COMMON ANODE OR CATHODE USE MAN 72 Type displays available from many manu facturers General common anodes should work although you may find intensity differences between them 4 WHERE CAN GET MORE 44 PIN EDGE CON NECTORS FOR KIM The connector is a standard part you can order a Vector No R644 from most electronic supply houses The connector is also carried by most Radio Shack stores as Part No 276 548 5 ARE THERE ANY INTERFACES OR PROM PRO GRAMMERS AVAIL
2. Chess playing program which runs in 1K 10 MICRO CHESS 27 Firstbroke Rd Toronto CANADA 212 4 A good group of games plus an intermediate level language called PLEASE for KIM 1 15 from THE COMPUTERIST Post Office Box 3 S Chelmsford MA 01824 5 The 6502 Program Exchange 2920 Moana Reno NV 89509 6 Micro Software Specialists 2024 Washington Street Commerce TX 75428 7 KIMATH a complete floating point math package in cluding both source and object code is available from MOS Technology for 15 8 A 4K version of FOCAL a BASIC like interpreter and a 6K Resident assemble text Editor both with source listings and object code on KIM cassette or paper tape are available from ARESCO 314 Second Ave Haddon Heights NJ 08035 The FOCAL is 50 and the assembler Editor is 70 A complete information package is 2 9 An 8K version of BASIC for KIM is available for 99 from Johnson Computing 123 W Washington St Medina Ohio 44256 215 725 4568 10 FIRST BOOK OF KIM is a collection of games utility programs hints and kinks etc 180 pgs 9 00 plus 50 postage from ORB P O Box 311 Argonne ILL 60439 INTERVAL TIMER OPERATION 1 OPERATION a Loading the timer The divide rate and interrupt option enable disable are pro grammed by decoding the least significant address bits KIM SUBROUTINES CALL ADDRESS ACTION EA RESULT NOTES Check for key depressed JSR GETKEY Get key from
3. keyboard JSR SCANS Display F9 FA FB JSR GETCH Put character from TTY A JSR PRTBYT Prints A as 2 Hex Char JSR PRTPNT Prints Contents of FB amp FA Try JSR OUTCH Print ASCII char inA on TTY JSR OUTSP Print a space 0 Key down 0 No Key down X amp Y lost gt 15 illegal or no key A X Y are lost X preserved Y FF A preserved X preserved Y FF A lost X preserved Y FF X is preserved Y FF A FF A FF X preserved Y FF The starting count for the timer is determined by the value written to that address Writing Sets Divide Interrupt to Address Ratio To Capability Is 1704 1 Disabled 1705 8 Disabled 1706 64 Disabled 1707 1024 Disabled 170C 1 Enabled 170D 8 Enabled 170E 64 Enabled 170F 1024 Enabled b Determining the timer status After timing has begun reading address location 1707 will provide the timer status f the counter has passed the count of zero bit 7 will be set to 1 otherwise bit 7 and all other bits in location 1707 will be zero This allows a program to watch location 1707 and determine when the timer has timed out Note that reading 1707 provides an entirely different function from writing the same lo cation c Reading the count in the timer If the timer has not counted past zero reading location 1706 will provide the current timer count and disable the interrupt option reading location 170E will provide the current time
4. specified rate begins The timer counts down at the clock frequency divided by the divide rate The current timer count may be read at any time At the user s option the timer may be programmed to generate an interrupt when the counter counts down past zero When a count of zero is passed the divide rate is automatically set to 1 and the counter con tinues to count down at the clock rate starting at a count of FF 1 in two s complement arithmetic This allows the user to determine how many clock cycles have passed since the timer reached a count of zero Since the counter never stops continued counting down will reach 00 again then FF and the count will continue 3 INTERVAL TIMER AND KEYBOARD OPERATION The following three programs show the use of the interval timer keyboard and seven segment displays in user programs The first program loads a value of 50 in the timer and waits for it to time out repeats the process and then increments the count in the display register DOFA and OOFB and calls the display subroutine SCANS The process then repeats The second program performs the same function as the first but uses the timer to provide interrupts rather than watching the timer status register 1707 Thus this program is con stantly cycling through the display program SCANS except when the timer generates an interrupt When an interrupt occurs the interrupt service routine starting at location 010C resets the timer i
5. ABLE WITH KIM TO PROGRAM EPROMs OR TO DUPLICATE PROMs No not yet 6 IS THERE AN 1 0 EXPANSION BOARD AVAIL ABLE Not yet soon we hope 7 IS THERE A BOARD AVAILABLE TO MAKE USE OF MEMORY ADDRESSES 0400 13FF Check the Kilobaud article issue 4 April 1 1977 page 74 entitled KIM Memory Expansion ANSWERS TO POPULAR KIM SYSTEM QUESTIONS 8 HOW DO I SET UP MY KIM FOR AUDIO CASSETTE RECORDING AND PLAYBACK A number of KIM 1 customers have reported difficulty in achieving correct results for the sample problem shown in Sec 2 4 of the KIM 1 User Manual In addi tion some customers have experienced problems in recording or playback of audio cassettes Sec 2 5 of the KIM 1 User Manual In all cases the problems have been traced to a single cause the inadvertent setting of the DECIMAL MODE The 6502 Microprocessor Array used in the KIM 1 system is capable of operating in either binary or decimal arithmetic mode The programmer must be certain that the mode is selected correctly for the pro gram to be executed Since the system may be in either mode after initial power on a specific action is required to insure the selection of the correct mode Specifically the results predicted for the sample problem Sec 2 4 are based on the assumption that the system is operating in the binary arithmetic mode To insure that this is the case insert the following key sequence prior to the key opera
6. Byte magazine and in the first issue of the KIM user notes Reproduced below 5v RS232 MAY WORK AS WELL D Other common sources of Teletype problems are a short circuit in C5 or a burned out 07 Signal tracing with a scope should reveal these problems 11 12 13 HOW DO I SOLVE PAPER TAPE PROBLEMS 15 having a date code in 1975 on the 6502 will not read paper tape correctly These CPU s will be replaced by MOS without charge Tom Pittman s TINY BASIC will not work on these machines either The problem occurs because early versions of the pro cessor did not set the zero flag correctly on TXA TYA TAX or TAY instructions B When using a Texas Instruments Silent 700 data terminal equipped with digital cassettes or other higher speed paper tape devices a O paper tape dump may be performed at any speed acceptable to the data terminal but playback through the L command must be at 10 cps WHAT DO I DO ABOUT OTHER PROBLEMS A Ifthe RESET on KIM causes only a single digit or segment to light on the display the KIM must be returned for repair B When in doubt check all power supply voltages on the KIM board not at the power supply terminals C When software works strangely or erratically decimal binary mode problems may be involved D There is an error in the KIM Resident Assembler manual regarding the addresses for the symbol table vectors The vector loca
7. NABLED 7 ISA ONE IF TIME OUT HAS OCCURRED BIT 7 IS ZERO IF TIME OUT HAS NOT OCCURRED BITS 0 6 ARE ALL ZERO WHEN THE TIMER TIMES OUT THE DIVIDER IS SET TO A DIV BY ONE AND THE TIMER CONTINUES TO COUNT AT CLOCK RATE WHEN THE TIMER IS READ THE DIVIDER IS RESTORED TO ITS ORIGINAL VALUE AND THE INTERRUPT IS RESET SCANS 1F1F EXTERNAL SUBROUTINES INCPT 1F63 GETKEY 1 6 TO USE INTERRUPT PB7 MUST BE EXTERNALLY WIRED TO IRQ Program 1 THIS EXAMPLE DOES NOT USE INTERRUPTS THE DISPLAY WILL DIM AS A RESULT OF SLOW SCANNING COUNT 2 COUNT DOWN 2 TIMES DELAY 50 EACH DELAY 50 CYCLES 0000 0000 ORGATO 0000 A2 02 STARTI LDX COUNT 0002 A9 32 LDA DELAY 0004 8D 06 17 AGAIN STA C64D DIV BY 64 DISABLE INT 0007 2C 07 17 WAIT BIT SR READ STATUS DISABLE INT 000A 10 FB BPL WAIT BIT 7 1 TIME OUT COMPLETE 000C CA DEX 000D DO F5 BNE AGAIN LOOP ON COUNT 000F 20 63 IF JSR INCPT MONITOR UTIL INC FA FB 0012 20 IF IF JSR SCANS MONITOR UTIL DISP F9 FA FB 0015 4C 00 00 JMP STARTI CARD LOC 0018 0100 58 0101 A9 FF 0103 8D OF 17 0106 20 0109 4 06 01 010 9 FF 010 80 17 0111 20 63 IF 0114 40 0115 VEE 0 01 1800 0200 58 0201 D8 0202 20 IF tr 0205 DO F9 0207 20 IE IF 020A FO FB 020C 20 020F 20 6A 1F 0212 C9 15 0214 10 EA 0216 2A 0217 2A 0218 2A 0219 2A 021A AO 04 021C 2A 021D 26 F9 021F 26 FA 0221 26 FB 0223 88 0224 DO F6 0226 4C 00 02 INTERVAL TIMER C
8. ncrements the display register and returns to the display program Note that the LED display is brighter when using this program because most of the computer s time is spent displaying rather than watching the timer The third example program demonstrates the use of the keyboard and display Any key depressed will appear in the rightmost digit of the display and will be shifted to the left with each successive keyboard entry Notice that the SCANS routine not only displays the con tents of 00 9 OOFA and 00 but also returns with the Z flag set to if a key is currently depressed The GET KEY routine is then called to determine which key has been depressed Since the SCANS subroutine takes several milliseconds a call to this routine can be used to waste time and let any keybounce stop INTERVAL TIMER LOC CODE DEFINITION OF COMMONLY USED LOCATIONS DA 1700 DATAREGA DDA 1701 DATA DIREC REGA DB 1702 DATA REG B DDB 1703 DATA DIREC REG B TIMERS WRITE TIME TO 1 1704 DIV BY 1 DISABLE INT C8D 1705 DIV BY 8 DISABLE INT C64D 1706 DIV BY 64 DISABLE INT C1024D 1707 DIV BY 1024 DISABLE INT CIE 170C DIV BY 1 ENABLE INT C8E 170D DIV BY 8 ENABLE INT C64E 170E DIVBY64 ENABLE INT C1024E 170F DIV BY 1024 ENABLE INT TRD 1706 READ TIME DISABLE INT SR 1707 READ INT STAT TRE 170E READ TIME ENABLE INT WHEN THE INTERRUPT STATUS IS READ THE INTERRUPT IS NEITHER DISABLED OR E
9. ontinued CODE CARD Program 2 THIS EXAMPLE USES INT WIRE PB7 TO IRQ EXTERNALLY 0100 START 2 CLI LDA FF STA 1024 DISP JSR SCANS JMP DISP ORG AT HEX 100 CLEAR INT MASK THIS ENABLES TMR INT FIRST TIME THIS IS AN ENDLESS LOOP THAT DISPLAYS CONTENTS OF F9 FA FB INTERRUPT SERVICE ROUTINE INTSVC LDA FF STA 1024 JSR INCPT RTI 17FE IROT WORD INTSVC Program 3 SET DISPLAY TO 255 CPS PR INT ORG AT IRQ VECTOR SET TO INT SERVICE THIS EXAMPLE DESCRIBES USE OF KEYBOARD AND DISPLAY 0200 INH F9 PTL FA PTH FB START 3 CLI CLD JSR 5 5 BNE START3 DISP1 JSR SCANS BEQ DISP1 VALIDT JSR SCANS JSR GETKEY 15 BPL START3 ROL A ROL A ROL A ROL A LDY 4 V1 ROL A ROL INH ROL PTL ROL PTH DEY BNE V1 JMP START3 END END OF MOS TECHNOLOGY 650X ASSEMBLY VERSION 4 NUMBER OF ERRORS 0 NUMBER OF WARNINGS 0 LSD S THESE 3 BYTES ARE DISPLAY BVF MSD S IF KEY IS DEPRESSED WAIT FOR ITS RELEASE WAIT FOR KEY DEPRESSED WHEN DEPRESSED GO TO VALIDATION THIS USED AS DEBOUNCE MONITOR UTIL WHICH GETS KEY VAL IF MPU IN DEC MODE THEN GET KEY GETS DECIMAL VALUE A 10 LEFT JUSTIFY KEY VALUE SET UP LOOP COUNT 4 SHIFT ALL DIGITS 1 PLACE LEFT DO THIS ONE BIT AT A TIME FOR 4 BITS
10. r count and enable the interrupt option Thus the interrupt option can be changed while the timer is counting down Note that you read 1706 or 170E regard less of which location 1704 OF was written to start the timer If the timer has counted past zero reading either memory location 1706 or 170E will restore the divide ratio to its previously programmed value disable the interrupt option and leave the timer with its current count d Using the interrupt option In order to use the interrupt option described above line PB7 application connector pin 15 should be connected to either the IRO Expansion Connector pin 4 or NMI Ex pansion Connector pin 6 pin depending on the desired interrupt function PB7 should be programmed as an input line it s normal state after a RESET NOTE If the programmer desires to use PB7 as a nor mal 1 0 line the programmer is responsible for disabling the timer interrupt option by writing or reading address 1706 so that it does not interfere with normal operation of PB7 Also PB7 was designed to be wire ORed with other possible interrupt sources if this is not desired 5 1 resistor should be used as a pull up from PB7 to 5v The pull up should NOT be used if PB7 is connected to NMI or IRQ 2 CAPABILITIES The KIM Interval Timer allows the user to specify a preset count and a clock divide rate by writing to a memory loca tion As soon as the write occurs counting at the
11. rk with an AC adapter because of hum induced during record or playback Tapes should always be rewound before removal from the machine as a finger print on the tape will result in errors on playback E Make sure that only a single ground line is run from the KIM ground to the barrel of the microphone input of the cassette recorder Leave the barrel of the ear phone output ungrounded The shield around the line to the earphone should be attached to ground on KIM F Problems of playing a tape recorded on one KIM system back on another system or a different cassette player can usually be solved by adjusting the head adjustment screw on the new cassette recorder Play back a cassette recorded on the old deck on the new machine and adjust the head screw on the new machine for maximum volume This adjustment is especially critical when using the SuperTape program 10 HOW DO I SOLVE TELETYPE PROBLEMS A The most common problem is that the system does not respond to a reset rubout sequence with a model 33 Teletype This can be fixed by removing the wire connected to pin R on the KIM application connector connecting a 470 ohm resistor to that wire and con necting the other end of the resistor to the 12V supply at pin N KIM N TO 12 v 470 R HX TO TELETYPE KEYBOARD B No information is available on connecting other Teletype models 14 28 32 to KIM C Schematics for interfacing KIM to an RS232C port are in the April 1976
12. tions are DF 0 E1 E2 The text is incorrect the example is correct E Problems with KIM 2 3 s which fail the memory test program can almost always be traced to excessive cable length between the KIM 1 and the KIM 2 3 Any cable should be 6 in length or less WHAT ARE THE KIM SYSTEM POWER SUPPLY REQUIREMENTS KIM 1 Microcomputer Board KIM 3A 8K RAM Memory Board 12 5V 15 100 mA 12V 5 The actual power measured ranges 700 mA to 1A at 5V and the schematic indicating 3A at transformer is incorrect Recommended ee Recommended 5V 3A Average consumption calculated is about 2 4A Board has 5V regulator accepting unregulated 8 to 10V DC KIM 4 Mother Board 14 Consumption about 200mA Board has 5V regula tor accepting unregulated 8 to 10V DC and 12V regulator accepting unregulated 15V DC to support both KIM1 and KIM 4 KIM 4 has 6 slots for memory expansion with KIM2 and KIM3 and hence a total power supply requirement is a cumula tive value dependent on KIM System configuration WHAT SOFTWARE IS AVAILABLE The following software is available for use with the KIM 1 and or other 6502 based systems gt Tiny BASIC runs in 2K 5 for paper tape from Tom Pittman Box 23189 San Jose California 95153 2 Many games and other information in the KIM 1 User Group Newsletter 5 for 6 issues Eric Rehnke 109 Centre Avenue W Norriton PA 19401 3 An excellent
13. tions shown at the bottom of Page 11 of the KIM 1 User Manual Lo Lo E 47 007 07 This sequence the decimal mode flag the Sta tus Register prior to the execution of the sample program The same key sequence may be inserted prior to the key operations shown on pages 14 and 15 for audio cassette recording and playback These operations will not be performed correctly if the decimal mode is in effect In general whenever a program is to be executed in response to the key the programmer should insure that the correct arithmetic mode has been set in the status register 00 1 prior to program execution HOW DO I SOLVE AUDIO CASSETTE INTERFACE PROBLEMS A Insure that memory location OOF1 has been set to a value of 00 before recording or playing back the tape This is the source of 90 of all cassette problems Mis adjustment of the variable resistor VR 1 in the cassette circuitry is almost never a problem Any setting near the center of its rotation will work fine C Make sure that 12V is connected during playback NOTE 12V is not required for recording so a lack of 12V will result in good recording but no playback D if the display frequently relights showing FFFF the fault is probably in the tape unit itself not the KIM Using poor quality cassettes is usually to blame Some cassette recorders have such poor power filtering circuits that they will work fine on batteries but will not wo

Download Pdf Manuals

image

Related Search

Related Contents

Bouteille Oxycure Oxygène médical  Polar FT60 Manuel d`utilisation  SillaCocheBebe.com  EPSON E-150 取扱説明書  Samsung SGH-E760 Instrukcja obsługi  Baumatic BCG605SS Technical Drawing  T。g"`寶^ 東芝川り照明器具取扱説明書 保管用  ダウンロード  EN Dear Customer, Gigaset Communications GmbH is the  Tenda F300 router  

Copyright © All rights reserved.
Failed to retrieve file