public class CnS
extends java.lang.Object
CnS format:
Byte offset | Content |
---|---|
0-1 | Object ID |
2 | Operation Type |
3 | Reserved |
4-7 | Application ID |
8-9 | Length of payload (0�246) |
[10-255] | Parameter (if needed for the object) |
The maximum length of a CnS message is 255 bytes. The minimum length is 10.
Copyright (c) 2009 Eurotech Inc. All rights reserved.
Modifier and Type | Field and Description |
---|---|
static int |
C8xx_APPLICATION_ID
CnS 'C8xx Application' ID
|
static int |
MC572x_APPLICATION_ID
CnS 'MC572x Application' ID
|
static int |
MC87xx_APPLICATION_ID
CnS 'MC87xx Application' ID
|
static int |
MODEM_CHANNEL_APPLICATION_ID
CnS 'Channel Application' object ID
|
static int |
OBJID_FIRMWARE_VERSION_ID
CnS 'Firmware Version' object ID
|
static byte |
OPTYPE_ERROR
CnS Operation Type - 'Error'
|
static byte |
OPTYPE_GET
CnS Operation Type - 'GetRequest'
|
static byte |
OPTYPE_GETREP
CnS Operation Type - reply to 'GetRequest'
|
static byte |
OPTYPE_NOTIF_DISABLE
CnS Operation Type - 'Notification Disable'
|
static byte |
OPTYPE_NOTIF_DISABLE_ACK
CnS Operation Type - acknowledge to 'Notification Disable'
|
static byte |
OPTYPE_NOTIF_ENB
CnS Operation Type - 'NotificationEnable'
|
static byte |
OPTYPE_NOTIF_ENB_REP
CnS Operation Type - reply to 'NotificationEnable'
|
static byte |
OPTYPE_NOTIFICATION
CnS Operation Type - 'Notification'
|
static byte |
OPTYPE_SET
CnS Operation Type - 'Set' (CnS command)
|
static byte |
OPTYPE_SETACK
CnS Operation Type - 'SetAck' (acknowledge to Set)
|
static int |
PAYLOAD_OFFSET
CnS offset number of bytes into the payload
|
static int |
USB598_APPLICATION_ID
CnS 'USB 598 Application' ID
|
Constructor and Description |
---|
CnS(byte[] msg)
CnS reply constructor.
|
CnS(int objectID,
byte opType,
int appID)
CnS message constructor.
|
CnS(int objectID,
byte opType,
int appID,
byte[] pload)
CnS message constructor
|
CnS(int objectID,
byte opType,
int appID,
int param)
CnS message constructor
|
CnS(int objectID,
byte opType,
int appID,
long param)
CnS message constructor
|
Modifier and Type | Method and Description |
---|---|
long |
getApplicationId()
Reports CnS Application ID
|
int |
getObjectId()
Reports CnS object ID
|
int |
getOperationType()
Reports CnS operation type
|
byte[] |
getPayload()
Reports payload of CnS message
|
int |
getPayloadLength()
Reports the length of Cns payload
|
byte[] |
getRequest()
Reports CnS request
|
int |
getReserved()
Reports reserved word
|
public static final int MODEM_CHANNEL_APPLICATION_ID
public static final int MC572x_APPLICATION_ID
public static final int MC87xx_APPLICATION_ID
public static final int C8xx_APPLICATION_ID
public static final int USB598_APPLICATION_ID
public static final int OBJID_FIRMWARE_VERSION_ID
public static final byte OPTYPE_GET
public static final byte OPTYPE_GETREP
public static final byte OPTYPE_SET
public static final byte OPTYPE_SETACK
public static final byte OPTYPE_NOTIF_ENB
public static final byte OPTYPE_NOTIF_ENB_REP
public static final byte OPTYPE_NOTIFICATION
public static final byte OPTYPE_NOTIF_DISABLE
public static final byte OPTYPE_NOTIF_DISABLE_ACK
public static final byte OPTYPE_ERROR
public static final int PAYLOAD_OFFSET
public CnS(int objectID, byte opType, int appID)
CnS request constructor
objectID
- - object IDopType
- - operation typeappID
- - application IDpublic CnS(int objectID, byte opType, int appID, byte[] pload)
objectID
- - object IDopType
- - operation typeappID
- - application IDpload
- CnS payloadpublic CnS(int objectID, byte opType, int appID, int param)
objectID
- - object IDopType
- - operation typeappID
- - application IDparam
- - payloadpublic CnS(int objectID, byte opType, int appID, long param)
objectID
- - object IDopType
- - operation typeappID
- - application IDparam
- - payloadpublic CnS(byte[] msg)
msg
- byte array to hold CnS reply from modempublic byte[] getRequest()
public byte[] getPayload()
public long getApplicationId()
public int getObjectId()
public int getOperationType()
public int getPayloadLength()
public int getReserved()
Copyright © 2009 Eurotech Inc. All rights reserved.