We're using cookies to ensure you get the best experience on our website. More info
Understood
@dogpRegistered July 25, 2003Active 7 years, 4 months ago
1,461 Replies made

I first tried with 3.4.4, and second with 4.3.4… both on a 32-bit system. I’ll see if I can build your 2.95 version w/ my environment (I never had a problem w/ DT’s build).

DogP

I’m trying to build blitter’s 4.4.2 patched version, but it keeps segfaulting while building binutils… any ideas? Here’s the crash output:

./libtool: line 1128:  8016 Segmentation fault      (core dumped) gcc -DHAVE_CON
FIG_H -I. -I../../binutils-2.20/bfd -I. -I../../binutils-2.20/bfd -I../../binuti
ls-2.20/bfd/../include -DBINDIR=\"/opt/gccvb/bin\" -W -Wall -Wstrict-prototypes
-Wmissing-prototypes -Werror -Wno-error -MT archive.lo -MD -MP -MF .deps/archive
.Tpo -c ../../binutils-2.20/bfd/archive.c -o archive.o

I tried it with my old cygwin, and just made a new cygwin with latest gcc and other packages… both did the same thing. I’m following David Tucker’s original instructions as far as which packages are required and stuff… then I just do ./make_v810.sh .

Thanks,
DogP

IPS patches themselves are just the differences between the original ROM and the hacked ROM (keeps patches legal, since there’s none of the original copyrighted ROM). I assume what you’re really asking is how to hack ROMs.

There’s lots of ways to do it… but typically you open the ROM in a hex editor, find what you want to change, change it, then try it in an emulator and make sure it does what you want. Of course the hardest part is finding what you want… which can be found by searching the ROM for certain numbers (like if you know you get 55 seconds, search for 55), or if you’re trying to change text, search for words… and so on.

DogP

Yeah, you can adjust the time limit through a ROM hack… but why? I haven’t played it in a while, but I don’t really remember time being a problem with the game. Have you played it enough to get familiar with the maps, or are you just wanting to be able to run through it first time?

DogP

Thanks… I’ll see if I can build 4.4.2 for Windows w/ the patches. I agree about moving forward… as long as there’s no good reason to stay with the old compiler, we might as well enter the new millenium ;).

DogP

BTW, I see there’s a precompiled GCC 2.95 for download here: http://www.planetvb.com/modules/tech/index.php?sec=utils&pid=gccvb … is this what most people are using?

How about the others that are using GCC 4.x? I see some references here: http://www.planetvb.com/modules/newbb/viewtopic.php?topic_id=4125&forum=2 and http://www.planetvb.com/modules/newbb/viewtopic.php?topic_id=3883&forum=2 .

Is there any disadvantage to using GCC 4.x, with all the patches? Is it possible to make a precompiled version of GCC 4.x that can just be downloaded, rather than needing to be built? I’d like to get working on the library, but I really need to set up the environment for whatever GCC version we should call the “standard”… and IMO if there’s nothing wrong with GCC 4.x, I think we might as well jump to that.

Thanks,
DogP

HorvatM wrote:
My suggestion for audio is to use WAV and MIDI, because for musicians they’re the easiest to work with, even if they are hard to convert.

But there’s another option: I’ve written a simple DOS-based tracker that supports (a maximum of) four channels and plays them to the PC speaker. The file format is very simple and the four channels conveniently map to the VB’s four wave channels, leaving the sweep channel for Atari 2600-like sound effects and the noise channel for percussion or whatever.

Well… it’s not necessarily the file format, but more the limitations of the hardware to reproduce the sounds available on WAV and MIDI. It’s hard to tell someone to make you a WAV or MIDI for a video game, then convert it and have it sound completely different. I really think a WYHIWYG composer would be nice, so they know exactly how it’d sound on the VB. Of course that also makes the job easier for putting it on the VB.

Your DOS-based tracker sounds interesting… do you have a link?

blitter wrote:
Back in college, I did some Game Boy Advance dev using the HAM engine and SDK. The IDE we used integrated with GDB over a TCP/IP link to a local Debugging version of the VisualBoyAdvance emulator. USB link to hardware would be cool but I was thinking more along the lines of the setup I just described. Work done to get a v810 version of GDB working would also be beneficial to both the VB and the PC-FX homebrew communities. Ideally I would hope this could lead to (pie in the sky idea here) getting the Mednafen team interested in supporting a similar setup going between your GDB client of choice and Mednafen– I believe Mednafen borrows some code from VBA anyway (not sure what parts, so it may be irrelevant).

Yeah, GDB would be nice in an emulator as well… I know Reality Boy has quite a few debugging features, but nothing that links back to the source code, like GDB would. I’m sure there’d be some inaccuracies, but maybe it’d help improve emulation, as well as help debug code.

One major downside to debugging on hardware is that the V810 only has one hardware breakpoint available, and since the cart is typically ROM (flash included, though technically rewritable), it’s hard to do software breakpoints. It would be possible to rewrite the flash at run-time with a special breakpoint routine, though more difficult than if running from RAM like a lot of systems that do software breakpoints. Of course special code could be written to look for breakpoints when entering a function or something, but that’s kinda hackish.

DogP

Thanks… it was very good. Lots of turkey, stuffing, Cranberry sauce, and other good Thanksgiving food.

DogP

Heh, that’s me, too 😛 But, there are open-source clones of Mario Paint, so, why not make one that saves MML? Actually, the Windows one I use (Mario Sequencer) saves a fairly simple file format that could be converted pretty readily, plus the sounds are all .WAV files in a folder, so they can be changed out to match the actual VB “instruments”. It would at least get programmers started with a way to make a prototype of what they want the music to sound like, which then gets handed off to an actual musician for polish.

That’s a good point, though Mario Paint style doesn’t translate to VB particularly well… the “instruments” are more complex than the VB does, and everything is short duration notes. Musagi ( http://www.drpetter.se/project_musagi.html ) could possibly get us close to a working VB music generator, though the output isn’t musically pleasing on its own without knowing something about music… so it still doesn’t help me 😉 .

I’ve got a working, albeit not comprehensive, version I split into .C and .H files. I’ve been slowly cleaning it up and adding to it. It might be a good base to work from.

Yeah, if you’ve got a good base, please post it here, or you could email to me if you’d prefer.

It’s attached. I’m still not a very good C programmer, so the two .h files is all I could come up with to solve some cryptic compiler errors. You can probably eliminate the hack, for which I would be grateful.

Thanks… I’ll check it out!

Oh, I didn’t know you weren’t using dasi’s port of that printf routine. It works great with bgmap_print type stuff. But, I wasn’t really talking about debugging. For that, I think we should work on a link-port option.

No, I was talking about text output in an actual game, such as an RPG, inventory adventure, etc. I would especially like to work on features like those found in the Paper Mario games, like “shaking” text for scared people, different sizes for yelling and whispering, etc.

Ah… that’s right… I need to try the pos_printf() or whatever that was. But I’m talking about both debugging output as well as normal in-game text. I like to use text functions for things like score, pause screens, dialog, etc. But for shaking text and stuff, couldn’t you just use a specific world for that text, printf to it, then move the world? Resizing text would be a little tougher, unless you used Affine, which would probably be overkill.

Objects:
I actually prefer objects over BGMaps because of their versatility, but they are a bit of a pain to manage. If you want to “generalize” object management, you have to come up with some way of allocating objects, and then keeping track of them. This should be easy, but might have some nasty overhead. I have my own more hackish solutions to this problem…

Yeah, I’ve done some OBJ management, and yes… there’s overhead allocating, managing, etc… but I mostly just find it to be annoying to deal with. My problem is that 8×8 is pretty small, so if you want enemies that are 32×32 or so, you end up having 4×4 objs, and for moving, you need to move 16 OBJs, and say the enemy turns around… rather than just flipping the chars, you need to flip as well as reorder the chars. This gets tedious, since some enemies could be 32×32, others could be 48×16, etc. A library that would allow operations on a “collection” of OBJs would be really nice IMO. Basically, if we had something that allowed BG-like control, but without the limitations of only 1 BG per world.

There’s also the specifics of using OBJs which tend to cause confusion… like the SPTx regs.

As a parting note, I would prefer it if whatever gets added to the pool is not tied down to an IDE. Personally, I develop in Vim and terminal, so having to use an IDE would be frustrating for me.

Yes, of course nothing would be tied to an IDE… but an IDE is nice to just jump in and get going without needing to deal with configuring stuff that’s not really related to what you’re trying to make.

blitter wrote:
GDB. ‘Nough said. 🙂

Yeah… I’d like to get the USB link adapter set up to work with GDB… but I don’t know nearly enough about GDB to do this at the moment. Do you know the inner workings of GDB to help with this?

DogP

Heh, I got one of them a long time ago… that thing is SO ugly 😛 . But yeah, I’d personally take off that pin and keep it with my other video game collectibles.

DogP

That depends on whether you’re talking about sound effects or music. For sound effects, I’d like something like SFXr that generates VSU code like your non-real-time emulator. Music should obviously be synthesized by the VSU, so you have to start with a “music language” of some kind. A member named “mic_” posted about adding VB support to his MML compiler. Then there’s DanB’s unreleased MIDI playing code. Also, I’ve chatted a bit with Kitaro (who helped get Bound High working) about music playing on the VB. I seem to recall him saying something about having VB code that can play music in a format similar to that used in Bound High (which I believe is also a version of MML).

Thanks for the links… I hadn’t seen SFXr before… that’s pretty cool (interesting how it smartly randomly generates stuff that actually sounds good 😉 ). Also, on the same page is musagi, which looks pretty nice for creating music as well.

So, you’re going with the assumption that it’s better to create VB music rather than convert it from something else? I do think that’s the case here… like my wav converter works fine for small amounts of speech, but that’d be horribly inefficient and bad sounding to do a whole music track and sound effects like that. And I’m not sure that FFT sequences are up to the task of converting music (that’s how I did the some music and the sound effects in Mario Kart).

And yeah… a MIDI player may be nice, though that’s what I did with most of the Mario Kart music, as well as the demo song in my first sound tester app. The problem is that MIDI instruments are much more capable than the VB waveforms, as well as having more channels, so they don’t always work out. And yep… I believe BH did use MML, which of course is great, except how do we generate MML? My skill level is in line with placing Smiley Faces, Marios, Cats, Dogs, etc on a Mario Paint screen 😉 .

I think the thing about Grit is just getting it set up in a makefile and designing your code/work-flow around naming the input image files and using the generated variable/constant names. It should be a mostly hands-off process, where you just dump images in a folder with your code and have them converted when you rebuild.

Wait… you’re saying to convert files with Grit on the fly, rather than just using it as a tool to create graphics .h files? That’s an interesting thought, though I kinda like to have real-time control (like in VIDE I usually end up converting my files several times to get the brightness/contrast levels correct to make a good conversion, as well as visually seeing that I’m making efficient use of chars… which is why I’d like a nice GUI for tweaking).

This is also a very confusing topic to me. Parasyte started working on a shell script that downloads, patches, and builds everything. That’s a good way to go for the Linux camp. I think the best distribution for Windows would be a set of pre-compiled, native win32 (and win64?) binaries, linked against only the MS run-times, so it can be used with the Mingw versions of make, etc. from the Windows command-line, or integrated into things like Notepad2, etc. We should also look into the Eclipse thing mbuchman mentioned, of course.

I currently use a version built in cygwin, which means I have to use the bash shell provided with cygwin to run it, instead of having it integrated into my text-editor. It’s just a bit less convenient than I’d like.

I’m also using a cygwin build (somewhat old DT version)… it seems like there’s been talk of newer builds with various patches, but unfortunately I haven’t paid much attention. I agree, a precompiled downloadable zip would be nice. Maybe someone who’s running a newer patched version can chime in?

I’ve got a working, albeit not comprehensive, version I split into .C and .H files. I’ve been slowly cleaning it up and adding to it. It might be a good base to work from.

Yeah, if you’ve got a good base, please post it here, or you could email to me if you’d prefer.

I’ve started work on a “virtual timer” library that allows a number of “events” to be triggered at different times by a free-running timer kernel based on the timer interrupt. It’s a simple idea: set the timer to some fixed rate (that won’t take too much CPU time for servicing the interrupts) and then decrement a number of counters, calling function pointers when they reach zero.

Cool, yeah… that’s one thing I was thinking would be good for the timer… basically creating periodic functions, so one “function” doesn’t hog the only timer. I use those in RTOSes, though I’m not sure how many things need to be periodic on the VB. Sound is really the one that comes to mind, though I’m unsure that it needs more than 50Hz update (a 20ms note is pretty short). A lot of the periodic things really could (and probably should) be synced to the game frames. Like controller reads, graphics drawing, game timers, etc.

But yeah, that’d be nice to be able to basically “add” a periodic function… just tell it how many ticks and pass a pointer to the function to call.

I doubt if there’s any “boiler-plate” solution that would work for every situation. We should just make it easy to understand how the subsystem works, and make efficient access functions, constants, etc. with which to access them.

Yep… but I don’t think we’re there yet. BGMaps are VERY easy to deal with… OBJs aren’t, IMO. I think this could use a little work in the improved library.

One of the first things I thought of upon seeing Fwirt’s BGMap pixel routines was making a variable-width font renderer (with a compressed, i18n-compatible font format, of course ;-)).

¿qué? I’m just thinking something like what we have with bgmap_print() and itoa(), but with a smaller font table and more friendly usage (annoyances like negative numbers show up as really large numbers, then when you go back positive, it only overwrites the characters used, leaving a mess). I’ve made quick hacks to some of these functions for specific purposes, but something a little more standard would be nice.

Using user input isn’t necessarily game-specific, as long as most games include some form of warning, IPD, and “activate auto-pause?” screens. If we standardize that code (while allowing custom imagery/text), we could incorporate a high-speed counter for random seeding.

True, though assuming you press start to get through the warning screen, you have to verify that holding start doesn’t automatically skip that screen (basically check for not pressed, then pressed). And yeah, you’d want that counter as fast as possible, or to modify the seed several times during startup or throughout gameplay to give the best randomness.

Link

Definitely. Get to work on that 😉 j/k.

Yep… that’s one of the first things on my list for putting into the library. I’ll probably be looking for input once I get working on it.

I agree: audio is still very much a “black art” among most VB devs, and severely lacking in the existing homebrew library. I can somewhat grasp the basics of the VSU, but my complete lack of musical talent provides a rather large barrier to getting anything written. We need a way to let the “artistic” folks do their thing in a way that can be easily incorporated into a game.

Yeah, musical talent is what usually holds me back too 😛 . Like you said, if we had a way for musically talented people to make stuff (or remove the need for music talent 😉 ), we’d be in good shape.

That being said, you also have a point about a clean, easy to follow library/code-base to work from… And then there’s the compiler situation… Hmm, quite a lot to do before beginning the “uber homebrew project” 😉 but I think we’re up to it! :thumpup:

Yep… when it’s me coding for myself, I tend to just hack stuff together, but if we’re going to make a large collaborative project, we really need a well structured and clean base. I think audio handling and a better/common library are critical.

DogP

Yep… I agree that an IDE would be nice, though IMO there’s more important things… but if someone wants to take charge of it, I’m all for it! I’m okay with just using Notepad2 or some other text editor though.

And yeah… it does seem like Eclipse is the cool IDE these days… I’ve never dealt with it though, so hopefully someone with some experience could chime in about how difficult it would be to integrate it. Heh, this reminds me of Office Space when they’re talking about how they’re a bunch of nerds looking up Money Laundering in the dictionary 😛 . We know Eclipse could be the answer, but don’t know anything about it 😉 .

DogP

I’ve also found that recording with the camera sideways sometimes gives a better video… it probably depends on the camera though. Of course the VB draws vertical lines scanned horizontally… rather than a normal TV which draws horizontally lines. Then you can use software to rotate it back. It just takes trial and error to see if this helps any.

DogP

Emulation is possible, but not really realistic for most systems. I ported a Gameboy emulator a long time ago, but it was HORRIBLY slow (<1 FPS). While it certainly could have been optimized, it probably couldn't be made to run full speed.

If you want a GB emulator, you'd probably need to do something like a Super Gameboy, which actually uses hardware to run the Gameboy, and just using the host system for controls, display, audio, etc.

DogP

Congrats guys! Lots of cool stuff, and best of all, we get an awesome looking poster 🙂 .

DogP

True 🙂 .

DogP

Just wanted to poke here and let you guys know I still REALLY like this idea and am making some behind the scenes progress… but I also have some other higher priority stuff to take care of in the next few weeks. So… keep the ideas/input coming, and hold tight… we’ll get this going!

DogP

Antoine BCN wrote:
I’m interested too . Could you produce a link cable with box and instructions like the Flashboy?. If you do this , more VB collectors join to this project .

I could probably do a box/instructions, though the price is already more expensive than I’d like… I’d hate to make it out of reach for something superficial like that. Heh, and I’m not sure what “instructions” are needed for a link cable 😉 .

I would also like to sell individual connectors in case anyone wants them for custom projects as well… no need to hack up a perfectly good cable just for the connector 😉 .

DogP

While there may be some developers without flash carts… there’s also plenty of us too lazy to use them 😛 . I wrote Super Bounce in less than a half day, and it played in an emulator, so I said good enough. I didn’t feel like grabbing my flash cart, burning the chips, seeing bugs (which I was sure were going to be there), then have to go back and fix the problems.

A better plan IMO is to make emulation more accurate, because developing on emulators is much easier, quicker, and just overall better.

DogP

I’ll try to find out about colors… I was just told that they could do different colors, no idea on cost. If it makes no difference to do half of them red, half of them black, I may just do that.

DogP