Setup DSLogic Plus DSView v1.1.2 for Z80 ======================================== LOGIC ANALYZER CONNECTIONS: (Z80 signals ON PROCESSOR) Name Pin 1 DO 14 black 2 D1 15 brown 3 D2 12 red 4 D3 8 orange 5 D4 7 yellow 6 D5 9 green 7 D6 10 blue 8 D7 13 violet 9 /M1 27 black 10 /RD 21 brown 11 /WR 22 red 12 /MREQ 19 org 13 /IORQ 20 yellow 14 /INT 16 green 15 blue 16 violet OTHER SIGNALS OF INTEREST: /INTD dart PIN 5 (SHOULD BE SAME AS CPU /INT) IE1 dart PIN 4 (SHOULD BE +5) TO ENABLE INTR CHAINING RXDB dart PIN 28 SERIAL INPUT TO B CHANNEL TXDB dart PIN 26 SERIAL OUPUT FROM CHANNEL B UART Now we can setup some of the features in DSView. start the program called DSView... Click ignore on the popup document window 1) Clear current setup. Top menu: File | Settings | Default 2) Top menu: Options button. Set the following options: Operation Mode: Buffer Mode Stop Options: Upload Captured Data Threshold Level: 1.0V Filter Targets: None Max Height: 1X Next 3 items not checked Channels: Use Channels 0~15 (Max 100MHz) Lets make the display pretty by assigning trace colors. 3) On the far left side, choose the grey block beside channel "0". Choose colour from the left bank of choices, (light yellow) (do this for the first 8 items which will become the data bus lines.) now for 8-12 pick another color (light blue) for the control signals for 13 and 14 pick another color (bright red) for our trigger signals Lets define what are signals are. 4) On the far left side, choose "0" beside the grey block you recoloured earlier, and type "D0". Continue labeling all the signals. (D0,D1,D2,D3,D4,D5,D6,D7,/M1,/RD,/WR,/MR,/IO,/INT,ODF,15) In the Z80 decoder window, we need to match up the decoder signals to the analyser lines we just defined. 5) Top menu: Decode | Protocol | Drop-down | Z80 (at the bottom) Right-side top area: Protocol | + this should display a menu of decoder options. Observe values in the list. Defaults are: D0 to D7 /M1 /RD /WR /MREQ /IORQ A0 to A15 click on the Z80 Address bus eye symbol to disable it. Now you can click on D0 and select D0 from the list you have started to create. Repeat for the first bunch until D7 matches D7. Now you will need to use the scroll bar to see more line options. Now assign /M1,/RD,/WR,/MR,/IO. You dont need to assign any address lines as we are not monitoring them in this setup. You can now click on OK to close the Z80 decoder options window. 6) We're almost ready to start. At the top left of your screen beside the crossed tools Option icon, you should see a drop-down list for Duration (it's not labeled Duration): choose 2.00ms. The longer the timer interval, the longer you'll have to wait for the right side and top data area to complete their decodes. This selection will save 2ms worth of transitions around the trigger point. The field next to the duration is the sample rate and should be changed from 1MHz to 4 to 10x our expected signal frequencies. For a 4MHz Z80, a good sample rate is 20MHz. We need to set the trigger signal. There are several trigger choices including positive-going, high level, low-going, low level, and edge trigger. These are the symbols next the pin definitions on the far left of the screen. For now, select the 3rd symbol on the /INT line (falling edge). 7) At the top of your DSLogic Plus screen, click the Start button. You will notice a medium-sized graphic in the screen center that indicates it's waiting for the trigger. Now run the Z80 program. Do whatever you need to do to generate an interrupt signal to the Z80. You specified 2ms so you should have got 2ms worth of "trace" when the graphic briefly turns green in colour to indicate it was successful in buffering the data. In the upper right corner you'll see see a new item under Protocol. It will show "100%" in green indicating it has finished decoding the buffered "trace" completely. If you choose a very high time duration value, you may have to wait a while for the decodes to complete. If all went well then you'll see the operand hex values in green below the top menu and above the channels. Just below them will be the decoded operands in purple. If you can't really see what I described, it's because we'll need to zoom in on the display. The app should already have moved to the trigger, the /INT channel going low. At the very bottom of the screen, move the slider ever so slightly to the right so that the trigger marker moves to the left. You could also use left-mouse click and drag to do the same. With your mouse clicked on the display near the trigger, use the mouse wheel to slowly expand the time frame so you can start to see the operand hex and the decoded data. 8) This would be a good time to save your configuration: File | Settings | Store and give it an appropriate name. It will be stored with a .dsc extension. Now you know what to load up if you lose or change your configuration. Since we tied line 14 to an I/O port decode at address 0DFH on my CPU card, we can use this as a trigger line. The signal will go low whenever the Z80 executes an OUT 0DFH instruction. By inserting these output instructions in our code, we can see what is happening around the time the out instruction was executed. Its not exactly a hardware breakpoint, but by looking at the data on the databus and the decoded instructions, you can see what instructions are executed and what data is moved on and off the bus.