C4EV3
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
Macros | Functions
back_compatibility.h File Reference

Back-compatible functions to read sensors like in the original c4ev3. More...

#include "ev3_sensors.h"

Go to the source code of this file.

Macros

#define NO_SEN   -1
 
#define TOUCH_PRESS   1
 
#define COL_REFLECT   2
 
#define COL_AMBIENT   3
 
#define COL_COLOR   4
 
#define US_DIST_CM   5
 
#define US_DIST_MM   6
 
#define US_DIST_IN   7
 
#define GYRO_ANG   8
 
#define GYRO_RATE   9
 
#define IR_PROX   10
 
#define IR_SEEK   11
 
#define IR_REMOTE   12
 
#define NXT_IR_SEEKER   20
 
#define NXT_TEMP_C   21
 
#define NXT_TEMP_F   22
 

Functions

int SetAllSensorMode (int name_1, int name_2, int name_3, int name_4)
 
int ReadSensor (int sensorPort)
 
int SetIRBeaconCH (int sensorPort, int channel)
 

Detailed Description

Back-compatible functions to read sensors like in the original c4ev3.

Macro Definition Documentation

#define COL_AMBIENT   3
#define COL_COLOR   4
#define COL_REFLECT   2
#define GYRO_ANG   8
#define GYRO_RATE   9
#define IR_PROX   10
#define IR_REMOTE   12
#define IR_SEEK   11
#define NO_SEN   -1
#define NXT_IR_SEEKER   20
#define NXT_TEMP_C   21
#define NXT_TEMP_F   22
#define TOUCH_PRESS   1
#define US_DIST_CM   5
#define US_DIST_IN   7
#define US_DIST_MM   6

Function Documentation

int ReadSensor ( int  sensorPort)
int SetAllSensorMode ( int  name_1,
int  name_2,
int  name_3,
int  name_4 
)

Initializes the sensors. This function may be called only once at the beginning

Parameters
name_1
name_2
name_3
name_4
Returns
int SetIRBeaconCH ( int  sensorPort,
int  channel 
)