Statistics
| Branch: | Tag: | Revision:

root / Keyboard.h @ master

History | View | Annotate | Download (2.1 KB)

1
/*
2
             LUFA Library
3
     Copyright (C) Dean Camera, 2011.
4

5
  dean [at] fourwalledcubicle [dot] com
6
           www.lufa-lib.org
7
*/
8

    
9
/*
10
  Copyright 2011  Dean Camera (dean [at] fourwalledcubicle [dot] com)
11
  Copyright 2010  Denver Gingerich (denver [at] ossguy [dot] com)
12

13
  Permission to use, copy, modify, distribute, and sell this
14
  software and its documentation for any purpose is hereby granted
15
  without fee, provided that the above copyright notice appear in
16
  all copies and that both that the copyright notice and this
17
  permission notice and warranty disclaimer appear in supporting
18
  documentation, and that the name of the author not be used in
19
  advertising or publicity pertaining to distribution of the
20
  software without specific, written prior permission.
21

22
  The author disclaim all warranties with regard to this
23
  software, including all implied warranties of merchantability
24
  and fitness.  In no event shall the author be liable for any
25
  special, indirect or consequential damages or any damages
26
  whatsoever resulting from loss of use, data or profits, whether
27
  in an action of contract, negligence or other tortious action,
28
  arising out of or in connection with the use or performance of
29
  this software.
30
*/
31

    
32
/** \file
33
 *
34
 *  Header file for Keyboard.c.
35
 */
36

    
37
#ifndef _KEYBOARD_H_
38
#define _KEYBOARD_H_
39

    
40
        /* Includes: */
41
                #include <avr/io.h>
42
                #include <avr/wdt.h>
43
                #include <avr/power.h>
44
                #include <avr/interrupt.h>
45
                #include <stdbool.h>
46
                #include <string.h>
47

    
48
                #include "Descriptors.h"
49
                #include "MatrixScan.h"
50

    
51
                #include <LUFA/Version.h>
52
                #include <LUFA/Drivers/USB/USB.h>
53
                #include <LUFA/Drivers/Board/LEDs.h>
54

    
55
        /* Function Prototypes: */
56
                void SetupHardware(void);
57
                void HID_Task(void);
58

    
59
                void EVENT_USB_Device_Connect(void);
60
                void EVENT_USB_Device_Disconnect(void);
61
                void EVENT_USB_Device_ConfigurationChanged(void);
62
                void EVENT_USB_Device_ControlRequest(void);
63
                void EVENT_USB_Device_StartOfFrame(void);
64

    
65
                void CreateKeyboardReport(USB_KeyboardReport_Data_t* const ReportData);
66
                void ProcessLEDReport(const uint8_t LEDReport);
67
                void SendNextReport(void);
68
                void ReceiveNextReport(void);
69

    
70
#endif
71