Having the GPU chip able to flash the Z80 using the st-link is IMHO a really good idea.
The less tools you need to get the zikzak to run or to modify its code, the better it is.
Even more if the tool "eliminated" is expensive.
yeah, theres a few options buzzing around my head. I'd like things to be flexible, but not complicate the design.
So..
1) Programmer header for the STM32F4 GPU
2) Programmer header for the eZ80 (ZDI, Zilog Debug Interface header)
3) Maybe also hook up STM32 to eZ80 ZGI, so that we could code up a proxy or whatever
4) Serial/USB CPU: Given 64KB flash in the eZ80 model I've chosen to test with (may or may not be final brain, but I sure like the specs,
and it ditches the I/O chip need for us, bringing us very close to final design!), it may be possible to flash a bootloader on there, of
sorts; ie: wake up, check for various things, and boot up cartridge if present; if no cart present, show a terminal of some sort? If cart
present, wait a few secs, then boot cart .. if something hits (say) serial in those secs, open terminal. -> Terminal could have an option
to reflash the 64KB flash, or even write to the cart (since some or all carts will have eeproms .. my carts so far can be written to by any
cpu.)
5) Serial/USB GPU: May be able to build the same into this, but I forget offhand how muvch of itsd flash it can write to while live
So in my brain, an STM ST-Link V2 cable would be a good thing to have, for debug and flash the GPU, and through that maybe also the cpu and
maybe cart. But even without that, seems reasonable that it coudl be coded up so the cpu and carts could be flashed with pruely a usb
cable, or say a usb-serial-ftdi cable if I don't put all those FTDI's on board.
Remember with the Zikburner test.. I use an FTDI on the board, and talks seiral over usb, and can program the cart right there live; wrote
a little serial server on the avr controller there, which does hexdumps and verifies and all that good stuff. Same sort of thing running on
the eZ80 would rock
---
I'm looking at
Mockingboard's
datasheet/schemati
cs since I would like to make a nice PCB able to accommodate at least two 3910. I have some troubles to pick the capacitors I should
use to get a clean sound signal, so I'll probably just copy their circuitry for this part
Nice
Pretty awesome board, but seems way more complicated. In a way its great to be an electronics noob and free of worries about safety
.. so far I've had very good lluck with my very simple boards working well, ignoring all the extra circuitry peopel used to throw in;
really, I think this is a side effect of modern specifications.. the old chips would fry if you looked at them funny, but nowadays, tough
as hell. I dunno.. Mockingboard had a lot of stuff on it last time I looked, but really just needed a couple chips and call it a day
I 'm also considering designing a PCB for one 40 pin ZIF socket, to easily connect it to breadboards with ribbon cables. I've seen how
easily I can bend chip pin while trying to remove them from breadboards. -_-
Geez, you using a spoon to pry them out?! (I use a ball point pen..)
Never had this problem.
Buy yourself a couple sockets then .. I mean, locally they're expensive for me, but I ordered a stupuid pile of them from Futurlec long
ago.. got like 20 various 40pin ones (a few widths), some 32, 28, 16, etc, assorted sizes; got a huge bag of about 100 sockets
I've been
known to stick a few mcu's into them, and jst keep wedging those into the BB's, let the sockets bend up and save the mcu. But in practice,
I've not had a problem ..
My pricier 3 BB thing, is very tight; have to use pliers to stick wires in; that worries me a bit for cpu pins, but so far so good.
My big giant 10 BB monster uses those $6 cheapo BB's, and they're pretty loose; no problem, but you do run the risk of wires slipping out,
and on BB with 40 or 100 connections, you don't want to be debugging _that_ :/
When I had zikzak r3 (giant one with double buffering in hardware), a lot of my problems were just line inductance between the 'mcdonalds
arches' wires, and stray capacitance and... lose wires; a few wires were in place, but just not solid connection and you'd see all sorts of
display noise and problems, unless I held the wires just so or squished them, or breathed at them .. nightmare until I found out which were
the culprits.
So now I try to use the tight BB and good solid wire jumpers. (I bought assorted spools of wires, and hung them on a piece of wood.. think
toilet paper roll, with 5 or 6 spools across it. Black, Red, White, Blue, Green, etc..); use good wire. Expensive, but worth it, and re-use
them.
LQFP adapters are still on their way, I hope to get those ASAP since the ST-Link/V2 should arrive soon. I'm eager to get started with ARM
MCU even if they seem no as straightforward as PIC, AVR or MSP430, from what you've told.
You probably sleep more than me, and maybe have more experience? At least you have the benefit of my experience, which should put you into
work no problem.
ie: For me, it was the 'okay, I soldered it, now what? .. too many pieces to look at, a large surface area to attack; when you find 10
manuals, each 1000 pages, its sort of 'w-t-f'! .. but I can point you right at a diagram that shows the _actual_ required minimum pinouts
(I had an ST engineer write it out for me, since the specs are not entirely clear.). Once you get the ST Link pdf, it has the pinouts for
that, and coupled with th eminimum pinout, you can be up and going. Then.. how to write code? I didn't know where to start, from basic
reister dump in datasheet, to the ARM standard CMSIS register naming, to the "Standard Peripheral Library" (thats the main API, oddly named
as it is), to libopencm3 (open source library), ... Let me tell you, ignore the register dump, ignore CMSIS, and go right for Std
Peripheral Library. Its a very thin wrapper over the registers, but comes with a Windows style chm help file that documents how to use the
stuff, and includes examples in the zip file. Anyone in the ST forum asking questions will get answers in StdsPeriph lib format.
libopencm3 looks like its pretty good, but I found it .. a thin layer over the registers, withotu much documentation.. and since it doesn't
relate back to the StdPeriph, you end up going back to ARM CMSIS docs etc, which are a nightmare (too much info!).
So for 'day 1', get the Standard Periph library (I can point it out if you can't find it), and good to go.
Use gcc. Makefiles for my test experiments are in the 'zik80' directory in my github.
What I use is the libopencm3 Makefiles, of sorts, to get good linkerscripts and to get the function names to ISR mappings. ie: This way I
can refer to tim1_isr(), and the lilbopencm3 crap will slot that into the right address to work, but I'm not actually using libopencm3 much
(just to set the clock speed
)
So you see, I rammed head first into a lot of complications; libopencm3 works, but confusing
oh, debugging and gdb stubs and such .. get the launchpad arm toolchain, .. that gets you gcc, gdb, etc; use debian/ubuntu, get the openocd
package for the gdb stubs, and to flash stuff; you'll see in my makefiles and sh-scripts, theres a ./build.sh script, and a ./deploy.sh
script (and the gdb-attach and gdb-start type scripts.)
-> save you a lot of time!
I also found otu the F2 was not well supported in libopencm3 and openocd etc .. the 'flash and restart' would crash ,for instance.. so
eventualyl I figured out I could do a full erase (slow), and then flash, and then start, 3 steps of commands; but when I switched to F4, it
all magicaly works very nicely.. and in general, F4 has much more support around the net. So you went F4, you're a foto up where I was.
So, yeah, a lot of things to wrestle.. toolchain, debugging, programmer, API, ARM, etc. But ... get launchpad toolchain, openocd, Standard
Periph lib, and use my makefiles and scripts, and you'll be up and going fast.
I received 3 SOP20/SSOP20 adapters (with those useful bridge pads), the pcb are pretty thick and seem really sturdy. They came with good
quality machined pin headers.
I may buy more of this kind of pin headers, they look far more sturdy than the cheap ones with square pins. And the round machined pins are
quite slimmer, better for using with breadboards and sockets, I think.
I got burned here a bit.. I wasn't sure of the diff, so when I ordered from futurelec, I ordere both machine pin sockets and regular
sockets (so damned cheap, at least at the time.) Around me though, machine pin headers are REALLY expensive, more than the already
expensive normal ones. I found them really hard to solder.. the ones I ahve don't stick to solder at all, which is annoying as shit
A
normal chip can't fit into machine pin socket, etc.. just machine pin headers. So you end up with compatibility issues, but if you get all
the matching pins together, they snap together snug and tight, which is nice.
FWIW, a tight breadboard.. no problem. A loosey goosey BB, the machien pins may be too thin and slip out or make poor connection, so test
them out.
ebay again though.. I have a parts box just for header pins .. machine pin or not, right angle or straight, extra long, and extra extra
wire wrap long.. and female straight, female rightr angle; single and double row, etc. Hit up ebay, and stock up on all varieties
I need to keep ordering more.. drives the poor wife nuts, but I mean.. buy a baggy of 20 20-pin headers of each kind for a couple bucks..
spend $20 or so, get a big pile of headers.. you always need them, in every kind.
Other good news : I received the japanese Pop'n Twinbee: Rainbow Bell Adventure cartridge I ordered.
Now, I'm waiting for the super famicom to try it. The seller told me that they were late for the shipping, so they'll upgrade my shipping
to airmail instead of economical shipping for free.
So much fun in one post my man
My one kid was driving me insane on Friday; I ended up putting he rin her room, and jkeeping my back up against the door while she threw
her stuff around and raged, keeping the babies up and making the wife cry.. quite annoying. But during it, I retail therapied myself via my
tablet.. eep
So I've got about 6 orders in, mostly some good prices, vbut took a bath on some stuff. Ordered 4 eZ80's ($5/ea), a bunch
of those 128KB RAMs I found ($2/ea, love them to bits from the datasheet, will use them in a lot of things), a couple 28C256Kb eeproms (I'm
running out, and making some carts for experimentation), some 2x16P .156" edge connectors (arcade style, so I can use old fingerboards on
them for testing), and some other junk; mostly ebay, but some digikey (ouch, for those ram and eZ80s).
Hard to find edge connectors, but I've been needing to order some; I've got a small stack of various non-36pin ones around from my arcade
repair stuff, mostly 44p and JAMMA 56p .. but I want 36pin specifically, since they fit into Atari 2600 carts still, and have the right
numebr of pins. I need to get explicit measurements (my dad gave me a nice digital caliper) so I can make Eagle parts for the board layout.
Since I'm going to socket a lot of stuff, and because all CADs suck, I'm basicly going to have to make all new parts. ITs quite..
despairing to think, great.I can sit down and redo the schematic and get it near final.. and then think 'oh, instead of that 1-2 night
task, I have 10 nights of finding parts, redoing them, tossing htem out, redoign them again..'; you spend 90% of your time screwing around,
and you have to do it up front before you get to real work :/
If we go with eZ80, then it may be best to just put the DIP drill holes on the board, and then get those $1.50 futurlec adaptors; I put an
order in for some of those ut who knows when they will come, or if they'll all be the same from one order to the next; but as long as I get
1, I can clone them if I have to since its just a straight up adaptor. Anyway, once I get _that_, I can measure it and clone it into
schematic .. all the pins need to be entere dinto CAD etc, exactly right.
So I can come up with a near-final schematic, but I'll have to redo it for board design anyway once I get those adaptors in etc..
.. and baby is up, another night down the tube
jeff