Rev 1537 |
Blame |
Compare with Previous |
Last modification |
View Log
| RSS feed
package dongfang.mkt.frames;
public abstract class Frame {
public static final byte FC_ADDRESS =
1;
public static final byte NC_ADDRESS =
2;
public static final byte MK3MAG_ADDRESS =
3;
/* General / several targets */
public enum REQUEST_IDS
{
ANALOG_DEBUG_LABEL
('a'),
EXTERNAL_CONTROL
('b'),
DISPLAY1
('h'),
DISPLAY2
('l'),
VERSION
('v'),
ANALOG_DEBUG
('d'),
RESET
('R'),
COMPASSHEADING
('K'),
MOTORTEST
('t'),
READPARAMETERSET
('q'),
WRITEPARAMETERSET
('s'),
RCCHANNELS
('p'),
DDATAINTERVAL
('c'),
READMIXERTABLE
('n'),
WRITEMIXERTABLE
('m'),
CHANGEPARAMETERSET
('f'),
NC_TESTLINK
('z'),
NC_ERRORTEXT
('e'),
NC_SET_WAYPOINT
('w'),
NC_GET_WAYPOINT
('x'),
GET_OSDDATA
('o'),
REDIRECT_UART
('u'),
SET3DDATA_INTERVAL
('c'),
MK3MAGHEADING
('w');
private final char id
;
REQUEST_IDS
(char id
) { this.
id = id
; }
public char getId
() {return id
;}
}
public static enum RESPONSE_IDS
{
ANALOG_DEBUG_LABEL
('A'),
EXTERNAL_CONTROL
('B'),
DISPLAY1
('H'),
DISPLAY2
('L'),
VERSION
('V'),
ANALOG_DEBUG
('D'),
/* FC specific */
COMPASSHEADING
('w'),
MOTORTEST
('T'),
READPARAMETERSET
('Q'),
WRITEPARAMETERSET
('S'),
RCCHANNELS
('P'),
THREEDDATAINTERVAL
('C'),
READMIXERTABLE
('N'),
WRITEMIXERTABLE
('M'),
CHANGEPARAMETERSET
('F'),
REQUEST_SETVARIABLE
('y'),
/* NC specific */
NC_TESTLINK
('Z'),
NC_ERRORTEXT
('E'),
REQUEST_NC_SET_TARGETPOSITION
('s'),
NC_SET_WAYPOINT
('W'),
NC_GET_WAYPOINT
('X'),
GET_OSDDATA
('O'),
SET3DDATA_INTERVAL
('C'),
/* Mk3Mag specific */
MK3MAGHEADING
('K');
private final char id
;
RESPONSE_IDS
(char id
) { this.
id = id
; }
public char getId
() { return id
; }
}
protected final int address
;
protected Frame(int address
) {
this.
address = address
;
}
public int getAddress
() {
return address
;
}
}