GNU
|
Liberty Eiffel
|
Automated Tests
|
Wiki
|
Savannah project
|
Debian packages
|
Documentation
>
libraries
>
TERMINAL_SETTINGS
+
Point of view
FILE_STREAM
ANY
INTERNALS_HANDLER
TYPED_INTERNALS
FILE_STREAM
All features
class TERMINAL_SETTINGS
Summary
top
Terminal settings for serial communication lines. see termios.h in POSIX todo:
make objects recyclable?
Direct parents
Insert list:
DISPOSABLE
Overview
top
Creation features
make
(a_fd:
POINTER
, a_fs:
FILE_STREAM
)
Exported features
make
(a_fd:
POINTER
, a_fs:
FILE_STREAM
)
dispose
Action to be executed just before garbage collection reclaims an object.
set_speed
(a_speed:
INTEGER_32
)
set input and output communication speed to
a_speed
set_input_speed
(a_speed:
INTEGER_32
)
set input communication speed to
a_speed
baud
set_output_speed
(a_speed:
INTEGER_32
)
set output communication speed to
a_speed
baud
output_speed
:
INTEGER_32
return the currently configured output speed
input_speed
:
INTEGER_32
return the currently configured input speed
drain
wait until all data in tx buffer is transmitted
associated_stream
:
FILE_STREAM
the file stream associated with the terminal settings
fd
:
POINTER
pointer to the underlaying
FILE
handle
last_error
:
INTEGER_32
last error code
last_error_description
:
STRING
error_string_storage
:
STRING
is_valid_speed
(a_speed:
INTEGER_32
):
BOOLEAN
check if a given terminal speed is valid some day we might want to consider non-standard baudrates with termios2
make
(a_fd:
POINTER
, a_fs:
FILE_STREAM
)
effective procedure
top
require
valid_stream:
a_fs /= Void
valid_file_descriptor:
not a_fd.is_null = a_fs /= Void and then a_fs.is_connected
ensure
associated_stream
= a_fs
fd
= a_fd
dispose
effective procedure
top
Action to be executed just before garbage collection reclaims an object.
set_speed
(a_speed:
INTEGER_32
)
effective procedure
top
set input and output communication speed to
a_speed
require
valid_speed:
is_valid_speed
(a_speed)
set_input_speed
(a_speed:
INTEGER_32
)
effective procedure
top
set input communication speed to
a_speed
baud
require
valid_speed:
is_valid_speed
(a_speed)
set_output_speed
(a_speed:
INTEGER_32
)
effective procedure
top
set output communication speed to
a_speed
baud
require
valid_speed:
is_valid_speed
(a_speed)
output_speed
:
INTEGER_32
effective function
top
return the currently configured output speed
ensure
valid_speed:
is_valid_speed
(Result)
input_speed
:
INTEGER_32
effective function
top
return the currently configured input speed
ensure
valid_speed:
is_valid_speed
(Result)
drain
effective procedure
top
wait until all data in tx buffer is transmitted
require
connected:
associated_stream
.is_connected
associated_stream
:
FILE_STREAM
writable attribute
top
the file stream associated with the terminal settings
fd
:
POINTER
writable attribute
top
pointer to the underlaying
FILE
handle
last_error
:
INTEGER_32
writable attribute
top
last error code
last_error_description
:
STRING
effective function
top
error_string_storage
:
STRING
writable attribute
top
is_valid_speed
(a_speed:
INTEGER_32
):
BOOLEAN
effective function
top
check if a given terminal speed is valid some day we might want to consider non-standard baudrates with termios2