Index >> Products >> Support & Download >> Remore serial ports

RepBuf

RepBuf is a new protocol for retrieving data from the buffer of PortStore2 PL products. It is now possible to re-read data that have already been sent, as well as confirm data reception. RepBuf increases the reliability of CMDR/CDR data transfer and processing in call accounting applications.

 

The RepBuf protocol supports controlled reading and deletion of individual memory blocks, as well as re-reading all stored data. It uses extended NVT commands; however, it does not support the Client/Server mode.

RepBuf overview

  • RepBuf allows partial reading of data, or reading the entire buffer multiple times.
  • With RepBuf, data are marked as read only after it is confirmed that they are stored in a database. Hence, data loss can be avoided.
  • RepBuf can be combined with TEA authentication for security.
  • RepBuf requires NVT support.
  • RepBuf can be only used with PortStore2 products in TCP Server mode.
  • RepBuf works as a TCP server only.

 

How does RepBuf work

RAW and Raw + NVT

In the standard RAW and Raw + NVT modes, the internal PortStore memory works as a LIFO buffer. When a connection to the unit is established, all stored data are transmitted first, and then the unit acts as a transparent TCP/IP to serial port bridge.
All stored data are transmitted in both the TCP Server and the TCP Client/Server mode of a PortStore2 unit.

In the RAW and Raw + NVT modes, PortStore2 starts firing off the stored data as soon as a connection is established.

 

RepBuf

In the RepBuf mode, data download is fully controlled, via NVT commands, by the PC application (TCP Client) that initiated the connection. The NVT commands allow to:

  • Query buffer status (volume of unread data).
  • Move the pointers to a specified position.
  • Download data from the current pointer position to the end of a block (1 Byte to 64 kBytes).

 

In the RepBuf mode, after a connection is established, the PortStore2 device waits for a RepBuf command sent using the NVT protocol. Newly incoming data are stored in the internal buffer first, and the PC application detects them by periodically polling the buffer state and subsequently reading the data.

 

How to use / implement RepBuf

  • If you are an user:
    Use the Visual Basic example that utilizes an ActiveX library. This example is included in the HWg SDK:
    EX418: PortStore Downloader
     
  • If you are an experienced user or an administrator:
    Use the command line downloader that includes automatic detection of PortStore2 mode.
    This example is included in the HWg SDK:
    EX114: PortStore Downloader CMD (Borland C++ Builder)
  • If you are a programmer:
    Download repbufrdr.exe – a stand-alone example in Borland C++, including documentation and the RepBuf protocol description, and create your own implementation: HWg_RepBuf_downloader.zip