Table: ComPort
Entriy defines a set of COM port parameters.
ComPortID |
INTEGER |
PK |
NN |
|
Unique ID
of Com port setting |
SetupID |
INTEGER |
FK |
NN |
|
Setup ID
(foreign key refers to table Setup) |
Speed |
SMALLINT(6) |
|
|
|
Com
speed0 | 1200 | 1 | 2400 | 2 | 4800 | 3 | 9600 | 4 | 19200 | 5 | 38400 | 6 | 57600 | 7 | 115200 |
|
Parity |
SMALLINT(6) |
|
|
|
Com
parity |
Stop |
SMALLINT(6) |
|
|
|
Com
stop bits.0 | Stop bits: 1 | 1 | Stop bits: 2 |
|
Flow |
SMALLINT(6) |
|
|
|
Com
flow control.0 | None | 1 | RTS/CTS | 2 | XON/XOFF | 3 | Both |
|
Width |
SMALLINT(6) |
|
|
|
Com
word width.0 | 5 Bits | 1 | 6 Bits | 2 | 7 Bits | 3 | 8 Bits |
|
ReservedString1 |
NVARCHAR(255) |
|
|
|
|
ReservedString2 |
NVARCHAR(255) |
|
|
|
|
ReservedInt1 |
INTEGER |
|
|
|
|
ReservedInt2 |
INTEGER |
|
|
|
|
PRIMARY |
PRIMARY |
ComPortID
|
how to create
CREATE TABLE ComPort(
ComPortID INTEGER NOT NULL,
SetupID INTEGER NOT NULL,
Speed SMALLINT,
Parity SMALLINT,
Stop SMALLINT,
Flow SMALLINT,
Width SMALLINT,
ReservedString1 NVARCHAR(255),
ReservedString2 NVARCHAR(255),
ReservedInt1 INTEGER,
ReservedInt2 INTEGER,
CONSTRAINT FK_ComPort_SetupID_Setup_SetupID FOREIGN KEY (SetupID) REFERENCES Setup (SetupID),
PRIMARY KEY (ComPortID));