1 |
/* |
/* |
2 |
* Copyright (C) 2005 Anders Gavare. All rights reserved. |
* Copyright (C) 2005-2006 Anders Gavare. All rights reserved. |
3 |
* |
* |
4 |
* Redistribution and use in source and binary forms, with or without |
* Redistribution and use in source and binary forms, with or without |
5 |
* modification, are permitted provided that the following conditions are met: |
* modification, are permitted provided that the following conditions are met: |
25 |
* SUCH DAMAGE. |
* SUCH DAMAGE. |
26 |
* |
* |
27 |
* |
* |
28 |
* $Id: yamon.c,v 1.1 2005/08/29 14:46:34 debug Exp $ |
* $Id: yamon.c,v 1.3 2006/02/16 05:57:10 debug Exp $ |
29 |
* |
* |
30 |
* YAMON emulation. |
* YAMON emulation. |
31 |
*/ |
*/ |
73 |
switch (ofs) { |
switch (ofs) { |
74 |
case 0x804: /* "print count": string at a1, count at a2 */ |
case 0x804: /* "print count": string at a1, count at a2 */ |
75 |
n = 0; |
n = 0; |
76 |
while (n < cpu->cd.mips.gpr[MIPS_GPR_A2]) { |
while (n < (int)cpu->cd.mips.gpr[MIPS_GPR_A2]) { |
77 |
char ch = mem_readchar(cpu, MIPS_GPR_A1, n); |
char ch = mem_readchar(cpu, MIPS_GPR_A1, n); |
78 |
console_putchar(cpu->machine->main_console_handle, |
console_putchar(cpu->machine->main_console_handle, |
79 |
ch); |
ch); |