diff -r 7d5c74cc8f91 -r 0a30e161d63c include/unix/canfestival.h --- a/include/unix/canfestival.h Thu Nov 20 07:51:14 2008 +0100 +++ b/include/unix/canfestival.h Sat Jan 17 17:25:58 2009 +0100 @@ -16,12 +16,69 @@ typedef void* LIB_HANDLE; +/** @defgroup userapi User API */ + +/** @defgroup can CAN management + * @ingroup userapi + */ + +/** + * @ingroup can + * @{ + */ + +/** + * @ingroup can + * @brief Unload CAN driver interface + * @param handle The library handle + * @return 0 if succes + */ UNS8 UnLoadCanDriver(LIB_HANDLE handle); + +/** + * @ingroup can + * @brief Load CAN driver interface + * @param *driver_name The location of the library to load + * @return handle The library handle + */ LIB_HANDLE LoadCanDriver(const char* driver_name); + +/** + * @ingroup can + * @brief Send a CAN message + * @param port CanFestival file descriptor + * @param *m The message to send + * @return 0 if succes + */ UNS8 canSend(CAN_PORT port, Message *m); + +/** + * @ingroup can + * @brief Open a CANopen device + * @param *board Pointer on the board structure that contains busname and baudrate + * @param *d Pointer on the CAN object data structure + * @return port CanFestival file descriptor + */ CAN_PORT canOpen(s_BOARD *board, CO_Data * d); + +/** + * @ingroup can + * @brief Stop the timer task + * @param *d Pointer on the CAN object data structure + * @return 0 if succes + */ int canClose(CO_Data * d); + +/** + * @ingroup can + * @brief Stop the timer task + * @param port CanFestival file descriptor + * @param *baud The new baudrate to assign + * @return 0 if succes + */ UNS8 canChangeBaudRate(CAN_PORT port, char* baud); +/** @} */ + #ifdef __cplusplus };