45 lines
1.6 KiB
Plaintext
45 lines
1.6 KiB
Plaintext
1 Build environment
|
|
The gcc compiler is used by default (see Makefile).
|
|
libfuse-dev - Filesystem in Userspace (development) must be installed
|
|
at the build system.
|
|
glibc must support pthreads.
|
|
|
|
2 Target
|
|
The linux kernel at the target system must support FUSE (FUSE_FS=y) and
|
|
libpthread and libfuse must be installed in the root filesystem.
|
|
|
|
3 Build
|
|
The default target in the Makefile builds the Network Virtual Terminal.
|
|
Output name is: ttynvt.
|
|
|
|
4 Run
|
|
The application (ttynvt) installs a virtual serial device in the /dev
|
|
directory (by default: /dev/ttyNVT0).
|
|
The major/minor number of the device, the address (name/IP) and the port
|
|
number of the serial server must be specified when the application
|
|
is started (command-line options).
|
|
|
|
E.g.
|
|
./ttynvt -M 199 -m 6 -n ttyNVT0 -p 5020 -s 169.254.1.1
|
|
|
|
To get a list of all command-line options:
|
|
./ttynvt --help
|
|
|
|
5. Test
|
|
The serial server: ser2net (http://ser2net.sourceforge.net/) might be used
|
|
to test the virtual serial server on the target.
|
|
Install the server (ser2net) and add folling line to the configuration
|
|
file (/etc/ser2net.conf):
|
|
5020:telnet:0:/dev/ttyS0:115200 remctl NONE 1STOPBIT 8DATABITS RTSCTS HANGUP_WHEN_DONE
|
|
Plug-in a loopback connector in the serial port (ttyS0)
|
|
Open the serial port, with a termial program, e.g minicom:
|
|
minicom -D /dev/ttyNVT0
|
|
|
|
6 Diagnostic
|
|
Add the command-line option '-l' to enable logging of diagnostic information.
|
|
Wireshark is also very useful when debugging the interface between the client
|
|
and the server.
|
|
|
|
Ref: RFC-854 - Telnet Protocol Specification
|
|
RFC-2217 - Telnet Com Port Control Option
|