Sophie Dexter
/
Just4Trionic
Just4Trionic - CAN and BDM FLASH programmer for Saab cars
Embed:
(wiki syntax)
Show/hide line numbers
canutils.h
00001 /******************************************************************************* 00002 00003 canutils.h - information and definitions needed for the CAN bus 00004 (c) 2010, 2012 by Sophie Dexter 00005 00006 ******************************************************************************** 00007 00008 WARNING: Use at your own risk, sadly this software comes with no guarantees. 00009 This software is provided 'free' and in good faith, but the author does not 00010 accept liability for any damage arising from its use. 00011 00012 *******************************************************************************/ 00013 00014 #ifndef __CANUTILS_H__ 00015 #define __CANUTILS_H__ 00016 00017 #include "CAN.h" 00018 #include "mbed.h" 00019 00020 #include "common.h" 00021 00022 #define CANsuppliedCLK 24000000 00023 00024 extern void can_disable(uint8_t chan); 00025 extern void can_enable(uint8_t chan); 00026 extern void can_configure(uint8_t chan, uint32_t baud, bool listen); 00027 extern void can_add_filter(uint8_t chan, uint32_t id); 00028 extern void can_reset_filters(); 00029 extern void can_use_filters(bool active); 00030 00031 extern void can_open(); 00032 extern void can_close(); 00033 extern void can_monitor(); 00034 extern void can_active(); 00035 extern uint8_t can_set_speed(uint32_t speed); 00036 extern void show_can_message(); 00037 extern void show_T5can_message(); 00038 extern void show_T7can_message(); 00039 extern void show_T8can_message(); 00040 extern void silent_can_message(); 00041 00042 extern bool can_send_timeout (uint32_t id, char *frame, uint8_t len, uint16_t timeout); 00043 extern bool can_wait_timeout (uint32_t id, char *frame, uint8_t len, uint16_t timeout); 00044 00045 #endif
Generated on Fri Jul 15 2022 00:43:05 by 1.7.2