Microsoft KB Archive/33732

From BetaArchive Wiki
Knowledge Base


COM1 and COM2: Communications Device Default Buffer Size

Article ID: 33732

Article Last Modified on 11/21/2006

This article was previously published under Q33732

SUMMARY

The receive and transmission buffer sizes for COM1 and COM2 default to 512 bytes in Microsoft QuickBasic versions 4.00, 4.00b, and 4.50, and in Microsoft Basic Compiler versions 6.00 and 6.00b [and in Microsoft Basic Professional Development System (PDS) version 7.00, as described in a separate article].

A sentence under the /C:buffersize option (in the section "Using BC Command Options") on Page 210 of the manuals listed below incorrectly states the following: "the default receive-buffer size is 256 bytes total for both ports." The default receive-buffer size is actually 512 bytes for both the COM1 and COM2 communications ports. The affected manuals are as follows:

  1. Page 210 of "Microsoft QuickBasic 4.0: Learning and Using QuickBasic" for QuickBasic 4.00 and 4.00b
  2. Page 210 of "Microsoft Basic Compiler 6.0: Learning and Using QuickBasic" for Microsoft Basic Compiler versions 6.00 and 6.00b

The section "Using BC Command Options" on Page 354 of the following manual incorrectly states that "the transmission buffer is allocated 128 bytes for each communications port" and should be changed to say that 512 bytes is the default transmission buffer size:

Page 354 of "Microsoft Basic 4.5: Programming in Basic" manual for QuickBasic version 4.50


MORE INFORMATION

Note that the default receive buffer size (512 bytes) is CORRECTLY documented in the following places:

  1. Page 298 in the "Microsoft QuickBasic 4.0: Basic Language Reference" manual for versions 4.00 and 4.00b


This page correctly documents the RB[n] and TB[n] options for the OPEN COM statement. RB[n] changes the receive buffer size and TB[n] changes the transmission buffer size in the OPEN COM statement. The RB option overrides the receive buffer size specified by the /C option (if any). There is no compile-time option (including /C) that affects the transmission buffer size; TB is instead used in the OPEN COM statement at run time.

  1. Page 151 of "Microsoft QuickBasic 4.5: Learning to Use" manual for version 4.50
  2. Page 354 of "Microsoft QuickBasic 4.5: Programming in Basic" manual for version 4.50



Additional query words: QuickBas BasicCom

Keywords: KB33732