Close
0%
0%

Building a 22MHz Z80 Computer in 4 Stages

Step-by-step instruction on building a high-performance, CP/M-ready, expandable Z80 computer

Similar projects worth following
This project starts with a simple Z80 design with 4 integrated circuits and build it up in stages into a high performance, sophisticated Z80-based system. The Z80 computer is functional in each stage, more functionalities are added in each subsequent stages. The goal is a high-performance, expandable, CP/M capable Z80 system. This Z80 design is based on Z80SBC64.

Outline of the project:
Introduction

Stage 1 hardware

Stage 1 software

Stage 2, Non-volatile RAM

Stage 3, CP/M

Stage 4, RC2014 Ecosystem

  • Adding RC2014 connector

Video of Z80SBC64 running selected monitor commands and CP/M commands in real time

cpm22all.hex

CP/M 2.2 CCP/BDOS/BIOS

hex - 17.84 kB - 03/03/2019 at 13:05

Download

XMODEM.HEX

xmodem in Intel Hex format. save it as CP/M file with the command 'save 17 xmodem.com'

hex - 9.94 kB - 03/03/2019 at 13:03

Download

unarj.com

CP/M decompress program. the command is 'unarj e filename'

octet-stream - 12.00 kB - 03/03/2019 at 13:02

Download

CPM22DRI.ARJ

Compressed CP/M 2.2 executables. uncompress with unarj.com

x-arj - 65.53 kB - 03/03/2019 at 13:01

Download

Z80MB64_demo.mp4

Z80SBC64 in action. Real time execution of commands

MPEG-4 Video - 14.70 MB - 02/21/2019 at 18:02

Download

View all 13 files

  • Stage 3, Installing CP/M

    Plasmode03/03/2019 at 13:18 0 comments

    To support CF disk and CP/M, the ZMon64 monitor has several additional commands.  The monitor is tailored for a particular CP/M configuration which is four 8-meg disks as drive A/B/C/D.  The following is the disk parameter of each drive:
    Drive A:
    1024 sectors per track,
    4096 bytes per block ,
    track offset of 1,
    512 directory entries

    Drive B/C/D:
    1024 sectors per track,
    4096 bytes per block,
    track offset of 0x40 from previous drive,
    512 directory entries.

    To format a new CF disk for CP/M, the directory area of each drive must be filled with 0xE5.  The 'x' command of ZMon64 formats the specified drive.  The command to format drive A, B, C, D are retrospectively:
    xA
    xB
    xC
    xD
    Please note the drive letter must be in upper case.

    ZMon64 also has a command to read a CF sector.  The command is 'r' followed by track number and sector number in hexadecimal.  Based on the disk parameters, drive A's directory starts from track 01, sector 00, drive B's directories starts from track 0x40, sector 0x00, drive C's directories starts from track 0x80, sector 0x00 and drive D directories starts from track 0xC0, sector 0x00.  Each drive has 512 directory entries, so that takes 32 sectors.  Picture below is a screen shot of a console session where directory of drive B is displayed with 'r 40 00' command.  Drive B is formatted with 'xB' command, and directory displayed again which show all '0xE5'

    ZMon64 has two more commands related to CP/M: 'c' command to copy files into CF or RAM; and 'b' command to boot up a file.  For CP/M 2, the copy command is 'c2' and the boot CP/M 2 command is 'b2'.  Before executing the 'c2' command, the CP/M2 CCP/BDOS/BIOS must be first loaded in memory so 'c2' command can save it to designated location on a CF drive.  Both 'b2' command and CP/M2 warm boot access the designated location for CCP/BDOS/BIOS.

    I'm not going to describe the process of creating BIOS for CP/M2.  Having a working CCP/BDOS/BIOS that is installed in a formatted CF disk with 'c2' command, the next step is to transfer CP/M executable files into the newly formatted CF disk.  The file transfer program is XMODEM, so load XMODEM.HEX first then boot up CP/M2 with 'b2' command, then type:

    save 17 xmodem.com

    This will save the XMODEM.HEX image in RAM as a CP/M file called 'xmodem.com'.  The first CP/M file is now created on the CF disk.  Use xmodem to transfer the rest of files to the CF disk with the command:

    xmodem filename /r/c/z1

    Instead of xmodem each individual files, it is easier to compress a collection of files, transfer it over, and decompress in CP/M.  There are many such compress/decompress programs, the one I used is arj.exe/unarj.com.  CP/M2 executable are compressed with arj.exe; I first xmodem the unarj.com and compressed CP/M2 executable; then decompress it with unarj.com:

    unarj e cpm2

    Here is a screen shot of the series of operation to create CP/M files on a new CF disk.

    WIth CP/M2 installed, one quick benchmark to run is ASCIIART.TXT which should take 52 seconds to execute on a 22MHz Z80.  At the CP/M prompt, type:

    mbasic80 asciiart.txt

    The following should be displayed.

  • Stage 3, CP/M-ready Hardware

    Plasmode03/01/2019 at 14:59 0 comments

    While it is possible to have CP/M reside in system that has only non-volatile RAM, Most CP/M system have a mass storage device in form of floppy disk, hard disk, and/or flash disk.  The Z80SBC64 is designed with a compact flash disk interface.  The hardware addition is simple, just solder a IDE44 adapter to the CF interface and Voila, we now have the CP/M capability.

    CP/M software, however, is quite a bit more involved.  Fortunately a system integration guide for porting CP/M to specific hardware is still readily available from Internet.  http://cpm.z80.de/ is a well-know repository of CP/M for Z80 and other processors.  It is not my intention to provide a tutorial on porting CP/M to Z80, but I do want to describe certain CP/M related functions specific to Z80SBC64 in next project.

  • Stage 2 Hardware, Non-volatile RAM

    Plasmode02/28/2019 at 17:12 0 comments

    While loading a small bootstrap code serially is fairly easy and quick, but as the application software get bigger and numerous, the process of loading several software every power cycle or reset become tedious.  Fortunately the RAM has extremely low power consumption in standby voltage of 3V or less, so its content can be retained for a year or more with a button cell battery and non volatile memory controller.  In stage 2 of the hardware assembly, we'll add the button cell battery and install the non-volatile memory controller.

    The two jumpers in U6 are removed and replaced with DS1210.  A CR1220 3V Lithium cell is inserted in the battery holder as shown.  While it is not absolutely required, the voltage supervisor is also installed in this stage so we don't have to press reset button for every power cycle.

    Just because the RAM's content is retained between power cycles, we are not yet safe from having to load code over and over again.  This is because application codes like CP/M takes over the entire memory space and write into page 0 (0x0 to 0xFF) of the RAM.  To prevent the bootstrap code from being overwritten, we need to place it in a banked memory that's accessible at reset, but can be switched out and replaced with another bank.  As explained in the Theory of Operation, the 128KB RAM is splitted into four 32KB banks with bank 2 as the common memory always at the top 32KB and bank 3 located at lower 32KB at reset.  A bank select register can place bank 0 or bank 1 at lower 32KB under software control.  Z80Monitor has a command 'c0' that copies itself from 0xB000-0xBFFF into 0x0-0xFFF of bank 3 and switches out bank 3 and switch in bank 0 in its place.  So with the 'c0' command, Z80Mon make itself boot-able and hidden from other applications.  Other applications such as CP/M will have unfetter access to the entire Z80 memory space, but power cycle or reset will enable the bank 3 where Z80Mon is located and boot up with Z80Mon.

    We can zero out the entire memory (other than ZMon) with the 'z' command, but it will still boot up with reset or power cycling.  With bootstrap code safely protected from application software, we can now move the jumper to RAM bootstrap position and power up to Z80Monitor every power cycle or reset.

    Bank 3 has 32KB of storage, but only 4K is reserved for Z80Mon.  The remaining space can be used to store other application, such as SCMonitor.  This is what 'c1' command does.  It copies whatever program from 0x0 to 0x3FFF to bank 3 and 'b1' command restore the content of 0x0-0x3FFF from bank 3 and start execution from 0x0.  So 'c1' command saves SCMonitor, and 'b1' command boot up SCMonitor.  Bank 3 is effectively a non-volatile memory, but one that can be easily written.

    With the serial bootstrap capability and banked nonvolatile RAM, we now have a Z80 computer that can be reprogrammed from scratch at will, but yet retain its characteristics over reset and power cycling.  We are ready for stage 3 and tackle CP/M!

  • Running software on the minimal Z80SBC64

    Plasmode02/17/2019 at 16:22 0 comments

    I'm ready to apply power to the minimal Z80SBC64 hardware.  It needs 5V, 250mA power via 2.1mm x 5.5mm power plug, center is 5V, barrel is ground.  The serial port is wired to accept a CP2102 6-pin USB serial adapter.  Terminal software is TeraTerm set to 115200-N-8-1, no handshake.

    Power up!  

    The current consumption should be around 100mA, Z80 is tri-stated waiting for incoming serial data.  The first file to send is Z80SBCLD.BIN.  This is a 255-byte binary file that is a simple Intel Hex file loader.  Be sure to check the 'binary' option box of the "Send file" menu in TeraTerm.  The Z80SBC64 should respond with:

    Z80SBC64 Loader v0.3
    Auto start at 0xB400

    This means Z80 is alive and executing the Z80SBCLD program, current consumption should goes up to 140mA.  The bootstrap file loader is waiting for 2nd file and will start execution from 0xB400 upon completion of the 2nd file load.  Be sure to un-check the 'binary' option box because all subsequent files will be Intel HEX files.  The 2nd file to load is ZMON64.HEX.  This is a monitor/debugger for Z80SBC64.  After the 2nd file is loaded, it will start execution at the entry address of 0xB400 and sign on.  A 'h' display the help menu:

    >help
    G <addr> CR
    R <track> <sector>
    D <start addr> <end addr>
    I <port>
    O <value> <port>
    L <start addr> <end addr>
    Z CR
    F CR
    T CR
    E <addr>
    X <options> CR
    B <options> CR
    C <options> CR

    This monitor can display, modify memory, read/write I/O ports, zero or fill memory, load Intel HEX files and test memory.  There are other functions but working only when a compact flash disk is installed later on.  A 't' command will test memory and print 'OK' if memory is OK.  Any input keystroke will abort the memory test.  Picture below shows a monitor session.

    While this is interesting, there is a more sophisticated monitor, SCMonitor, that also runs on Z80SBC64.  SCMonitor is written by Steve Cousin and more information can be found on his website.  To load SCMonitor, send SCMon.hex to Z80SBC64, when file load is completed, type 'g0000' to start SCMonitor.  Refer to Steve Cousin's SCMonitor document for operating instruction.  Included in SCMonitor is BASIC 4.7b.  You can enter the BASIC program by typing 'basic'.   Picture below shows a short session with SCMonitor.

    This is all well and good, but where is the GAMES?  Well, I'm glad you asked because StarTrek runs in BASIC 4.7b.  Instead of cut-and-past the long StarTrek BASIC program into SCMonitor, there is an Intel Hex file of SCMonitor already with StarTrek program loaded.  So load up SCMonitor_Startrek and "Beam me up, Scotty"!!!

  • Z80SBC64 Theory of Operation

    Plasmode02/16/2019 at 16:41 0 comments

    Z80SBC64 has two modes of operation as determined by the Bootstrap jumper at power up (see the last picture of the previous project for location of bootstrap jumper).

    Serial Bootstrap

    At power up Z80 processor is tri-stated waiting for 255 bytes of instruction is be uploaded to the serial port (115200 baud, N81, no handshake) which is copied to memory starting from location 0x0. When the 255th byte of data is received and copied to memory, the CPLD state machine release Z80 to run from location 0x0.  The 255-byte code can be any software such as hardware diagnostic, but is normally a simple file loader to load more sophisticated application software.  In this stage, it is a simple Intel Hex loader, Z80SBCLD.BIN that loads a monitor/debugger and executes it at the completion of file load.

    RAM Bootstrap

    This is normal mode of operation.  At power up, Z80 fetches program from physical location 0 which contains the bootstrap monitor. The bootstrap monitor write-protect physical page 0 where bootstrap monitor resides. It then makes a copy of itself to 0xB000-0xBFFF and jump to it. Lastly the physical page 0 is replaced with logical page 0 which mapped to different physical page. This way the physical page 0 containing the bootstrap monitor is write protected and moved out of way. The application program will have unfettered access to all 64K space of the target processor.

    Memory Map
    Z80SBC64 has 128KB of RAM which is divided into 4 banks of 32KB each.  At any time only 2 banks (64KB) are accessible by Z80.  Bank 1 is always at the upper 32KB memory (0x8000-0xFFFF), it is the common memory that can not be switched out.  The lower 32KB can be switched between bank 0, 2, and 3 by writing 0x0, 0x2, and 0x3, respectively, to the bank register.  At reset the lower 32KB is always mapped to bank 3.  Bank 3 contains the bootstrap monitor code that copies itself to upper 32KB and switch bank 0 into the lower 32KB, thus protect the content of bank 3 from other programs.

    I/O Map
    Bank Register is located at I/O space 0x1F.  It is a write-only register, a read will get random value.  Only the least significant 2 bits of the Bank Register are used, the upper 6 bits are "don't care".  At reset the content of bank register is set to 0x3 which maps bank 3 to the lower 32KB.  Bank 3 is reserved for the bootstrap monitor and system software.  Writing 0x2 will map bank 2 to the lower 32KB of memory space.  Bank 2 is normally used by CP/M 3.  Writing 0x0 will map bank 0 to the lower 32KB of the memory.  Bank 0 is the default bank after the bootstrap monitor completes the booting process.

    Compact flash is located at I/O space 0x10-0x17.
    0x10    CF Data Register
    0x11    CF Error Register (read), Feature Register (write)
    0x12    CF Sector Count Register
    0x13    LBA Low, LBA(7:0)
    0x14    LBA Mid, LBA(15:8)
    0x15    LBA High, LBA(23:16)
    0x16    Device Register, LBA(27:24)
    0x17    CF Status (read) and Command (write) Register

    Serial port is located at I/O space 0xF8-0xF9.
    0xF8    Serial Status Register
        bit 0 is RxReady flag.  bit 0 is high when receive data is ready.  cleared to zero when the received data is read.
    0xF9    Serial Transmit (write) and Receive (read) register.  When write to 0xF9, TX pin of the CPLD is equal to the value of d(0) (bit 0) of the data.  d(7:1) are "don't care".  The serial port has no interrupt capability and no handshake.  It is hardwired to 8 data bit, 1 stop bit and no parity.  The baud rate is CPU clock /192.  e.g., 22.1184MHz CPU clock results in 115200 serial clock.

  • Stage 1 Hardware, Building A Minimal Z80 Computer

    Plasmode02/10/2019 at 04:47 0 comments

    In the first stage we'll build a very simple yet functioning Z80 computer with just 4 integrated circuits, plus resistors,  capacitors and hardware.  The bill of materials is included in the Files Section.  In stage 1 the following items will be assembled:

    PartNameSource
    U1Z84C0020PEGMouser 692-Z84C0020PEG
    U2EPM7064SLC44UTSource
    U3128Kx8 Static RAMMouser 913-AS6C1008-55PCN
    U422MHz oscillator
    R154.7K 8-pin SIP BusJameco 1970367
    R1-4, R8-9, R16
    4.7K, 1/8W
    C3-80.1uF bypass
    S1Push button SPSTJameco 149948
    J12.1mm x 5.5mm Power
    Jack
    Jameco 101178
    T343-pin header
    P21x6 right angle female
    header
    P32x5 header

    The pc board artwork is included in the FIles Section, so is the schematic of Z80SBC64 and the Altera EPM7064 programming file.

    Here are step-by-step pictorial assembly guides for building a minimal Z80 computer.  The order of assembly is based on the height of the components, the lowest components are soldered down first and the tallest last.  In the first picture, all resistors (4.7K), bypass capacitor (0.1uF), and SIP resistor (4.7K BUS) are soldered down.  Orientation of SIP resistor is important, pin 1 is marked with a black bar and oriented where the red arrow is pointed.


    In the second picture, the IC sockets are installed as well as the 1x6 serial port header.


    In the third picture, the PLCC socket is installed.  The orientation of the socket is important, the beveled corner should be placed where the red arrow is pointed.  1x3 jumper block (T34), 2x5 programming header (P3), push button (S1), and 2.1mm x 5.5mm power jack (J1) are also installed. 


    The fourth picture shows the solder side of the pc board.  Because the reset supervisor, U5, is not yet installed, a 4.7K pull up resistor from nRESET to VCC is required to negate the nRESET signal.  Please note, U5 may be optionally installed in this stage.  If U5 is installed, then the pull-up resistor is not required. 

    The 1st stage assembly is now completed.  The board should be cleaned with isopropyl alcohol and dried before installing components.



    In the fifth picture the Altera EPM7064SLC44 is installed.  Observe the orientation of the part, the beveled side with dimple in the middle must be aligned with the red arrow.  Program the EPM7064 with USB Blaster, line up the pin 1 of USB Blaster cable (red strip) with the pin 1 of 2x5 header (pointed by a red arrow).

    The last picture shows how the remaining integrated circuits are installed.  Observe the orientation of the components.  Also install the jumper to 'serial bootstrap' position as shown with a red arrow.  Install two jumpers across pin1 & pin8 of U6 and across pin5 & pin6 of U6.  The board is now populated and ready for power.

  • Introduction to Z80SBC64

    Plasmode02/09/2019 at 01:21 0 comments

    The z80 design is based on Z80SBC64, the '64' refers to Altera EPM7064, but as many Z80 SBC that must had been built over the years, this can easily be the 64th Z80 SBC.  The current trend in low chip-count Z80 SBC is using another processor to provide bootstrap function as well as I/O functions for the Z80.  Such dual-processor architecture requires complex software interaction between the two processors, and the combined throughput of the two processors are less than the throughput of any one of the processors, so it feels like stepping backward in performance and the hardware/software seems harder to comprehend and to modify.  I prefer the traditional computer architecture where Z80 controls everything around it but does it faster and with fewer chips.  The key is using programmable logic instead of TTL logic, but instead of the expensive FPGA that requires 5V-to-3.3V translation, using the low-cost 5V complex programmable logic device (CPLD).  Furthermore, the CPLD has sufficient logic to implement an unusual feature, serial bootstrap, that uses serial port to load the traditional ROM code in RAM resulting in a ROM-less computer.  The ROM-less design eliminates the hassle of ROM programming and further reduces the chip count resulting in a small 2" x 4" pc board.

    The original design was prototyped with Altera EPM7128S CPLD, a 100-pin surface mount device that is difficult for most hobbyists to assemble.   Further design refinements allow the final design to fit in a EPM7064S as 44-pin PLCC package.  By hosting the PLCC device in a through-hole PLCC socket, the pc board can be assembled by most hobbyists.  The final Z80SBC64 design is proven with successful construction and operation of 10 or more boards.

    The four-stage approach is originally conceived to simplify the assembling and testing process where the partially assembled board can be functionally tested in each stage.  This approach is particularly suited for hobbyists putting together a new board.  It is reassuring to take baby steps and verify things are working in each step.  Another issue is parts ordered may not be available or delivered, but we like to play with the partially assembled system without all the parts.  Furthermore, I believe the learning process is enhanced as limitations and capabilities of the computer at each stage are explored and we learn how new features added in next stage enhances the existing capabilities.

    Each of the 4 stages are breakdown into hardware phase and software phase.  The hardware is the assembly phase, and the software is the testing and exploration phase.  The computer is functioning at each stage and gains sophistication as the assembly progresses.  It is not necessary to finish all 4 stages of assembly.  The computer is functioning and may be perfectly suited for certain applications without reaching the end of stage 4. 

    Here are brief descriptions of the four stages:

    • Stage 1, minimal operating Z80, runs native monitor, SCMonitor, BASIC programs, games
    • Stage 2, software are preserved between power cycles, banked memory hardware protects system software from application software.
    • Stage 3, compact flash interface and CP/M
    • Stage 4, RC2014 expansion bus, interface to RC2014 compatible boards

    While the board is capable of 22 MHz operation, it is not necessary to run at 22Mhz.  If only slower Z80, RAM and oscillator are available, it is perfectly fine to run the board at the lower clock frequency.  The serial port baud rate is directly determined by the CPU clock, the table below show the relationship between clock frequency, serial baud, and RAM speed:

    Clock Frequency
    Serial Baud
    RAM access time
    22.1184MHz
    11.0592MHz
    7.3728MHz
    3.6864MHz
    115200
    57600
    38400
    19200
    55ns
    120ns
    slow RAM
    slow RAM

View all 7 project logs

Enjoy this project?

Share

Discussions

Plasmode wrote 11/13/2020 at 00:17 point

Hi Assif,

OK, I'm back. 

The Z80 RESET low is not a good sign.  It should be low when you press the reset button, but goes high when released.  Since you don't have the voltage supervisor installed, you should've install a 4.7K pull up as shown in this photo: https://cdn.hackaday.io/images/2713781549836203800.jpg

Since you have a scope, the signal you may want to monitor is Z80 pin 25, BUSRQ.  At power up, CPLD will hold BUSRQ low.  As soon as it has received 256 bytes of serial data, it will release BUSRQ so Z80 can start execution.

The small file 'Z80SBCLD_r03.bin' is a binary file, so be sure to send it as binary.  In TeraTerm Send file menu there is a 'Binary Option' box that need to be checked.  You should see the message: Z80SBC64 Loader v0.3
Auto start at 0xB400


  Are you sure? yes | no

Assif wrote 11/13/2020 at 09:23 point

Hi Bill, thanks for the tips.  

I've gone through and double checked these points this morning.  I think this may be at least partly measurement problems by myself.
I have remeasured the voltage drops without any ICs installed.  I am getting 5V across C3.  But I couldn't see 5V across the two pins of the barrel jack. ( this was the source of the issue I think because whenever I use the barrel as ground for my multi-meter I don't get a good connection.)  But using a ground point on the board instead I get 5V across the pull-up and 5V at Z80pin26.  This drops to 0V when the button is pushed.  All good.
I installed the ICs and got the same - so maybe it was a measurement problem? I don't know because I had checked that on the scope ...

Now, I'm not able to use the scope yet, as I need to relocate to my shed - and I'm supposed to be at work! But the multi-meter shows that Z80Pin25 is at 5V.

What I am wondering is that maybe the nBUSRQ starts low and then gets pulled up - maybe the counter is counting noise on the power?  I did see a LOTof 50Hz noise on the scope when I used it before.  I will trigger on reset and see if I can establish what is happening.

I will re-check all of these things tonight and try to give you a better picture of what is going on. 

Thanks very much for your help so far!

kind regards,

Assif

  Are you sure? yes | no

Plasmode wrote 11/13/2020 at 13:00 point

Assif,
You should visually inspect all your solder joints.  Your cell phone camera is a great inspection tool; you can rest the phone on a solid block and carefully take pictures of your board without moving the phone; and then zoom in to look at each solder point.  Send me pictures of top and bottom and I can help you inspect.

50Hz noise is an indication of poor ground that you are picking up your powerline emission.

  Bill

  Are you sure? yes | no

Assif wrote 11/14/2020 at 11:06 point

Hi Bill, great progress to report.  

I cleaned everything up as much as possible with alcohol and cloth, and had another go.  Reset is now working as it should, going low only when the button is pressed.  And BUSRQ starts low and stays low.

Then when I send the boot-strap file (Z80SBCLS_r03.BIN) as binary the BUSRQ goes high!

But there is no response (ie.e no message in TeraTerm) from the board.

Looks like I've moved the problem elsewhere.  I might start monitoring more pins at the Z80 (data/address) and see if I can see any activity.

I'll also see if I can get my cheap 8-bit data logic analyser on the case.

kind regards, and thanks as always.

Assif

  Are you sure? yes | no

Plasmode wrote 11/14/2020 at 12:50 point

Assif,
Since BUSRQ is behaving correctly I believe the CPLD is programming correctly and likely to be working as designed and the serial port receive is connected correctly.  Good.  Now the question is whether the 256-byte instructions sent to the serial port is transferred to RAM and whether Z80 is able to execute these instruction correctly.  It is even possible that everything is working correctly except data coming out of the serial transmit is not received.

You can use BUSRQ going high as the trigger and examine the Z80's MREQ (pin 19) and IORQ (pin 20) which are the 'heart beats' of the Z80.  I expect continuous activities on MREQ, it should toggle ever 100-200nS as it executes instruction.  IORQ is less active; initially it goes low once every 8uS immediately after BUSRQ going high; then it settled down to going low once every 1.5uS.

It is also possible that 22MHz is too fast for your hardware.  You can also try with slower oscillator such as 11.05MHz, 7.37MHz, 3.68MHz or even 1.84MHz.   With a slower oscillator you need to lower the serial baud; so 57600 for 11.05MHz oscillator, 38400 for 7.37, 19200 for 3.68, and 9600 for 1.84.

  Bill

PS, I saw your photos.  You used a little too much solder, but they should be OK.  The solder around the power jack looked 'cold'.  I would fill the holes with solder to get better mechanical strength so not to break the solder joints plugging in the power plug.

  Are you sure? yes | no

Assif wrote 11/14/2020 at 14:45 point

(sorry I don't seem to be able to reply to your most recent message)

examining MREQ, there is a lot of activity on there after the file is transmitted, but it is not ~200ns, more like every 4 clock cycles (7.2MHz).  IRQ is high mostly and goes to 0 every ~100ns 

So that seems wrong.

I have swapped out the memory (as a new chip arrived this morning)  but it is as before.

I can't swap out the Z80 - I purchased a couple, but I don't think they are 20MHz rated.  (They were labeled Z80CPB1 - the seller said 20MHz but I don't believe them - it got hot very fast)

I think my next step will be to down clock the board. I don't have any other oscillators (except a 1mhz one - lol) so I will have to get creative and use a counter to step it down.

I'm sure this isn't the best way to keep you updated with progress, but I can't think of another - so, I will update again when I have made any significant progress.

But for now, thanks,

Assif

Edit: SUCCESS!

I have clocked it down to 11MHz and ... it works!

The hack, is in the shared album Bill, it may give you a chuckle.

  Are you sure? yes | no

Plasmode wrote 11/14/2020 at 15:34 point

All right!  Looks like a reasonable hack to me--I've done much worse.  CMOS Z80 should not get hot at 22MHz, so your Z80 is most likely NMOS and running 11MHz for NMOS Z80 is pushing it a bit.

  Bill

  Are you sure? yes | no

Plasmode wrote 11/12/2020 at 12:41 point

Hello Assif,

I am happy to work with you debugging your board.  I do have a few pressing tasks I need to take care this morning.  I'll get back to you for more details in 12 hours.

  Bill

  Are you sure? yes | no

Assif wrote 11/12/2020 at 22:46 point

Thanks Bill, very much appreciated.

  Are you sure? yes | no

Assif wrote 11/11/2020 at 23:22 point

Hi - first I'd like to say thank you for this is a well put together idea and an inspiring project.  So much so that I went for it and got the PCB printed and sourced all the parts I did not have.

I have since built the board and populated it as per the steps outlined in the hardware build.  However, I was not able to get a response from the board after the boot-loader was sent over the serial.  So, inevitably, I am seeking advise and hoping I can get past this hurdle.

So far I have; made sure that I can see 5V across the capacitors (without any chips in), can see on a scope that the oscillator is generating 22.1184MHz and visually inspected and tested continuity as much as possible.

I got hold of Quartus II v9.0 and (with only the PLCC installed), connected the USB Blaster and loaded the design file (Top.pof). Quartus told me it was all OK.  Phew!

Then I populated all the chips (except the voltage supervisor, battery backup and ram control chip) -  and set the jumper to bootstrap and also pulled the reset switch pole high with a resistor as in the instruction.  I connected the USB serial (connecting just Gnd, Tx and Rx - crossed over), set the port to 115200-8-1, and sent the bootstrap code.

But, I sadly got no response from the Z80.  

I then went through each pin of the Z80 on the scope, and found one unusual thing - that the reset pin 26 was being held low.  I'm pretty sure that the PLCC is supposed to control that pin and pull high on reset. But it doesn't seem to.

Unfortunately I have no idea where to go from here.  I really don't know which part could be faulty. Short of getting replacement parts and trying them out I have run out of ideas.

So, here's hoping someone can give me some pointers and help me out - maybe there are some other diagnostics I could do?

Many thanks!

Assif

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates