Subversion Repositories Projects

Compare Revisions

Regard whitespace Rev 345 → Rev 346

/C-OSD/trunk/usart1.h
23,7 → 23,21
#define RXD_BUFFER_LEN 150
#define TXD_BUFFER_LEN 150
 
extern volatile uint8_t rxd_buffer_locked;
extern volatile uint8_t rxd_buffer[RXD_BUFFER_LEN];
extern volatile uint8_t txd_buffer[TXD_BUFFER_LEN];
extern volatile uint8_t ReceivedBytes;
extern volatile uint8_t *pRxData;
extern volatile uint8_t RxDataLen;
 
extern
 
/**
* init usart1
*/
void usart1_init();
 
/**
* disable the txd pin of usart1
*/
void usart1_DisableTXD(void);
32,3 → 46,37
* enable the txd pin of usart1
*/
void usart1_EnableTXD(void);
 
/**
* send a <string> throught usart1
*/
void usart1_puts(char*);
 
/**
* receive data through usart1
* portions taken and adapted from
* http://svn.mikrokopter.de/mikrowebsvn/filedetails.php?repname=FlightCtrl&path=%2Fbranches%2FV0.72p+Code+Redesign+killagreg%2Fuart0.c
*/
ISR(SIG_USART1_RECV);
 
/**
* Decode the recevied Buffer
* portions taken and adapted from
* http://svn.mikrokopter.de/mikrowebsvn/filedetails.php?repname=FlightCtrl&path=%2Ftags%2FV0.72p%2Fuart.c
*/
void Decode64(void);
 
/**
* request Data through USART in special MK format by adding checksum and
* encode data in modified Base64
* portions taken and adapted from
* http://svn.mikrokopter.de/mikrowebsvn/filedetails.php?repname=FlightCtrl&path=%2Ftags%2FV0.72p%2Fuart.c
*/
void sendMKData(unsigned char, unsigned char, unsigned char*, unsigned char);
 
/**
* short script to directly send a request thorugh usart including en- and disabling it
* where <address> is the address of the receipient, <label> is which data set to request
* and <ms> represents the milliseconds delay between data
*/
void usart1_request_mk_data(uint8_t, char, uint8_t);