From f5b2a9241a32402b29d56af634212096fe9b9edf Mon Sep 17 00:00:00 2001 From: Tom Nisbet Date: Sat, 22 Dec 2018 09:59:41 -0500 Subject: [PATCH] Fix address error with 8755A burning --- TommyPROM/PromDevice8755A.cpp | 3 +-- TommyPROM/TommyPROM.ino | 17 +++++++++++++++-- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/TommyPROM/PromDevice8755A.cpp b/TommyPROM/PromDevice8755A.cpp index b6ef95e..2ad82ce 100644 --- a/TommyPROM/PromDevice8755A.cpp +++ b/TommyPROM/PromDevice8755A.cpp @@ -54,6 +54,7 @@ void PromDevice8755A::begin() // address lines. The read and burn code will take care of the ALE line void PromDevice8755A::setAddress(word address) { + setDataBusMode(OUTPUT); writeDataBus(byte(address & 0xff)); digitalWrite(AD8, address & 0x100 ? HIGH : LOW); digitalWrite(AD9, address & 0x200 ? HIGH : LOW); @@ -70,14 +71,12 @@ byte PromDevice8755A::readByte(word address) // Put the address on the bus and latch it with ALE digitalWrite(CE2, HIGH); - setDataBusMode(OUTPUT); setAddress(address); digitalWrite(ALE, HIGH); digitalWrite(ALE, LOW); // Read a byte setDataBusMode(INPUT); - setAddress(0xff); digitalWrite(RD, LOW); delayMicroseconds(1); data = readDataBus(); diff --git a/TommyPROM/TommyPROM.ino b/TommyPROM/TommyPROM.ino index 160cf63..848aa4c 100644 --- a/TommyPROM/TommyPROM.ino +++ b/TommyPROM/TommyPROM.ino @@ -29,6 +29,17 @@ CmdStatus cmdStatus; // Data polling supported PromDevice28C prom(32 * 1024L, 64, 10, true); +#elif defined(PROM_IS_27) +// Define a device for a 2764 EPROM with the following parameters: +// 8K byte device capacity +// 1000us (1ms) write pulse +// 15 write attempts +// 4x overwrite pulse +PromDevice27 prom(8 * 1024L, 1000L, 15, 4); // 2764 with SEEQ intelligent programming +//PromDevice27 prom(32 * 1024L, 1000L, 25, 3); // 27C256 with SEEQ intelligent programming +//PromDevice27 prom(2 * 1024L, 50000L, 1, 0); // 2716 with single 50ms write +//PromDevice27 prom(64 * 1024L, 100L, 11, 0); // 27C040 with Atmel rapid programming + #elif defined(PROM_IS_8755A) // Define a device for an 8755A. This has a fixed size of 2K and no // other parameters. @@ -490,7 +501,7 @@ void zapTest(word start) return; } - delayMicroseconds(10000); + delay(100); for (int ix = 0; ix < sizeof(testData); ix++) { byte val = prom.readData(start + ix); @@ -529,6 +540,7 @@ void setup() * executing read or write requestes. **/ +/* 8085 Test programs byte ledTest[] = { 0xc3, 0x03, 0x80, 0x3e, 0xc0, 0x30, 0x3e, 0xff, @@ -545,6 +557,7 @@ byte charTest[] = 0x3e, 0x40, 0x30, 0x3e, 0xc0, 0x30, 0x3e, 0x40, 0x30, 0x21, 0xff, 0xff, 0x2d, 0xc2, 0x30, 0x80, 0x25, 0xc2, 0x30, 0x80, 0xc3, 0x03, 0x80 }; +*/ word start = 0; word end = 0xff; @@ -644,7 +657,7 @@ void loop() break; default: - Serial.println(F("TommyPROM 1.5\n")); + Serial.println(F("TommyPROM 1.6\n")); Serial.println(F("Valid commands are:")); Serial.println(F(" Cssss eeee - Compute checksum from device")); Serial.println(F(" Dssss eeee - Dump bytes from device to terminal"));