PsiSwarm Library  0.8
All Classes Files Functions Macros Pages
i2c_setup.h
1 /* University of York Robotics Laboratory PsiSwarm Library: I2C Setup Header File
2  *
3  * Copyright 2016 University of York
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
7  * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS
8  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9  * See the License for the specific language governing permissions and limitations under the License.
10  *
11  * File: i2c_setup.h
12  *
13  * (C) Dept. Electronics & Computer Science, University of York
14  * James Hilder, Alan Millard, Alexander Horsfield, Homero Elizondo, Jon Timmis
15  *
16  * PsiSwarm Library Version: 0.8
17  *
18  * October 2016
19  *
20  *
21  */
22 
23 #ifndef I2C_H
24 #define I2C_H
25 
32 class Setup
33 {
34 public:
35 char get_dc_status(void);
36 
37 char IF_setup_led_expansion_ic(void);
38 void IF_setup_gpio_expansion_ic(void);
39 
40 void IF_read_aux_ic_data(void);
41 void IF_parse_gpio_byte0(char byte);
42 void IF_parse_gpio_byte1(char byte);
43 void IF_handle_gpio_interrupt(void);
44 void IF_update_gpio_inputs(void);
45 void IF_set_base_LED(char state);
46 void IF_set_IR_emitter_output(char emitter, char state);
47 unsigned short IF_read_IR_adc_value(char adc, char index);
48 char IF_is_switch_pressed(void);
49 char IF_get_switch_state(void);
50 void IF_write_to_led_ic(char byte_0, char byte_1);
51 void IF_setup_temperature_sensor(void);
52 float IF_read_from_temperature_sensor(void);
53 };
54 #endif