Atmel Software Framework

uhi_hid_mouse.c File Reference

USB host Human Interface Device (HID) mouse driver.

Copyright (C) 2011 - 2014 Atmel Corporation. All rights reserved.

#include "conf_usb_host.h"
#include "usb_protocol.h"
#include "uhd.h"
#include "uhc.h"
#include "uhi_hid_mouse.h"
#include <string.h>

Data Structures

struct  uhi_hid_mouse_dev_t
 

Macros

Index in HID report for usual HID mouse events
#define UHI_HID_MOUSE_BTN   0
 
#define UHI_HID_MOUSE_MOV_X   1
 
#define UHI_HID_MOUSE_MOV_Y   2
 
#define UHI_HID_MOUSE_MOV_SCROLL   3
 

Functions

Internal routines
static void uhi_hid_mouse_start_trans_report (usb_add_t add)
 Starts the reception of the HID mouse report. More...
 
static void uhi_hid_mouse_report_reception (usb_add_t add, usb_ep_t ep, uhd_trans_status_t status, iram_size_t nb_transfered)
 Decodes the HID mouse report received. More...
 
Functions required by UHC
uhc_enum_status_t uhi_hid_mouse_install (uhc_device_t *dev)
 
void uhi_hid_mouse_enable (uhc_device_t *dev)
 
void uhi_hid_mouse_uninstall (uhc_device_t *dev)
 

Variables

Structure to store information about USB Device HID mouse
static uhi_hid_mouse_dev_t uhi_hid_mouse_dev