/* $Id: dev_nbus.h,v 1.4 2004/09/21 15:04:56 stevelim Exp $ */ /* dev_ubp.h - 68HC08 based Ford UBP card */ /* EVENT definitions (FT_EVENT frames) */ /* Monitor Mode */ #define GNBUSRXTEXT 0x41 /* Start Rx text */ #define GNBUSRXBINARY 0x42 /* Start Rx binary */ #define GNBUSRXMASTER 0x43 /* Rx msg Master */ #define GNBUSRXSLAVE0 0x44 /* Rx msg Slave 0 */ #define GNBUSRXSLAVE1 0x45 /* Rx msg Slave 1 */ #define GNBUSTIMERA 0x46 /* Timer A expired */ #define GNBUSTIMERB 0x47 /* Timer B expired */ #define GNBUSTIMERF 0x48 /* Timer F expired */ #define GNBUSSL0REQHI 0x49 /* Slave 0 Req hi */ #define GNBUSSL0REQLO 0x4A /* Slave 0 Req lo */ #define GNBUSSL1REQHI 0x4B /* Slave 1 Req hi */ #define GNBUSSL1REQLO 0x4C /* Slave 1 Req lo */ #define GNBUSSLSELHI 0x4D /* Slave select hi */ #define GNBUSSLSELLO 0x4E /* Slave select lo */ /* Master & Slave Modes */ #define GNBUSXMITABORT 0x51 /* Xmit Aborted */ #define GNBUSXMITEOT 0x52 /* Xmit Received EOT */ #define GNBUSXMITMSGLMT 0x53 /* Xmit Msg Retry Limit */ #define GNBUSXMITREQLMT 0x54 /* Xmit Req Retry Limit */ #define GNBUSXMITNAKLMT 0x55 /* Xmit NAK Retry Limit */ #define GNBUSXMITTIMER 0x56 /* Xmit Timer E Timeout */ #define GNBUSRCVINVALID 0x57 /* Received invalid message */ /* IOCTL definitions - comments indicate data size in bytes */ #define GNBUSGETMODE 0x11B00001 /* 1 */ #define GNBUSSETMODE 0x11B00002 /* 1 Takes effect on next INIT */ #define GNBUSGETCOMMANDS 0x11B00003 /* 2 thru 258 */ #define GNBUSADDCOMMANDS 0x11B00004 /* 2 thru 258 Takes effect on next INIT */ #define GNBUSDELCOMMANDS 0x11B00005 /* 2 thru 258 Takes effect on next INIT */ #define GNBUSCLRCOMMANDS 0x11B00006 /* 0 */ #define GNBUSGETVERMODE 0x11B00007 /* 1 */ #define GNBUSSETVERMODE 0x11B00008 /* 1 Takes effect on next INIT */ /* driver Mode definitions */ #define NBUS_MODE_NOTHING 0 #define NBUS_MODE_MONITOR 1 #define NBUS_MODE_MASTER 2 #define NBUS_MODE_SLAVE 3 /* verification Mode definitions */ #define NBUS_NONE 0 #define NBUS_COMMAND 1 /* STAT field definitions */ #define GNBUSSTAT_TEXT 0x01 /* Text mode message (bit 0) */ #define GNBUSSTAT_FR_SLAVE1 0x02 /* Source is slave1 (bit 1) */ #define GNBUSSTAT_FR_MASTER 0x04 /* Source is master (bit 2) */ #define GNBUSSTAT_TO_SLAVE1 0x08 /* dest is slave1 (bit 3) */ #define GNBUSSTAT_TO_MASTER 0x10 /* dest is master (bit 4) */