Sunday, June 3, 2012

CHED - Update

Project CHED (Combined Hardware Emulated Drives)

It has been a while since I have worked on the hardware part of this project. A few months back I hit a stumbling block. The load on the microcontroller was too great when bit-banging the serial output and at the same time handling all the other tasks. To free up the controller I added a parallel to serial FIFO chip. Even though the bitsteam generated by CHED looked correct I was still unable to the get the virtual master disk to boot. With the tools I had at my disposal I was unable to pinpoint the cause of the problem. The logic analyser I was using was capable of high speed captures and was great for viewing the 16 bit data bus but it had a shortcoming. The buffer was too small for analysing data that had high frequency bitstreams on one channel but low frequency ones on another. The analyser software was also limiting when analysing non popular protocols. By changing a few settings on the standard serial protocol analyser I was able to get it to produce some promising results. Unfortunately only a few dozen bytes get converted before it looses the plot and produces invalid results. Some better tools were required if I were to continue.



I sourced a new analyser. It's not as fast as the other but high speed is not required when dealing with Apple II signals. The great thing is that it is not limited by its own memory. It uses a connected computer to store the captured data. The downside is only having eight channels but that should be enough for this project. The reason I selected this package was because of its great software development kit (SDK) that allows you to create custom protocol analysers. Using the examples provided it was not too difficult to create the AppleIIDiskII protocol analyser. Being able to the record the entire boot process was a fantastic sight to see. Seeing the results is one thing but interpreting the data is another. The data frame processing of the SDK is yet to be fully developed so my best option was to export the byte stream and process it myself.



I generated a simple Microsoft Access application to process the data and produce a sequential view of the information that is read by the Apple II. These two tools have given me a better understanding of what is going on. So far I have only captured the data from a real DOS3.3 master disk booting. I have yet to use these tools to diagnose my own device.



For those of you who wanted screen captures of the DiskII protocol I can go one better. You can download my tools and have a look at the data yourself. You will need :-

1. Saleae Logic 1.1.15 software from here http://www.saleae.com/downloads (no licence required to view data). 

2. CHED_MasterBoot.zip from here https://docs.google.com/open?id=0B5PVarmqxaOnUGJINWd4N2RsRkk. File contains :-
    a. Instructions.txt - Instructions on getting started.
    b. AppleIIDiskIIAnalyzer.dll - DiskII Protocol for the Saleae Logic analyser.
    c. MasterBoot.logicdata - Captured data from a real Apple II master boot disk. View using Saleae Logic 1.1.15 software.
    d. DiskIIDataStreamProcessor.mdb - Microsoft Access 2003 application for processing and viewing the DiskII data stream. You will need MS Access 2003 or above to run this application.

There is still plenty of work to be done. However, I am currently looking into another platform which, if it works out, could fast track CHED's development.