• R/O
  • SSH
  • HTTPS

unagi: コミット


コミットメタ情報

リビジョン419 (tree)
日時2015-06-06 18:26:23
作者naruko

ログメッセージ

flash programming is supported

変更サマリ

差分

--- client/trunk/anago/anago_gui.cpp (revision 418)
+++ client/trunk/anago/anago_gui.cpp (revision 419)
@@ -1,4 +1,4 @@
1-///////////////////////////////////////////////////////////////////////////
1+//////////////////////////////////////////
22 // C++ code generated with wxFormBuilder (version Sep 8 2010)
33 // http://www.wxformbuilder.org/
44 //
@@ -54,7 +54,7 @@
5454
5555 bSizer30->Add( m_version_title, 0, wxALL, 2 );
5656
57- m_version_copyright = new wxStaticText( this, wxID_ANY, wxT("(C) unagi development team 2010"), wxDefaultPosition, wxDefaultSize, 0 );
57+ m_version_copyright = new wxStaticText( this, wxID_ANY, wxT("(C) unagi development team 2010-2014"), wxDefaultPosition, wxDefaultSize, 0 );
5858 m_version_copyright->Wrap( -1 );
5959 bSizer30->Add( m_version_copyright, 0, wxALL, 2 );
6060
--- client/trunk/anago/anago_cui.c (revision 418)
+++ client/trunk/anago/anago_cui.c (revision 419)
@@ -14,6 +14,7 @@
1414 #include "script_dump.h"
1515 #include "flash_device.h"
1616 #include "script_program.h"
17+#include "crc32.h"
1718
1819 #ifdef _UNICODE
1920 #define PUTS _putws
@@ -249,14 +250,16 @@
249250 r->control.close(h);
250251 }
251252
252-#include "crc32.h"
253253 static void crc32_dump(const wgChar *name, const wgChar *str, struct memory *m)
254254 {
255- const long banksize = STRTOUL(str, NULL, 0x10);
255+ long banksize = STRTOUL(str, NULL, 0x10);
256256 if(banksize < 0x400 || (banksize & 0xff) != 0){
257257 PUTS(wgT("banksize requires over 0x400"));
258258 return;
259259 }
260+ if(banksize > m->size){
261+ banksize = m->size;
262+ }
260263 int i, j;
261264 PRINTF(wgT("%s 0x%x byte\n"), name, m->size);
262265 for(i = 0, j = 0; i < m->size; i += banksize, j++){
@@ -291,7 +294,7 @@
291294 PUTS(wgT("fF- flash program with kazzo"));
292295 PUTS(wgT("r - workram read with kazzo"));
293296 PUTS(wgT("w - workram write with kazzo"));
294- PUTS(wgT("V - VRAM A10 scan"));
297+ PUTS(wgT("v - VRAM A10 scan with kazzo"));
295298 PUTS(wgT("b - display each CRC32s by required size"));
296299 if(DEBUG == 1){
297300 PUTS(wgT("z - ROM dump for test"));
--- client/trunk/anago/script_dump.c (revision 418)
+++ client/trunk/anago/script_dump.c (revision 419)
@@ -348,10 +348,11 @@
348348 r = qr_argument_get(v, 2, &d->cpu.memory.size, &d->ppu.memory.size);
349349 return r;
350350 }
351-
351+//sq_pushroottable(v); //push the root table(were the globals of the script will are stored)
352352 static bool script_execute(HSQUIRRELVM v, struct dump_config *d)
353353 {
354354 bool ret = true;
355+// sq_pushroottable(v);
355356 if(SQ_FAILED(sqstd_dofile(v, wgT("dumpcore.nut"), SQFalse, SQTrue))){
356357 d->log.append(d->log.object, wgT("dump core script error\n"));
357358 ret = false;
@@ -403,6 +404,7 @@
403404 return false;
404405 }
405406 qr_close(v);
407+ v = NULL;
406408 }
407409
408410 d->handle = d->control->open(d->except, &d->log);
@@ -410,13 +412,9 @@
410412 d->log.append(d->log.object, wgT("reader open error\n"));
411413 return false;
412414 }
413-/* d->control->init(d->handle);
414- if(connection_check(d->handle, &d->log, d->cpu.access, d->ppu.access) == false){
415- d->control->close(d->handle);
416- return false;
417- }*/
415+ //d->log.append(d->log.object, wgT("haohao\n"));
418416 {
419- HSQUIRRELVM v = qr_open(&d->log);
417+ volatile HSQUIRRELVM v = qr_open(&d->log);
420418 qr_function_register_global(v, wgT("memory_new"), memory_new);
421419 qr_function_register_global(v, wgT("nesfile_save"), nesfile_save);
422420 qr_function_register_global(v, wgT("cpu_write"), cpu_write);
@@ -425,6 +423,7 @@
425423 qr_function_register_global(v, wgT("ppu_ramfind"), ppu_ramfind);
426424 script_execute(v, d);
427425 qr_close(v);
426+ v = NULL;
428427 }
429428 d->control->close(d->handle);
430429 d->handle = NULL;
--- client/trunk/anago/squirrel_wrap.c (revision 418)
+++ client/trunk/anago/squirrel_wrap.c (revision 419)
@@ -42,9 +42,9 @@
4242 sq_setprintfunc(v, print_other);
4343 }
4444 sq_pushroottable(v);
45- sqstd_seterrorhandlers(v);
4645 sqstd_register_iolib(v);
4746 sqstd_register_stringlib(v);
47+ sqstd_seterrorhandlers(v);
4848 return v;
4949 }
5050
旧リポジトリブラウザで表示