KBDSetDetachCallback

Syntax

#include <revolution/kbd.h>

KBDDevCallbackF KBDSetDetachCallback (KBDDevCallbackF fn);

Arguments

fn Pointer to a function to call back when a USB keyboard device is physically detached.

Return Values

KBDDevCallbackF A pointer to the previous keyboard device detach callback.

Description

Registers a function with the USB keyboard library to call whenever a USB keyboard device is detached. The function pointer typedef KBDDevCallbackF is defined as follows.

typedef struct _KBDDevEvent { 
  KBDChannel channel;
} KBDDevEvent;

typedef void (*KBDDevCallbackF) (KBDDevEvent*);

The function fn is called with a pointer to a KBDDevEvent structure that contains the channel (keyboard) that was detached.

See Also

Keyboard API Function List

Revision History

2007/03/19 Initial version.


CONFIDENTIAL