Make component/script names match XML device names (specifically, serial and parallel, which used to be serialport and parallelport)
This commit is contained in:
parent
51c7b96f3c
commit
ded8f15e86
22 changed files with 913 additions and 925 deletions
|
|
@ -21,8 +21,8 @@ begin connecting PCs to terminals.
|
|||
Below you'll find an 80286-based [IBM PC AT](/devices/pcx86/machine/5170/ega/2048kb/rev3/) connected to an 8080-based
|
||||
[VT100 Terminal](/devices/pc8080/machine/vt100/) via the PC's **COM2** serial port.
|
||||
|
||||
At this point, the connection is *very* thin. The [PCx86](/modules/pcx86/) [SerialPort](/modules/pcx86/lib/serialport.js)
|
||||
and [PC8080](/modules/pc8080/) [SerialPort](/modules/pc8080/lib/serialport.js) each export exactly two methods:
|
||||
At this point, the connection is *very* thin. The [PCx86](/modules/pcx86/) [SerialPort](/modules/pcx86/lib/serial.js)
|
||||
and [PC8080](/modules/pc8080/) [SerialPort](/modules/pc8080/lib/serial.js) each export exactly two methods:
|
||||
|
||||
- *initConnection()*
|
||||
- *receiveData()*
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ Most of the work remaining is in device management. Like other PCjs emulators,
|
|||
UNIBUS addresses. During the initial port, I moved all of Paul's original device management code into one "catch-all"
|
||||
component, [device.js](/modules/pdp11/lib/device.js), which has now been converted to the new I/O registration model.
|
||||
|
||||
The first new device component is [serialport.js](/modules/pdp11/lib/serialport.js), which is currently the
|
||||
The first new device component is [serial.js](/modules/pdp11/lib/serial.js), which is currently the
|
||||
only means PDPjs has of communicating with the outside world. So you can try
|
||||
[PDPjs connected to a VT100 Terminal](/devices/pdp11/machine/1170/vt100/), by clicking the **Run** button on the test machine.
|
||||
The test machine is running [custom boot code](/apps/pdp11/boot/test/), adapted from boot code written by Paul, but due to the
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ permalink: /devices/pdp11/dl11/
|
|||
DL11 Serial Interface for Display Terminals
|
||||
-------------------------------------------
|
||||
|
||||
PDPjs implements the DL11 component in [SerialPortPDP11](/modules/pdp11/lib/serialport.js).
|
||||
PDPjs implements the DL11 component in [SerialPortPDP11](/modules/pdp11/lib/serial.js).
|
||||
|
||||
This component is typically instantiated by a Machine XML file using:
|
||||
|
||||
|
|
@ -19,6 +19,6 @@ display terminal.
|
|||
However, some machines, such as the [PDP-11/70 with VT100 Terminal](/devices/pdp11/machine/1170/vt100/), connect the DL11
|
||||
to a separate machine (eg, a [VT100 Terminal](/devices/pc8080/machine/vt100/)), using the PDP-11 machine's *connection* property.
|
||||
|
||||
Refer to the *initConnection()* function in the [SerialPortPDP11](/modules/pdp11/lib/serialport.js),
|
||||
[SerialPort8080](/modules/pc8080/lib/serialport.js), and [SerialPort for PCx86](/modules/pcx86/lib/serialport.js)
|
||||
Refer to the *initConnection()* function in the [SerialPortPDP11](/modules/pdp11/lib/serial.js),
|
||||
[SerialPort8080](/modules/pc8080/lib/serial.js), and [SerialPort for PCx86](/modules/pcx86/lib/serial.js)
|
||||
components.
|
||||
|
|
|
|||
|
|
@ -33,8 +33,8 @@
|
|||
http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallelport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serialport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2016
|
||||
|
|
|
|||
|
|
@ -33,8 +33,8 @@
|
|||
http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallelport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serialport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2016
|
||||
|
|
|
|||
|
|
@ -31,6 +31,6 @@ PC8080 is comprised of the following non-shared components, as listed in [packag
|
|||
* [ram.js](/modules/pc8080/lib/ram.js)
|
||||
* [keyboard.js](/modules/pc8080/lib/keyboard.js)
|
||||
* [video.js](/modules/pc8080/lib/video.js)
|
||||
* [serialport.js](/modules/pc8080/lib/serialport.js)
|
||||
* [serial.js](/modules/pc8080/lib/serial.js)
|
||||
* [debugger.js](/modules/pc8080/lib/debugger.js)
|
||||
* [computer.js](/modules/pc8080/lib/computer.js)
|
||||
|
|
|
|||
|
|
@ -62,8 +62,8 @@ At the time of this writing, the recommended order is:
|
|||
* [pcx86/ram.js](lib/ram.js)
|
||||
* [pcx86/keyboard.js](lib/keyboard.js)
|
||||
* [pcx86/video.js](lib/video.js)
|
||||
* [pcx86/parallelport.js](lib/parallelport.js)
|
||||
* [pcx86/serialport.js](lib/serialport.js)
|
||||
* [pcx86/parallel.js](lib/parallel.js)
|
||||
* [pcx86/serial.js](lib/serial.js)
|
||||
* [pcx86/mouse.js](lib/mouse.js)
|
||||
* [pcx86/disk.js](lib/disk.js)
|
||||
* [pcx86/fdc.js](lib/fdc.js)
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@
|
|||
"model": "deskpro386",
|
||||
"sound": false
|
||||
},
|
||||
"serialport": {
|
||||
"serial": {
|
||||
"id": "com2",
|
||||
"adapter": 2,
|
||||
"binding": "console"
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ if (NODE) {
|
|||
var State = require("../../shared/lib/state");
|
||||
var PCX86 = require("./defines");
|
||||
var Messages = require("./messages");
|
||||
var SerialPort = require("./serialport");
|
||||
var SerialPort = require("./serial");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ PDPjs is currently comprised of the following PDP-11 components, as listed in [p
|
|||
* [rk11.js](/modules/pdp11/lib/rk11.js)
|
||||
* [rl11.js](/modules/pdp11/lib/rl11.js)
|
||||
* [rom.js](/modules/pdp11/lib/rom.js)
|
||||
* [serialport.js](/modules/pdp11/lib/serialport.js)
|
||||
* [serial.js](/modules/pdp11/lib/serial.js)
|
||||
|
||||
Since this module was written in 2016, it seemed appropriate to start adopting some of the more useful features of
|
||||
[ECMAScript](http://www.ecma-international.org/ecma-262/6.0/index.html) 2015 (aka ES6), including:
|
||||
|
|
|
|||
|
|
@ -210,20 +210,6 @@ function initMachine(xml)
|
|||
|
||||
var component = aComponents[iComponent], sDeviceName = component.name;
|
||||
|
||||
/*
|
||||
* TODO: Should I change the component names serialport and parallelport to serial and parallel?
|
||||
*
|
||||
* The XML device names are currently serial and parallel. I'm tempted to rev the XML device names
|
||||
* (eg, to serialport and parallelport) and leave the component names (and corresponding script filenames)
|
||||
* alone, but until then, we must manually remap these component names to their XML device names.
|
||||
*
|
||||
* I actually prefer camelCase and XML device names serialPort and parallelPort (not to mention chipSet),
|
||||
* but that would require changing the script filenames (eg, to serialPort.js and parallelPort.js), since
|
||||
* our list of component names is derived from the list of script filenames in package.json.
|
||||
*/
|
||||
if (sDeviceName == "serialport") sDeviceName = "serial";
|
||||
if (sDeviceName == "parallelport") sDeviceName = "parallel";
|
||||
|
||||
var aDevices = machine[sDeviceName], iDevice;
|
||||
|
||||
if (aDevices) {
|
||||
|
|
|
|||
|
|
@ -130,8 +130,8 @@
|
|||
"./modules/pcx86/lib/ram.js",
|
||||
"./modules/pcx86/lib/keyboard.js",
|
||||
"./modules/pcx86/lib/video.js",
|
||||
"./modules/pcx86/lib/parallelport.js",
|
||||
"./modules/pcx86/lib/serialport.js",
|
||||
"./modules/pcx86/lib/parallel.js",
|
||||
"./modules/pcx86/lib/serial.js",
|
||||
"./modules/pcx86/lib/mouse.js",
|
||||
"./modules/pcx86/lib/disk.js",
|
||||
"./modules/pcx86/lib/fdc.js",
|
||||
|
|
@ -167,7 +167,7 @@
|
|||
"./modules/pc8080/lib/ram.js",
|
||||
"./modules/pc8080/lib/keyboard.js",
|
||||
"./modules/pc8080/lib/video.js",
|
||||
"./modules/pc8080/lib/serialport.js",
|
||||
"./modules/pc8080/lib/serial.js",
|
||||
"./modules/shared/es6/debugger.js",
|
||||
"./modules/pc8080/lib/debugger.js",
|
||||
"./modules/pc8080/lib/computer.js",
|
||||
|
|
@ -197,7 +197,7 @@
|
|||
"./modules/pdp11/lib/rom.js",
|
||||
"./modules/pdp11/lib/ram.js",
|
||||
"./modules/pdp11/lib/keyboard.js",
|
||||
"./modules/pdp11/lib/serialport.js",
|
||||
"./modules/pdp11/lib/serial.js",
|
||||
"./modules/pdp11/lib/pc11.js",
|
||||
"./modules/pdp11/lib/disk.js",
|
||||
"./modules/pdp11/lib/rk11.js",
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -33,8 +33,8 @@
|
|||
http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallelport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serialport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2016
|
||||
|
|
|
|||
|
|
@ -33,8 +33,8 @@
|
|||
http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallelport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serialport.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2016
|
||||
http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2016
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue