Announcement

Collapse
No announcement yet.

Project Artemis

Collapse
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Originally posted by Gtlcpimp View Post
    It is possible to perform that task, however it will not work for all games. The module dependencies will stop you when attempting that exact process. Not all games use the exact same modules as you do when you compile your source, so not all games will be compatible. For the games that you can do a live dump with, it will take a while. If you plan on doing a full 32 MB dump to the memory card, then you MUST have a good compression library embedded into your program and you MUST have a blank memory card.
    the reason i was wondering is
    that way artemis could dump then mem the load its software then reload the mem to start the game again
    Last edited by dlsmd; 02-06-2009, 05:01:56 PM.

    Comment


    • I made considerable progress in creating a basic cheat system.

      More coming soon...

      Comment


      • From what you mentioned, we've almost completely solved one of our chief concerns
        I may be lazy, but I can...zzzZZZzzzZZZzzzZZZ...

        Comment


        • How to use dump2mass

          --------
          Last edited by Maori-Jigglypuff; 03-01-2009, 12:23:13 PM.

          Comment


          • Lies deine Mail.

            Comment


            • Originally posted by Lazy Bastard View Post
              From what you mentioned, we've almost completely solved one of our chief concerns
              http://gshi.org/vb/showthread.php?t=3450

              Comment


              • Just a note, but I don't recollect any dumping functions in the dumping source, it was a bunch of launchers and nothing more.
                Code:
                void dump_memory(void)
                {
                	#define MAX_DUMPS 100
                	#define DUMP_SIZE 32000000
                	void find_dump_num(char *input)
                	{
                		int fd0;
                		int counter;
                		char *template = "mc0:/dump%d.ram";
                		for(counter = 0; counter <= MAX_DUMPS; counter++)
                		{
                			sprintf(input, template, counter);
                			fd0 = fioOpen(input, O_RDONLY);
                			if(fd0 <= 0) break;//Note it's free, nothing to close
                			fioClose(fd0);//It ain't, close it
                		}
                		return;
                	}
                	char *dumpBuff = (char*)malloc(60);
                	find_dump_num(dumpBuff);
                	int fd0 = fioOpen(dumpBuff, O_WRONLY);
                	free(dumpBuff);
                	int sizeDumped = fioWrite(fd0, (void*)0x00000000, DUMP_SIZE);
                	fioClose(fd0);
                	#undef MAX_DUMPS
                	#undef DUMP_SIZE
                	/*Optional Printing Stuff HERE*/
                	dumpBuff = (char*)malloc(20);
                	sprintf(dumpBuff, "Dumped %d bytes", sizeDumped);
                	//PUT IT HERE DUDE!
                	free(dumpBuff);
                	return;
                }
                Just an example of something that'd dump to the given file, though usb would be wiser. It checks for pre-existing and all.
                Last edited by aaronic; 03-23-2009, 08:54:35 PM.

                Comment


                • This won't work without entering kernel mode:

                  int sizeDumped = fioWrite(fd0, (void*)0x00000000, DUMP_SIZE);

                  Comment


                  • This is the memory dump function that I have made a long time ago...

                    Code:
                    void DumpRange(char *fname, int from, int to)
                    {
                    	FILE *fle = fopen(fname, "w+b");
                    	u8 toput[8192];
                    
                    	printf("\n  Dumping Range: %08X -> %08X ... ", from, to);
                    
                    	int offset, i;
                    	for (offset = from; offset < to; offset += 8192)
                    	{
                    		for (i = 0; i < 8192; i++)
                    		{
                    			ee_kmode_enter();
                    			toput[i] = _lb(offset + i);
                    			ee_kmode_exit();
                    		}
                    
                    		fwrite(toput, 8192, 1, fle);
                    
                    		printf("\n  Dumped Chunk: %08X ", offset);
                    	}
                    	fclose(fle);
                    	printf("\n  Dumping Range: %08X -> %08X Complete. ", from, to);
                    }

                    Comment


                    • Why are you reading only one byte at a time? You can call memcpy() after ee_kmode_enter().

                      Comment


                      • Well then my bad, naturally edit as needed.

                        That's great gtlc, but dumping chunks is a lot less efficient as it has to open->write->seek->write->seek->write->seek->(etc)close, rather than a constant task of just straight write(which is 100x+ faster). It's more stressful your way.

                        Comment


                        • Originally posted by misfire View Post
                          Why are you reading only one byte at a time? You can call memcpy() after ee_kmode_enter().
                          2 Things:

                          1) memcpy reads 1 byte, then writes 1 byte. I am saving the stress of having to call up another function by just implementing it directly into mine.
                          2) I wrote this function a LONG time ago.

                          Code:
                          void memcpy(unsigned char *dest, unsigned char *org, int ndata)
                          {
                          	int n;
                          	for(n = 0; n < ndata; n++)
                          		dest[n] = org[n];
                          }
                          Originally posted by aaronic View Post
                          Well then my bad, naturally edit as needed.

                          That's great gtlc, but dumping chunks is a lot less efficient as it has to open->write->seek->write->seek->write->seek->(etc)close, rather than a constant task of just straight write(which is 100x+ faster). It's more stressful your way.
                          I have no clue what point your trying to get across, but when it comes to file writing, you are limited to how fast you can write. If you just do individual bytes your operation is extremely slow. If you chunk it, it will run a whole lot faster. You build a package of X amount of bytes, then write that to the file, and loop back until you have finished dumping all you wanted. Chunking it is more efficient in almost every aspect. If you try to write too large of information at the same time, it slows down the operation dramatically. If you do individual bytes at a time, it will take really long. If you write in chunks, the chunks write extremely fast, and the 8kb chunks are built extremely fast. Thus, you have a faster operation.

                          Comment


                          • Originally posted by Gtlcpimp View Post
                            2 Things:

                            1) memcpy reads 1 byte, then writes 1 byte. I am saving the stress of having to call up another function by just implementing it directly into mine.
                            2) I wrote this function a LONG time ago.

                            Code:
                            void memcpy(unsigned char *dest, unsigned char *org, int ndata)
                            {
                            	int n;
                            	for(n = 0; n < ndata; n++)
                            		dest[n] = org[n];
                            }


                            I have no clue what point your trying to get across, but when it comes to file writing, you are limited to how fast you can write. If you just do individual bytes your operation is extremely slow. If you chunk it, it will run a whole lot faster. You build a package of X amount of bytes, then write that to the file, and loop back until you have finished dumping all you wanted. Chunking it is more efficient in almost every aspect. If you try to write too large of information at the same time, it slows down the operation dramatically. If you do individual bytes at a time, it will take really long. If you write in chunks, the chunks write extremely fast, and the 8kb chunks are built extremely fast. Thus, you have a faster operation.
                            I was trying to get across that given an all-at-once thing, it will handle it more efficiently, as it can cover more than 8kb, and it does the same exact thing as the 8kb chunk, just without the if's and butts.

                            Needless to say, I suppose it wouldn't make much difference supposing the PS2's io is rather quick.

                            Comment


                            • Originally posted by Gtlcpimp View Post
                              2 Things:

                              1) memcpy reads 1 byte, then writes 1 byte. I am saving the stress of having to call up another function by just implementing it directly into mine.
                              That would be a pretty dumb memcpy.

                              Actually, memcpy is a highly optimized function that can read/write 16 bytes at the time using EE's LQ/SQ quadword instructions.

                              http://svn.ps2dev.org/filedetails.ph...src%2Fmemcpy.S

                              Comment


                              • I must have some old and beat up SDK, because my memcpy() only does 1 byte at a time (which is why I never use it) lol.

                                Comment

                                Working...
                                X