Make serial port, data format, and bps configurable.

This commit is contained in:
rnordier 1998-10-20 20:20:48 +00:00
parent 93df632528
commit 43fd8ab5aa
4 changed files with 24 additions and 12 deletions

View File

@ -1,4 +1,4 @@
# $Id: Makefile,v 1.6 1998/10/15 20:04:21 rnordier Exp $
# $Id: Makefile,v 1.7 1998/10/15 22:08:13 rnordier Exp $
PROG= boot2
NOMAN=
@ -11,6 +11,10 @@ CLEANFILES+= boot1 boot1.out boot1.o \
M4?= m4
B2SIOPRT?= 0x3f8
B2SIOFMT?= 0x3
B2SIODIV?= 0xc
.if exists(${.OBJDIR}/../btx)
BTX= ${.OBJDIR}/../btx
.else
@ -58,7 +62,9 @@ boot2.out: boot2.o sio.o
${BTX}/lib/crt0.o boot2.o sio.o
sio.o: sio.s
${AS} ${AFLAGS} -o ${.TARGET} ${.IMPSRC}
(cd ${.CURDIR}; ${M4} -DSIOPRT=${B2SIOPRT} \
-DSIOFMT=${B2SIOFMT} -DSIODIV=${B2SIODIV} sio.s) | \
${AS} ${AFLAGS} -o ${.TARGET}
install:
${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \

View File

@ -13,11 +13,11 @@
# purpose.
#
# $Id:$
# $Id: sio.s,v 1.1 1998/10/15 20:04:21 rnordier Exp $
.set SIO_PRT,0x3f8 # Base port
.set SIO_FMT,0x3 # 8N1
.set SIO_DIV,0xc # 115200 / 9600
.set SIO_PRT,SIOPRT # Base port
.set SIO_FMT,SIOFMT # 8N1
.set SIO_DIV,SIODIV # 115200 / BPS
.globl sio_init
.globl sio_flush

View File

@ -13,11 +13,11 @@
# purpose.
#
# $Id:$
# $Id: sio.s,v 1.1 1998/10/15 20:04:21 rnordier Exp $
.set SIO_PRT,0x3f8 # Base port
.set SIO_FMT,0x3 # 8N1
.set SIO_DIV,0xc # 115200 / 9600
.set SIO_PRT,SIOPRT # Base port
.set SIO_FMT,SIOFMT # 8N1
.set SIO_DIV,SIODIV # 115200 / BPS
.globl sio_init
.globl sio_flush

View File

@ -1,4 +1,4 @@
# $Id: Makefile,v 1.6 1998/10/15 20:04:21 rnordier Exp $
# $Id: Makefile,v 1.7 1998/10/15 22:08:13 rnordier Exp $
PROG= boot2
NOMAN=
@ -11,6 +11,10 @@ CLEANFILES+= boot1 boot1.out boot1.o \
M4?= m4
B2SIOPRT?= 0x3f8
B2SIOFMT?= 0x3
B2SIODIV?= 0xc
.if exists(${.OBJDIR}/../btx)
BTX= ${.OBJDIR}/../btx
.else
@ -58,7 +62,9 @@ boot2.out: boot2.o sio.o
${BTX}/lib/crt0.o boot2.o sio.o
sio.o: sio.s
${AS} ${AFLAGS} -o ${.TARGET} ${.IMPSRC}
(cd ${.CURDIR}; ${M4} -DSIOPRT=${B2SIOPRT} \
-DSIOFMT=${B2SIOFMT} -DSIODIV=${B2SIODIV} sio.s) | \
${AS} ${AFLAGS} -o ${.TARGET}
install:
${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \