All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
apollo.h File Reference

Status display for VT100 console macros and prototypes. More...

Go to the source code of this file.

Macros

terminal origin and size
#define T_X_ORIGIN   1
 
#define T_Y_ORIGIN   1
 
#define T_WIDTH   80
 
#define T_HEIGHT   24
 
Motor status origin and size
#define M_X_POS   1
 
#define M_WIDTH   41
 
#define M_Y_POS   1
 
#define M_HEIGHT   15
 
Digital ports status origin and size
#define D_X_POS   (M_X_POS+M_WIDTH-1)
 
#define D_WIDTH   21
 
#define D_Y_POS   1
 
#define D_HEIGHT   15
 
Analog ports status origin and size
#define A_X_POS   (D_X_POS+D_WIDTH-1)
 
#define A_WIDTH   20
 
#define A_Y_POS   1
 
#define A_HEIGHT   15
 
Joystick status origin
#define J_X_POS   1
 
#define J_Y_POS   15
 

Functions

void apolloScreenSetup (void)
 Draw static lines for the display. More...
 
void apolloMotorSetup (void)
 Setup motor section of the display. More...
 
void apolloDigitalSetup (void)
 Setup digital port status section of the display. More...
 
void apolloAnalogSetup (void)
 Setup analog port status section of the display. More...
 
void apolloJoystickSetup (int joystick)
 Setup joystick status section of the display. More...
 
void apolloInit (void)
 Apollo initialization. More...
 
void apolloDeinit (void)
 Apollo de-init. Cleans up screen when done. More...
 
void apolloUpdateMotor (int m)
 Update motor status. More...
 
void apolloUpdateCortex (int p)
 Update cortex current and temperature status. More...
 
void apolloUpdateDigital (int pin)
 Update digital port status. More...
 
void apolloUpdateAnalog (int pin)
 Update analog port status. More...
 
void apolloUpdateSystem (void)
 Update system status. More...
 
void apolloUpdateJoystickButton (int joystick, int row, int up, int down, int left, int right)
 Update joystick button status. More...
 
void apolloUpdateJoystickAnalog (int joystick, int row, int h, int v)
 Update joystick analog status. More...
 
void apolloUpdate (void)
 Apollo update - update all status. More...
 

Detailed Description

Status display for VT100 console macros and prototypes.

Macro Definition Documentation

#define T_X_ORIGIN   1
#define T_Y_ORIGIN   1
#define T_WIDTH   80
#define T_HEIGHT   24
#define M_X_POS   1
#define M_WIDTH   41
#define M_Y_POS   1
#define M_HEIGHT   15
#define D_X_POS   (M_X_POS+M_WIDTH-1)
#define D_WIDTH   21
#define D_Y_POS   1
#define D_HEIGHT   15
#define A_X_POS   (D_X_POS+D_WIDTH-1)
#define A_WIDTH   20
#define A_Y_POS   1
#define A_HEIGHT   15
#define J_X_POS   1
#define J_Y_POS   15

Function Documentation

void apolloScreenSetup ( void  )

Draw static lines for the display.

void apolloMotorSetup ( void  )

Setup motor section of the display.

void apolloDigitalSetup ( void  )

Setup digital port status section of the display.

void apolloAnalogSetup ( void  )

Setup analog port status section of the display.

void apolloJoystickSetup ( int  joystick)

Setup joystick status section of the display.

void apolloInit ( void  )

Apollo initialization.

void apolloDeinit ( void  )

Apollo de-init. Cleans up screen when done.

void apolloUpdateMotor ( int  m)

Update motor status.

Parameters
[in]mThe smart motor port number (0 - 9)
void apolloUpdateCortex ( int  p)

Update cortex current and temperature status.

Parameters
[in]pThe smart motor port number (0 or 1)
void apolloUpdateDigital ( int  pin)

Update digital port status.

Parameters
[in]pinThe digital port number
void apolloUpdateAnalog ( int  pin)

Update analog port status.

Parameters
[in]pinThe analog port number
void apolloUpdateSystem ( void  )

Update system status.

void apolloUpdateJoystickButton ( int  joystick,
int  row,
int  up,
int  down,
int  left,
int  right 
)

Update joystick button status.

Parameters
[in]joystickWhich joystick, 0 for main, 1 for partner
[in]rowThe row for the data (0 - 4)
[in]upUp button status
[in]downUp down status
[in]leftUp left status
[in]rightUp right status
void apolloUpdateJoystickAnalog ( int  joystick,
int  row,
int  h,
int  v 
)

Update joystick analog status.

Parameters
[in]joystickWhich joystick, 0 for main, 1 for partner
[in]rowThe row for the data (0, 1 or 2)
[in]hthe horizontal joystick data
[in]vthe vertical joystick data
void apolloUpdate ( void  )

Apollo update - update all status.