Processor Interface

Got a question Guys!

I'm diddling with a Z80 CPU with a half-baked idea of building a low budget Z80 computer (one of the many shiny things that keep from me from completing much of anything :-( ).
The question... While testing, I'd like to use a Basic Stamp to supply the Z80's clock frequency. Can I output a BS2 waveform directly to the Z80 clock pin or would I need some same of interface?

Thanks for any wisdom!

@
Founder of the "Society for Aimless Tinkering and World Conquest"

Comments

  • 13 Comments sorted by Date Added Votes
  • Directly from the Stamp to the Z80 should be fine. Running it to other chips increases the loading so at some point a clock driver will be needed.
    In science there is no authority. There is only experiment.
    Life is unpredictable. Eat dessert first.
  • It sounds a fair idea. I think the z80 is still an incredibly capable chip, especially with the cmos 20MHz variants. There seems to be a few projects out there for z80 based single board computers. I have a few of the early maplin boards. I suppose you could use a signal generator set to square wave, but a stamp is an awful lot cheaper.
    I'm interested to see how you get on.
    regards john
  • One problem with the Stamp is that it does not have a command that will output an arbitrary square wave frequency. The FREQOUT command generates a sine wave (based on PWM).

    What frequency do you need? There are so many little packaged oscillators available that cost about a buck, pick your frequency. And doesn't the Z80 have a crystal option?
  • One problem with the Stamp is that it does not have a command that will output an arbitrary square wave frequency. The FREQOUT command generates a sine wave (based on PWM).

    What frequency do you need? There are so many little packaged oscillators available that cost about a buck, pick your frequency. And doesn't the Z80 have a crystal option?

    IIRC the original Z80 required an external clock signal. Later versions may have had an on chip oscillator that only required a xtal but I am not certain about that. Too much time has passed.
    In science there is no authority. There is only experiment.
    Life is unpredictable. Eat dessert first.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 21,223
    edited April 25 Vote Up0Vote Down
    The other problem with the BS2 is that there's no command that will output a waveform indefinitely. And doing it by a software loop would be too slow. The Propeller could handle the job easily, though.

    -Phil
    “Perfection is achieved not when there is nothing more to add, but when there is nothing left to take away. -Antoine de Saint-Exupery
  • The propeller would be a better choice, and having control over the Z80 clock frequency and all those cogs would be a big help with debugging hardware and software.


    In science there is no authority. There is only experiment.
    Life is unpredictable. Eat dessert first.
  • Just in the testing phase right now. A clock frequency somewhere around 1kHz-ish would be fine.
    I only thought of using the Stamp cuz I'm too lazy to wire up a 555. :-|

    @
    Founder of the "Society for Aimless Tinkering and World Conquest"
  • ercoerco Posts: 18,405
    edited April 27 Vote Up0Vote Down
    ajward wrote: »
    Just in the testing phase right now. A clock frequency somewhere around 1kHz-ish would be fine.
    I only thought of using the Stamp cuz I'm too lazy to wire up a 555. :-|

    Stamp: $50
    555 timer: 4 cents http://forums.parallax.com/discussion/comment/1393138/#Comment_1393138

    Just sayin'.
    "When you make a thing, a thing that is new, it is so complicated making it that it is bound to be ugly. But those that make it after you, they don’t have to worry about making it. And they can make it pretty, and so everybody can like it when others make it after you."

    - Pablo Picasso
  • I have a little stack of SMT 555 breakouts prewired as square wave generators which were shipped by mistake when I ordered a set of HX711 ADC breakouts. When I informed the seller of the mistake they went ahead and sent me the HX711's and said keep the 555's.
  • ercoerco Posts: 18,405
    "When you make a thing, a thing that is new, it is so complicated making it that it is bound to be ugly. But those that make it after you, they don’t have to worry about making it. And they can make it pretty, and so everybody can like it when others make it after you."

    - Pablo Picasso
  • ajwardajward Posts: 1,074
    edited June 3 Vote Up0Vote Down
    A bit of progress on my Z80 activity. Started wiring the CPU and and connecting an 74LS244 octal line driver to the address lines. Using this small-ish breadboard, I quickly realized "You're gonna need a bigger breadboard!!".
    Bought an Elenco board with over 3000 tie points. Even with this, I'm going to keep some sections off the main board. Initially at least, the power supply, clock generator and address line LEDs.
    To start, all data lines are tied low to load an NOP instruction to all the accessibile memory locations. (Non-existent at the moment) Moving forward I have some 32K ram chips to try to integrate.
    Edit: I'm going to need to use 2-74LS244 chips to handle the 16-address lines. (Off to another breadboard).

    If anyone has experience with something like this, I'd appreciate you sharing your wisdom!
    My goal is to kinda simulate the Altair 8800... I used to own one and foolishly traded it away. DOH!
    900 x 675 - 215K
    Founder of the "Society for Aimless Tinkering and World Conquest"
  • Hi Amanda,
    Haven't seen you around for a while.

    There has been a number of projects using a prop to do a lot of the glue for the Z80 including loading up the RAM as ROM, and using the prop as an I/O device on the Z80 bus as well. Try the RetroBrewComputers forum and wiki for more info. Dr_Acula has done some work on this too.

    Or of course you could just use a prop with ZiCog - see my RamBlade link in my signature for the hardware (prop, eeprom, sram, glue gate and microSD. Cannot get much smaller than this matchbox ;)
    My Prop boards: P8XBlade2, RamBlade, CpuBlade, TriBlade
    Prop OS (also see Sphinx, PropDos, PropCmd, Spinix)
    Website: www.clusos.com
    Prop Tools (Index) , Emulators (Index) , ZiCog (Z80)
  • An update... after a few weeks of tinkering with my Z80 things are starting to come together (kinda).:-)
    Obviously, all this was fueled with liberal amounts of caffeine, adult beverage and colorful language.

    I jumped right into the project without a lot of research and started wiring things up with the first info I found... bad move! :-|
    Also started out with a 555 Sq wave generator picked up on eBay, For some reason it put out a really raggedy signal. Sucked it up and built my own that works just fine (Adjustable from 1 thru ~45Hz).

    Right now, I have all 8 data lines tied to ground to effect a NOP instruction. The 16 Address lines are connected to green LEDs through some 74LS244 driver chips. Pulled out 5 status lines to LEDs... left to right M1, Mreq, Rd, IOrq and Wr.
    The small breadboard to the right is my single-step circuit.

    Also wiring up a 62256 - 32K static ram module. Waiting for some decoder and latch modules to integrate the ram and future rom.

    https://www.flickr.com/photos/81065424@N00/34874306154/in/dateposted-public/
    Founder of the "Society for Aimless Tinkering and World Conquest"
Sign In or Register to comment.