11170 Flatiron Dr.
Lafayette, CO 80026
303.828.9156  (voice)
303.828.9316 (fax)

Product Data Sheet


32 byte RS232 Serial Data Buffer IC



The RSB509B is an easy to use, low cost, data buffer IC. RS232 serial format data is received at the input pin and stored inside the RSB509B until the host signals that it is ready to process the data. The data can then be processed one byte at a time, or the entire buffer contents can be sent to the host.

The RSB509B allows the host processor to perform other tasks independent of the timing of incoming RS232 data. This allows single thread processors, like Parallax's Basic STAMP, to receive up to 32 bytes of data in background. More sophisticated processors also benefit from the use of the RSB509B when multiple intermittent input streams need to be handled.

The RSB509B is easily interfaced to a host via a single bi-directional I/O pin. Configuration of the RSB509B is also accomplished through this single I/O pin. A pulse on the interface pin signals the RSB509B to  send data contained in its buffer. If the pulse is longer than 1200us, the RSB509B prepares to receive one or two configuration bytes from the host. Using this simple pulse protocol, received data bytes can be individually retrieved and processed.


  • Small 8-pin DIP or SOIC package.

  • Only a 4MHz crystal or clock source, a diode, and a few resistors are required for operation.

  • 32 byte buffer receives data and retransmits it to the host when requested.

  • Only one host I/O pin is required to interface to the RSB509B.

  • A simple pulse protocol is used to configure the RSB509C and to gate the output bytes.

  • Programmable input baud rates of 9600, 4800, 2400, or 1200 baud. Lower rates possible with slower crystal.

  • Input stream can be either inverted (direct connect to RS232 levels) or true (connection to signal receiver like MAX232 or RS1489).

  • Communication with host is fixed at 9600 baud, inverted.

  • Pulse protocol compatible with Basic STAMP's SERIN command.

  • Packet modes for implementing simple multi-drop addressed serial networks

  • Buffer Empty output pin for status or handshaking.

  • Buffer Full output pin for status or handshaking.

RSB509B Pin Assignments

  1. Vdd     - +5 vdc power supply for the device
  2. Osc1   - connect to a crystal or to a 4MHz square wave oscillator
  3. Osc2   - connect to a crystal or leave open when an oscillator is used
  4. Serin   - RS232 input. Connect to an RS232 receiver or connect to an RS232 source via a 22K resistor, when connecting to an RS232 source, this pin must be over voltage protected by placing a diode from this pin to Vdd.
  5. Ready - This open source output indicates that the buffer is not full. This line must be pulled low.
  6. Empty - This open source output indicates that the buffer is empty. This line must be pulled low.
  7. Data    - This open source directional pin is connected to the host processor. This line must be pulled low.
  8. Gnd     - Ground connection for the device

Configuration Information

Operational Timing Parameters: Condition: Osc=4MHz
Parameter Min Max
Tcommp Duration of Command Initiate Pulse 1200 us -
Treqp Data Retrieve Initiate Pulse 52 us 1000 us
Trecvd Delay from request pulse to start bit of data if any data is present within the buffer. 52 us 78 us
Trecd2 Delay between subsequent data bytes if any subsequent data is present in a burst mode transmission. 52 us 52 us
Trecmax Maximum delay before complete transmission of data after initial request pulse 1092 us 1118 us

When the RSB509B is first powered up, it is idle waiting to be configured. Configuration is accomplished by pulling the data interface pin high for a minimum of 1200 us. The host then lowers the interface pin for a minimum of 52 us then sends two bytes of configuration data. The first byte is an address byte used only for packet addressing but required as a place holder in the configuration sequence. The second byte is the control byte used for setting input polarity, baud rate, reception modes, and host interface mode.

The address byte is used only when the RSB509B is in an addressed packet reception mode. When in this mode, The RSB509B will not buffer data until the address match criteria have been met. The RSB509B will then buffer data until it is reconfigured. An address byte must be sent during configuration regardless of the reception mode however. If the RSB509B is not in an addressed mode, the address byte is simply ignored.

The configuration byte is a bit mapped register with the meaning of the bits described in the following table:

Bit 0 Must be low
Bit 1 Must be low
Bit 2 High = Input is inverted, open drain for direct connection to RS232 cable levels
Low = Input is true, full totem for connection to an RS232 receiver buffer IC like the MAX232
Bit 3 Input Baud rate setting: 00 is 9600, 01 is 4800, 10 is 2400, 11 is 1200
Bit 4
Bit 5 Reception mode setting: 00 is normal byte oriented mode. 01 is address match packet mode
   10 is break delineated address match packet mode.
Bit 6
Bit 7 High = Request pulse causes sequential send of entire buffer contents
Low = Request pulse causes send of the next data byte only.

After the two bytes of configuration, the RSB509B clears it's buffer and prepares for incoming data while monitoring the interface pin for a configuration or a request pulse. If no data is in the buffer when a request pulse is detected, the pulse is simply ignored. The host can time out while waiting for data after 78us. This allows the host to poll the RSB509B for data.

Example Connection Diagrams

The host used is not significant to either RS232 input connection, but is shown for reference.

TICkit 62 using "inverted" direct RS232

Basic STAMP II using "true" RS232 receivers

Sample Programs to Configure and Receive Data from an RSB509B

TICkit 62 Sample

; Program for RSB509B serial buffering
DEF tic62_c
LIB fbasic.lib
LIB rsb509b.lib

FUNC none main
  ; generate a long pulse on interface pin to
  ; signal initialization to RSB509
  pin_high( pin_d0 )
  delay( 2 )
  =( in_err, pin_in( pin_d0 ))

  ; no match byte used but one must be sent
  ; as a place holder during initialization
  rs_param_set( rs_invert | rs_9600 | pin_d0 )
  rs_send( ' ' )

  ; serial input is inverted and 9600 baud.
  rs_send( rsb509_invert | rsb509_baud1 )
  ; wait for RSB509 to reset.
  delay( 1 )
    ; generate a quick pulse for each
    ; byte to be read. pin high creates start
    ; of pulse.
    ; rs_receive creates end of pulse
    ; when it makes the pin an input.
    pin_high( pin_d1 )

    ; pin D1 will be used for input
    rs_param_set( rs_invert |~
     ~ rs_9600 | pin_d0 )
    ; read each byte with a short wait
    =( in_val, rs_receive( 100, 0b, in_err ))
    IF in_err
      rs_param_set( debug_pin )
      con_out_char( in_val )

Basic Stamp II Sample

' sample program for RSB509B on STAMP II
inval VAR byte

' generate a 10 ms pulse to signal
' initialization

' pin P1 is used for input.
' we are using open, inverted, 9600,
' 8N1 format. No match byte is used
' but we must send a byte to hold our place
' during initialization
SEROUT 1, 49236, [" "]

' pin P1 is used for input.
' we are using open, inverted, 9600,
' 8N1 format
' serial input is inverted and 9600 baud
SEROUT 1, 49236, [%00000100]

' wait for RSB509 to reset

' generate a quick pulse for each byte
' to be read. HIGH creates the start of
' the pulse. SERIN creates the end of the
' pulse when it makes the pin an input
' because the interface pin is pulled low

' pin P1 is used for input.
' we are using open, inverted, 9600,
' 8N1 format. If a byte is not received within
' 1 ms branch to "around" to poll again.
' data will only be displayed when
' byte is received
SERIN 1, 16468, 1, around, [inval]

' show character received on debug window
DEBUG inval

GOTO around