Skip to content

Commit d1b1e67

Browse files
committed
Update to CrabEmu r261
1 parent 83c3edc commit d1b1e67

File tree

15 files changed

+1686
-90
lines changed

15 files changed

+1686
-90
lines changed

CrabEmu.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Copyright (C) 2009, 2012, 2014 Lawrence Sebald
55
66
CrabEmu is free software; you can redistribute it and/or modify
7-
it under the terms of the GNU General Public License version 2
7+
it under the terms of the GNU General Public License version 2
88
as published by the Free Software Foundation.
99
1010
CrabEmu is distributed in the hope that it will be useful,

CrabEmu.xcodeproj/project.pbxproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,9 @@
143143
878700E21B675EB4006841C9 /* nesmapper9.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = nesmapper9.c; sourceTree = "<group>"; };
144144
878700E31B675EB4006841C9 /* nesmapper66.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = nesmapper66.c; sourceTree = "<group>"; };
145145
878700E41B675EF0006841C9 /* console.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = console.h; sourceTree = "<group>"; };
146+
87ACB6E41D26C1F600138B7E /* CrabZ80_gbmacros.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CrabZ80_gbmacros.h; sourceTree = "<group>"; };
147+
87ACB6E51D26C1F600138B7E /* CrabZ80gbops.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CrabZ80gbops.h; sourceTree = "<group>"; };
148+
87ACB6E61D26C1F700138B7E /* CrabZ80gbopsCB.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CrabZ80gbopsCB.h; sourceTree = "<group>"; };
146149
8D5B49B6048680CD000E48DA /* CrabEmu.oecoreplugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = CrabEmu.oecoreplugin; sourceTree = BUILT_PRODUCTS_DIR; };
147150
8D5B49B7048680CD000E48DA /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
148151
9443D39B1715F2EB00E452AC /* colecomem.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = colecomem.c; sourceTree = "<group>"; };
@@ -495,6 +498,9 @@
495498
9443D3FF1715F31000E452AC /* CrabZ80_tables.h */,
496499
9443D4001715F31000E452AC /* CrabZ80d.c */,
497500
9443D4011715F31000E452AC /* CrabZ80d.h */,
501+
87ACB6E41D26C1F600138B7E /* CrabZ80_gbmacros.h */,
502+
87ACB6E51D26C1F600138B7E /* CrabZ80gbops.h */,
503+
87ACB6E61D26C1F700138B7E /* CrabZ80gbopsCB.h */,
498504
9443D4021715F31000E452AC /* CrabZ80ops.h */,
499505
9443D4031715F31000E452AC /* CrabZ80opsCB.h */,
500506
9443D4041715F31000E452AC /* CrabZ80opsDD-FD.h */,

Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<key>CFBundleSignature</key>
1818
<string>OpEm</string>
1919
<key>CFBundleVersion</key>
20-
<string>0.2.1.256</string>
20+
<string>0.2.1.261</string>
2121
<key>NSPrincipalClass</key>
2222
<string>OEGameCoreController</string>
2323
<key>OEGameCoreClass</key>

console.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*
22
This file is part of CrabEmu.
33
4-
Copyright (C) 2014, 2015 Lawrence Sebald
4+
Copyright (C) 2014, 2015, 2016 Lawrence Sebald
55
66
CrabEmu is free software; you can redistribute it and/or modify
77
it under the terms of the GNU General Public License version 2
@@ -36,6 +36,12 @@ CLINKAGE
3636
/* 7 left blank for now... */
3737
#define CONSOLE_CHIP8 8 /* Chip-8 "Console" */
3838

39+
/* Region codes. */
40+
#define REGION_NONE 0x00
41+
#define REGION_JAPAN 0x01
42+
#define REGION_US 0x02
43+
#define REGION_EUROPE 0x04
44+
3945
/* This structure is meant to provide an abstraction of a console, such that
4046
there can be less console-specific code up at the GUI level. Rignt now, this
4147
doesn't take care of everything, but that might eventually change... Each

consoles/colecovision/colecovision.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2014 Lawrence Sebald
55
66
CrabEmu is free software; you can redistribute it and/or modify
7-
it under the terms of the GNU General Public License version 2
7+
it under the terms of the GNU General Public License version 2
88
as published by the Free Software Foundation.
99
1010
CrabEmu is distributed in the hope that it will be useful,
@@ -103,18 +103,18 @@ colecovision_t colecovision_cons = {
103103
&tms9918a_vdp_activeframe,
104104
NULL, /* save_cheats */
105105
#ifndef _arch_dreamcast
106-
&coleco_scanline,
107-
&coleco_single_step,
108-
&coleco_finish_frame,
109-
&coleco_finish_scanline,
106+
&coleco_scanline,
107+
&coleco_single_step,
108+
&coleco_finish_frame,
109+
&coleco_finish_scanline,
110110
#else
111111
NULL,
112112
NULL,
113113
NULL,
114114
NULL,
115115
#endif
116-
&coleco_current_scanline,
117-
&coleco_cycles_left,
116+
&coleco_current_scanline,
117+
&coleco_cycles_left,
118118
NULL /* set_control */
119119
}
120120
};
@@ -148,7 +148,7 @@ int coleco_init(int video_system) {
148148

149149
for(i = 0; i < PAL_LINES_PER_FRAME; ++i) {
150150
psg_samples[i] = (uint32) (tmp * (i + 1)) -
151-
(uint32) (tmp * i);
151+
(uint32) (tmp * i);
152152
}
153153

154154
/* We need 882 samples per frame @ 44100 Hz, 50fps. */
@@ -308,7 +308,7 @@ void coleco_button_released(int player, int button) {
308308
}
309309

310310
#ifndef _arch_dreamcast
311-
static __INLINE__ int update_sound(int16 buf[], int start, int line) {
311+
static __INLINE__ int update_sound(int16 buf[], int start, int line) {
312312
if(sms_psg_enabled)
313313
sn76489_execute_samples(&psg, buf + start, psg_samples[line]);
314314
else

consoles/sms/mappers.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
/*
22
This file is part of CrabEmu.
33
4-
Copyright (C) 2008, 2012 Lawrence Sebald
4+
Copyright (C) 2008, 2012, 2015 Lawrence Sebald
55
66
CrabEmu is free software; you can redistribute it and/or modify
7-
it under the terms of the GNU General Public License version 2
7+
it under the terms of the GNU General Public License version 2
88
as published by the Free Software Foundation.
99
1010
CrabEmu is distributed in the hope that it will be useful,

consoles/sms/sms.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Copyright (C) 2005, 2007, 2009, 2012, 2014 Lawrence Sebald
55
66
CrabEmu is free software; you can redistribute it and/or modify
7-
it under the terms of the GNU General Public License version 2
7+
it under the terms of the GNU General Public License version 2
88
as published by the Free Software Foundation.
99
1010
CrabEmu is distributed in the hope that it will be useful,
@@ -95,8 +95,8 @@ extern int sms_read_state(FILE *fp);
9595
#define SMS_TH_MASK 0xC000
9696

9797
/* Region types */
98-
#define SMS_REGION_DOMESTIC 0x01
99-
#define SMS_REGION_EXPORT 0x02
98+
#define SMS_REGION_DOMESTIC REGION_JAPAN
99+
#define SMS_REGION_EXPORT REGION_US
100100

101101
/* Video Standards */
102102
#define SMS_VIDEO_NTSC VIDEO_NTSC

consoles/sms/smsz80.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Copyright (C) 2005, 2006, 2007, 2008, 2009 Lawrence Sebald
55
66
CrabEmu is free software; you can redistribute it and/or modify
7-
it under the terms of the GNU General Public License version 2
7+
it under the terms of the GNU General Public License version 2
88
as published by the Free Software Foundation.
99
1010
CrabEmu is distributed in the hope that it will be useful,
@@ -34,7 +34,7 @@ int sms_z80_init(void) {
3434
return -1;
3535
}
3636

37-
CrabZ80_init(cpuz80);
37+
CrabZ80_init(cpuz80, CRABZ80_CPU_Z80);
3838
CrabZ80_reset(cpuz80);
3939

4040
CrabZ80_set_portwrite(cpuz80, sms_port_write);

0 commit comments

Comments
 (0)