00001 /***************************************************************************** 00002 * bluetooth.h 00003 * 00004 * Author: Clemens Valens 00005 * License: GNU General Public License 00006 * 00007 * History 00008 * 2009.11.05 ver 1.00 Preliminary version, first release 00009 * 00010 ******************************************************************************/ 00011 00017 #ifndef __BLUETOOTH_H__ 00018 #define __BLUETOOTH_H__ 00019 00020 00021 #define BLUETOOTH_OFF 0 00022 #define BLUETOOTH_ON 1 00023 00024 void bluetooth_power(int power); 00025 bool_t bluetooth_init(int baudrate); 00026 bool_t bluetooth_set_friendly_name(char *p_name); 00027 bool_t bluetooth_set_pin(char *p_pin); 00028 int bluetooth_send(char *p_data, int data_size); 00029 uint8_t bluetooth_scan(void); 00030 bool_t bluetooth_connect(bool_t as_slave, char *p_pin, uint8_t device, uint32_t timeout_ms, bool_t reconnect); 00031 bool_t bluetooth_is_connected(void); 00032 void bluetooth_get_module_info(void); 00033 00034 00035 #endif // __BLUETOOTH_H__