StoRC
Autonomous Payload Delivery System
rc.pde File Reference

Commands for reading and updating RC values. More...

Go to the source code of this file.

Functions

void read_RC (void)
void send_RC (void)
boolean check_drop (void)
void drop_payload (void)
void reset_drop (void)
int rc_filter (int rc, int rc_old)

Detailed Description

Commands for reading and updating RC values.

Author:
Michael Posner (CIS, MEAM '12)
Timothy Hennelly (ESE '12)
Jacob Orloff (MEAM '12)

Definition in file rc.pde.


Function Documentation

boolean check_drop ( void  )

Check if the 4th RC channel is signaling a payload drop

Returns:
true if ready to drop, false if not yet ready

Definition at line 87 of file rc.pde.

void drop_payload ( void  )

Drop payload by sending output to the servo controlling the release.

Definition at line 119 of file rc.pde.

int rc_filter ( int  rc,
int  rc_old 
)

Filter RC commands when they are read. This function limits the difference between the current and previous reading to prevent wild readings from being used.

Parameters:
rcthe current RC value as read from the board
rc_oldthe previous RC value
Returns:
the adjusted current RC value to be used

Definition at line 139 of file rc.pde.

void read_RC ( void  )

Read RC values from the board (using the APM_RC library) and adjust them as necessary.

See also:
APM_RC

Definition at line 44 of file rc.pde.

void reset_drop ( void  )

Reset the servo controlling the payload drop.

Definition at line 126 of file rc.pde.

void send_RC ( void  )

Send RC commands to the board outputs (using the APM_RC library) and make sure they are reasonable.

See also:
APM_RC

Definition at line 69 of file rc.pde.