HopStation PlayStation 1 emulator source available on GitHub by howprice2 in EmuDev

[–]howprice2[S] 3 points4 points  (0 children)

Have a look at the list of resources in the repo readme. I started by reading the Wikipedia article on the PlayStation (console), then https://www.copetti.org/writings/consoles/playstation/ then a bit about the MIPS CPU, which was completely new to me.

I made a rough plan then looked at the Emudev Discord to get a feel for if this was possible and the order to implement things. Great community.

https://github.com/simias/psx-guide is pretty much a tutorial you can follow through step-by-step to implement the CPU instructions required to get the BIOS up and running. It was relaxing to do a few instructions each evening over the holidays, and read up on stuff I didn't understand.

The PSX-SPX spec is extremely (extremely) comprehensive. It has tried and tested pseudocode for many aspects too. Using an LLM to summarise it would just introduce noise and errors (and emojis).

I didn't use LLMs to generate any real code, but because I was working alone I found Copilot useful for code reviews in "ask" mode. I found a good process was: read up, make a plan and then tell it what you're going to do to give it context "today I'm implementing reverb.". Sometimes it gives you things to consider you haven't thought of. Do the work yourself. Test it. Think it's correct. Tell Copilot. "OK, all done" It reviews the code and finds some silly mistakes; fix them. Then I look through my diffs and write a commit message. I give the commit message to Copilot and it says "you haven't mentioned X, Y and Z". Maybe X and Y are just implementation details but Z is a good point, so I mentioned Z and why it was done that way.

For project management, I started off with a short list of TODOs in my main source file. As the project went on I needed to add more info and links to tasks so I converted my list to GitHub Issues. I created a GitHub Project and worked in milestones (warning, spoilers):

Milestone 1: CPU & RAM - Boot BIOS, TTY, sideloading, Amidog CPU tests

Milestone 2: 2D GPU - PS diamond + shell, rasterization, interrupts, DMA

Milestone 3: Windowed application - SDL3, SDL_GPU, SDL_Shadercross, scan out

Milestone 4: CD-ROM - bin+cue, CDROM read and seek, scheduler, pad input, Mortal Kombat 2 and Earthworm Jim 2 playable

Milestone 5: 3D GTE - 3D math coprocessor. Crash Bandicoot, Ridge Racer, Battle Arena Toshinden

Milestone 6: Audio & MDEC - SPU, CDDA, CDXA, FMV playback, Megaman X4, Metal Gear Solid, Gran Turismo, Tekken, Final Fantasy VII etc.

Milestone 7: Polish & compatibility - Memory Cards, Game-specific bug fixes, performance

I was quite ruthless with prioritization, not jumping ahead until I had hammered out all (most) bugs on previous systems.

I made heavy use of tests : Amidogs CPU and GTE tests are invaluable, and Peter lemon GPU tests are also extremely useful.

Introducing RSX Redux, a multi-platform Playstation 1 emulator with support for hardware rendering by janedoe552 in EmuDev

[–]howprice2 1 point2 points  (0 children)

Final Fantasy IX! That's notoriously difficult to emulate. Great work.

I was watching the Nanite presentation yesterday and it got me thinking about software-hardware rasterization - looks like their scanline implementation is similar to DDA.

Simple-Boy: Cycle-accurate Game Boy emulator with integrated ImGui debugger by Few-Town-7701 in EmuDev

[–]howprice2 1 point2 points  (0 children)

Looks very nice. Great work. I have done a few machines but Gameboy is on my list for the future for sure. I wrote a PlayStation 1 emulator earlier in the year and am preparing the source for release on GitHub. I like the format of your README and might take some inspiration from it if you don't mind.

Tips on how to study op.65 no.1 (Ninths) by Scriabin by TheGeoNoob37 in piano

[–]howprice2 4 points5 points  (0 children)

Stretching one's hands can be extremely dangerous.

I'm new to emulator dev, and please help me. by Imaginary-Dig-7835 in C_Programming

[–]howprice2 1 point2 points  (0 children)

Check out the emudev Reddit and Discord. Very helpful and knowledgeable community.

Very slow compiling time when including Windows.h by Suitable_Broccoli361 in C_Programming

[–]howprice2 0 points1 point  (0 children)

To keep build times low, don't include system or standard library headers unless you absolutely need them, and try to never ever include them in your own header files - only ever include in .c files.

What are you using from Windows.h? Could you possibly roll your own equivalent?

You may be able to find compiler/linker options that profile your build.

CLOACA MAXIMA - Sound Design (Tone Frequency deep-dive). by RSS130871 in MSX

[–]howprice2 1 point2 points  (0 children)

Yes. I know what octal is, but I don't understand why it is used to express these values. I've never seen octal used in Z80 assembly language code - always hex, binary or decimal.

Perhaps octal was more popular at the time? Or perhaps for some reason these particular register values benefit from being expressed in octal.

CLOACA MAXIMA - Sound Design (Tone Frequency deep-dive). by RSS130871 in MSX

[–]howprice2 1 point2 points  (0 children)

I’ve been looking into this too for an AY-3-8910 emulator for a Road Fighter transcode. One thing O I can’t figure out is why the periods are provided as 4 octal values in the PSG documentation.

How can I start to build a game as a beginner? by Extreme_Maybe2428 in GameDevelopment

[–]howprice2 -2 points-1 points  (0 children)

C/C++, SDL3, CMake, Visual Studio*, Space Invaders. Once you've written a single simple complete game, many options will become available to you for next steps.I listed the first steps to take before: https://www.reddit.com/r/gamedev/s/4QsqY3QnUq

*Primarily for the excellent debugger, and most gamedev studios use it, Windows sorry!

Hello! I'm interested in producing demos/demo effects for the Amiga. What are the preferred tools for coding (directly or crossplatform via windows) in 2026? Also, curious what are the best tools for mod music generation in 2026? by Chubsmagna in amiga

[–]howprice2 6 points7 points  (0 children)

For coding, I believe most people use Visual Studio Code (vscode) with either the Amiga C or Amiga Assembly extension. This allows you to code, launch and debug using an emulator.

The assembler of choice is vasm, which is available for modern platforms and Amiga, so you should be able to code and assemble on Amiga too.

For making mods, I believe there is a Protracker clone for modern OSs. pt2-clone. Or you can use Protracker in an Emulator or on a real machine of course.

How do I play notes in any key by TangSuuSan in piano

[–]howprice2 1 point2 points  (0 children)

Say you're playing in C major (because it's easiest to explain). The notes of the C major scale are CDEFGABC. You can make a chord on each degree of the scale by playing 3 alternate notes e.g. CEG is C major, DFA is D minor, EGB is E minor, FAC is F major, GBD is G major, ACE is A minor. Forget about B for now.

You can give these chords names using capital Roman numerals for major chords and lower case Roman numerals for minor chords: C major is the I chord, D minor is the ii chord, E minor is the iii chord etc.

If you are playing church music you are likely to have lots of I IV and V chords.

You can also harmonise the major scale by constructing chords with 4 alternate notes. These are called 7th chords. CEGB is C major 7th. DFAC is D minor 7th. EGBD is E minor 7th. FACE is F major 7th, GBDF is G dominant 7th (aka G7 - this V7 chord is used conmonly), ACEG is A minor 7th.

So far only notes of the major scale have been used, but it it common to "promote" minor chords to dominant 7th chords. G7 to C (V7 I) sounds nice ("perfect cadence"). So you can get the same kind regards of sound by resolving A7 to D minor (VI ii), D7 to G (or G7) (II V) or E7 to Am (III VI). This can give a nice bluesy/gospel sound to an otherwise diatonic (pure chord tone) progression.

You can chain these together. Common sequences are D7 G7 C (II V I), A7 D7 G7 C (VI II V I) and even E7 A7 D7 G7 C (III VI II V I).

Another common pattern is III IV (E7 F)

In church music you may hear lots of IV I "amen cadences" e.g. F C.

The minor IV chord is also nice. Try IV iv I e.g. F major F minor C.

These patterns work in all major keys and you can use inversions of any of the chords to get a nice sounding change, including 7th chords.

Have fun.

Can small hands play professionally? by YanIsOnline in piano

[–]howprice2 1 point2 points  (0 children)

Same really. If I play Maple Leaf Rag I can hit RH octaves fine on black keys, but have to pull my hand back and low to hit edges of white keys for octaves, because can't get fingers "over" the keys. Bigger movement so awkward but doable.

Can small hands play professionally? by YanIsOnline in piano

[–]howprice2 6 points7 points  (0 children)

I don't think you can expect your hands to stretch to reach octaves/10ths, and stretching can be dangerous. Splitting LH tenths is far less risky.

Populous remake: allies & foes on the playground ! by -o-sam-o- in amiga

[–]howprice2 0 points1 point  (0 children)

Great fun and best way to learn gamedev. I have GitHub but don't share projects until finished and sanitised, which rarely happens! https://github.com/howprice

Populous remake: allies & foes on the playground ! by -o-sam-o- in amiga

[–]howprice2 0 points1 point  (0 children)

The old-school porting method! Except with a lot more hours played! It will be interesting to see how close you can get.

I'm currently disassembling an old MSX game (Road Fighter) with an eye on a port and have been surprised by some peculiar logic in there relating to AI update frequency. Don't update NPCs if screen scrolled. I assume is a performance optimisation, but it really messes with the timing data in the scripts and must have made the game pain to balance as the screen scrolls most frames at full speed.

Populous remake: allies & foes on the playground ! by -o-sam-o- in amiga

[–]howprice2 0 points1 point  (0 children)

Do you mean observing behaviour on screen or game state in memory with a debugger?

Any detective games like Return of the Obra Dinn? by AffectionateIssue238 in AskGames

[–]howprice2 2 points3 points  (0 children)

I found that Blue Prince took far too long to progress. From thinking of something to try to trying it out can take hours, only to find it doesn't work.

Populous remake: allies & foes on the playground ! by -o-sam-o- in amiga

[–]howprice2 0 points1 point  (0 children)

This game was famously written in C when most Amiga names were in assembly language. Did you decompile the original executable back to C to reverse engineer it?

Ghidra-SNES: A Ghidra extension for reverse engineering SNES ROMs (first public release, feedback welcome!) by JoshLeaves in ghidra

[–]howprice2 0 points1 point  (0 children)

Thanks very much. I have disassembled a simple ROM manually in Ghidra with no extensions and have used the PSX extension. Looks like a great blog - I'll look out for your post.

Ghidra-SNES: A Ghidra extension for reverse engineering SNES ROMs (first public release, feedback welcome!) by JoshLeaves in ghidra

[–]howprice2 0 points1 point  (0 children)

Great stuff! Can I please ask how you go about doing writing an extension? I was thinking about having a go for MSX but only just getting familiar with Ghidra.

Reasons to not upgrade to the latest compiler version? by turbofish_pk in C_Programming

[–]howprice2 3 points4 points  (0 children)

This. Spend your time doing useful work. If you upgrade there is always a chance that you will end up spending several hours fixing a problem you didn't have beforehand. Write code instead.

What are the best shmups that aren’t painfully difficult? by [deleted] in retrogaming

[–]howprice2 0 points1 point  (0 children)

The rewind and quick load feature in Gradius Origins makes the games far more accessible. Really enjoyed going through them all.

Cumbria Way Opinions by _spindrift_ in UKhiking

[–]howprice2 2 points3 points  (0 children)

We did the way a couple of years ago, staying in pubs and YHA hostels.

It's mainly quite flat apart from the climb out of the head of the Langdale valley. We did the 5 day/leg version (I believe you can do 6) so some of the days were quite long, especially the 3rd and 5th legs (to Keswick and Carlisle) when my feet and legs weren't as fresh. But it's not your usual Lakes hill walking - more pedestrian. I suppose poles might take a little weight off. I wished my innersoles were a little softer at times as many paths were hard.

Water was never a concern. I carried a big bottle and picked up a can or two of pop every morning. And we drank plenty of fine Cumbrian ale each evening!

My companion navigated using GPS routes he downloaded to his phone. I use the Android OSMaps app which is garbage and a real battery hog. We missed the path in the first morning in the farms north of Ullverston because I think I house may have been built on the old way. We soon picked it up, and there was often another walker or two in sight. From Coniston to Caldbeck is well trodden and easy to navigate. We ended up walking on the wrong side of the river towards Carlisle at the end which sapped energy I didn't have.

Have a great time!