Grzegorz Bernacki | 1230487 | 2009-06-12 11:33:54 +0200 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2009 |
| 3 | * Werner Pfister <Pfister_Werner@intercontrol.de> |
| 4 | * |
| 5 | * (C) Copyright 2009 Semihalf, Grzegorz Bernacki |
| 6 | * |
Wolfgang Denk | 1a45966 | 2013-07-08 09:37:19 +0200 | [diff] [blame] | 7 | * SPDX-License-Identifier: GPL-2.0+ |
Grzegorz Bernacki | 1230487 | 2009-06-12 11:33:54 +0200 | [diff] [blame] | 8 | */ |
| 9 | |
| 10 | #ifndef CMD_MTC_H |
| 11 | #define CMD_MTC_H |
| 12 | |
| 13 | #define CMD_WD_PARA 0x02 |
Grzegorz Bernacki | 5cc6908 | 2009-08-05 18:37:42 +0200 | [diff] [blame] | 14 | #define CMD_WD_WDSTATE 0x04 |
Grzegorz Bernacki | 1230487 | 2009-06-12 11:33:54 +0200 | [diff] [blame] | 15 | #define CMD_FW_VERSION 0x10 |
| 16 | #define CMD_GET_VIM 0x30 |
| 17 | #define CMD_SET_LED 0x40 |
| 18 | |
| 19 | typedef struct { |
| 20 | u8 cmd; |
| 21 | u8 sys_in; |
| 22 | u8 cmd_val0; |
| 23 | u8 cmd_val1; |
| 24 | u8 cmd_val2; |
| 25 | u8 user_out; |
| 26 | u8 cks; |
| 27 | u8 dummy1; |
| 28 | u8 dummy2; |
| 29 | } tx_msp_cmd; |
| 30 | |
| 31 | typedef struct { |
| 32 | u8 input; |
| 33 | u8 state; |
| 34 | u8 ack2; |
| 35 | u8 ack3; |
| 36 | u8 ack0; |
| 37 | u8 ack1; |
| 38 | u8 ack; |
| 39 | u8 dummy; |
| 40 | u8 cks; |
| 41 | } rx_msp_cmd; |
| 42 | |
| 43 | #define MTC_TRANSFER_SIZE (sizeof(tx_msp_cmd) * 8) |
| 44 | |
| 45 | #endif |