Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: SPI_TFTx2 TFT_fonts TOUCH_TFTx2 beep mbed
Fork of CANary by
CANary.h
- Committer:
- TickTock
- Date:
- 2013-02-19
- Revision:
- 5:ebf6fa994b78
- Parent:
- 4:8d7759f4fe7a
- Child:
- 7:17bf9ceaf0aa
File content as of revision 5:ebf6fa994b78:
//CANary
#include "mbed.h"
#include "CAN.h"
#include "beep.h"
#include "MSCFileSystem.h"
#include "SPI_TFTx2.h"
#include "Arial12x12.h"
#include "Arial12x12_prop.h"
#include "Arial28x28.h"
//#include "Neu42x35.h"
#include "SCProSB31x55.h"
#include "TOUCH_TFTx2.h"
#include "PowerControl.h"
#include "EthernetPowerControl.h"
#define upLine "\033[1A"
#define maxBufLen 1536
#define canTimeout 5
#define userTimeout 10
#define maxModes 6
#define offMode 0
#define logMode 1
#define dteMode 2
#define brakeMode 3
#define powerMode 4
#define controlMode 5
#define monitorMode 6
#define btn31x1 12
#define btn31x2 101
#define btn32x1 115
#define btn32x2 204
#define btn33x1 218
#define btn33x2 307
#define btn11y1 180
#define btn11y2 229
//LEAF OBD
//1:
//2:
//3: AVCAN-L White/Blue
//4:
//5: VSS Brown,White/Brown
//6: CARCAN-H Green
//7:
//8: 12V-SW Orange,White/Orange
//9:
//10:
//11: AVCAN-H Blue
//12: EVCAN-L White/Grey
//13: EVCAN-H Grey
//14: CARCAN-L White/Green
//15:
//16: 12V-AON Red/Blue,Blue/Red
//VP230
//1:D
//2:GND
//3:VCC
//4:R
//5:Vref
//6:CANL
//7:CANH
//8:RS
//LPC1768
//1: VSS
//2: NC:VIN (4.5-9V supply)
//3: NC:VB
//4: NC:nR
//5: SPI:CS0
//6: SPI:CS1
//7: SPI:Reset
//8: CAN1:Sleep --> 8:CAN1:RS
//9: CAN1:RX --> 4:CAN1:R
//10: CAN1:TX --> 1:CAN1:D
//11: SPI:MOSI
//12: SPI:MISO
//13: SPI:SCLK
//14: NC:Ain
//15: MON12V --> 4K to 12V, 1K to VSS (To be implemented)
//16: TOUCH_X+
//17: TOUCH_X-
//18: NC:Aout
//19: TOUCH_Y+
//20: TOUCH_Y-
//21: Spkr+
//22: Spkr- (optional complimentary output for more volume)
//23: NC:pwm
//24: LED
//25: NC:pwm
//26: NC:pwm
//27: NC
//28: CAN2:Sleep --> 8:CAN2:RS
//29: CAN2:TX --> 1:CAN2:D
//30: CAN2:RX --> 4:CAN2:R
//31: USB_D+
//32: USB_D-
//33: NC:Eth_TD+
//34: NC:Eth_TD-
//35: NC:Eth_RD+
//36: NC:Eth_RD-
//37: NC:IF+
//38: NC:IF-
//39: NC:5Vout (only available when connected as USB device)
//40: VCC3.3
