Main Page   Modules   Data Structures   File List   Data Fields   Globals  

Tty getting & leaving

How to take control of ttys for direct braille display / read. More...

Defines

#define BRLKEYCODES   ((uint32_t) 1)
#define BRLCOMMANDS   ((uint32_t) 2)

Functions

int brlapi_getTty (uint32_t tty, uint32_t how, brlapi_keybinding_t *keybinding)
int brlapi_leaveTty (void)

Detailed Description

Before being able to write on the braille display, the application must tell the server which tty it will handle. Some checking is done just to be sure that only one client gets control of each tty.

The application must also specify how braille keys will be delivered to it. Two ways are possible: KEYCODES and COMMANDS

See also:
brlapi_readKey() brlapi_readCommand() brlapi_readBinding()

Define Documentation

#define BRLCOMMANDS   ((uint32_t) 2)
 

ask for brltty commands

#define BRLKEYCODES   ((uint32_t) 1)
 

ask for raw driver keycodes


Function Documentation

int brlapi_getTty uint32_t    tty,
uint32_t    how,
brlapi_keybinding_t   keybinding
 

ask for some tty, with some key mechanism

Parameters:
tty  * - If tty>0, application takes control of the specified tty;
Parameters:
how  tells whether the application wants brlapi_readKey() to return keycodes or brltty commands: either BRLKEYCODES or BRLCOMMANDS;
keybinding  tells settings for bindings. This is only necessary if brlapi_readBinding() will be called; else NULL can be given.
Returns:
0 on success, -1 on error

int brlapi_leaveTty void   
 

stop controlling the tty

Returns:
0 on success, -1 on error.


Generated on Fri Sep 26 09:33:48 2003 for BrlAPI by doxygen1.2.15