[edit] - ( see below for the previous stuff )
.. and "because I need a loader" ( or something ) then the "idea number 2"
( in reality in plan since beginning ) came out.
"Let's use two spare bits to implement a serial port".
So take a 3 state buffer and a level converter and voila' all you have
to do is to write some software polling those bits and doing things ...
Because this kind of stuff in the past was "my speciality" ( like to
implement protocols on stuff not done for communications at all )
that thing "it has to be done" came in.
.. the amount of swearing, nuttyness and all this SW made me .. well ..
.. a bit beyond what I was expecting ..
Actually .. I had only 3 bugs .. and it's a definitive proof that "coding
for fun" during the night aroun 1.00 AM before to go bed and such is
not totally sane nor devoid of risks.
So it took me two days to find out :
- a semicolon in a place that had not to be
- that "bit 7 reset" is 7FH and NOT EFH
- consider the baudrates can have a certain error and are not uS precise
I should also add that "dump on the screen should take for account of
non printable carachters that are there but that you can't see with a print"
After lot of swearing, oscilloscope and such .. here .. in all its glory ..
And that cable goes connected to the glorious VT220
Now you have a kind of "mini shell" ( that is studied also to be
"simple" so to allow me to write a PC "uploader" program ).
All the idea was to have a "minimalist system" that can do "cool things".
So the "shell" supports those commands :
Insert byte(s) starting from address <address>
I <address> <byte> [byte] [byte] [ .... ]
Display Hex/ASCII dump starting from address <address>
Z <address>
Jump and run code at <address> ( RET brings back to shell )
J <address>
And that's it, here a screenshot
Now the final thing is .. that unforunately I did not manage to reach
"goal 0" so I had to go for "goal 1".
Remember all this is made by sampling a bit, it communcates in
Half Duplex mode at 9600 Baud, 8 Bits, Parity None, 1 Stop bit and
you need to use local echo ( for now ).
All the code is "with counted clock cycles".
It handles buffer overflow and backspace too.
Now the "goal 0" was 256 bytes .. I failed it but I am withing "goal 1"
all this program fits in
452 bytes( so less than 512 ), I mean really
everything including the welcome message and such.
Now I have something "interesting" to play with a quite a nice set of
"bios routines" debugged I can work with
Next, shell 2.0 probably
== original post follows ==
I finally made it
So .. "back in the days" ( 1984 or so ) I think everyone at some point
dreamt/said "one day I'll build up my small computer" ...
Lot of ideas/things sketched on papers during the nights ... always for
one reason or another ending up in "one day I will .. ".
So two weeks ago .. it was there on ebay .. we were fixing all those old
consoles and such and I tought "well, we could make some cartridges too "
and "ok fuck off, take those 25 pounds" I bought an Eprom/Flash/Pic a bit of mix programmer.
Then I had that box with those OLD chips .. SO long time those chips been
collected a bit there and there and been there .. waiting .. or just getting
dust with time passing by ..
I had this piece of board .. a bit of things on the desk .. so two nights ago
"just for fun" I tried to put together a 4 Mhz clock oscillator, despite it
may seem "a silly frequency" let me tell you it's NOT .. not really so silly ..
After two nights of fiddling it was looking a reasonably good wave ..
But still "the impulse was not there" ..
But then .. I was looking at it .. and thinking .. and .. "well .. maybe I could
put together this chip and that one " ..
Sunday .. after 20 years or so .. "something clicked right" .. after a
previous night of a bit of sketching while "meditating" I had this mad
idea to start doing this thing "a little piece at time" testing part by part
as it was going ..
I did not know what I was going into but at some point I was in that
"full electronics love mode

" .. I've been soldering and testing stuff
on my desk for 12 hours solid without moving .. every piece that I
was putting up was tested ..
All done "with just all I had in the desk" .. most notably that "crap red
wire" that is multi-pole TINY wire I had to piece by piece to strip just using scissors
( I don't have a cable stripper for that ) and all made by hand ( I don't have small pliers ) ..
Literally those moments "I can't eat, I can't drink I can't sleep, it's just the love .. ".
So after 12 hours .. it was finished .. but there was a problem .. I don't
have yet a proper UV lamp so I was trying to use another PCB UV lamp
I have to clean that 2764 .. it did not work well but I found out the upper
4 Kb of ram was still blank by its own so with a trick I "shifted" it one
page and I overprogrammed .. it worked ..
And then .. the moment of truth .. will all that mess of wires work ?
YES IT WORKS !
So what's all this thing about ?
Here my MINI Z80 computer system, it could have been done with one
chip less but I was missing another 74LS138 so I did a thing with a
couple of OR/NOR ports.
Specifications :
CPU Z80A 4 Mhz
CLOCK 4 Mhz
ROM 8K ( 4K in this moment )
RAM 8K static ram
1 8 bit I/O port
( will be added a serial port using 2 bits left )
here in its beauty :
Top view ( looks nice )
Bottom view ( looks a mess

)
That foil is to shield the high freq part of the oscillator.
It's actually running this code happily
Code:
;
; Test program to see if the CPU works
;
DI
LD A,0
;
LD SP,2400H
;
Main:
LD DE, Segtable
LD C,16
;
OutSeg:
LD A,(DE)
OUT (254),A
;
LD HL,0
Delay:
DEC HL
LD A,H
OR L
JR NZ,Delay
;
INC DE
DEC C
JR NZ, OutSeg
;
JR Main
;
Segtable:
DB 40H, 79H, 24H, 30H,19H, 12H,02H,78H
DB 00H, 10H, 08H,03H,46H,21H,06H,0EH
Here one more pics with some details
Useless ? Weird ? Nonsense ?
It does not matter, this is a thing that for 20 years I said "one day I will .. "
and finally .. it's HERE .. I've done it !
Now I feel SO happy .. wow .. I can say "I can do it"
The most important thing to me is that this is a dream I always had
and now it's true, I can make it all better but the thing is "it's not a dream
any more"..
I'd never imagined that one day I would have done it "all in a day"
I feel SO happy .. maybe it's "silly happiness" but to me it's lot
It's really
