[KDCOM][NTOS:INBV][FREELDR] Decrease default baud rate for PC-98 target (#2601)

According to PC-9801 Bible p. 50, divisor for PIT will become unsupported in some cases after having removed the fractional part. Replace 19200 value with 9600 which is supported by both 10 MHz and 8 MHz machines.
This commit is contained in:
Dmitry Borisov 2020-04-22 02:22:42 +06:00 committed by GitHub
parent 181ed94e22
commit 4501bbac8f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 53 additions and 21 deletions

View file

@ -13,12 +13,19 @@
#include <ndk/halfuncs.h>
/* Serial debug connection */
#if defined(SARCH_PC98)
#define DEFAULT_DEBUG_PORT 2 /* COM2 */
#define DEFAULT_DEBUG_COM1_IRQ 4 /* COM1 IRQ */
#define DEFAULT_DEBUG_COM2_IRQ 3 /* COM2 IRQ */
#define DEFAULT_DEBUG_BAUD_RATE 115200 /* 115200 Baud */
#define DEFAULT_BAUD_RATE 19200
#define DEFAULT_DEBUG_COM1_IRQ 4
#define DEFAULT_DEBUG_COM2_IRQ 5
#define DEFAULT_DEBUG_BAUD_RATE 9600
#define DEFAULT_BAUD_RATE 9600
#else
#define DEFAULT_DEBUG_PORT 2 /* COM2 */
#define DEFAULT_DEBUG_COM1_IRQ 4
#define DEFAULT_DEBUG_COM2_IRQ 3
#define DEFAULT_DEBUG_BAUD_RATE 115200
#define DEFAULT_BAUD_RATE 19200
#endif
#if defined(_M_IX86) || defined(_M_AMD64)
#if defined(SARCH_PC98)
@ -299,12 +306,12 @@ NTAPI
KdpReceiveByte(_Out_ PUCHAR OutByte)
{
USHORT CpStatus;
do
{
CpStatus = CpGetByte(&KdComPort, OutByte, TRUE, FALSE);
} while (CpStatus == CP_GET_NODATA);
/* Get the byte */
if (CpStatus == CP_GET_SUCCESS)
{