Shop OBEX P1 Docs P2 Docs Learn Events
Propeller and a microprocessor — Parallax Forums

Propeller and a microprocessor

jaegjaeg Posts: 156
edited 2011-04-07 20:11 in Propeller 1
http://mini-altair.tripod.com/Version1.html
In that link someone has loaded a bootloader into a processors ram using a pic. I'm assuming this can be done with a propeller (while also possibly using it to display video for the computer). Now to my actual question. I'd like to have more that 32k loadable into the ram how can I do this?

Please note this project is just for fun and really has no practical use.

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2011-03-22 20:45
    Assuming that you want to use the Propeller to load the RAM of the 8085 or other processor, it certainly can be done. The Propeller can be used as a display controller as well. It mostly depends on the number of I/O pins used to control the RAM. For a 64K parallel RAM, you'll need 16 I/O pins for the address bus plus maybe 4 I/O pins for the control lines. Depending on how you need to hook up the RAM, you may need another 8 I/O pins for the data bus or maybe you can multiplex the data bus with 8 bits of the address bus.

    Loading more than 32K into the RAM is a problem if you want to load the RAM from the Propeller's RAM. There are other ways. You could attach an SD card and copy the data from an SD card file to the RAM. You could use a larger EEPROM on the Propeller, like a 128Kbyte device and use half of it for the data to be loaded in the RAM.
  • jaegjaeg Posts: 156
    edited 2011-03-22 20:54
    Thanks for the response. If using a 128kb eeprom can I load it from the propeller software? One of the reasons to try to use a propeller is to avoid having to use an eeprom programmer while also using the propeller as a video generator.
  • Mike GreenMike Green Posts: 23,101
    edited 2011-03-22 21:10
    You can't load the extra EEPROM using the Propeller Tool or BST, but there are some utility programs that you might be able to use or you can write your own. There was one for loading .WAV files into EEPROM for playback and Catalina (a C compiler for the Propeller) has a loader for loading external SPI flash that you could modify. There are XMODEM, YMODEM and KERMIT receive programs that could be easily modified as well.

    The existing EEPROM libraries can handle any size EEPROM as well as multiple EEPROMs on the I/O pins used for the Prop's boot EEPROM and EEPROMs on other pairs of I/O pins.
  • Heater.Heater. Posts: 21,230
    edited 2011-03-23 00:25
    jaeg,

    What an excellent little project you have linked to. Good to see another 8080, Altair, CP/M enthusiast here.

    When I first discovered the Propeller I was on the verge of building myself a little 8085 system like that, my own Altair.

    Then I found the Prop and realized I could use it as a boot device, as in the linked project. Not only that it could soak up a bunch of peripherals like the UART, the video and the disk storage (On SD card). All you need is the 8085, some RAM and a Prop.

    But then it hit me. Whilst learning something about PASM I ended up creating an 8080 emulation to run on the Prop. Wow, now I only need the Prop, some RAM and an SD card!

    And there started a long journey which included getting all the original Microsoft BASICs running on the Propeller, then CP/M 2.2 using an SD card, then WordStar, then the BDSC C compiler etc etc.

    The 8080 emulation of the original PropAltair grew into a (almost) full emulation of the Z80, quite a bigger task.

    Recently PullMoll on this forum wrote his own Z80 emulation which is 100% accurate. That led to such things as the complete emulation of a NASCOM Z80 computer.

    Here is the long history:

    Zilog In a Match box: http://hackaday.com/2009/12/27/zilog-in-a-matchbox/

    PropAltair: http://forums.parallax.com/showthread.php?101495-PropAltair-CP-M-operating-system-for-Propeller-anyone

    ZiCog, a Z80 in a Cog : http://forums.parallaxinc.com/forums/default.aspx?f=25&m=332138

    PullMoll's qZ80 emulator : http://forums.parallax.com/showthread.php?121579-qZ80-the-third-shot
  • Cluso99Cluso99 Posts: 18,069
    edited 2011-03-23 00:35
    I believe the guys on the N8VEM project were trying to load the SRAM via a prop to save having to program an EEPROM. Not sure how they went. You can search google for the links.

    Nice little project you have linked to. You should look at ZiCog as it is quite a lot simpler and you can change the code to be 100% 8080A if you desire.
  • jaegjaeg Posts: 156
    edited 2011-03-23 07:07
    You guys make a good point. My goal right now really isn't an Altair just a generic computer system. I'd like to keep the number of props down to one so if I'm interfacing it with various peripherals could I do it in a similar way as you would a z80? Maybe set up write/read enable lines and a databus?
  • AleAle Posts: 2,363
    edited 2011-03-23 07:14
  • jaegjaeg Posts: 156
    edited 2011-03-23 07:30
    Thanks for the link. I'm starting to consider making a Mark-8 computer just for kicks and using a propeller to act as some of the hard to find chips (8008 processor and there are a couple of others I can't think of for some reason) I'm going to try to not condense the design more than I have to to stay in the spirit of the original computer.

    Eh I'm weird I know.
  • ctwardellctwardell Posts: 1,716
    edited 2011-03-23 07:45
    jaeg wrote: »
    Eh I'm weird I know.

    Yes, you may be weird, but you'll fit in just fine with us other weirdo's....

    C.W.
  • SarielSariel Posts: 182
    edited 2011-03-23 08:59
    It certainly is possible to load an EEPROM using a propeller. I have done it with a BS2 in the past, and I can't see there being much difference in the way it would work on the Prop. What you want to do is write a program that will bit-bang the information into the EEPROM. My project was just a bunch of serial information that amounted to phonemes I wanted to feed into a SpeakJet so that it could say a few "Pre-recorded" sentences when prompted to dump EEPROM memory directly to the SpeakJet. It did work pretty good, although I think there was a timing issue between the EEPROM and the SpeakJet that needed a bit of uC buffering. But that was a different problem.

    Large amounts of data might prove a challenge tho. (I'm sure someone will flame me for the idea), But I am theorizing that you "could" use a hex editor to copy/paste the raw data from your EEPROM file into the prop tool along with the correct methods to get the data to it's destination. Then it would be a matter of dumping the program to the Prop, running it, and, you just might get a programmed EEPROM out of it. If you run out of program space and have to put more data on the EEPROM, you can just "Save As", make a couple alterations so that it starts off on your first empty address, and dump more data. Maybe even advance this to building your own EEPROM programmer using a Prop, an SD card (check out Kye's FAT16/32 SD object. I have read a little on it, and it is fantastic), and a couple different EEPROM ZIF sockets, like Mike had suggested.

    Hrm... maybe I'll build one of these if my current project will ever go away.

    I know it is a LOT of work to do it like this, but when you are as cheap and prone to accepting a challenge as I am, you certainly can get it to work.
  • jaegjaeg Posts: 156
    edited 2011-03-24 10:28
    I want to expand on something I mentioned earlier about using a single Prop in a way similar to a z80 or other micro processor.
    Prop Pin Assignments:
    P0--P7 = D0-D7 <-Databus
    P8-P23 = A0 - A15 <- Addresses
    P24 = Read
    P25 = Write
    P26 = I/O Request
    P27 = Mem Request

    Basically you would treat the peripherals like you would on a uP by using an address decoder -> http://cpuville.com/images/Z80/schematic_4.GIF
    Then you can hook things up any other way you want similar to this -> http://cpuville.com/images/Z80/schematic_7.GIF
    Using this I could attach SD, Keyboard, Ram, and maybe Video but I'll have to look into the that. I won't have to worry about conserving too much of the hub ram interpreting since the actual program will be kept in the external ram. A majority of how the pins works with regard to the upper half of the address bus being used to identify chip select for ram when mem request is active and the lower half for I/O request. What do you guys think?

    EDIT
    Sorry pictures can't be linked to
    http://cpuville.com/Z80.htm
    I'm refering to the control bus buff and address decoder for the first one and output port for the second link.
  • ssoutherssouther Posts: 7
    edited 2011-03-30 20:55
    jaeg wrote: »
    I want to expand on something I mentioned earlier about using a single Prop in a way similar to a z80 or other micro processor.
    Prop Pin Assignments:
    P0--P7 = D0-D7 <-Databus
    P8-P23 = A0 - A15 <- Addresses
    P24 = Read
    P25 = Write
    P26 = I/O Request
    P27 = Mem Request

    Basically you would treat the peripherals like you would on a uP by using an address decoder -> http://cpuville.com/images/Z80/schematic_4.GIF
    Then you can hook things up any other way you want similar to this -> http://cpuville.com/images/Z80/schematic_7.GIF
    Using this I could attach SD, Keyboard, Ram, and maybe Video but I'll have to look into the that. I won't have to worry about conserving too much of the hub ram interpreting since the actual program will be kept in the external ram. A majority of how the pins works with regard to the upper half of the address bus being used to identify chip select for ram when mem request is active and the lower half for I/O request. What do you guys think?

    Not sure what the two diagrams refer to as I was unable to link to them, but sounds very much like you could go ahead and plug in an 8255 for memory mapped I/O in such a design. I might hesitate to do such a thing here, as I think the propeller allows me to access KB,VID,and SD storage with something like 10-12 pins, leaving 20 for a memory bus like you have discussed above. If you mulitplexed 8 of 'em for data with additional read cycles for word level reads/writes, then you've basically got an 8088 design and most of its ability, that should be good enough, especially if you're not using the RAM for device I/O. Maybe I'm not seeing something here, and if that's the case feel free to point it out, I'm new to the propeller but love what I've seen so far.
    Steve
  • kwinnkwinn Posts: 8,697
    edited 2011-03-30 22:01
    It is possible to build an 8008/8080/8085/Z80/8088 based computer without eeprom by having a propeller load the bootstrap code into a ram chip before the other cpu chip starts up. Once the bootstrap code has been loaded to ram the propeller then becomes the keyboard/mouse/video/serial/sd controller. For CPM and DOS the boot code is relatively small.
  • Heater.Heater. Posts: 21,230
    edited 2011-03-30 22:10
    jaeg,

    Now I'm confused. Is the idea to:
    A) Have the Prop emulate the CPU (8008, 8080, 8085 or Z80) and then use old style peripherals with it (8255 etc)
    or
    B) Use a real CPU chip (8008, 8080, 8085 or Z80) and then use the Prop as one or more of the peripherals.

    Option B) was my original plan before I realized one could emulate an 8085 in the Prop itself. It's also the way they were going in the N8VEM group.
  • M. K. BorriM. K. Borri Posts: 279
    edited 2011-03-30 22:19
    Now I wonder if I can build a commodore 64 around a 6502, a SID and a Prop. (I know the Prop can emulate a SID, but I have two good original chips, may as well do something with 'em)
  • potatoheadpotatohead Posts: 10,261
    edited 2011-03-31 07:25
    I've went a little ways down that road, with a real 6502. Haven't finished the build yet, but you might find this project very interesting:

    http://www.parallax.com/tabid/708/Default.aspx

    I think doing the VIC II with a prop is doable, BTW.
  • jaegjaeg Posts: 156
    edited 2011-03-31 18:03
    Sorry heater. I'm keep jumping tracks between various ideas. I'm surprised my train of thought hasn't destroyed a small village yet.
  • Dr_AculaDr_Acula Posts: 5,484
    edited 2011-03-31 19:11
    Nothing wrong with the ideas jumping around. This is fun!
    Then you can hook things up any other way you want similar to this -> http://cpuville.com/images/Z80/schematic_7.GIF
    Using this I could attach SD, Keyboard, Ram, and maybe Video but I'll have to look into the that. I won't have to worry about conserving too much of the hub ram interpreting since the actual program will be kept in the external ram. A majority of how the pins works with regard to the upper half of the address bus being used to identify chip select for ram when mem request is active and the lower half for I/O request. What do you guys think?

    Cluso99 has done that with a ram chip and it works well. He ended up with just a handful of precious pins leftover, so then went on and designed some "1 pin" things - from memory I think a video driver and keyboard driver.

    I have a design for a MPM computer and propeller hybrid where the Z80 and ram chip do their thing, and the propeller is used to load it up at the beginning and act as a peripheral. I've even had some boards made but I haven't soldered them up.

    For peripherals, everything is a compromise - more pins = more speed, but more pins uses up pins that you might be able to do more clever things with, eg mouse, keyboard, directly driving a video display rather than needing another chip devoted to video.

    There are a number of designs out there and I think they have explored many of the options - eg devote a couple of pins to serial ram. Or 12 pins and decode them with other chips to give you all the address lines (dracblade). Or devote pretty much all the pins as you describe.

    The great thing about the propeller is that all these things are possible and you can reconfigure the chip in software.

    Heater has given a very good summary of what has been done so far.
  • jaegjaeg Posts: 156
    edited 2011-03-31 20:03
    I edited my post about my processor description sorry I didn't realize that you couldn't link to that website like that.
  • jaegjaeg Posts: 156
    edited 2011-04-07 17:59
    I have a design for a MPM computer and propeller hybrid where the Z80 and ram chip do their thing, and the propeller is used to load it up at the beginning and act as a peripheral. I've even had some boards made but I haven't soldered them up.
    Are you having the propeller load the Z80's ram from an SD card? You could always load the ram the old fashion way, switches. lol
  • Dr_AculaDr_Acula Posts: 5,484
    edited 2011-04-07 19:47
    Switches instead of an eeprom? Hmm, I like that!
  • jaegjaeg Posts: 156
    edited 2011-04-07 20:11
    And if the novelty of switches wears off you can do something similar to what the Replica 1 from Briel does by using the propeller as a terminal which feeds it keystrokes/databits to program it faster as well. I think his Altair clone does something similar as well.

    If you really wanted to you could use something like Rayman's flash/ram boards which gets loaded with code from switches or some other means and the Propeller interprets the code like a regular microprocessor (not really a new idea) but even if you just use a 32k chip that's like a fresh propeller after most of the actual propeller's ram is used up with video drivers, ram management, and interpreter. (still nothing really new haha)
Sign In or Register to comment.