Example #1
0
        public void ProcessCecMessageTest_GetMenuLanguage_PlaybackDevice()
        {
            var device   = CreatePlaybackDevice();
            var message  = CecMessageBuilder.GetMenuLanguage(LogicalAddress.TV, device.LogicalAddress);
            var response = device.ProcessCecMessage(message);

            var expected = CecMessageBuilder.FeatureAbort(device.LogicalAddress, message.Source,
                                                          Command.GetMenuLanguage, AbortReason.UnrecognizedOpcode);

            Assert.AreEqual(expected, response);
        }
Example #2
0
 /// <inheritdoc cref="Command.FeatureAbort"/>
 /// <param name="device">The device.</param>
 /// <param name="destination">The destination address.</param>
 /// <param name="opCode">The command being aborted.</param>
 /// <param name="reason">The abort reason.</param>
 /// <returns>A <see cref="CecMessage"/> object representing the command.</returns>
 public static CecMessage FeatureAbort(this CecDevice device, LogicalAddress destination, Command opCode, AbortReason reason)
 {
     return(CecMessageBuilder.FeatureAbort(device.LogicalAddress, destination, opCode, reason));
 }