|
Author | Topic: SRAM doesn't work (Read 90 times) |
TheMVRules Burger Head
  member is offline
i'm t3h h0ly k1ng 0f w0r1d
Joined: Oct 2009 Posts: 12 Location: sweden
|  | SRAM doesn't work « Thread Started on Oct 19, 2009, 8:11am » | |
Strings works but longs gives you an assembler error and integers crashes the rom with an 'Adress Error'. Also, the saveram example doesn't save anything.
| blah blah |
|
Mairtrus >> 9 MILLIMETER <<
     member is offline
![[avatar]](http://i114.photobucket.com/albums/n273/patriaka/shaow_f.png)
^^ LOL caveman
Joined: Nov 2007 Gender: Male  Posts: 120 Location: Mendoza, Argentina
|  | Re: SRAM doesn't work « Reply #1 on Oct 22, 2009, 5:09pm » | |
Maybe you didn't set correctly the SRAM support. Maybe if you post how you are trying to access to the SRAM we can help you.
|
¿Tenés problemas con BasiEgaXorz? ¡Escribime, carajo! |
|
TheMVRules Burger Head
  member is offline
i'm t3h h0ly k1ng 0f w0r1d
Joined: Oct 2009 Posts: 12 Location: sweden
|  | Re: SRAM doesn't work « Reply #2 on Oct 23, 2009, 9:44am » | |
I'm copying the code from the SRAM example, but using ReadP/WriteP instead of those old writing commands.
| blah blah |
|
jlf65 >> 9 MILLIMETER <<
     member is offline
Joined: Dec 2005 Gender: Male  Posts: 225
|  | Re: SRAM doesn't work « Reply #3 on Oct 26, 2009, 3:16pm » | |
If you aren't using a custom cart you built yourself, you're using an MD-Pro or a Neo Myth. Both use the SSF2 rules for accessing SRAM:
store a byte of 0x01 to 0xA130F1 to enable SRAM as writable store a byte of 0x02 to 0xA130F1 to disable SRAM store a byte of 0x03 to 0xA130F1 to enable SRAM as write protected (read-only)
Once the SRAM is enabled, you read/write the ODD bytes between 0x200001 to 0x20FFFF.
| |
|
|