Docklight Manual
Docklight Manual
0 User
Manual 02/2013
Copyright 2013 Flachmann und Heggelbacher GbR
I Docklight V2.0 User Manual 02/2013
Table of Contents
1 Copyright 1
2 Introduction 2
2.1 Docklight
...................................................................................................................................
- Overview 2
2.2 Typical
...................................................................................................................................
Applications 2
2.3 System
...................................................................................................................................
Requirements 3
3 User Interface 5
3.1 Main
...................................................................................................................................
Window 5
3.2 Clipboard
...................................................................................................................................
- Cut, Copy & Paste 5
3.3 Notepad
................................................................................................................................... 6
8 Reference 24
8.1 Menu
...................................................................................................................................
and Toolbar 24
8.2 Dialog:
...................................................................................................................................
Edit Send Sequence 25
8.3 Dialog:
...................................................................................................................................
Edit Receive Sequence 26
8.4 Dialog:
...................................................................................................................................
Create Log File(s) 27
8.5 Dialog:
...................................................................................................................................
Find Sequence 27
8.6 Dialog:
...................................................................................................................................
Send Sequence Parameter 28
8.7 Dialog:
...................................................................................................................................
Project Settings - Communication 28
8.8 Dialog:
...................................................................................................................................
Project Settings - Flow Control 29
8.9 Dialog:
...................................................................................................................................
Project Settings - Communication Filter 30
8.10 Dialog:
...................................................................................................................................
Options 30
8.11 Dialog:
...................................................................................................................................
Customize HTML Output 32
8.12 Dialog:
...................................................................................................................................
Expert Options 33
8.13 Keyboard
...................................................................................................................................
Console 34
9 Support 35
9.1 Web
...................................................................................................................................
Support and Troubleshooting 35
9.2 E-Mail
...................................................................................................................................
Support 35
10 Appendix 36
10.1 ASCII
...................................................................................................................................
Character Set Tables 36
10.2 Hot...................................................................................................................................
Keys 38
10.3 RS232
...................................................................................................................................
Connectors / Pinout 40
10.4 Standard
...................................................................................................................................
RS232 Cables 42
10.5 Docklight
...................................................................................................................................
Monitoring Cable RS232 SUB D9 43
10.6 Docklight
...................................................................................................................................
Tap 44
II
III Docklight V2.0 User Manual 02/2013
11.21 Virtual
...................................................................................................................................
Null Modem 50
11.22 Wildcard
................................................................................................................................... 51
1 Copyright
Copyright 2013 Flachmann und Heggelbacher GbR
All rights reserved. No parts of this work may be reproduced in any form or by any means - graphic,
electronic, or mechanical, including photocopying, recording, taping, or information storage and
retrieval systems - without the written permission of the publisher.
Trademarks
Products that are referred to in this document may be either trademarks and/or registered
trademarks of the respective owners. The publisher and the author make no claim to these
trademarks.
Microsoft and Windows are either registered trademarks or trademarks of Microsoft Corporation in
the United States and/or other countries.
Disclaimer
While every precaution has been taken in the preparation of this document, the publisher and the
author assume no responsibility for errors or omissions, or for damages resulting from the use of
information contained in this document or from the use of programs and source code that may
accompany it. In no event shall the publisher and the author be liable for any loss of profit or any
other commercial damage caused or alleged to have been caused directly or indirectly by this
document.
Contact
2 Introduction
2.1 Docklight - Overview
Docklight is a testing, analysis and simulation tool for serial communication protocols (RS232,
RS485/422 and others). It allows you to monitor communications between two serial devices or to
test the serial communication of a single device. Docklight is easy to use and works on almost any
standard PC running Windows 8, Windows 7, Windows Vista and Windows XP.
Docklight will work with the COM communication ports provided by your operating system.
Physically, these ports will be RS232 SUB D9 interfaces in many cases. However, it is also
possible to use Docklight for other communication standards such as RS485 and RS422, which
have a different electrical design to RS232 but follow the RS232 communication mechanism.
Docklight has also been successfully tested with many popular USB-to-Serial converters, virtual null
modem software drivers, or Embedded Development tools that appear as a virtual COM port in
Windows.
For RS232 full-duplex monitoring applications, we recommend our Docklight Tap USB accessory, or
our Docklight Monitoring Cable.
This manual only refers to RS232 serial connections in detail, since this is the basis for other serial
connections mentioned above.
TIP: For getting started, have a look at the Docklight sample projects, which demonstrate some of
the basic Docklight functions.
Additional requirements
For RS232 testing or simulation: Minimum one COM port available. Two COM ports for monitoring
communication between two serial devices.
For low-latency monitoring using Docklight Tap: One USB port
Additional cables or software drivers may be required for connecting the equipment to be tested. See
the sections on Docklight Tap, Docklight Monitoring Cable RS232 SUB D9, Standard RS232 Cables
and virtual null modem drivers.
3 User Interface
3.1 Main Window
The main window of Docklight is divided into four sections:
2. Send Sequences
Define, edit and manage your Send Sequences here. Using the arrow symbol, the selected
sequence can be sent out immediately. Double click on the blank field at the end of a list to create a
new sequence. The sequence list can be reordered by dragging a sequence to a new position with
the left mouse button pressed. A context menu (right mouse button) is available to cut, copy or
paste entire Send Sequences to/from the Clipboard. See Editing and Managing Sequences and
Dialog: Edit Send Sequence for more information.
3. Receive Sequences
Define, edit and manage your Receive Sequences here. Double click on the blank field at the end of
a list to create a new sequence. The Receive Sequence list supports the same reordering and
clipboard operations as the Send Sequence list. You can also copy a Send Sequence to the
clipboard and paste it into the Receive Sequence list. See Editing and Managing Sequences and
Dialog: Edit Receive Sequence for more information.
4. Communication Window
Displays the outgoing and incoming communication on the serial port. Various display options are
available for communication data, including ASCII / HEX / Decimal / Binary display, time stamps and
highlighting (see Options). If serial communication is stopped, all data from the communications
window may be copied to the clipboard or printed. You may also search for specific sequences
using the Find Sequence function. See How Serial Data is Processed and Displayed for more
information.
You can cut a serial data sequence from the communication window and create a new Send or
Receive Sequence by simply pasting it into the appropriate list. Or edit a Send Sequence, copy a
part of this sequence to the clipboard and create a new Receive Sequence out of it by pasting it into
the Receive Sequence window.
TIP: Try the right mouse button to display a context menu for Cut, Copy and Paste operations.
3.3 Notepad
The Docklight Notepad is a separate window for writing down additional notes concerning your
Docklight project (how to use the Send / Receive Sequences, notes on additional test equipment,
etc.). The notepad window can be shown using the F12 key or the menu Tools > Show Notepad.
The notepad is a simple text box that does not offer formatting menus or toolbars, but you can paste
formatted text from the Windowsclipboard.
The notepad contents are stored along with all other Docklight project settings (see saving and
loading your project data). When opening a Docklight project file, the notepad is displayed
automatically, if project notes are available.
NOTE: Closing the notepad window does not delete your notes. They will be still available when you
press F12 again. To remove all notes, empty the text box using Ctrl+A (Select All) and the DEL
key.
Docklight's communication window shows the current communication on the selected serial port(s).
Docklight distinguishes between two communication channels (channel 1 and channel 2), which
represent the incoming and outgoing data in Send/Receive Mode or the two communication
channels being observed in Monitoring Mode. Channel 1 and channel 2 data are displayed using
different colors or fonts, and the communication data may be printed or stored as a log file in plain
text or HTML format.
Besides the serial data, Docklight inserts date/time stamps into the communication display. By
default, a date/time stamp is inserted every time the data flow direction switches between channel 1
and channel 2, or before a new Send Sequence is transmitted. There are several options available for
inserting additional time stamps. This is especially useful when monitoring a half-duplex line with
only one communication channel. See Options --> Date/Time Stamps
Docklight is able to process serial data streams containing any ASCII code 0 - 255 decimal. Since
there are non-printing control characters (ASCII code < 32) and different encodings for ASCII code >
127, not all of these characters can be displayed in the ASCII text window. Nonetheless, all
characters will be processed properly by Docklight and can be displayed in HEX, Decimal or Binary
format. Docklight will process the serial data on any language version of the Windows operating
system in the same way, although the ASCII display might be different. For control characters
(ASCII code < 32), an additional display option is available to display their text equivalent in the
communication window. See Options dialog and Appendix, ASCII Character Set Tables.
Docklight allows you to suppress all original serial data, if you are running a test where you do not
need to see the actual data, but only the additional evaluations generated using Receive Sequences.
See the Project Settings for Communication Filter.
Sequences are defined using the Edit Send Sequence or Edit Receive Sequence dialog window.
This dialog window is opened
1. by choosing Edit from the context menu available using the right mouse button.
2. by double-clicking on an existing sequence or pressing Ctrl + E with the Send Sequence or
Receive Sequence list selected.
3. when creating a new sequence by double-clicking on the blank field at the end of a list (or
pressing Ctrl + E).
4. when pasting a new sequence into the sequence list.
Docklight supports the use of wildcards (e.g. wildcard "?" as a placeholder for one arbitrary
character) within Receive Sequences and Send Sequences. See the sections sending commands
with parameters and checking for sequences with random characters for details and examples.
Preconditions
You need the specification of the protocol to test, e.g. in written form.
The serial device to test should be connected to one of the PC's COM ports. See section
Standard RS232 Cables for details on how to connect two serial devices.
The serial device must be ready to operate.
1. Double click on the last line of the Send Sequences table. The Edit Send Sequence dialog is
displayed (see also Editing and Managing Sequences).
2. Enter a Name for the sequence. The sequence name should be unique for every Send
Sequence defined.
3. Enter the Sequence itself. You may enter the sequence either in ASCII, HEX, Decimal or
Binary format. Switching between the different formats is possible at any time using the Edit
Mode radio buttons.
4. After clicking the OK button the new sequence will be added to the Send Sequence lists.
Repeat steps 1 - 4 to define the other Send Sequences needed to perform your test.
Sequences.
1. Double click on the last line of the Receive Sequences table. The dialog Edit Receive Sequence
is displayed. The dialog consist of three parts: Name field, Sequence field, and Action field.
2. Edit the Name and Sequence fields.
3. Specify an Action to perform after the sequence has been received by Docklight. There are four
types of actions available:
Answer - After receiving the sequence, transmit one of the Send Sequences.
Comment - After receiving the sequence, insert a user-defined comment into the
communication window (and log file, if available).
Trigger - This is an advanced feature described in Catching a specific sequence...
Stop - After receiving the sequence, Docklight stops communications.
4. Click the OK button to add the new sequence to the list.
Repeat steps 1 - 4 to define the other Receive Sequences you need to perform your test.
Docklight will open a serial connection according to the parameters specified. It will then display all
incoming and outgoing communication in the communication window. Use the Send button
to send one of the defined sequences to the serial device. The on-screen display of all data transfer
allows you to check the device's behavior. All protocol information can be logged in a text file for
further analysis. Please see section Logging and analyzing a test.
TIP: Using the notepad window (F12 key / menu Tools > Show Notepad), you can easily take
additional notes, or copy & paste parts of the communication log for further documentation.
Preconditions
You need the specification of the behavior of the serial device you want to simulate, e.g. what kind
of information is sent back after receiving a certain command.
A second device is connected to a PC COM port, which will communicate with your simulator.
This second device and its behavior is the actual object of interest. An example could be a device
that periodically checks the status of an UPS (Uninterruptible Power Supply) using a serial
communication protocol. You could use Docklight to simulate basic UPS behavior and certain UPS
problem cases. This is very useful when testing the other device, because it can be quite difficult to
reproduce an alarm condition (like a bad battery) at the real UPS.
NOTE: The second device may also be a second software application. It is possible to run both
Docklight and the software application on the same PC. Simply use a different COM port for each of
the two applications and connect the two COM ports using a RS232 null modem cable. You can
also use a virtual null modem for this purpose.
NOTE: See Testing a serial device... to learn how to define Send Sequences.
For every command sequence defined, specify Answer as an action. Choose one of the sequences
defined in C). If you want to use two or more alternative response sequences, make several copies of
the same Receive Sequence, give them a different name (e.g. "status cmd - answer ok", "status
cmd - answer battery failure", "status cmd - answer mains failure") and assign different Send
Sequences as an action. In the example, you would have three elements in the Receive Sequences
list that would respond to the same command with three different answers. During the test you may
decide which answer should be sent by checking or unchecking the list elements using the Active
column.
Docklight will now respond to all commands received from the connected serial device.
The on-screen data transfer display allows you to monitor the communications flow. All protocol
information can be logged to a text file for further analysis. See section Logging and analyzing a
test.
TIP: Using the notepad window (F12 key / menu Tools > Show Notepad), you can easily take
additional notes, or copy & paste parts of the communication log for further documentation.
Preconditions
A Docklight Monitoring Cable or a Docklight Tap is required to tap the RS232 TX signals of both
serial devices and feed them into Docklight, while not interfering with the communications between
the devices.
For a Docklight Monitoring Cable setup, two COM ports must be available on your PC for
monitoring. Each port will receive the data from one of the serial devices being monitored.
For a Docklight Tap setup, please make sure you have installed up-to-date USB drivers (FTDI
drivers), as available on our Docklight Download page.
Device 1 and Device 2 must be ready to operate.
NOTE: In Docklight Monitoring Mode, all received data from one COM port is re-sent on the TX
channel of the opposite COM port ("Data Forwarding"). This does not have any effect for
Docklight Monitoring Cable setups, since the TX signal is not connected. But it can be useful for
special applications where you need to route the serial data traffic through Docklight using
standard RS232 cabling. If you require a pure passive monitoring behavior where no TX data
appears, you can disable the "Data Forwarding" using the menu Tools > Expert Options...
4. Set the baud rate and all other communication parameters for the protocol being used
NOTE: Make sure your PC's serial interfaces port works properly at the baud rate and for the
communication settings used by Device 1 and Device 2. If Device 1 and 2 use a high speed
data transfer protocol, the PC's serial interfaces and the Docklight software itself might be too
slow to receive all data properly.
5. Confirm the settings and close the dialog by clicking the OK button.
NOTE: Since a special monitoring cable is used for this test, all communication between serial
device 1 and serial device 2 will remain unbiased and no additional delays will be introduced by
Docklight itself. This is particularly important when using Docklight for tracking down timing
problems. This means, however, that there is no way to influence the serial communication between
the two devices. While communication mode Monitoring is selected, it is not possible to use Send
Sequences.
TIP: The Snapshot Function allows you to locate a rare sequence or error condition in a
communication protocol with a large amount of data.
TIP: See the sections How to Increase the Processing Speed... and How to Obtain Best Timing
Accuracy to learn how to adjust Docklight for applications with high amounts of data, or increased
timing accuracy requirements.
Preconditions
Docklight is ready to run a test as described in the previous use cases, e.g. monitoring serial
communications between two devices.
Taking a snapshot
NOTE: Do not forget to disable the trigger option for all other Receive Sequences that should be
ignored in your test so that they do not trigger the snapshot.
B) Creating a snapshot
Click on the Snapshot button of the toolbar. Docklight will start communications, but will not
display anything in the communication window. If the trigger sequence is detected, Docklight will
display communication data before and after the trigger event. Further data is processed, until the
trigger sequence is located roughly in the middle of the communication window. Docklight will then
stop communication and position the cursor at the trigger sequence.
Docklight is ready to run a test as described in the previous use cases, e.g.
Testing a serial device or a protocol implementation
For each representation (ASCII, HEX, ...), a separate log file may be created. Choose at least one
representation. Log files will have a ".txt" or ".htm" file extension. Docklight additionally adds the
representation type to the file name to distinguish the different log files. E.g. if the user specifies
"Test1" as the base log file name, the plain text ASCII file will be named "Test1_asc.txt", whereas
an HTML HEX log file will be named "Test1_hex.htm".
Confirm your log file settings and start logging by clicking the OK button.
To stop logging and close the log file(s), click the Stop Logging button on the main toolbar.
Unless the log file(s) have been closed, it is not possible to view their entire contents.
Take, for example, the following situation: A serial device measures the temperature and periodically
sends the actual reading. Docklight shows the following output:
07/30/2012 10:20:08.022 [RX] - temperature=82F<CR>
07/30/2012 10:22:10.558 [RX] - temperature=85F<CR>
07/30/2012 10:24:12.087 [RX] - temperature=93F<CR>
07/30/2012 10:26:14.891 [RX] - temperature=102F<CR>
...
Defining an individual Receive Sequence for every temperature value possible would not be a
practical option. Instead you would define one Receive Sequence using wildcards. For example:
t|e|m|p|e|r|a|t|u|r|e|=|?|#|#|F|r
("r" is the terminating <CR> Carriage Return character)
This ReceiveSequence would trigger on any of the temperature strings listed above. It allows a 1-3
digit value for the temperature (i.e. from "0" to "999"). The following step-by-step example describes
how to define the above sequence. See also the additional remarks at the end of this section for
some extra information on '#' wildcards.
Preconditions
Docklight is ready to run a test as described in the previous use cases, e.g. testing a serial device
or a protocol implementation.
The serial device (the temperature device in our example) is operating.
t|e|m|p|e|r|a|t|u|r|e|=|?|#|#|F|r
5. Specify an Action to perform after a temperature reading has been detected.
6. Click OK to add the new sequence to the Receive Sequence list.
NOTE: To distinguish the wildcards '?' and '#' from the regular question mark or number sign
characters (decimal code 63 / 35), the wildcards are shown on a different background color within
the sequence editor.
Docklight will now detect any temperature reading and perform the specified action.
Macro keywords can be used in the Edit Receive Sequence > 3 - Action > Comment text box, to
create Docklight comment texts with dynamic data, e.g. the actual data received.
%_C Insert the Docklight channel no. / data direction (1 or 2) for the data
received
%_A Insert the actual data that triggered this Receive Sequence. Use ASCII
representation
Example:
For a Receive Sequence as described above ( t | e | m | p | e | r | a | t | u | r | e | = | ? | # | # | F | r ),
you could define the following comment text:
82 °F
10/30/2012 10:22:10.558 [RX] - temperature=85F<CR>
New Temp =
85 °F
10/30/2012 10:24:12.087 [RX] - temperature=93F<CR>
New Temp =
93 °F
1. '#' wildcards at the end of a Receive Sequence have no effect. The Receive Sequence
"HelloWorld###" will behave like a Receive Sequence "HelloWorld".
It is recommended to save your current project before starting a test run. Please note the difference
between storing the project settings as described here and logging the communication during a test
(see section logging and analyzing a test). Test run results are stored separately from Projects.
Loading a project is done using the File > Open Project... menu.
Example: A digital camera supports a command to set the exposure time. For setting the exposure
time to 25 milliseconds, you need to send the following sequence:
e | x | p | | 0 | 2 | 5 | r ("r" is a terminating <CR> Carriage Return character)
To avoid defining a new Send Sequence for every exposure time you want to try, you can use a
Send Sequence with wildcards instead:
e|x|p| |?|?|?|r
The following step-by-step example describes how to define an exposure time command with a
parameter and use a different exposure value each time the sequence is sent.
Preconditions
NOTE: To distinguish a '?' wildcard from a question mark ASCII character (decimal code 63), the
wildcard is shown on a different background color within the sequence editor.
It is possible to define commands with several parameters, using several wildcard areas within one
sequence. The Send Sequence Parameter dialog will then appear several times before sending out a
sequence.
NOTE: If you are using Wildcard '?', you must provide exactly one character for each '?' when
sending the sequence. For variable-length parameters use Wildcard '#' (matches zero or one
character).
NOTE: You cannot use a Send Sequence with wildcards as an automatic answer for a Receive
Sequence (see Action).
6.2 How to Increase the Processing Speed and Avoid "Input Buffer
Overflow" Messages
When monitoring serial communications between two devices, Docklight cannot control the amount
of incoming data. Since Docklight applies a number of formatting and conversion rules on the serial
data, only a limited number of bytes per seconds can be processed. There are numerous factors
that determine the processing speed, e.g. the PC and COM devices used, the Display Settings, and
the Receive Sequence Actions defined. It is therefore not possible to specify any typical data rates.
If Docklight cannot keep up with the incoming data, it adds the following comment to the
communication data display:
TIP: Search for this message using the Find Sequence in Communication Window... (Ctrl +
F) function.
Docklight will also react slowly to any user input, including a Stop communication command.
If you are experiencing the above behavior, Docklight offers you several ways to increase the data
throughput.
2. Log the communication data to a plain text file instead of using the communication window(s):
- Use the "plain text" Log File Format
- Create only a log file for the Representation (ASCII / HEX / Decimal / Binary) you actually need
- Disable the communication windows while logging, using the High Speed Logging option
3. Use the Communication Filter from the Project Settings... dialog, and disable the original
serial data for one or both communication directions. This is especially useful if you actually
know what you are looking for and can define one or several Receive Sequences for this pieces
of data. These Receive Sequences can print a comment each time the sequence appears in the
data stream so you still know what has happened, even if the original serial data is not
displayed by Docklight.
This behavior is not caused by poor programming, but is rather characteristic for a PC/Windows
system, and the various hardware and software layers involved. Unspecified delays and timing
inaccuracies can be introduced by:
The COM device’s chipset, e.g. the internal FIFO (First-In-First-Out) data buffer.
The USB bus transfer (for USB to Serial converters).
The serial device driver for Windows.
The task/process scheduling in a multitasking operating system like Windows.
The accuracy of the date/time provider.
Docklight comes with a very accurate date/time provider with milliseconds granularity, but it still
needs to accept the restrictions from the hardware and software environment around it.
Here is what you can do to minimize additional delays and inaccuracies and achieve a typical time
tagging accuracy of 5 milliseconds or better:
1. Get our Docklight Tap for lowest USB-related latency times. Or use on-board RS232 ports, if
still available on your PC.
2. Choose External / High Priority Process Mode in the Tools > Expert Options... dialog.
3. When monitoring high amounts of data, use the recommendations from the previous section
How to Increase the Processing Speed... to avoid input buffer overflows and that the computer
become irresponsive because of high CPU usage.
NOTE: The Expert Options... recommended above will change the overall system balance and must
be used with care. Best results can be achieved only when logged in as an Administrator. Please
make sure you understood the remarks and warning in the documentation.
NOTE: If you are logged on with a restricted user account, you will not have permission to make any
changes in the program files directory. In this case, saving a project file or any other data into
the \Samples folder will produce an error.
NOTE: For additional sample projects and Application Notes, see our online resources at
www.docklight.de/examples_en.htm
This is a simple example for Testing a serial device or a protocol implementation. The sample project
uses the communication settings listed below. This should work for most standard modems.
Getting started
Use the Windows Device Manager to find out which COM Port is a modem device. This demo
project may be used with any AT-compatible modem available on your PC, e.g. a built-in notebook
modem, or a GSM or Bluetooth modem driver than can be accessed through a virtual COM port.
TIP: For a simple test without specialized hardware, add your mobile phone as Bluetooth Device
on your Windows PC. Then find your phone in the Windows Devices and Printers list. Right-click
on it, choose Properties and go to the Hardware tab. In the Device Functions list it should
mention the modem related COM Ports.
Go to the Project Settings... dialog and make sure you have selected the same COM Port
for Send/Receive on comm. channel.
Press the Start Communication button in the toolbar.
Try sending any of the predefined modem commands by pressing the Send button
You should now receive a response from your modem, e.g. "OK" if your command was accepted, a
model identification number, etc. The response will vary with the modem model.
After sending several sequences, the Docklight communication window could look like this:
Further Information
The Send Sequences list includes the following standard AT modem commands:
The \Samples folder also contains a log file ModemDiagnostics_Logfile_asc.txt. It shows a test
run where the above Send Sequences were sent to a real modem.
Getting started
Docklight will detect the incoming data as being one of the defined Receive Sequences. It will then
perform the action predefined for this event, which is sending out another sequence. As a result,
Docklight will send out alternating Send Sequences - "Ping" and "Pong".
See also the corresponding log files in the \Samples folder (PingPong_Logfile_asc.htm and
PingPong_Logfile_hex.htm).
Further Information
1. Run two Docklight applications on the same PC using different COM ports. The two COM ports
are connected using a simple null modem cable.
2. Instead of two RS232 COM ports and a null modem cable you can use a virtual null modem.
3. Use two PCs and run Docklight on each PC. Connect the two PCs using a simple null modem
cable.
8 Reference
8.1 Menu and Toolbar
File Menu
New Project
Close the current Docklight project and create a new one.
Exit
Quit Docklight.
Edit Menu
Run Menu
Start communication
Open the communication ports and enable serial data transfer.
Stop communication
Stop serial data transfer and close the communication ports.
Tools Menu
Keyboard Console On
Enable the keyboard console to send keyboard input directly.
Show Notepad
Show the notepad window.
Project Settings...
Select the current project settings (communication settings, flow control settings, communication
filter...).
Options...
Select general settings (e.g. display).
Expert Options...
Select expert program options intended for advanced users and specific applications (e.g. high
monitoring accuracy).
Index
The index of the sequence displayed below. The first sequence has index 0 (zero).
1 - Name
Unique name for this sequence (e.g. "Set modem speaker volume"). This name is for referencing the
sequence. It is not the data that will be sent out through the serial port. See "2 - Sequence" below.
2 - Sequence
The character sequence that will be transmitted through the serial port.
3 - Additional Settings
Check the "Send periodically..." option to define a sequence that is sent periodically. A time interval
between 0.01 seconds and 9999 seconds can be specified.
NOTE: The Windows reference time used for this purpose has only limited precision. Time intervals
< 0.03 seconds will usually not be accurate.
Wildcards
Wildcards can be used to introduce parameters into a Send Sequence that you wish to insert
manually each time the sequence is sent. See section Sending commands with parameters for
details and examples.
Use Options... --> Control Character Shortcuts to define other shortcuts you find useful.
Index
The index of the sequence displayed below. The first sequence has index 0 (zero).
1 - Name
Unique name for this sequence (e.g. "Ping received"). This name is for referencing the sequence. It
is not the sequence received through the serial port. See "2 - Sequence" below.
2 - Sequence
The character sequence which should be detected by Docklight within the incoming serial data.
3 - Action
The action(s) performed when Docklight detects the sequence defined above.
Wildcards
Wildcards can be used to test for sequences that have a variable part with changing values (e.g.
measurement or status values). See section Checking for sequences with random characters for
details and examples.
Use Options... --> Control Character Shortcuts to define other shortcuts you find useful.
Representation
A separate log file may be created for each data representation (ASCII, HEX, ...). Choose at least
one representation. The log files will have a ".txt" or ".htm" file extension. Docklight additionally adds
the representation type to the file name to distinguish the different log files. E.g. if the user specifies
"Test1" as the base log file name, the plain text ASCII log file will be named "Test1_asc.txt",
whereas the plain text HEX log file will be named "Test1_hex.txt".
The Find Sequence function searches the contents of the communication window. The search is
performed in the communication window tab that is currently selected (ASCII, HEX, Decimal or
Binary). You may, however, define your search string in any other representation.
You can search for anything that is already defined as a Send Sequence or a Receive Sequence, or
you may define a custom search sequence.
NOTE: If you are looking for a sequence within the ASCII communication window, please remember
the following limitations:
The Find Sequence function is not able to locate sequences containing non-printing control
characters (ASCII decimal code < 32) or other special characters (decimal code > 127). This is
due to the nature of the ASCII display. Search using the HEX or Decimal communication window
tab instead.
In ASCII mode, the Find Sequence function will treat date/time stamps and any other comments
in the same way as regular communication data. In HEX / Decimal / Binary mode, all additional
information is ignored as long as it does not look like a character byte value.
NOTE: While the Send Sequence Parameter dialog is shown, all serial communication is paused.
Docklight does not receive any data and does not send any (periodical) Send Sequences.
Communication Mode
Send/Receive
Docklight acts both as transmitter and receiver of serial data. This mode is used when Testing the
functionality or the protocol implementation of a serial device or simulating a serial device.
Naming conventions: The received data (RX) will be displayed and processed as "Channel 1", the
transmitted data (TX) will be displayed as "Channel 2".
Monitoring
Docklight receives serial data on two different communication channels. This mode is used, for
example, when Monitoring the communication between two devices.
Naming conventions: The serial data from device 1 is "Channel 1", the data from device 2 is "Channel
2".
For Docklight Tap monitoring applications, open the dropdown list and choose the TAP port (e.g.
TAP0 for Channel 1, and TAP1 for Channel 2) from the 'USB Tap' section below the COM ports. The
TAP connections are only available if Communication Mode is set to 'Monitoring', the Docklight Tap
is plugged in and the Docklight Tap USB device drivers are installed properly.
Baud Rate
Choose a standard baud rate from the dropdown list, or use a non-standard baud rate by typing any
integer number between 110 and 9999999.
NOTE: Non-standard baud rates may not work correctly on all COM ports, dependant on the
capabilities of your COM port's hardware UART chip. You will receive no warning, if any non-standard
rate cannot be applied.
NOTE: Although Docklight's Project Settings allow you to specify baud rates up to 9 MBaud, this
does not mean Docklight is able to handle this level of throughput continuously. The average data
throughput depends very much on your PC's performance and the Docklight display settings. See
also How to Increase the Processing Speed.
NOTE: There are many COM ports drivers and applications that do not use actual RS232/422 or 485
transmission, and do not require any of the RS232 communication parameters. In some cases such
COM port drivers even return an error when trying to set the RS232 parameters, so Docklight would
fail to open the COM channel. Use the Baud Rate setting None for these applications.
Parity
All common parity check options are available here. (The settings 'Mark' and 'Space' will probably
not be used in practical applications. 'Mark' specifies that the parity bit always is 1, 'Space' that the
parity bit is always 0, regardless of the character transmitted.)
NOTE: Choose "(ignore)" for the Parity Error Character if you need to transmit/receive the parity bit
but Docklight should preserve all incoming characters, even when the parity bit is wrong. This is
useful for applications where a 9th bit is used for addressing purposes and not for error checking.
Used to specify additional hardware or software flow control settings for serial communications in
Docklight Send/Receive Mode.
Off
No hardware or software flow control mechanism is used. RTS and DTR are enabled when the COM
port is opened.
Manual
Use this mode to control the RTS and DTR signals manually and display the current state of the
CTS, DSR, DCD and RI lines. If flow control is set to "Manual", an additional status element is
displayed in the Docklight main window. You may toggle the RTS and DTR lines by double clicking
on the corresponding indicator.
NOTE: Flow control signals are not treated as communication data and will not be displayed in the
communication window or logged to a file.
NOTE: Many USB-to-Serial converters or virtual COM port drivers do not implement the Windows
RTS_CONTROL_TOGGLE mode properly. If you experience problems with RS485 Transceiver
Control, try using a PC with an on-board COM interface or a standard PCI COM card.
Use the Contents Filter option if you do not need to see the original communication data on the
serial line and only require the additional comments inserted by a Receive Sequence. This is useful
for applications with high data throughput, where most of the data is irrelevant for testing and you
only need to watch for very specific events. These events (and related display output) can be defined
using Receive Sequences.
Display
NOTE: If you change the font size, the communication window contents will be deleted. For all other
changes, Docklight will try to preserve the display contents.
Display Modes
Date/Time Stamps
For applications where the data flow direction does not change very often, you may want to have
additional date/time stamps at regular time intervals. For this, activate the Clock - additional date/
time stamp... option then and choose a time interval.
On a half duplex line (e.g. 2 wire RS485), changes in data direction are difficult to detect. Still, in
most applications there will be a pause on the communication bus before a new device starts
sending. Use the Pause detection... option to introduce additional time stamps and make the
pauses visible in your communication log.
Date/Time Format
Docklight offers time stamps with a resolution of up to 1/1000 seconds (1 millisecond). For
compatibility to earlier Docklight versions (V1.8 and smaller), 1/100 seconds is available, too.
NOTE: The resulting time tagging accuracy can be considerably different, e.g. 10-20 milliseconds
only. The actual accuracy depends on your serial communications equipment, your PC
configuration, the Docklight Display Settings (see above) and the Docklight Expert Options. See the
section How to Obtain Best Timing Accuracy for details.
Here you can define your own keyboard shortcuts for ASCII Control Characters (ASCII code < 32), or
for any character code > 126. Keyboard shortcuts can be used within the following Docklight dialogs
and functions
For each character from decimal code 0 to 31 and from 127 to 255, you can define a keyboard
combination to insert this character into a sequence (Shortcut). You may also define a letter which
is used to display this control character when editing a sequence in ASCII mode (Editor).
You need some basic understanding of HTML documents and CSS style attributes. We
recommend http://www.htmldog.com (English) or http://www.selfhtml.org (German and French) for a
quick overview on these topics.
NOTE: Use the semicolon (";") as a separator between two different CSS style attributes, e.g.
font-family:sans-serif; font-size:small
NOTE: Docklight will insert additional <u> (underline), <i> (italic) and <b> (bold) HTML tags, if such
formatting options are activated in the Display Settings. You do not have to use the font-style or
font-weight attribute to create these effects.
The template code for the header, footer and data parts contains Docklight-specific wildcards which
must not be deleted:
Wildcard Description
%BACKCOLOR% The background color, as selected in the Display Settings
%HEADERMSG% Header text at the start of the log file
%FOOTERMSG% Footer text at the end of the log file
%DATA% a chunk of the log file data: channel 1 data, channel 2 data, or a
comment text
%TEXTCOLOR% The text color to apply for %DATA%, as selected in the Display
Settings
When generating a log file, Docklight replaces the wildcards with the current display settings and the
actual communication data.
Expert Options are additional settings for specialized applications with additional requirements (e.g.
high time tagging accuracy).
Performance
Use External / High Priority Process mode to work around a common problem for any Windows
user mode application: unspecified delays and timing inaccuracies can be introduced by the
Windows task/process scheduling, especially if you are running other applications besides
Docklight. External / High Priority Process mode is recommended for high accuracy / low latency
monitoring using the Docklight Tap.
In External / High Priority Process mode, the data collection in Docklight becomes a separate
Windows process with realtime priority class. It will be executed with higher priority than any other
user application or additional application software like Antivirus. For best results you need to be
logged in as an Administrator. Otherwise the data collection process will run with the maximum
permitted priority, but not "realtime class".
NOTE: External / High Priority Process mode must be used with care, especially when you intend
to monitor a high-speed data connection with large amounts of data. The PC might become
irresponsive to user input. To resolve such a situation, simply "pull the plug": First disconnect the
data connections or the monitoring cable to bring down the CPU load and restore the
responsiveness. Then choose Stop communication in Docklight.
NOTE: See the section How to Obtain Best Timing Accuracy for some background information on
timing accuracy.
When Monitoring Serial Communications Between Two Devices, all received data from one COM
port is re-sent on the TX channel of the opposite COM port by default ("Data Forwarding"). This is
intended for special applications that require routing the serial data traffic through Docklight using
standard RS232 cabling.
Use the No Data Forwarding Expert Option for applications with two serial COM ports where you
need to avoid that any TX data is sent. This can be used to improve performance when using a
Docklight Monitoring Cable, or to work around problems caused with instable serial device drivers.
For Docklight Tap applications (e.g. using Communication Channel TAP0 / TAP1), the 'Data
Forwarding' setting has no effect. The Docklight Tap is accessed in read-only mode always, and no
data is forwarded.
After activating the keyboard console, click in the communication window and type some
characters.
Docklight will transmit the characters directly through the selected serial port. The communication
window will display the characters the same way it does a Send Sequence.
NOTE: The Keyboard Console tool supports pasting and transmitting a character sequence from the
clipboard, using Ctrl + V. This is similar to pasting clipboard data inside the Edit Send Sequence
Dialog. Clipboard contents that exceeds the maximum sequence size of 1024 characters gets
truncated.
NOTE: The keyboard console is not a full-featured terminal and does not support specific terminal
standards, such as VT 100. The Enter key is transmitted as <CR> (ASCII 13) plus <LF> (ASCII 10),
as per the Windows standard text file format. Use control character shortcuts to send other ASCII
control characters.
9 Support
9.1 Web Support and Troubleshooting
For up-to-date FAQs and troubleshooting information, see our online support pages available at
http://www.docklight.de/support_en.htm
docklight@fuh-edv.de
10 Appendix
10.1 ASCII Character Set Tables
Control Characters
Printing Characters
41 29 ) )
42 2A * *
43 2B + +
44 2C , ,
45 2D - -
46 2E . .
47 2F / /
48 30 0 Zero
49 31 1 One
50 32 2 Two
51 33 3 Three
52 34 4 Four
53 35 5 Five
54 36 6 Six
55 37 7 Seven
56 38 8 Eight
57 39 9 Nine
58 3A : :
59 3B ; ;
60 3C < <
61 3D = =
62 3E > >
63 3F ? ?
64 40 @ @
65 41 A A
66 42 B B
67 43 C C
68 44 D D
69 45 E E
70 46 F F
71 47 G G
72 48 H H
73 49 I I
74 4A J J
75 4B K K
76 4C L L
77 4D M M
78 4E N N
79 4F O O
80 50 P P
81 51 Q Q
82 52 R R
83 53 S S
84 54 T T
85 55 U U
86 56 V V
87 57 W W
88 58 X X
89 59 Y Y
90 5A Z Z
91 5B [ [
92 5C \ \
93 5D ] ]
94 5E ^ ^
95 5F _ _
96 60 ` `
97 61 a a
98 62 b b
99 63 c c
100 64 d d
101 65 e e
102 66 f f
103 67 g g
104 68 h h
105 69 i i
106 6A j j
107 6B k k
108 6C l l
109 6D m m
110 6E n n
111 6F o o
112 70 p p
113 71 q q
114 72 r r
115 73 s s
116 74 t t
117 75 u u
118 76 v v
119 77 w w
120 78 x x
121 79 y y
122 7A z z
123 7B { {
124 7C | |
125 7D } }
126 7E ~ Tilde
127 7F DEL Delete
Applies to
Communication window (ASCII, HEX, Decimal, Binary)
Edit Send Sequence dialog / Edit Receive Sequence dialog
Docklight Notepad
Docklight menu
Communication Window
Notepad Window
9-pole SUB D9 (EIA/TIA 574 standard). Introduced by IBM and widely used. See below.
25-pole SUB D25 (RS232-C). This is the original connector introduced for the RS232 standard. It
provides a secondary communication channel.
8-pole RJ45 (RS232-D, according to EIA/TIA-561 standard).
When connecting two serial devices, different cable types must be used, depending on the
characteristics of the serial device and the type of communication used.
Area of Application: DTE-DCE Communication where no additional handshake signals are used.
Area of Application: DTE-DCE Communication with hardware flow control using additional handshake
signals.
Area of Application: DTE-DTE Communication where no additional handshake signals are used.
Area of Application: DTE-DTE Communication with DTE/DCE compatible hardware flow control.
Works also when no handshake signals are used.
We offer a custom RS232 cable that is designed for the use with Docklight Monitoring Mode,
according to the cable specification below. Visit our product overview pages for the Docklight
Monitoring Cable, a professional and rugged cable solution for industrial applications.
Docklight has built-in support for the Docklight Tap. It recognizes the dual port USB serial converter
and offers high-speed, low-latency access to the monitoring data. Use Docklight Monitoring Mode
and Receive Channel settings TAP0 / TAP1. See the Docklight Project Settings and How to Obtain
Best Timing Accuracy for details.
Please also see our product overview pages for more information about the Docklight Tap.
11.2 Break
A break state on an RS232 connection is characterized by the TX line going to Space (logical 0) for
a longer period than the maximum character frame length including start and stop bits. Some
application protocols, e.g. LIN, use this for synchronization purposes.
11.3 Character
A character is the basic unit of information processed by Docklight. Docklight always uses 8 bit
characters. Nevertheless, the communication settings also allow data transmission with 7 bits or
less. In this case, only a subset of the 256 possible 8 bit characters will be used but the characters
will still be stored and processed using an 8 bit format.
11.4 CRC
Cyclic Redundancy Code. A CRC is a method to detect whether a received sequence/message has
been corrupted, e.g. by transmission errors. This is done by constructing an additional checksum
value that is a function of the message data, and then appending this value to the original message.
The receiver calculates the checksum from the received data and compares it to the transmitted
CRC value to see if the message is unmodified. CRCs are commonly used because they allow the
detection of typical transmission errors (bit errors, burst errors) with a very high accuracy.
CRC algorithms are based on polynomial arithmetic, and come in many different versions. Common
algorithms are CRC-CCITT, CRC-16 and CRC-32. An example of an application protocol that uses a
CRC is MODBUS over Serial Line.
A very popular article about CRCs is "Easier said than done (Michael Barr) - A guide to CRC
calculation": http://www.netrino.com/Connecting/2000-01/
Docklight Scripting's CRC functionality (DL.CalcChecksum) was inspired by the above article and
the proposed Boost CRC library:
http://www.boost.org/libs/crc/index.html
Last not least, if you are truly fascinated by CRC alchemy, you will, sooner or later, run into the
following article:
"A Painless Guide to CRC Error Detection Algorithms" by Ross N. Williams
http://www.ross.net/crc/
11.5 DCE
Data Communications Equipment. The terms DCE and DTE refer to the serial devices on each side
of an RS232 link. A modem is a typical example of a DCE device. DCE are normally equipped with
a female SUB D9 or SUB D25 connector. See also DTE.
11.6 DTE
Data Terminal Equipment. The terms DCE and DTE refer to the serial devices on each side of an
RS232 link. A PC or a terminal are examples of a typical DTE device. DTE are commonly equipped
with a male SUB D9 or SUB D25 connector. All pinout specifications are written from a DTE
perspective. See also DCE.
11.8 LIN
Local Interconnect Network. A low cost serial communication bus targeted at distributed electronic
systems in vehicles, especially simple components like door motors, steering wheel controls,
climate sensors, etc. See also http://www.lin-subbus.org
11.9 MODBUS
MODBUS is an application layer messaging protocol that provides client/server communications
between devices connected on different types of buses or networks. It is commonly used as
"MODBUS over Serial Line" in RS422/485 networks, but can be implemented using TCP over
Ethernet as well ("MODBUS TCP").
Two different serial transmission modes for MODBUS are defined: "RTU mode" for 8 bit binary
transmissions, and "ASCII mode". "RTU mode" is the default mode that must be implemented by all
devices.
11.11 RS232
The RS232 standard is defined by the EIA/TIA (Electronic Industries Alliance / Telecommunications
Industry Associations). The standard defines an asynchronous serial data transfer mechanism, as
well as the physical and electrical characteristics of the interface.
RS232 uses serial bit streams transmitted at a predefined baud rate. The information is separated
into characters of 5 to 8 bits lengths. Additional start and stop bits are used for synchronization, and
a parity bit may be included to provide a simple error detection mechanism.
The electrical interface includes unbalanced line drivers, i.e. all signals are represented by a voltage
with reference to a common signal ground. RS232 defines two states for the data signals: mark
state (or logical 1) and space state (or logical 0). The range of voltages for representing these states
is specified as follows:
The physical characteristics of the RS232 standard are described in the section RS232 Connectors /
Pinout
11.12 RS422
An RS422 communication link is a four-wire link with balanced line drivers. In a balanced differential
system, one signal is transmitted using two wires (A and B). The signal state is represented by the
voltage across the two wires. Although a common signal ground connection is necessary, it is not
used to determine the signal state at the receiver. This results in a high immunity against EMI
(electromagnetic interference) and allows cable lengths of over 1000m, depending on the cable type
and baud rate.
The EIA Standard RS422-A "Electrical characteristics of balanced voltage digital interface circuits"
defines the characteristics of an RS422 interface.
Permitted Common Mode Voltage Vcm (mean voltage of A and B terminals with reference to signal
ground): -7V to +7V
11.13 RS485
The RS485 standard defines a balanced two-wire transmission line, which may be shared as a bus
line by up to 32 driver/receiver pairs. Many characteristics of the transmitters and receivers are the
same as RS422. The main differences between RS422 and RS485 are
Two-wire (half duplex) transmission instead of four-wire transmission
Balanced line drivers with tristate capability. The RS485 line driver has an additional "enable"
signal which is used to connect and disconnect the driver to its output terminal. The term "tristate"
refers to the three different states possible at the output terminal: mark (logical 1), space (logical
0) or "disconnected"
Extended Common Mode Voltage (Vcm) range from -7V to +12V.
The EIA Standard RS485 "Standard for electrical characteristics of generators and receivers for use
in balanced digital multipoint systems" defines the characteristics of an RS485 system.
11.15 Sequence
A sequence consists of one or more 8 bit characters. A sequence can be any part of the serial
communications you are analyzing. It can consist of printable ASCII characters, but may also
include every non-printable character between 0 and 255 decimal.
Example:
ATL2 (ASCII format)
41 54 4C 0D 0A (HEX format)
This sequence is a modem command to set the speaker volume on AT compatible modems. It
includes a Carriage Return (0D) and a Line Feed (0A) character at the end of the line.
11.18 Snapshot
Creating a snapshot in Docklight means generating a display of the serial communication shortly
before and after a Trigger sequence has been detected. This is useful when testing for a rare error
which is characterized by a specific sequence. See Catching a specific sequence and taking a
snapshot... for more information.
11.19 Trigger
A Trigger is a Receive Sequence with the "Trigger" option enabled (see Dialog: Edit Receive
Sequence). When the Snapshot function is enabled, Docklight will not produce any output until a
trigger sequence has been detected in the serial communication data. See Catching a specific
sequence and taking a snapshot... for more information.
11.20 UART
Universal Asynchronous Receiver / Transmitter. The UART is the hardware component that performs
the main serial communications tasks:
- converting characters into a serial bit stream
- adding start / stop / parity bits, and checking for parity errors on the receiver side
- all tasks related to timing, baud rates and synchronization
Common UARTs are compatible with the 16550A UART. They include a 16 byte buffer for incoming
data (RX FiFo), and a 16 byte buffer for outgoing data (TX FiFo). Usually these buffers can be
disabled/enabled using the Windows Device Manager and opening the property page for the
appropriate COM port (e.g. COM1).
By using a virtual null modem driver on your PC you can easily debug and simulate serial data
connections without the use of real RS232 ports and cables.
Virtual COM connections do not give you the same timing as real RS232 connections and usually
do not emulate the actual bit-by-bit transmission using a predefined baud rate. Any data packet sent
on the first COM port will appear in the second COM port's receive buffer almost immediately. For
most debugging and simulation purposes this limitation can be easily tolerated. Some virtual null
modem drivers offer an additional baud rate emulation mode, where the data transfer is delayed to
emulate a real RS232 connection and its limited transmission rate.
For an Open Source Windows software that has been successfully tested with Docklight, see
http://com0com.sourceforge.net/
11.22 Wildcard
A wildcard is a special character that serves as a placeholder within a sequence. It may be used for
Receive Sequences when parts of the received data are unspecified, e.g. measurement readings
reported by a serial device. Wildcards can also be used to support parameters in a Send Sequence.