コード例 #1
0
    /// <summary>
    /// Gets a value depending on the Embedded controller
    /// </summary>
    /// <param name="low">The low byte command to process</param>
    /// <param name="high">The high byte command to process</param>
    /// <returns></returns>
    private int GetValue(ushort low, ushort high)
    {
        //Use Embedded controller to get said value
        //ECPort.ReadEC(command);
        //Testing Purposeses
        var lowValue  = ECPort.ReadEC(low);
        var highValue = ECPort.ReadEC(high);

        return((int)((highValue << 8) + lowValue));
    }
コード例 #2
0
 private int GetValue(ushort command)
 {
     return((int)ECPort.ReadEC(command));
 }