intel MCS BASIC-52 — Intel MCS BASIC-52 Versions 1 & 1.1 Operating and Reference Manual PDF (EN)

int e l 9.2 GENERAL PURPOSE ROUTINES To select the "INTELLIGENT" EPROM PROGRAMMING algorithm the directly addressable BIT 51 (33H) MUST be set to 1 before the EPROM PROGRAMMING routine is called. The "STANDARD" 50 ms EPROM PROGRAMMING algorithm is selected by CLEARING BIT 51 (33H) (i.e. BIT 51 = 0) before calling the EPROM PROGRAMMING routine. The directly addressable BIT 51 is located in internal memory location 38.3 (26.3H) (BIT 3 of BYTE 38 (26H) in internal memory). This BIT can be SET or CLEARED by the BASIC STATEMENTS DBY(38) = DBY(38).0R.08H to SET and DBY(38)=DBY(38).AND.0F7H to CLEAR.

Of course, the user can set or clear this bit in assembly language with a SETB 51 or CLR 51 instruction. The user must also turn on the EPROM PROGRAMMING voltage BEFORE calling the EPROM PRO- GRAMMING routine. This is done by CLEARING BIT P1.5, the fifth BIT on PORT 1. This too can be done in BASIC with a PORT1 = PORT1.AND.0DFH instruction or in assembly language with a CLR P1.5 instruction. The user must also set this bit when the PROM PROGRAMMING procedure is complete. This instruction assumes that the hardware surrounding the MCS BASIC-52 device is the same as the suggestions in the EPROM PROGRAMMING chapter of this manual. - 110 -