Previous 15994 Revisions Next

r1167 Monday 22nd October, 2007 at 00:04:03 UTC by Dirk Best
[ACRNSYS1] Added skeleton driver for the Acorn System 1 (also known as Microcomputer Kit).
[docs]messnew.txt
[src/mess]mess.mak messdriv.c
[src/mess/drivers]acrnsys1.c*
[src/mess/layout]acrnsys1.lay*

src/mess/layout/acrnsys1.lay
r0r1167
1<!-- acrnsys1.lay -->
2 
3<!-- 2007-10-21: Initial version.  [Dirk Best] -->
4 
5<mamelayout version="2">
6 
7   <element name="digit" defstate="0">
8      <led7seg>
9         <color red="1.0" green="0.0" blue="0.0" />
10      </led7seg>
11   </element>
12 
13   <element name="background">
14      <rect>
15         <bounds left="0" top="0" right="1" bottom="1" />
16         <color red="0.0" green="0.0" blue="0.0" />
17      </rect>   
18   </element>
19 
20   <view name="LEDs only">
21 
22      <!-- Background -->
23      <backdrop element="background">
24         <bounds left="0" top="0" right="406" bottom="69" />
25      </backdrop>
26 
27      <!-- LEDs -->
28      <bezel name="digit0" element="digit">
29         <bounds left="10" top="10" right="44" bottom="59" />
30      </bezel>
31      <bezel name="digit1" element="digit">
32         <bounds left="54" top="10" right="88" bottom="59" />
33      </bezel>
34      <bezel name="digit2" element="digit">
35         <bounds left="98" top="10" right="132" bottom="59" />
36      </bezel>
37      <bezel name="digit3" element="digit">
38         <bounds left="142" top="10" right="176" bottom="59" />
39      </bezel>
40      <bezel name="digit4" element="digit">
41         <bounds left="186" top="10" right="220" bottom="59" />
42      </bezel>
43      <bezel name="digit5" element="digit">
44         <bounds left="230" top="10" right="264" bottom="59" />
45      </bezel>
46      <bezel name="digit6" element="digit">
47         <bounds left="274" top="10" right="308" bottom="59" />
48      </bezel>
49      <bezel name="digit7" element="digit">
50         <bounds left="318" top="10" right="352" bottom="59" />
51      </bezel>
52      <bezel name="digit8" element="digit">
53         <bounds left="362" top="10" right="396" bottom="59" />
54      </bezel>
55 
56   </view>
57 
58</mamelayout>
src/mess/messdriv.c
r1166r1167
186186
187187/****************COMPUTERS***************************************************/
188188    /* ACORN */
189   DRIVER( acrnsys1 )  /* 1979 Acorn System 1 (Microcomputer Kit)          */
189190   DRIVER( atom )      /* 1979 Acorn Atom                           */
190191   DRIVER( atomeb )   /* 1979 Acorn Atom                           */
191192   DRIVER( bbca )      /* 1981 BBC Micro Model A                     */
src/mess/mess.mak
r1166r1167
898898   $(MESS_DRIVERS)/mtx.o
899899
900900$(MESSOBJ)/acorn.a:    \
901   $(MESS_DRIVERS)/acrnsys1.o \
901902   $(MESS_MACHINE)/i8271.o    \
902903   $(MESS_MACHINE)/upd7002.o  \
903904   $(MESS_VIDEO)/saa505x.o        \
r1166r1167
11661167
11671168$(MESS_DRIVERS)/sym1.o:      $(MESS_LAYOUT)/sym1.lh
11681169
1170$(MESS_DRIVERS)/acrnsys1.o:   $(MESS_LAYOUT)/acrnsys1.lh
1171
11691172$(MESS_DRIVERS)/cybiko.o:   $(MESS_LAYOUT)/cybiko.lh
11701173
11711174include src/mess/tools/imgtool/imgtool.mak
src/mess/drivers/acrnsys1.c
r0r1167
1/******************************************************************************
2 Acorn System 1 (Microcomputer Kit)
3 
4 Skeleton driver
5 
6 Written by Dirk Best October 2007
7 
8 TODO: Emulate the National Semiconductor INS8154
9 
10******************************************************************************/
11 
12#include "driver.h"
13#include "inputx.h"
14 
15/* Layout */
16#include "acrnsys1.lh"
17 
18 
19 
20/******************************************************************************
21 Memory Maps
22******************************************************************************/
23 
24 
25static ADDRESS_MAP_START( acrnsys1_map, ADDRESS_SPACE_PROGRAM, 8 )
26   AM_RANGE(0x0000, 0x03ff) AM_RAM
27//   AM_RANGE(0x0e00, 0x0e7f) AM_MIRROR(0x100) AM_READWRITE(ins8154_0_r, ins8154_0_w)
28   AM_RANGE(0x0e80, 0x0eff) AM_MIRROR(0x100) AM_RAM
29   AM_RANGE(0xfe00, 0xffff) AM_MIRROR(0x600) AM_ROM
30ADDRESS_MAP_END
31 
32 
33 
34/******************************************************************************
35 Input Ports
36******************************************************************************/
37 
38 
39INPUT_PORTS_START( acrnsys1 )
40   PORT_START_TAG("keyboard_0")
41   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("M") PORT_CODE(KEYCODE_M) PORT_CHAR('M')
42   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G") PORT_CODE(KEYCODE_G) PORT_CHAR('G')
43   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("P") PORT_CODE(KEYCODE_P) PORT_CHAR('P')
44   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("S") PORT_CODE(KEYCODE_S) PORT_CHAR('S')
45   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("L") PORT_CODE(KEYCODE_L) PORT_CHAR('L')
46   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C") PORT_CODE(KEYCODE_C) PORT_CHAR('C')
47   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\xE2\x86\x91") PORT_CODE(KEYCODE_UP)   PORT_CHAR(UCHAR_MAMEKEY(UP))
48   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\xE2\x86\x93") PORT_CODE(KEYCODE_DOWN) PORT_CHAR(UCHAR_MAMEKEY(DOWN))
49 
50   PORT_START_TAG("keyboard_1")
51   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8") PORT_CODE(KEYCODE_8) PORT_CHAR('8')
52   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9") PORT_CODE(KEYCODE_9) PORT_CHAR('9')
53   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A") PORT_CODE(KEYCODE_A) PORT_CHAR('A')
54   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B") PORT_CODE(KEYCODE_B) PORT_CHAR('B')
55   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C") PORT_CODE(KEYCODE_C) PORT_CHAR('C')
56   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D") PORT_CODE(KEYCODE_D) PORT_CHAR('D')
57   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E") PORT_CODE(KEYCODE_E) PORT_CHAR('E')
58   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F") PORT_CODE(KEYCODE_F) PORT_CHAR('F')
59 
60   PORT_START_TAG("keyboard_2")
61   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("0") PORT_CODE(KEYCODE_0) PORT_CHAR('0')
62   PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1") PORT_CODE(KEYCODE_1) PORT_CHAR('1')
63   PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("2") PORT_CODE(KEYCODE_2) PORT_CHAR('2')
64   PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("3") PORT_CODE(KEYCODE_3) PORT_CHAR('3')
65   PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("4") PORT_CODE(KEYCODE_4) PORT_CHAR('4')
66   PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5") PORT_CODE(KEYCODE_5) PORT_CHAR('5')
67   PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6") PORT_CODE(KEYCODE_6) PORT_CHAR('6')
68   PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7") PORT_CODE(KEYCODE_7) PORT_CHAR('7')
69 
70   PORT_START_TAG("reset")
71   PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("RST") PORT_CODE(KEYCODE_F3) PORT_CHAR(UCHAR_MAMEKEY(F3))
72   PORT_BIT(0xfe, IP_ACTIVE_LOW, IPT_UNUSED)
73INPUT_PORTS_END
74 
75 
76 
77/******************************************************************************
78 Machine Drivers
79******************************************************************************/
80 
81 
82static MACHINE_DRIVER_START( acrnsys1 )
83   /* basic machine hardware */
84   MDRV_CPU_ADD(M6502, 1008000)  /* 1.008 MHz */
85   MDRV_CPU_PROGRAM_MAP(acrnsys1_map, 0)
86 
87   /* "video" hardware */
88   MDRV_DEFAULT_LAYOUT(layout_acrnsys1)
89   MDRV_SCREEN_REFRESH_RATE(60)
90   MDRV_SCREEN_VBLANK_TIME(DEFAULT_REAL_60HZ_VBLANK_DURATION)
91MACHINE_DRIVER_END
92 
93 
94 
95/******************************************************************************
96 ROM Definitions
97******************************************************************************/
98 
99 
100ROM_START( acrnsys1 )
101   ROM_REGION(0x10000, REGION_CPU1, 0)
102   ROM_LOAD("acrnsys1.bin", 0xfe00, 0x0200, CRC(43dcfc16) SHA1(b987354c55beb5e2ced761970c3339b895a8c09d))
103ROM_END
104 
105 
106 
107/******************************************************************************
108 System Config
109******************************************************************************/
110 
111 
112SYSTEM_CONFIG_START( acrnsys1 )
113SYSTEM_CONFIG_END
114 
115 
116 
117/******************************************************************************
118 Drivers
119******************************************************************************/
120 
121 
122/*    YEAR  NAME      PARENT COMPAT MACHINE   INPUT     INIT CONFIG    COMPANY  FULLNAME    FLAGS */
123COMP( 1978, acrnsys1, 0,     0,     acrnsys1, acrnsys1, 0,   acrnsys1, "Acorn", "System 1", GAME_NOT_WORKING )
docs/messnew.txt
r1166r1167
22
33New System Drivers Supported (in no particular order):
44------------------------------------------------------
5- Acorn System 1  [Dirk Best] (not working)
56- Atari STBook [Curt Coder] (not working)
67- Synertec Systems Corp. SYM-1  [Dirk Best] (not working)
78

Previous 15994 Revisions Next


© 1998-2018 The MESS Team