Example #1
0
 /// <summary>
 /// Method called from autopoll to build batch command
 /// </summary>
 /// <returns>Value type on return after executing command</returns>
 internal static DataType GetBumpsValue_BatchCommand(PayLoadBuilder dataBuilder, ChainLayer layer, int port, int index)
 {
     dataBuilder.Raw((byte)OP.opINPUT_DEVICE);
     dataBuilder.Raw((byte)INPUT_DEVICE_SUBCODE.GET_BUMPS);
     dataBuilder.PAR8((byte)layer);
     dataBuilder.PAR8((byte)port);
     dataBuilder.GlobalIndex(index);
     return(DataType.DATAF);
 }
Example #2
0
 /// <summary>
 /// Method called from autopoll to build batch command
 /// </summary>
 internal static DataType GetSIValue_BatchCommand(PayLoadBuilder dataBuilder, ChainLayer layer, int port, ushort type = 0, int mode = -1, int index = 1)
 {
     dataBuilder.Raw((byte)OP.opINPUT_READSI);
     dataBuilder.PAR8((byte)layer);
     dataBuilder.PAR8((byte)port);
     dataBuilder.PAR8((byte)type);
     dataBuilder.PAR8((byte)mode);
     dataBuilder.GlobalIndex(index);
     return(DataType.DATAF);
 }
Example #3
0
 /// <summary>
 /// Method called from autopoll to build batch command
 /// </summary>
 internal static DataType GetReadyPct_BatchCommand(PayLoadBuilder dataBuilder, ChainLayer layer, int port, ushort type = 0, int mode = -1, int numberOfValues = 1, int index = 1)
 {
     dataBuilder.Raw((byte)OP.opINPUT_DEVICE);
     dataBuilder.Raw((byte)INPUT_DEVICE_SUBCODE.READY_PCT);
     dataBuilder.PAR8((byte)layer);
     dataBuilder.PAR8((byte)port);
     dataBuilder.PAR8((byte)type);
     dataBuilder.PAR8((byte)mode);
     dataBuilder.PAR8((byte)numberOfValues);
     dataBuilder.GlobalIndex(index);
     return(DataType.DATA32);
 }
 /// <summary>
 /// Method called from autopoll to build batch command
 /// </summary>
 internal static ushort BatchCommand(PayLoadBuilder payLoadBuilder, ButtonType button, ButtonMode mode, int index)
 {
     payLoadBuilder.Raw((byte)OP.opUI_BUTTON);
     payLoadBuilder.Raw((byte)mode);
     payLoadBuilder.PAR8((byte)button);
     payLoadBuilder.GlobalIndex(index);
     return(DataType.DATA8.ByteLength());
 }