decrementAudioUnitExternamPortInputControl
Decrement audioUnit/externalPortInput/control value
The following objects can be changed and trigger AEM Command on the device. *decrement* The **DECREMENT_CONTROL** command is used to decrement the specified values of a Control by the Control’s step sizes. The decrement_control command acts on a CONTROL descriptor in the current Configuration. An Entity may propagate the value change onto corresponding descriptors in other Configurations, but an AVDECC Controller cannot assume that this will happen. Note that the value only determines the index of control value, which is decremented. In response you will receive the current value, which is determined by the controlValueType. The maximum possible index is the value count described in the descriptor. option you can set the format but also have to specify the value count. The count parameter may only be used with the format parameter. Use this if the entity does not describe it with a descriptor. The values may not be displayed correctly.
/v1.0/devices/{deviceId}/descriptor/entity/configuration/{cfg_idx}/entity/configuration/audioUnit/{audioUnit_idx}/externalPortInput/{stream_idx}/control/{control_index}/decrement
Usage and SDK Samples
curl -X PATCH\
-H "Accept: application/json"\
-H "Content-Type: application/json,application/x-www-form-urlencoded"\
"http://localhost:7778/avb/v1.0/devices/{deviceId}/descriptor/entity/configuration/{cfg_idx}/entity/configuration/audioUnit/{audioUnit_idx}/externalPortInput/{stream_idx}/control/{control_index}/decrement"
import org.openapitools.client.*;
import org.openapitools.client.auth.*;
import org.openapitools.client.model.*;
import org.openapitools.client.api.AudioUnitApi;
import java.io.File;
import java.util.*;
public class AudioUnitApiExample {
public static void main(String[] args) {
// Create an instance of the API class
AudioUnitApi apiInstance = new AudioUnitApi();
String deviceId = 00-50-c2-ff-fe-d4-33-8d; // String | Entity device identifier
Integer cfgIdx = 0; // Integer | valid configurations index
Integer audioUnitIdx = 0; // Integer | Descriptor AUDIO_UNIT index
Integer streamIdx = 0; // Integer | Descriptor EXTERNAL_PORT_INPUT index
Integer controlIndex = 0; // Integer | Descriptor CONTROL index
CONTROLCREMENT cONTROLCREMENT = {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}}; // CONTROLCREMENT |
try {
CONTROL result = apiInstance.decrementAudioUnitExternamPortInputControl(deviceId, cfgIdx, audioUnitIdx, streamIdx, controlIndex, cONTROLCREMENT);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AudioUnitApi#decrementAudioUnitExternamPortInputControl");
e.printStackTrace();
}
}
}
import org.openapitools.client.api.AudioUnitApi;
public class AudioUnitApiExample {
public static void main(String[] args) {
AudioUnitApi apiInstance = new AudioUnitApi();
String deviceId = 00-50-c2-ff-fe-d4-33-8d; // String | Entity device identifier
Integer cfgIdx = 0; // Integer | valid configurations index
Integer audioUnitIdx = 0; // Integer | Descriptor AUDIO_UNIT index
Integer streamIdx = 0; // Integer | Descriptor EXTERNAL_PORT_INPUT index
Integer controlIndex = 0; // Integer | Descriptor CONTROL index
CONTROLCREMENT cONTROLCREMENT = {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}}; // CONTROLCREMENT |
try {
CONTROL result = apiInstance.decrementAudioUnitExternamPortInputControl(deviceId, cfgIdx, audioUnitIdx, streamIdx, controlIndex, cONTROLCREMENT);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AudioUnitApi#decrementAudioUnitExternamPortInputControl");
e.printStackTrace();
}
}
}
// Create an instance of the API class
AudioUnitApi *apiInstance = [[AudioUnitApi alloc] init];
String *deviceId = 00-50-c2-ff-fe-d4-33-8d; // Entity device identifier
(default to null)
Integer *cfgIdx = 0; // valid configurations index
(default to null)
Integer *audioUnitIdx = 0; // Descriptor AUDIO_UNIT index
(default to null)
Integer *streamIdx = 0; // Descriptor EXTERNAL_PORT_INPUT index
(default to null)
Integer *controlIndex = 0; // Descriptor CONTROL index
(default to null)
CONTROLCREMENT *cONTROLCREMENT = {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}}; // (optional)
// Decrement audioUnit/externalPortInput/control value
[apiInstance decrementAudioUnitExternamPortInputControlWith:deviceId
cfgIdx:cfgIdx
audioUnitIdx:audioUnitIdx
streamIdx:streamIdx
controlIndex:controlIndex
cONTROLCREMENT:cONTROLCREMENT
completionHandler: ^(CONTROL output, NSError* error) {
if (output) {
NSLog(@"%@", output);
}
if (error) {
NSLog(@"Error: %@", error);
}
}];
var RestIeee17221TsnController = require('rest_ieee_1722_1_tsn_controller');
// Create an instance of the API class
var api = new RestIeee17221TsnController.AudioUnitApi()
var deviceId = 00-50-c2-ff-fe-d4-33-8d; // {String} Entity device identifier
var cfgIdx = 0; // {Integer} valid configurations index
var audioUnitIdx = 0; // {Integer} Descriptor AUDIO_UNIT index
var streamIdx = 0; // {Integer} Descriptor EXTERNAL_PORT_INPUT index
var controlIndex = 0; // {Integer} Descriptor CONTROL index
var opts = {
'cONTROLCREMENT': {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}} // {CONTROLCREMENT}
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.decrementAudioUnitExternamPortInputControl(deviceId, cfgIdx, audioUnitIdx, streamIdx, controlIndex, opts, callback);
using System;
using System.Diagnostics;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Model;
namespace Example
{
public class decrementAudioUnitExternamPortInputControlExample
{
public void main()
{
// Create an instance of the API class
var apiInstance = new AudioUnitApi();
var deviceId = 00-50-c2-ff-fe-d4-33-8d; // String | Entity device identifier
(default to null)
var cfgIdx = 0; // Integer | valid configurations index
(default to null)
var audioUnitIdx = 0; // Integer | Descriptor AUDIO_UNIT index
(default to null)
var streamIdx = 0; // Integer | Descriptor EXTERNAL_PORT_INPUT index
(default to null)
var controlIndex = 0; // Integer | Descriptor CONTROL index
(default to null)
var cONTROLCREMENT = new CONTROLCREMENT(); // CONTROLCREMENT | (optional)
try {
// Decrement audioUnit/externalPortInput/control value
CONTROL result = apiInstance.decrementAudioUnitExternamPortInputControl(deviceId, cfgIdx, audioUnitIdx, streamIdx, controlIndex, cONTROLCREMENT);
Debug.WriteLine(result);
} catch (Exception e) {
Debug.Print("Exception when calling AudioUnitApi.decrementAudioUnitExternamPortInputControl: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Create an instance of the API class
$api_instance = new OpenAPITools\Client\Api\AudioUnitApi();
$deviceId = 00-50-c2-ff-fe-d4-33-8d; // String | Entity device identifier
$cfgIdx = 0; // Integer | valid configurations index
$audioUnitIdx = 0; // Integer | Descriptor AUDIO_UNIT index
$streamIdx = 0; // Integer | Descriptor EXTERNAL_PORT_INPUT index
$controlIndex = 0; // Integer | Descriptor CONTROL index
$cONTROLCREMENT = {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}}; // CONTROLCREMENT |
try {
$result = $api_instance->decrementAudioUnitExternamPortInputControl($deviceId, $cfgIdx, $audioUnitIdx, $streamIdx, $controlIndex, $cONTROLCREMENT);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling AudioUnitApi->decrementAudioUnitExternamPortInputControl: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::OPenAPIClient::Configuration;
use WWW::OPenAPIClient::AudioUnitApi;
# Create an instance of the API class
my $api_instance = WWW::OPenAPIClient::AudioUnitApi->new();
my $deviceId = 00-50-c2-ff-fe-d4-33-8d; # String | Entity device identifier
my $cfgIdx = 0; # Integer | valid configurations index
my $audioUnitIdx = 0; # Integer | Descriptor AUDIO_UNIT index
my $streamIdx = 0; # Integer | Descriptor EXTERNAL_PORT_INPUT index
my $controlIndex = 0; # Integer | Descriptor CONTROL index
my $cONTROLCREMENT = WWW::OPenAPIClient::Object::CONTROLCREMENT->new(); # CONTROLCREMENT |
eval {
my $result = $api_instance->decrementAudioUnitExternamPortInputControl(deviceId => $deviceId, cfgIdx => $cfgIdx, audioUnitIdx => $audioUnitIdx, streamIdx => $streamIdx, controlIndex => $controlIndex, cONTROLCREMENT => $cONTROLCREMENT);
print Dumper($result);
};
if ($@) {
warn "Exception when calling AudioUnitApi->decrementAudioUnitExternamPortInputControl: $@\n";
}
from __future__ import print_statement
import time
import openapi_client
from openapi_client.rest import ApiException
from pprint import pprint
# Create an instance of the API class
api_instance = openapi_client.AudioUnitApi()
deviceId = 00-50-c2-ff-fe-d4-33-8d # String | Entity device identifier
(default to null)
cfgIdx = 0 # Integer | valid configurations index
(default to null)
audioUnitIdx = 0 # Integer | Descriptor AUDIO_UNIT index
(default to null)
streamIdx = 0 # Integer | Descriptor EXTERNAL_PORT_INPUT index
(default to null)
controlIndex = 0 # Integer | Descriptor CONTROL index
(default to null)
cONTROLCREMENT = {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}} # CONTROLCREMENT | (optional)
try:
# Decrement audioUnit/externalPortInput/control value
api_response = api_instance.decrement_audio_unit_externam_port_input_control(deviceId, cfgIdx, audioUnitIdx, streamIdx, controlIndex, cONTROLCREMENT=cONTROLCREMENT)
pprint(api_response)
except ApiException as e:
print("Exception when calling AudioUnitApi->decrementAudioUnitExternamPortInputControl: %s\n" % e)
extern crate AudioUnitApi;
pub fn main() {
let deviceId = 00-50-c2-ff-fe-d4-33-8d; // String
let cfgIdx = 0; // Integer
let audioUnitIdx = 0; // Integer
let streamIdx = 0; // Integer
let controlIndex = 0; // Integer
let cONTROLCREMENT = {CONTROL={value={LINEAR_UINT8={numberValues=1, idx=[10]}}}}; // CONTROLCREMENT
let mut context = AudioUnitApi::Context::default();
let result = client.decrementAudioUnitExternamPortInputControl(deviceId, cfgIdx, audioUnitIdx, streamIdx, controlIndex, cONTROLCREMENT, &context).wait();
println!("{:?}", result);
}
Scopes
Parameters
| Name | Description |
|---|---|
| deviceId* |
String
Entity device identifier
Required
|
| cfg_idx* |
Integer
valid configurations index
Required
|
| audioUnit_idx* |
Integer
Descriptor AUDIO_UNIT index
Required
|
| stream_idx* |
Integer
Descriptor EXTERNAL_PORT_INPUT index
Required
|
| control_index* |
Integer
Descriptor CONTROL index
Required
|
| Name | Description |
|---|---|
| cONTROLCREMENT |
Set Object Name and Control Value |