Memory Mapping - Super Nintendo Entertainment System Features Pt. 09

Sdílet
Vložit
  • čas přidán 2. 09. 2019
  • How does the SNES's CPU know how to interact with all the different types of memory available? It's all explained right here.
    LINKS
    Twitter (updates): / retrogamemechex
    Patreon (support): / rgmechex
    Discord (discussion): discord.rgmechex.com
    PATRONS
    Thank you to all of my supporters on Patreon! I really appreciate the support!
    Dan Salvato, F. Murmel, Ange Albertini, Avi Drissman, Mike Gerow, Larry Koubiak, Joshua Goyder, Tina Wuest, Xander, Owen Christensen, Gynvael, Alec Johnson, Sijmen Schoon, FFVIMan, Chris Margroff, Brandan Lennox, Nik, Jason Hughes, Diamond Ice, Chris Post, Cypher Signal, Shannon Potter, Rupix, Gabe S, krivx, Walter Huf, Pixy011, David Spalding, Acceleration Shark, David Johnson, Gary Fenstamaker, Rory Kelly, Carl Cassler, Joe Mecca, Michael Greb, Kefen, Yann Le Brech, Nightcap, leftler, Drew Fitzpatrick, Foxchild, Scott Beca, 19day, VaporwaveProtogen, SUPER315, Chuck Ries, tripper, Nebelwerfer Granitara, Sten, 333Rich333, Glenn hEADcRASH Sugden NPC, Alex Yancey, David Mazarro, Steven, LiraNuna, null, Ryan, Corey Ogburn, Martin Trozell, Scott Harper, Garret Kelly, Jake Hickman, Narskogr, Joel Kuhn, Dan Shedd, Sembiance, 4F Panda, Max Roncace, David, A Sentient JDAM, Brian Henriquez, Travis Nellor, Zach Hugethanks, Buddy, Mikely Whiplash, Yakov, Joseph M, Oxygen Chen, Israel Jacquez, RetroReversing.com, yuriks, Chris Apple, Ceres, Jeremiah, jesugtz, Chris Roy, Chris Connett, Mark, Matthew, sapslaj, Jonathan Scott, Gescheit Gespielt, Seth N. Hetu, Xkeeper, Bjoern Hansen, ers35, Daniel Bernard (ReckedCat), Vier Ladair, Bwangry, Jared Johnstone, Phil Clayburn, zephyrin, Kit Spindler, Johnathan Roatch, Jeremy Wright, newnintendo64, Brandon, Matt Shepard, Felix Freiberger, Sypwn, William Thomas, Niles Rogoff, Kusabi, Reflet, Ly Fecha, Paxton Sanders, Eugene Bulkin, Walter Weaver, Gethiox, Zoe Mettauer, nexilar, Articate, Julian Meinking, Julien Oster, Braydon Kains, Juniper, buzzert, Steve Losh, Samuel Stoddard, Farrell Hayman, HattyJetty, Paige ☆ Hex, Yeero, Cruz Godar, Linh Pham, Noah Greenberg, Nick Rogers, & Adrian!
  • Hry

Komentáře • 275

  • @andriypredmyrskyy7791
    @andriypredmyrskyy7791 Před 5 lety +317

    It's crazy how such an obtuse and unintuitive subject can become simple and clear through just proper explanations and simple diagrams.
    Thank you for your work.

    • @LittleRainGames
      @LittleRainGames Před 4 lety +7

      @@B3Band ive been reading up on assembly for the snes, and this makes it so much more clear.

    • @ETXAlienRobot201
      @ETXAlienRobot201 Před 4 lety +13

      programming, in general has that reputation because people just don't explain it properly...
      assembly and other low-level cocepts tend to have it worse since they're considered "obsolete" in most applications [till you mess with drivers, compilers, NEW systems, embedded systems, so on]
      i'm personally starting to see assembly and whatnot as being positively more SANE than C++ and its derivatives..
      they still can be hard without the right sources of documentation, but the only real difference is there's a lot of manual memory management, and it takes many small steps to do something that seems 'simple' in other languages. i admit it's scary that you could so easily cause a fatal exception and totally crash the machine, but i somewhat prefer that over the abstractions and crap built-into C++ and the likes
      not sure if i'll ever touch SNES homebrew or hacking, but this is an awesome series, and i do find it quite interesting actually being able to LEARN how this stuff works. One of the big turn-offs for me is that finding good documentation is next to IMPOSSIBLE. [btw, don't lookup windows exes...]
      i've currently been looking into 68k assembly and trying to reverse-engineer a NEO-GEO game. that's... umm...interesting. So far, documentation on the system is pretty good. My gripe is the CPU... I have currently three major sources of documentation I'm using, all for specific purposes... >.> [Which is why I have not touched this particular project for months until now.] Ofc, the M68K is actually a fairly complicated processor, but it certainly isn't as bad as x86! I'm slowly starting to grasp it better. At least there was thought into what kinds of complicated instructions were really necessary. One of my least favorite x86 things to actually try and understand is/was "repeat not equal scan a string of bytes" aka repne scasb. I kinda get it now, but not personally one of my favorite opcodes to stumble upon... It's one thing to say "this is how you get the length of a string" [its main use]. It's another to break it down and EXPLAIN what, exactly it's doing...
      I have a few windows games I'm looking at, but I'm a bit burnt-out from the combination of x86's nightmare fuel instruction set and the way windows executable files work behind the scenes. It's just not fun... Good news is what I was doing this for was mainly to break-apart resource files, which I'm slowly figuring-out on my own. [and with some help] I could probably code the logic for one of these games by myself, now. The others might require some research, but it's certainly faster than slowly working-through assembly code.
      Anyways, the content on this channel is pretty top-notch. The world needs more like it. Maybe assembly wouldn't scare people so much, and maybe homebrew development and/or ROMhacking would be more accessible, if the resources were actually OUT there to explain it in a manner that's easy to digest. So far, they're quite lacking...
      I know assembly used to completely terrify me. And then I discovered the small handful of places that explain it in a way that it may be understood. [from my experience, it's usually not those technical manuals] I'm nowhere in a position to be completely proficient with it, or make use of it, but I'm learning, slowly. It's overall a pretty fun process. It can be stressful or frustrating, but it's exciting to learn about, especially actually be able to understand even a fraction of just how our computers manage all the complexity that most of us would take for granted.

    • @totaltotalmonkey
      @totaltotalmonkey Před 4 lety +1

      What about C, it's supposed to be closer to the 'metal' than C++?

    • @nebularain3338
      @nebularain3338 Před 4 lety +1

      @@B3Band He meant simple as in "easy to read", not "easy to make".

  • @Smokecall
    @Smokecall Před 5 lety +100

    With explanations like this, you could be a college professor of a SNES programming course

  • @FoxerTails
    @FoxerTails Před 5 lety +194

    Oh boy, next one is going to be about the SPC-700. I've been anticipating that one.

    • @DrakkarCalethiel
      @DrakkarCalethiel Před 5 lety +5

      Tails19935 The last three are the ones that interest me the most.

    • @aurathedraak7909
      @aurathedraak7909 Před 5 lety

      Yep

    • @henke37
      @henke37 Před 5 lety

      Yes, but actually no. The audio videos are going to be split. The next one will just be about how it interfaces with the rest of the system. Or so I hear.

    • @FoxerTails
      @FoxerTails Před 5 lety +4

      @@henke37 If that is the case then I can understand why. Like how the Super FX chip and other peripherals are going to be covered in a sperate video as mentioned in this one.
      To which I'll do the same as I've been doing. Waiting patiently while also enjoying any other content that comes down the pipeline.

    • @Menaiya
      @Menaiya Před 5 lety

      I can't wait either. This is an awesome series.

  • @epicsause21
    @epicsause21 Před 5 lety +144

    The more I watch this, the more i think, "wow the snes really is a super version of the NES"

    • @renakunisaki
      @renakunisaki Před 5 lety +31

      It was originally meant to be backward compatible! But they couldn't make that work without being too expensive.

    • @moosemaimer
      @moosemaimer Před 5 lety +29

      @@renakunisaki It's such a shame that they underclocked the CPU for that, but were too far along in development to reverse it when they cancelled the feature.

    • @aaendi6661
      @aaendi6661 Před 5 lety +14

      The Snes's CPU isn't even a problem. Everybody just programmed it the wrong way.

    • @JoaoBapt
      @JoaoBapt Před 4 lety +21

      @@aaendi6661 Well, if the programming techniques known to the programmers at that time were completely unorthodox to how the CPU should be programmed, is it the designer's fault or the programmers' fault?
      For me, particularly, the best thing they did on the GBA was putting an ARM processor.

    • @aaendi6661
      @aaendi6661 Před 4 lety +13

      @@JoaoBapt All they had to do was ditch the belief that "the more cycles you use the faster it runs."

  • @vuurniacsquarewave5091
    @vuurniacsquarewave5091 Před 4 lety +53

    Now imagine, on NES you only have the first column of this graph, 0000-FFFF, so only 16-bit addresses. This 64kB area is then broken down similarly:
    0000-07FF - 2kB Work RAM
    0800-1FFF - Mirrors of Work RAM
    2000-2007 - PPU registers
    2008-3FFF - Mirrors of PPU registers
    4000-401F - APU (sound) & Joypad registers, Factory testing registers (locked without modding)
    4020-7FFF - Not mapped / Open bus (typically used by extra Work or SRAM and more advanced MMC chips)
    8000-FFF9 - Cartridge ROM (an MMC chip in the cart if any, is responsible for banking the larger ROM into this area)
    FFFA-FFFF - Interrupt Vectors

    • @BastetFurry
      @BastetFurry Před 4 lety +6

      The SNES was planned to be backwards compatible but that idea was canned half trough the project, too late to change stuff around tough.

  • @LAMGFGC
    @LAMGFGC Před 4 lety +30

    oh, so that's why most action replay codes starts with 7E i wish i knew that back in the 90's

    • @hi_tech_reptiles
      @hi_tech_reptiles Před 3 lety +4

      I remember realizing that AR and Game Shark codes were all just hex code injected into games. I knew much less about computers/programming then, but it was def a profound realization lol

  • @MrOnosa
    @MrOnosa Před 5 lety +88

    Yay! More technical details about a system I'll never need to know about, but love learning about anyways!

    • @samuelthecamel
      @samuelthecamel Před 5 lety +1

      Sounds like school, just remove the "love" part

    • @Justin-TPG
      @Justin-TPG Před 4 lety +3

      Although, now that you do know a load of the technical details, why not do something with it just for fun? :-D

    • @DrNoBrazil
      @DrNoBrazil Před 4 lety +1

      You also don't "need" to know about history, art, geography, and so on... After all, you just need to know how to open your mouth and throw pringles in there... You will go very far in life with such mindset. Let me guess, another millenial?

    • @jl86_
      @jl86_ Před 4 lety

      @@DrNoBrazil What about Math?

    • @MrOnosa
      @MrOnosa Před 4 lety +3

      @@jl86_ Don't feed the trolls. He's wrong anyway. I prefer Funyuns.

  • @PC_YouTube_Channel
    @PC_YouTube_Channel Před 5 lety +59

    One of my favorite channels on CZcams. By far. Not only is the content niche and extremely interesting, but the delivery and presentation is absolutely exceptional. Keep it up!

  • @2WaterGuns
    @2WaterGuns Před 5 lety +6

    I'm glad you explained *why* all the different mapping modes exist. It seemed unnecessarily complicated to me when I read it (compared to the Genesis, for example, where the map is almost always the same), but having different modes for different tradeoffs w.r.t. data contiguity and access time makes a lot more sense.

    • @aaendi6661
      @aaendi6661 Před 4 lety +1

      It's too bad 99% ended up just using long addressing for everything in SNES, throwing any speed benefit from the way nintendo organized memory out the window.

    • @butterflyfilms939
      @butterflyfilms939 Před 4 lety

      @@aaendi6661 I'm very interested into which games actually used the SNES the best way possible, do you have examples?

  • @No-uc6fg
    @No-uc6fg Před 5 lety +36

    8 AM and an RGME video.
    Today's going to be a good day.

  • @discoRyne
    @discoRyne Před 5 lety +18

    Underrated creator. Keep it up bud, hope you hit 1M soon.

  • @kenfagerdotcom
    @kenfagerdotcom Před 5 lety +13

    I have a hard time entirely understanding these videos, but in every one I learn a little bit something new about the wonderful SNES. Keep up the good work.

  • @aaendi6661
    @aaendi6661 Před 4 lety +12

    The funny thing is that, Nintendo spent all this effort designing the memory map so programmers could use 16-bit addressing mode, yet 99% of programmers went with long addressimg mode for everything anyway.

    • @vuurniacsquarewave5091
      @vuurniacsquarewave5091 Před 4 lety +2

      what... but that's a huge hit on performance on an already underclocked CPU... It really should've run at 7.12Mhz, like the Turbografx

    • @aaendi6661
      @aaendi6661 Před 4 lety +4

      @@vuurniacsquarewave5091 The reason why everybody did it like that was because Konami did it that way, and everybody just took Konami's word for it.

    • @musaran2
      @musaran2 Před 3 lety +4

      Turns out developer time is a finite ressource too, and more costly than hardware.
      Also, hardware designers have a very bad habit of poor documentation. I do remember many early SNES games lagged unnecessarily because of this.

  • @ASAPShitPost
    @ASAPShitPost Před 5 lety +3

    This is why I never got very far into learning ASM when ROM hacking Super Mario World as a kid 😅 this stuff went way over my head. I'm sure I could learn it much easier now as an adult, but that scene has pretty much died out. Excited for the SPC video!

    • @vytah
      @vytah Před 5 lety +1

      To be fair, 65816 assembly is quite complicated and widely considered ugly. It's tricky to write and hard to decompile. Assembly and game hacking on a 6502-, Z80- or 68000-based platform would be much easier.

    • @aaendi6661
      @aaendi6661 Před 4 lety +2

      If you tried learning ASM from SMWCentral, it's no wonder why you would be confused. The SMW hacking scene has been notorious for getting facts mixed up.

  • @Brick_Eater_
    @Brick_Eater_ Před 3 lety +2

    I'm the most hardcore kind of gaming nerd and I didn't realize until I read out this comment from Tails19935: "Oh boy, next one is going to be about the SPC-700. I've been anticipating that one."

  • @amazingagent1404
    @amazingagent1404 Před 5 lety +1

    These are some of my favorite videos on CZcams. Amazing work!

  • @codiivt
    @codiivt Před 5 lety +9

    I love this series, it's super interesting, very well written and comprehensive. Thank you RGM, very cool.

  • @JSwanson547
    @JSwanson547 Před 5 lety +5

    Imagine if Nintendo had actually gone through with full NES backwards compatibility. I wonder how they would've implemented the audio in that case.

    • @aaendi6661
      @aaendi6661 Před 4 lety +3

      I actually wish the SNES had NES audio as well as a couple extra channels. The SPC700 is frustrating as hell to work with.

    • @ricarleite
      @ricarleite Před 4 lety

      Emulation?

    • @masicbemester
      @masicbemester Před 11 měsíci +2

      ​​@@aaendi6661is it possible to make some kind of expansion like the Super Game Boy but for NES games? There would be a NES CPU, PPU, and RAM (somehow condensed idk) as well as a NES cartridge port. I wonder if the NES APU could be played alongside the SPC700. Not sure how the Super Game Boy does it (if it even includes the LR35902 sound at all, I should've searched this up before writing)

  • @itsjoe8443
    @itsjoe8443 Před 5 lety +1

    Yay! Love this series, you have a way of explaining all these concepts and make them so easier to grasp :D

  • @Dhalin
    @Dhalin Před 5 lety +16

    *FOR THOSE ASKING ABOUT 'WHY MIRROR RAM'*
    From what I got (I'm no expert, but I have at least some understanding of memory and programming) .... picture a Playstation Game on 4 discs. Say, FF8. As you go through the game, you can revisit older areas. Why? Because those older areas' data are mirrored on the later discs. If they didn't mirror the older areas' data, then you would get a "Please Insert Disc 1" every time you wanted to step into Balamb Garden, for example. The memory mapping works much the same way: If you're working in a specific area of the RAM, it is much slower to jump out of that section, and into another section to find the data you need. UNLESS, of course, you copied that data and mirrored it into several different sections. Now, they didn't mirror ALL of the data, only some of it, just like in FF8 .... dialogue and cutscenes, for example, the FMV video that plays during the assault at the beginning of the game only exists on Disc1, as does the FMVs where Squall is dancing with Rinoa. Why? Because you'll never see that cutscene past that point in the game, no point in copying that onto the other discs. But, Balamb Garden's assets need to be copied onto 3 of the discs, because it is possible to visit Balamb Garden at multiple points in the game. You don't want the player switching discs constantly, so you copy some of those assets that you think the player will be needing periodically throughout the game. Make more sense?

    • @thealliedhacker
      @thealliedhacker Před 4 lety +4

      But the whole point of RAM is that it allows random access... I'm not sure what it means to "jump out of" a section of RAM, I'm not sure that makes sense. Are we talking about caching, or segment registers, or what?

    • @Dhalin
      @Dhalin Před 4 lety +1

      @@thealliedhacker If you saw earlier in the video, you address different parts of RAM with addresses. $AABBCC format where AA is the pointer to what section of RAM you're working in. Let's say there's an address that you need some data from at, say, 01AAAA. You could just simply write "AAAA" (which saves you 2 letters in the code) and if you're already working in area 01XXXX, the 01 is implied unless specified otherwise. But what happens if you're working in area 07XXXX and you need the data that's stored at 01AAAA? You'd have to code your instruction to specify 01AAAA every time you want to point to that data. Unless of course that 07AAAA is mirrored and is the same as 01AAAA. Then you could, in fact, just write AAAA and you'd get the same data (you'd be jumping to 07AAAA but that's fine, because 07AAAA has the same data as 01AAAA).
      EDIT: Also, correct me if I'm wrong, but if you're working in area 07XXXX and you specify that you wanna go to 01AAAA for data, doesn't the implied area change to 01 so you'd have to again change it back to 07 to return to area 07?

    • @thealliedhacker
      @thealliedhacker Před 4 lety

      @@Dhalin Well, that just sounds like we're trying to save memory by reducing the size of the instruction, not that the instruction will actually take longer to execute. It still seems like the speed is the same, unless decoding the longer instruction is slower or switching the bank has its own intrinsic cost for some reason...

    • @Dhalin
      @Dhalin Před 4 lety +1

      @@thealliedhacker Well, if my edit is true, then it would also take extra instruction time to swap whatever the "current" area of RAM is, too. There's probably more to it, in the actual circuitry, a millisecond here, a millisecond there, I mean, a lot of SNES games lag as it is when there's too much going on, so I'm sure they did these things for a valid reason.

    • @thealliedhacker
      @thealliedhacker Před 4 lety

      ​@@Dhalin Well, I assume it wouldn't require an extra instruction to move back though, since the next instruction could also just use an extended address, so we still wouldn't lose any time...? I dunno, maybe the main factor is just saving the space in the instructions.

  • @jekrixlokan4507
    @jekrixlokan4507 Před 5 lety +2

    I wish there was some quiz or something so I could make sure I'm properly digesting this information properly

    • @ricarleite
      @ricarleite Před 4 lety

      I always go back to older videos to remember a few things. This one is pretty self contained though.

  • @jooniethebest3709
    @jooniethebest3709 Před 5 lety +2

    Yes, I've been waiting for this! Nice video, it really taught me alot!

  • @fluffy_tail4365
    @fluffy_tail4365 Před 5 lety +2

    Excellent presentation as always. Memory mapping becomes intuitive with nice graphics!

  • @Perfectly_Luminous
    @Perfectly_Luminous Před 2 lety

    I love your video style! It's great for listening to when I'm working on things, I've already seen every video at least 3 times so far.

  • @jmanrocks152
    @jmanrocks152 Před 5 lety +1

    Hella cool as always!
    I love learning about how the old tech worked, and you teach it well!

  • @Nikku4211
    @Nikku4211 Před 5 lety +18

    I can't wait until 2020 when you will cover the S-DSP and SPC700 and we will see the true extent of pitch modulation, white noise, the delay module, and what's up with that BRR compression.

  • @tchitchouan
    @tchitchouan Před 5 lety +5

    next one will be the one we've been waiting in years

  • @opalpersonal
    @opalpersonal Před 4 lety

    I’m not even gonna pretend I can understand everything you’re talking about, but I still can’t get enough of your videos. You are too good! Keep it up.

  • @supernunb3128
    @supernunb3128 Před 5 lety +1

    Thank you so much for explaining the memory mapping! That was the confusing part of most of your prior videos having to do with RAM.

  • @MrBillgonzo
    @MrBillgonzo Před 5 lety

    I'm soooooooo excited for the next video!!! Always amazing and detailed content!

  • @miltiadiskoutsokeras9189
    @miltiadiskoutsokeras9189 Před 5 lety +6

    Brilliant stuff. Hoping for Mega Drive, PC Engine, Neo-Geo in the future. Good to know how my favorite stuff work.

  • @glitchy_weasel
    @glitchy_weasel Před 5 lety +1

    Such an interesting video! Love your channel, keep it up :D

  • @VivienBihl
    @VivienBihl Před 4 lety

    You are a legend. Everything so far is crystal clear. I can't wait for the SPC 700 video.

  • @markusfischhaber8178
    @markusfischhaber8178 Před 4 lety +2

    One thing to add is that the cpu can have 24 bit instructions. But works faster if you restrict yourself to instructions using only 16 or 8 bit addresses. This makes it useful to layout the memory in such a complicated way

    • @aaendi6661
      @aaendi6661 Před 4 lety

      Too bad nobody took advantage of this.

    • @MarioFanGamer659
      @MarioFanGamer659 Před 4 lety

      @@aaendi6661 I'm sure you're exaggerating a bit... Then again, I don't know too much of the SNES outside of SMW and YI.

    • @aaendi6661
      @aaendi6661 Před 4 lety +1

      @@MarioFanGamer659 I don't know about Yoshi's Island, but Super Mario World definitely overuses long addressing.

    • @MarioFanGamer659
      @MarioFanGamer659 Před 4 lety

      @@aaendi6661 I get your point but also remember that SMW is a launch game (it also was slightly rushed, IIRC) and the 65c816 processor is a rarely used processor it makes sense why it used unnecessarily long addressing (at least the lack of data bank shenanigans). Of course, it also uses (sometimes) long addressing when it isn't absolutely necessary (either same data bank or data bank switch is faster) which is where I get the "overused" part (I still believe you make mountains out of molehills, though).

    • @aaendi6661
      @aaendi6661 Před 4 lety +1

      @@MarioFanGamer659 Capcom never got any better with it.

  • @hicknopunk
    @hicknopunk Před 5 lety +2

    Thank you! I have wondered about this for some time.

  • @PhoenixClank
    @PhoenixClank Před 5 lety +2

    This goes straight above my head. (I still love watching it.)

    • @PhoenixClank
      @PhoenixClank Před 2 lety

      I just found this comment and by now I just about understand the video.

  • @LeftClickShift
    @LeftClickShift Před 5 lety

    Fantastic work on this!!

  • @DavidScotton
    @DavidScotton Před 4 lety

    Thank you, great video. This is the part of the SNES that I've really wanted a good explanation for.

  • @whamer100
    @whamer100 Před 4 lety

    hell yes, finally more of this, cant wait for the last two

  • @LeviathanRX
    @LeviathanRX Před 4 lety +1

    An unexpected windfall after a long day at work, time to kick back and nerd out =)

  • @johneygd
    @johneygd Před 4 lety +1

    Can’t wait for that sound department because it’s a really interesting subject to discuse about it.

  • @stcrussman
    @stcrussman Před 5 lety

    Great stuff, as always.

  • @renakunisaki
    @renakunisaki Před 5 lety +5

    Some Game Boy games might have had those null buffers too. I always wonder if they contain anything interesting. Even a ROM dump usually won't include them, unless it's done by extracting the actual chip.
    (The GB games would be any that use MBC1 chip with more than 1MB of ROM. But I'm not sure any exist... 😅)

  • @interactii
    @interactii Před 5 lety

    Another great video!

  • @chromosoze
    @chromosoze Před 5 lety +8

    *watches video about an interesting topic*
    i am bored
    *sees this*
    OH BOY

  • @nyccollin
    @nyccollin Před 4 lety

    Were you even alive when the SNES was popular? Great video!

  • @lively2774
    @lively2774 Před 5 lety +2

    my happiness levels have gone to maximum. and on my birthday, now thats epic

  • @somefreshbread
    @somefreshbread Před 4 lety +1

    God, your diagram game is SO damn good. Jesus man.

  • @parknplay8328
    @parknplay8328 Před 5 lety +2

    Almost at 100,000 subs LETS GO

  • @ggamer77
    @ggamer77 Před 5 lety +1

    Can't wait for the SPC700 video.

  • @onffxiimanon
    @onffxiimanon Před 5 lety

    This is super interesting and really helps me understand how mashups like Zelda/Metroid randomize works. One question for you: I thought Star Ocean used ExLoROM but you said it was never used by official games. What Map does Star Ocean use?
    Thanks again! I love the series!

    • @Dhalin
      @Dhalin Před 5 lety

      Well, if the game is bigger than 6MB, and if ExLoROM wasn't used commercially, then the only other choice would be ExHiROM. That, or they did some bank-switching magic like they used to do in the AT2600 days. I dunno if that's possible on a SNES or not, so just throwing theories out there?

  • @thegreatb3
    @thegreatb3 Před 4 lety

    Woo! 100,010 subs! Congrats!

  • @undefined7206
    @undefined7206 Před 5 lety +3

    Me and the bois learning about memory mapping

  • @frallan874
    @frallan874 Před 5 lety

    I Love these vids

  • @PicochillaTH
    @PicochillaTH Před 5 lety +25

    3:04 - "Retro Game Machanics says FF FF for 1 hour" when? :P

    • @ReatExists
      @ReatExists Před 4 lety

      FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF

    • @Dargonhuman
      @Dargonhuman Před 4 lety +6

      "F" to pay respects.

    • @smallgreen2131
      @smallgreen2131 Před 4 lety

      FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF

  • @d0nnyr0n
    @d0nnyr0n Před 5 lety +6

    Yeeeeeeeeeaaaaaaahhhhhhh! More technical-ness! Btw, do you think you will do the Sega Genesis after the SNES? I was just wondering bc I am intrigued about it.

    • @Redhotsmasher
      @Redhotsmasher Před 5 lety +4

      Sega Saturn would be even more interesting IMO.

    • @d0nnyr0n
      @d0nnyr0n Před 5 lety +1

      @@Redhotsmasher Saturn does sound interesting...

    • @jl86_
      @jl86_ Před 4 lety +1

      @@Redhotsmasher With how complex it is to program on it (from what I've heard at least), it definitely sounds interesting.

  • @commander_red
    @commander_red Před 5 lety +3

    Only 800 subs to 💯 k! But you really deserve it!

    • @chinarut
      @chinarut Před 4 lety

      Commander Red 🙌🏼 🎊

  • @MizoxNG
    @MizoxNG Před 5 lety +10

    emulation mode and a bunch of stuff meant to be backwards compatible with the NES... interesting...

    • @canebro1
      @canebro1 Před 4 lety

      "If it ain't broke don't fix it"

    • @ricarleite
      @ricarleite Před 4 lety +4

      Which was never actually put into good usage.

  • @Biospark88
    @Biospark88 Před 2 lety

    The more I learn, the more respect I have for Nintendo for sneaking all these workarounds in. They knew they effed up with their choice of a CPU (and their orphaned NES legacy), but they crammed in all the secret features they could to compensate. And when a developer actually USES them? The system punches well above its weight.

  • @madghostek3026
    @madghostek3026 Před 5 lety

    On the way to 100k subs!

  • @DaveVoyles
    @DaveVoyles Před 4 lety

    ** Replaces every university professor where it costs $50k/yr with this guy's CZcams channel **

  • @ponocni1
    @ponocni1 Před 5 lety

    after watching this vid i have more questions, then answers. And these questions are new ones.

  • @SammYLightfooD
    @SammYLightfooD Před 4 lety

    And I'm not even into SNes programming. But this is presented perfectly, respect!

  • @Jackpkmn
    @Jackpkmn Před 5 lety +1

    God it's so dry. *I love it!*

  • @iwanttocomplain
    @iwanttocomplain Před 18 dny

    3:33 Nintendo reversed the memory addresses? The mental gymnastics of working in this memory map would drive me to an early grave.

  • @dexterhaxxor
    @dexterhaxxor Před 2 lety +1

    Objects in address space may be smaller than they appear

  • @lollol-cx3pd
    @lollol-cx3pd Před 3 lety +1

    So fucking underrated

  • @strangedude9008
    @strangedude9008 Před 4 lety

    please posess assembling a playlist of this series

  • @andrew_stamps
    @andrew_stamps Před 5 lety +2

    I still dont get why the Address space wastes so many addresses on mirroring why mirror if the entire 24bit space is addressable? is it to save clock ticks on higher address access? Just dont get the logic.

    • @0x5D
      @0x5D Před 4 lety +3

      Incomplete decoding of addresses was a common trick to save transistors back then. The decoder circuit would only check the n highest or lowest bits of the address instead of checking every bit. Often, e.g. with smaller ROM chips, the excess high address lines were just ignored, which resulted in ROM mirroring over the CPU address space.
      And not many games used the entire ~8 MB theoretical ROM capacity of an un-switched SNES cart. They only started pushing this towards the very end of the SNES's lifespan. Super Mario World was only 512 KB.

  • @haruki_nyan
    @haruki_nyan Před 4 lety

    The LoROM seems similar to how memory mapping worked on the NES. If the program bank register is between $80 and $BF, the data bank register set to $80, and the direct page is set to $8000, the memory is almost laid out the same as the NES.

  • @GeneralBolas
    @GeneralBolas Před 5 lety +1

    All this block mirroring stuff makes me wonder if there is something going on that I don't know about. For example, is using a 24-bit address sufficiently burdensome that trying to use a 16-bit address within the same bank is preferable? Besides the obvious fact that 24-bit memory instructions are 32-bits in size, and the difficulty of assembling a 24-bit address from two registers.
    That's the only reason I can come up with for why mirroring would be so frequently used, when you could just have more available storage in the ROM.

    • @RGMechEx
      @RGMechEx  Před 5 lety +2

      As you'll see in the followup to this video, mirroring is just a side effect of the simplest and easiest way of interfacing with memory chips.

  • @Redhotsmasher
    @Redhotsmasher Před 5 lety

    I think this series should have a video on how the (unreleased) SNES CD addon works as well.

    • @CarbuncleMotha9
      @CarbuncleMotha9 Před 5 lety

      Hard to tell. There's only one "accessible" copy of the hardware in existence, its specs aren't well known, and when they attempted homebrew on it it wouldn't run without severe glitches due to... the SNES CD (Sony) adding new, completely unknown hardware interrupts.

    • @Redhotsmasher
      @Redhotsmasher Před 5 lety

      @@CarbuncleMotha9 I thought they got homebrew working properly in the end? Perhaps I'm mistaken.

  • @supermegazeldaland
    @supermegazeldaland Před 5 lety

    That is a cozy graph

  • @WillowEpp
    @WillowEpp Před 4 lety

    Please do a supplemental explanation for the Super Metroid/Link to the Past crossover randomiser so there's a decent explanation for linking literally anywhere.

  • @SC-iv7tj
    @SC-iv7tj Před 4 lety

    Your good at this, try the N64: Super Mario 64 Stair Glitch Explained

    • @DrayCrouse
      @DrayCrouse Před 4 lety

      You mean the Backwards Long Jump?

  • @memegasm8972
    @memegasm8972 Před 4 lety +1

    Going from the VIC 20 memory map to this was not a good idea, it was enjoyable tho.
    not even planning to learn assembler, just wanna know more or less the ins and outs of 8 and 16 bit machines.

  • @romajimamulo
    @romajimamulo Před 5 lety +1

    ... so all of these mirrors are so if you're on a particular vertical line/bank, what you can access from there without changing banks?

    • @0x5D
      @0x5D Před 4 lety +2

      For the RAM mirroring, yes. The 65816 instruction set was such that accessing data in the one "current" bank was 1 or 2 cycles faster, and took one less byte, than specifying a full 24 bit address. And the only way to change banks was with stack instructions (PHB,PLB,etc.) which were 3 or 4 cycles a pop (or push, hehe). Obviously this won't do during vblank, when you're in a tight race to get everything to the PPU for the next frame. So the solution was to have a small part of WRAM always visible in the same bank with all the I/O registers, so that if you structured your game's memory properly you wouldn't have to change banks often.
      ROM mirroring was mostly just because the ROM chips in smaller games didn't use all the available address lines. They only used the n lowest bits of the address and ignored the rest.

    • @romajimamulo
      @romajimamulo Před 4 lety +1

      @@0x5D so, basically, it's a bit like trying to use on CPU RAM for as much as possible.

  • @ninjacell2999
    @ninjacell2999 Před 5 lety +1

    Crispy

  • @BobMagana
    @BobMagana Před 5 lety

    New video!!!!!!!!!!!

  • @ge97aa
    @ge97aa Před 3 lety

    So can the normal HIROM mapping only support 128 kB of cartridge SRAM (16 banks of 8 kB segments)? I thought it supported 256 kB?

  • @InnoVintage
    @InnoVintage Před 4 lety

    Could you do a series about the Gameboy hardware?

  • @blindcat97
    @blindcat97 Před rokem

    Do you still plan to do a video about the other mapper chips, or any of the add on chips mentioned?

    • @RGMechEx
      @RGMechEx  Před rokem

      I would like to, yes, but they aren't a priority at the moment.

  • @prototypeinheritance515

    i love the snes series

  • @williamshader3370
    @williamshader3370 Před 4 lety +1

    When you write an instruction like STA 21 00, how do you know which page or what the actual address is?

    • @haruki_nyan
      @haruki_nyan Před 4 lety

      The 65c816 CPU inside the SNES has 3 extra registers for program and memory access: the Direct Page Register, Program Bank Register, and the Data Bank Register. Your question pertains to the Data Bank Register.
      The _DBR_ is an 8-bit register that specifies which bank data is accessed from when using a 16-bit addressing mode. So if the DBR has a value of $81, the instruction `LDA $2100` will access memory address $812100 . In short, the DBR acts as the high byte of the 24-bit address when a 16-bit addressing mode is used.
      Similarly, when using an 8-bit addressing mode, the _Direct Page Register_ is used. This register is 16-bit, so if the Direct Page register has a value of $7E00, the instruction `LDA $2D` will access address $7E002D.

    • @MarioFanGamer659
      @MarioFanGamer659 Před 3 lety +1

      @@haruki_nyan Except direct page doesn't represent the high and bank bytes but rather, it is the base address and the address on the opcode is an index to that base address with $00 as the bank. Sounds complicated but it's really just addr + DP on bank $00 so $7E00 on $2D actually results in $007E2D (usually not mapped to anything) instead of $7E002D. And if DP were, $00D3, you get $000100 on `LDA $2D`.

  • @coyallen5310
    @coyallen5310 Před 4 lety

    I might of missed this but where can you write to memory? like where is mario's lives/coins stored? everything seems to already be taken by mirrors or open bus space.

  • @alswo9628
    @alswo9628 Před 5 lety +5

    Patreon Notification Squad signing in

  • @bengoodwin2141
    @bengoodwin2141 Před 3 lety

    I haven't finished the video but is there really nothing that uses the space between JOY and PPU?
    Edit: oh I see, other chips can use it. Still feels strange.

  • @thecianinator
    @thecianinator Před 5 lety

    Banks wants to empty the banks, fill our streets with banks, and run a bank making operation out of his banks.

  • @moje12a
    @moje12a Před 4 lety

    Memory allocation:
    - 1st group 8-bit: cells
    - 2nd group 8-bit: pages
    - 3rd group 8-bit: banks
    - 4th group 8-bit: ???
    What next names group 8-bit ?
    (else memory bigger 16MB)

  • @Kinkajou1015
    @Kinkajou1015 Před 4 lety +1

    Can you explain why the memory map is conventionally flipped? I can't find any reasoning for it when I search but I might not be using the right terms in my search. I'm hoping there's more to it than "This is how it's always been done."

    • @RGMechEx
      @RGMechEx  Před 4 lety +1

      The memory map provided by Nintendo in their official developer's manual is in this orientation, and I guess every variation of it since then has just stuck to that orientation.

    • @Kinkajou1015
      @Kinkajou1015 Před 4 lety +1

      @@RGMechEx Thank you so much for solving that little mystery.

  • @Merrinen
    @Merrinen Před 4 lety +3

    My favorite address is $C0FFEE

  • @GustavoValdiviesso
    @GustavoValdiviesso Před 4 lety

    Wait, what!? 6502 emulation mode? I never heard about that before. You mean there's a way to execute 6502 assembly in the SNES CPU? What else is compatible with the NES? Not much I assume, otherwise we would have seen retrocompatibility back then. But I guess that explains some ports that are way too close to their NES counterparts, like Ninja Gaiden Trilogy. At least the logic could be ported, right?

    • @0x5D
      @0x5D Před 4 lety +3

      Yes, it's a standard feature of the 65816. Almost all SNES games switch to native mode almost immediately on boot though.
      The 65816 instruction set is a strict superset of the 6502's (as long as you don't rely on the "illegal" opcodes of the latter.) This similarity would generally have made it very easy to port NES code to the SNES. I imagine Super Mario All-Stars made good use of this. Has anyone actually checked? How much code in SMAS is copied verbatim from the original NES games?

    • @GustavoValdiviesso
      @GustavoValdiviesso Před 4 lety +1

      @@0x5D That's amazing. Unlike Sega, Nintendo wasn't very famous for retrocompatibility at the time and I don't remember ever reading about this before, but yet... It was there all the time.
      Now I'm also curious about SMAS.

  • @baddmatt9588
    @baddmatt9588 Před 5 lety +1

    So, are you saying the SNES is actually a 24-bit console with a 15-bit graphics card? You heard right, 15-bit. Because it can only choose from roughly 33,000 colors. 16-bit would by over 65,000 colors. Although I bet the video card itself does have a 16-bit wide data bus.

    • @renakunisaki
      @renakunisaki Před 5 lety

      It's considered 16 bit because that's the size of its CPU registers. Similarly the N64 only has a 32-bit bus.

    • @MarioFanGamer659
      @MarioFanGamer659 Před 5 lety +1

      Only the addressing is 24-bit but the SNES uses otherwise a 16-bit processor (65c816), though with an 8-bit bus. That the SNES uses 15-bits for its colour is only done to make each colour uniform as using all 16-bits means one colour can display more colours (and besides, the single bit won't make any major visual difference anyway), not to mention that the fixed colour (read: background colour) needs to be adjusted too (each primary colour in the fixed colour uses the same register: 5 bits are used for the colour value itself whereas bits 5 to 7 determine which colours to write to).

    • @vytah
      @vytah Před 5 lety +2

      If you judge CPU's by the size of their address bus, then MS-DOS was a 20-bit operating system and your PC is running now a 48-bit operating system.

    • @baddmatt9588
      @baddmatt9588 Před 5 lety

      @@vytah My understanding, CPUs bit sizing is based on it's memory allocation. 32-bit means it can allocate up to 32-bit amount of memory. Same as 64-bit. 64-bit addressing of memory.
      MS-DOS, Windows, Linux, etc are Operating System. Not CPUs.

    • @paulstelian97
      @paulstelian97 Před 4 lety

      @@baddmatt9588 Intel x64 supports up to 48 bits (currently) of virtual address bits and my particular CPU claims to have 39 physical lines. So is my CPU 39-bit, 48-bit?
      Of course not. Though I'm not sure if the pointer size (64 bits) is what gave it its name of 64-bit.
      The thing is, the bitness of each CPU is decided by convention and stuff such as address size, general purpose register size etc are mere heuristics.
      By the heuristic of general purpose registers, the Intel CPU in my laptop, the ARM (Cortex A53) CPUs in my phone and my RPI are 64-bit and the Intel 8086 is a 16-bit (with 20-bit addresses). The 65816 in the SNES is 16-bit due to its 16-bit registers (though it is claimed to be 8/16 bit due to the selectability between 8-bit and 16-bit registers; that's just another oddity in the naming, but they wanted to market that selectability so this stuck), while the 6502 is a definitely 8-bit CPU even though the address space is 16-bit.
      Look at the general purpose registers. Not address sizes, not other heuristics. The size of the general purpose registers determine the bitness of a CPU.
      If you look at the largest register, my CPU would be 512-bit due to the AVX registers. Old 32-bit-only Intel CPUs would be 80-bit because their FPU (which is inside the CPU since the '486) works with 80-bit floating point values (which some C compilers expose as "long double"). Of course that isn't a good heuristic!

  • @SuperSmashDolls
    @SuperSmashDolls Před 5 lety +3

    I have to wonder why there was never a MidROM configuration that uses the entire ROMSEL region to it's fullest. You always lose 2MB of addressing space in either configuration. (4MB for the Ex**ROM variants)

    • @aaendi6661
      @aaendi6661 Před 4 lety

      You mean a massive 95 megabit game?

    • @SuperSmashDolls
      @SuperSmashDolls Před 4 lety +1

      ​@@aaendi6661 Only if you used ExMidROM. And that's not really the point: the point is to avoid messing around with bank switching or stranding half your game in slow ROM mode.
      If you want >4MB in your ROM, you have to either use bank switching, or the slow ROM mirror space. Both are a pain in different ways, when you could get an extra 2MB "for free" by using ROMSEL space more efficiently.

  • @elecboy5126
    @elecboy5126 Před 4 lety +2

    16:46 - 16:49
    I’ve heard about misunderstandings concerning hexadecimal but this is rediculous

  • @der.Schtefan
    @der.Schtefan Před 3 lety

    Is that a Quadrant or a Quarter?

  • @danboekenoogen4957
    @danboekenoogen4957 Před 5 lety

    I really want the SFX video

  • @nathann1445
    @nathann1445 Před 4 lety

    Commodore 64 fits in one bank

  • @LordMarcus
    @LordMarcus Před 4 měsíci

    Did anything actually USE the 6502 emulation mode on the SNES???

  • @ackman3981
    @ackman3981 Před 6 měsíci

    This might have been mentioned already. At 1:10 you show the number 16777215. But say the number 16777216.