mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-08-31 19:08:29 +00:00
commit
31f6a4bcfd
46 changed files with 2992 additions and 2001 deletions
164
.github/workflows/docker.yml
vendored
164
.github/workflows/docker.yml
vendored
|
|
@ -78,16 +78,9 @@ jobs:
|
||||||
with:
|
with:
|
||||||
name: Version
|
name: Version
|
||||||
path: ${{env.GITHUB_HOME}}\output\version.txt
|
path: ${{env.GITHUB_HOME}}\output\version.txt
|
||||||
# Create the release on the source repo
|
|
||||||
- name: Create tag for non-rc builds
|
|
||||||
if: contains(env.VERSION, 'alpha') || contains(env.VERSION, 'beta')
|
|
||||||
run: |
|
|
||||||
git tag $($Env:VERSION)
|
|
||||||
git push --tags origin
|
|
||||||
- name: Create Release
|
- name: Create Release
|
||||||
id: create_release
|
id: create_release
|
||||||
# using contributor's version to allow for pointing at the right commit
|
# using contributor's version to allow for pointing at the right commit
|
||||||
if: contains(env.VERSION,'-rc-') || contains(env.VERSION,'-hotfix-')
|
|
||||||
uses: fleskesvor/create-release@feature/support-target-commitish
|
uses: fleskesvor/create-release@feature/support-target-commitish
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ env.VERSION }}
|
tag_name: ${{ env.VERSION }}
|
||||||
|
|
@ -150,160 +143,3 @@ jobs:
|
||||||
run: nuget push **/*.nupkg -source github
|
run: nuget push **/*.nupkg -source github
|
||||||
- name: Publish nuget package to nuget.org
|
- name: Publish nuget package to nuget.org
|
||||||
run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json
|
run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json
|
||||||
# This step always runs and pushes the build to the internal build rep
|
|
||||||
Internal_Push_Output:
|
|
||||||
needs: Build_Project
|
|
||||||
runs-on: windows-latest
|
|
||||||
steps:
|
|
||||||
- name: check Github ref
|
|
||||||
run: ${{toJson(github.ref)}}
|
|
||||||
# Checkout the repo
|
|
||||||
- name: Checkout Builds Repo
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.BUILDS_TOKEN }}
|
|
||||||
repository: PepperDash-Engineering/essentials-builds
|
|
||||||
ref: ${{ Env.GITHUB_REF }}
|
|
||||||
# Download the version artifact from the build job
|
|
||||||
- name: Download Build Version Info
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Version
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem "./"
|
|
||||||
# Set the version number environment variable from the file we just downloaded
|
|
||||||
- name: Set Version Number
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
Get-ChildItem "./Version"
|
|
||||||
$version = Get-Content -Path ./Version/version.txt
|
|
||||||
Write-Host "Version: $version"
|
|
||||||
echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
|
||||||
Remove-Item -Path ./Version/version.txt
|
|
||||||
Remove-Item -Path ./Version
|
|
||||||
# Checkout/Create the branch
|
|
||||||
- name: Create new branch
|
|
||||||
run: git checkout -b $($Env:GITHUB_REF -replace "refs/heads/")
|
|
||||||
# Download the build output into the repo
|
|
||||||
- name: Download Build output
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Build
|
|
||||||
path: ./
|
|
||||||
- name: Check directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Unzip the build package file
|
|
||||||
- name: Unzip Build file
|
|
||||||
run: |
|
|
||||||
Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\
|
|
||||||
Remove-Item -Path .\*.zip
|
|
||||||
- name: Check directory again
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Copy Contents of output folder to root directory
|
|
||||||
- name: Copy Files to root & delete output directory
|
|
||||||
run: |
|
|
||||||
Remove-Item -Path .\* -Include @("*.cpz","*.md","*.cplz","*.json","*.dll","*.clz")
|
|
||||||
Get-ChildItem -Path .\output\* | Copy-Item -Destination .\
|
|
||||||
Remove-Item -Path .\output -Recurse
|
|
||||||
# Commits the build output to the branch and tags it with the version
|
|
||||||
- name: Commit build output and tag the commit
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
git config user.email "actions@pepperdash.com"
|
|
||||||
git config user.name "GitHub Actions"
|
|
||||||
git add .
|
|
||||||
$commit = "Build $($Env:GITHUB_RUN_NUMBER) from commit: https://github.com/$($Env:GITHUB_REPOSITORY)/commit/$($Env:GITHUB_SHA)"
|
|
||||||
Write-Host "Commit: $commit"
|
|
||||||
git commit -m $commit
|
|
||||||
git tag $($Env:VERSION)
|
|
||||||
# Push the commit
|
|
||||||
- name: Push to Builds Repo
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
$branch = $($Env:GITHUB_REF) -replace "refs/heads/"
|
|
||||||
Write-Host "Branch: $branch"
|
|
||||||
git push -u origin $($branch) --force
|
|
||||||
# Push the tags
|
|
||||||
- name: Push tags
|
|
||||||
run: git push --tags origin
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# This step only runs if the branch is main or release/ runs and pushes the build to the public build repo
|
|
||||||
Public_Push_Output:
|
|
||||||
needs: Build_Project
|
|
||||||
runs-on: windows-latest
|
|
||||||
if: contains(github.ref, 'main') || contains(github.ref, '/release/')
|
|
||||||
steps:
|
|
||||||
# Checkout the repo
|
|
||||||
- name: check Github ref
|
|
||||||
run: ${{toJson(github.ref)}}
|
|
||||||
- name: Checkout Builds Repo
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.BUILDS_TOKEN }}
|
|
||||||
repository: PepperDash/Essentials-Builds
|
|
||||||
ref: ${{ Env.GITHUB_REF }}
|
|
||||||
# Download the version artifact from the build job
|
|
||||||
- name: Download Build Version Info
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Version
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem "./"
|
|
||||||
# Set the version number environment variable from the file we just downloaded
|
|
||||||
- name: Set Version Number
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
Get-ChildItem "./Version"
|
|
||||||
$version = Get-Content -Path ./Version/version.txt
|
|
||||||
Write-Host "Version: $version"
|
|
||||||
echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
|
||||||
Remove-Item -Path ./Version/version.txt
|
|
||||||
Remove-Item -Path ./Version
|
|
||||||
# Checkout/Create the branch
|
|
||||||
- name: Create new branch
|
|
||||||
run: git checkout -b $($Env:GITHUB_REF -replace "refs/heads/")
|
|
||||||
# Download the build output into the repo
|
|
||||||
- name: Download Build output
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Build
|
|
||||||
path: ./
|
|
||||||
- name: Check directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Unzip the build package file
|
|
||||||
- name: Unzip Build file
|
|
||||||
run: |
|
|
||||||
Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\
|
|
||||||
Remove-Item -Path .\*.zip
|
|
||||||
- name: Check directory again
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Copy Contents of output folder to root directory
|
|
||||||
- name: Copy Files to root & delete output directory
|
|
||||||
run: |
|
|
||||||
Remove-Item -Path .\* -Include @("*.cpz","*.md","*.cplz","*.json","*.dll","*.clz")
|
|
||||||
Get-ChildItem -Path .\output\* | Copy-Item -Destination .\
|
|
||||||
Remove-Item -Path .\output -Recurse
|
|
||||||
# Commits the build output to the branch and tags it with the version
|
|
||||||
- name: Commit build output and tag the commit
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
git config user.email "actions@pepperdash.com"
|
|
||||||
git config user.name "GitHub Actions"
|
|
||||||
git add .
|
|
||||||
$commit = "Build $($Env:GITHUB_RUN_NUMBER) from commit: https://github.com/$($Env:GITHUB_REPOSITORY)/commit/$($Env:GITHUB_SHA)"
|
|
||||||
Write-Host "Commit: $commit"
|
|
||||||
git commit -m $commit
|
|
||||||
git tag $($Env:VERSION)
|
|
||||||
# Push the commit
|
|
||||||
- name: Push to Builds Repo
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
$branch = $($Env:GITHUB_REF) -replace "refs/heads/"
|
|
||||||
Write-Host "Branch: $branch"
|
|
||||||
git push -u origin $($branch) --force
|
|
||||||
# Push the tags
|
|
||||||
- name: Push tags
|
|
||||||
run: git push --tags origin
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
|
|
|
||||||
145
.github/workflows/main.yml
vendored
145
.github/workflows/main.yml
vendored
|
|
@ -123,148 +123,3 @@ jobs:
|
||||||
run: nuget push **/*.nupkg -source github
|
run: nuget push **/*.nupkg -source github
|
||||||
- name: Publish nuget package to nuget.org
|
- name: Publish nuget package to nuget.org
|
||||||
run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json
|
run: nuget push **/*.nupkg -Source https://api.nuget.org/v3/index.json
|
||||||
Internal_Push_Output:
|
|
||||||
needs: Build_Project
|
|
||||||
runs-on: windows-latest
|
|
||||||
steps:
|
|
||||||
# Checkout the repo
|
|
||||||
- name: Checkout Builds Repo
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.BUILDS_TOKEN }}
|
|
||||||
repository: PepperDash-Engineering/essentials-builds
|
|
||||||
ref: ${{ Env.GITHUB_REF }}
|
|
||||||
# Download the version artifact from the build job
|
|
||||||
- name: Download Build Version Info
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Version
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem "./"
|
|
||||||
# Set the version number environment variable from the file we just downloaded
|
|
||||||
- name: Set Version Number
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
Get-ChildItem "./Version"
|
|
||||||
$version = Get-Content -Path ./Version/version.txt
|
|
||||||
Write-Host "Version: $version"
|
|
||||||
echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
|
||||||
Remove-Item -Path ./Version/version.txt
|
|
||||||
Remove-Item -Path ./Version
|
|
||||||
# Checkout/Create the branch
|
|
||||||
- name: Checkout main branch
|
|
||||||
run: git checkout main
|
|
||||||
# Download the build output into the repo
|
|
||||||
- name: Download Build output
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Build
|
|
||||||
path: ./
|
|
||||||
- name: Check directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Unzip the build package file
|
|
||||||
- name: Unzip Build file
|
|
||||||
run: |
|
|
||||||
Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\
|
|
||||||
Remove-Item -Path .\*.zip
|
|
||||||
- name: Check directory again
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Copy Contents of output folder to root directory
|
|
||||||
- name: Copy Files to root & delete output directory
|
|
||||||
run: |
|
|
||||||
Remove-Item -Path .\* -Include @("*.cpz","*.md","*.cplz","*.json","*.dll","*.clz")
|
|
||||||
Get-ChildItem -Path .\output\* | Copy-Item -Destination .\
|
|
||||||
Remove-Item -Path .\output -Recurse
|
|
||||||
# Commits the build output to the branch and tags it with the version
|
|
||||||
- name: Commit build output and tag the commit
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
git config user.email "actions@pepperdash.com"
|
|
||||||
git config user.name "GitHub Actions"
|
|
||||||
git add .
|
|
||||||
$commit = "Build $($Env:GITHUB_RUN_NUMBER) from commit: https://github.com/$($Env:GITHUB_REPOSITORY)/commit/$($Env:GITHUB_SHA)"
|
|
||||||
Write-Host "Commit: $commit"
|
|
||||||
git commit -m $commit
|
|
||||||
git tag $($Env:VERSION)
|
|
||||||
# Push the commit
|
|
||||||
- name: Push to Builds Repo
|
|
||||||
shell: powershell
|
|
||||||
run: git push -u origin main --force
|
|
||||||
# Push the tags
|
|
||||||
- name: Push tags
|
|
||||||
run: git push --tags origin
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# This step only runs if the branch is main or release/ runs and pushes the build to the public build repo
|
|
||||||
Public_Push_Output:
|
|
||||||
needs: Build_Project
|
|
||||||
runs-on: windows-latest
|
|
||||||
steps:
|
|
||||||
# Checkout the repo
|
|
||||||
- name: Checkout Builds Repo
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.BUILDS_TOKEN }}
|
|
||||||
repository: PepperDash/Essentials-Builds
|
|
||||||
ref: ${{ Env.GITHUB_REF }}
|
|
||||||
# Download the version artifact from the build job
|
|
||||||
- name: Download Build Version Info
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Version
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem "./"
|
|
||||||
# Set the version number environment variable from the file we just downloaded
|
|
||||||
- name: Set Version Number
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
Get-ChildItem "./Version"
|
|
||||||
$version = Get-Content -Path ./Version/version.txt
|
|
||||||
Write-Host "Version: $version"
|
|
||||||
echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
|
||||||
Remove-Item -Path ./Version/version.txt
|
|
||||||
Remove-Item -Path ./Version
|
|
||||||
# Checkout main branch
|
|
||||||
- name: Create new branch
|
|
||||||
run: git checkout main
|
|
||||||
# Download the build output into the repo
|
|
||||||
- name: Download Build output
|
|
||||||
uses: actions/download-artifact@v1
|
|
||||||
with:
|
|
||||||
name: Build
|
|
||||||
path: ./
|
|
||||||
- name: Check directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Unzip the build package file
|
|
||||||
- name: Unzip Build file
|
|
||||||
run: |
|
|
||||||
Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\
|
|
||||||
Remove-Item -Path .\*.zip
|
|
||||||
- name: Check directory again
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
# Copy Contents of output folder to root directory
|
|
||||||
- name: Copy Files to root & delete output directory
|
|
||||||
run: |
|
|
||||||
Remove-Item -Path .\* -Include @("*.cpz","*.md","*.cplz","*.json","*.dll","*.clz")
|
|
||||||
Get-ChildItem -Path .\output\* | Copy-Item -Destination .\
|
|
||||||
Remove-Item -Path .\output -Recurse
|
|
||||||
# Commits the build output to the branch and tags it with the version
|
|
||||||
- name: Commit build output and tag the commit
|
|
||||||
shell: powershell
|
|
||||||
run: |
|
|
||||||
git config user.email "actions@pepperdash.com"
|
|
||||||
git config user.name "GitHub Actions"
|
|
||||||
git add .
|
|
||||||
$commit = "Build $($Env:GITHUB_RUN_NUMBER) from commit: https://github.com/$($Env:GITHUB_REPOSITORY)/commit/$($Env:GITHUB_SHA)"
|
|
||||||
Write-Host "Commit: $commit"
|
|
||||||
git commit -m $commit
|
|
||||||
git tag $($Env:VERSION)
|
|
||||||
# Push the commit
|
|
||||||
- name: Push to Builds Repo
|
|
||||||
shell: powershell
|
|
||||||
run: git push -u origin main --force
|
|
||||||
# Push the tags
|
|
||||||
- name: Push tags
|
|
||||||
run: git push --tags origin
|
|
||||||
- name: Check Directory
|
|
||||||
run: Get-ChildItem ./
|
|
||||||
|
|
|
||||||
|
|
@ -383,11 +383,11 @@ namespace PepperDash.Essentials
|
||||||
if (newDev != null)
|
if (newDev != null)
|
||||||
DeviceManager.AddDevice(newDev);
|
DeviceManager.AddDevice(newDev);
|
||||||
else
|
else
|
||||||
Debug.Console(0, Debug.ErrorLogLevel.Notice, "ERROR: Cannot load unknown device type '{0}', key '{1}'.", devConf.Type, devConf.Key);
|
Debug.Console(0, Debug.ErrorLogLevel.Error, "ERROR: Cannot load unknown device type '{0}', key '{1}'.", devConf.Type, devConf.Key);
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Debug.Console(0, Debug.ErrorLogLevel.Notice, "ERROR: Creating device {0}. Skipping device. \r{1}", devConf.Key, e);
|
Debug.Console(0, Debug.ErrorLogLevel.Error, "ERROR: Creating device {0}. Skipping device. \r{1}", devConf.Key, e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Debug.Console(0, Debug.ErrorLogLevel.Notice, "All Devices Loaded.");
|
Debug.Console(0, Debug.ErrorLogLevel.Notice, "All Devices Loaded.");
|
||||||
|
|
|
||||||
|
|
@ -5,30 +5,62 @@ namespace PepperDash.Essentials.Room.Config
|
||||||
{
|
{
|
||||||
public class EssentialsTechRoomConfig
|
public class EssentialsTechRoomConfig
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The key of the dummy device used to enable routing
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("dummySourceKey")]
|
[JsonProperty("dummySourceKey")]
|
||||||
public string DummySourceKey { get; set; }
|
public string DummySourceKey { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The keys of the displays assigned to this room
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("displays")]
|
[JsonProperty("displays")]
|
||||||
public List<string> Displays;
|
public List<string> Displays { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The keys of the tuners assinged to this room
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("tuners")]
|
[JsonProperty("tuners")]
|
||||||
public List<string> Tuners;
|
public List<string> Tuners { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// PIN to access the room as a normal user
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("userPin")]
|
[JsonProperty("userPin")]
|
||||||
public string UserPin;
|
public string UserPin { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// PIN to access the room as a tech user
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("techPin")]
|
[JsonProperty("techPin")]
|
||||||
public string TechPin;
|
public string TechPin { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Name of the presets file. Path prefix is assumed to be /html/presets/lists/
|
||||||
|
/// </summary>
|
||||||
[JsonProperty("presetsFileName")]
|
[JsonProperty("presetsFileName")]
|
||||||
public string PresetsFileName;
|
public string PresetsFileName { get; set; }
|
||||||
|
|
||||||
[JsonProperty("scheduledEvents")]
|
[JsonProperty("scheduledEvents")]
|
||||||
public List<ScheduledEventConfig> ScheduledEvents;
|
public List<ScheduledEventConfig> ScheduledEvents { get; set; }
|
||||||
|
|
||||||
[JsonProperty("isPrimary")] public bool IsPrimary;
|
/// <summary>
|
||||||
|
/// Indicates that the room is the primary when true
|
||||||
|
/// </summary>
|
||||||
|
[JsonProperty("isPrimary")]
|
||||||
|
public bool IsPrimary { get; set; }
|
||||||
|
|
||||||
[JsonProperty("isTvPresetsProvider")] public bool IsTvPresetsProvider;
|
/// <summary>
|
||||||
|
/// Indicates which tuners should mirror preset recall when two rooms are configured in a primary->secondary scenario
|
||||||
|
/// </summary>
|
||||||
|
[JsonProperty("mirroredTuners")]
|
||||||
|
public Dictionary<uint, string> MirroredTuners { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Indicates the room
|
||||||
|
/// </summary>
|
||||||
|
[JsonProperty("isTvPresetsProvider")]
|
||||||
|
public bool IsTvPresetsProvider;
|
||||||
|
|
||||||
public EssentialsTechRoomConfig()
|
public EssentialsTechRoomConfig()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ using PepperDash.Essentials.Room.Config;
|
||||||
using PepperDash.Essentials.Devices.Common.Codec;
|
using PepperDash.Essentials.Devices.Common.Codec;
|
||||||
using PepperDash.Essentials.Devices.Common.VideoCodec;
|
using PepperDash.Essentials.Devices.Common.VideoCodec;
|
||||||
using PepperDash.Essentials.Devices.Common.AudioCodec;
|
using PepperDash.Essentials.Devices.Common.AudioCodec;
|
||||||
using PepperDash_Essentials_Core.DeviceTypeInterfaces;
|
using PepperDash.Essentials.Core.DeviceTypeInterfaces;
|
||||||
|
|
||||||
namespace PepperDash.Essentials
|
namespace PepperDash.Essentials
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -373,13 +373,32 @@ Params: {2}"
|
||||||
uint i;
|
uint i;
|
||||||
if (_config.IsPrimary)
|
if (_config.IsPrimary)
|
||||||
{
|
{
|
||||||
i = 0;
|
Debug.Console(1, this, "Linking Primary system Tuner Preset Mirroring");
|
||||||
foreach (var feedback in CurrentPresetsFeedbacks)
|
if (_config.MirroredTuners != null && _config.MirroredTuners.Count > 0)
|
||||||
{
|
{
|
||||||
feedback.Value.LinkInputSig(trilist.StringInput[(uint) (joinMap.CurrentPreset.JoinNumber + i)]);
|
foreach (var tuner in _config.MirroredTuners)
|
||||||
i++;
|
{
|
||||||
|
var f = CurrentPresetsFeedbacks[tuner.Value];
|
||||||
|
|
||||||
|
if (f == null)
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, "Unable to find feedback with key: {0}", tuner.Value);
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var join = joinMap.CurrentPreset.JoinNumber + tuner.Key;
|
||||||
|
f.LinkInputSig(trilist.StringInput[(uint)(join)]);
|
||||||
|
Debug.Console(1, this, "Linked Current Preset feedback for tuner: {0} to serial join: {1}", tuner.Value, join);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//i = 0;
|
||||||
|
//foreach (var feedback in CurrentPresetsFeedbacks)
|
||||||
|
//{
|
||||||
|
// feedback.Value.LinkInputSig(trilist.StringInput[(uint) (joinMap.CurrentPreset.JoinNumber + i)]);
|
||||||
|
// i++;
|
||||||
|
//}
|
||||||
|
|
||||||
trilist.OnlineStatusChange += (device, args) =>
|
trilist.OnlineStatusChange += (device, args) =>
|
||||||
{
|
{
|
||||||
if (!args.DeviceOnLine)
|
if (!args.DeviceOnLine)
|
||||||
|
|
@ -395,15 +414,35 @@ Params: {2}"
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
i = 0;
|
|
||||||
foreach (var setTopBox in _tuners)
|
|
||||||
{
|
{
|
||||||
var tuner = setTopBox;
|
Debug.Console(1, this, "Linking Secondary system Tuner Preset Mirroring");
|
||||||
|
|
||||||
trilist.SetStringSigAction(joinMap.CurrentPreset.JoinNumber + i, s => _tunerPresets.Dial(s, tuner.Value));
|
if (_config.MirroredTuners != null && _config.MirroredTuners.Count > 0)
|
||||||
|
{
|
||||||
|
foreach (var tuner in _config.MirroredTuners)
|
||||||
|
{
|
||||||
|
var t = _tuners[tuner.Value];
|
||||||
|
|
||||||
i++;
|
if (t == null)
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, "Unable to find tuner with key: {0}", tuner.Value);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
var join = joinMap.CurrentPreset.JoinNumber + tuner.Key;
|
||||||
|
trilist.SetStringSigAction(join, s => _tunerPresets.Dial(s, t));
|
||||||
|
Debug.Console(1, this, "Linked preset recall action for tuner: {0} to serial join: {1}", tuner.Value, join);
|
||||||
|
}
|
||||||
|
|
||||||
|
//foreach (var setTopBox in _tuners)
|
||||||
|
//{
|
||||||
|
// var tuner = setTopBox;
|
||||||
|
|
||||||
|
// trilist.SetStringSigAction(joinMap.CurrentPreset.JoinNumber + i, s => _tunerPresets.Dial(s, tuner.Value));
|
||||||
|
|
||||||
|
//}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -154,7 +154,7 @@ namespace PepperDash.Essentials.Core.Bridges
|
||||||
|
|
||||||
[JoinName("PirSensitivityInVacantState")]
|
[JoinName("PirSensitivityInVacantState")]
|
||||||
public JoinDataComplete PirSensitivityInVacantState = new JoinDataComplete(new JoinData { JoinNumber = 8, JoinSpan = 1 },
|
public JoinDataComplete PirSensitivityInVacantState = new JoinDataComplete(new JoinData { JoinNumber = 8, JoinSpan = 1 },
|
||||||
new JoinMetadata { Description = "Occ Sensor Ultrasonic Sensitivity in Vacant State", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Analog });
|
new JoinMetadata { Description = "Occ Sensor PIR Sensitivity in Vacant State", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Analog });
|
||||||
|
|
||||||
[JoinName("Name")]
|
[JoinName("Name")]
|
||||||
public JoinDataComplete Name = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
public JoinDataComplete Name = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
using System;
|
using System;
|
||||||
using PepperDash.Essentials.Core;
|
using PepperDash.Essentials.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||||
{
|
{
|
||||||
public class GlsPartitionSensorJoinMap : JoinMapBaseAdvanced
|
public class GlsPartitionSensorJoinMap : JoinMapBaseAdvanced
|
||||||
{
|
{
|
||||||
|
|
@ -122,7 +122,7 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="joinStart">Join this join map will start at</param>
|
/// <param name="joinStart">Join this join map will start at</param>
|
||||||
public GlsPartitionSensorJoinMap(uint joinStart)
|
public GlsPartitionSensorJoinMap(uint joinStart)
|
||||||
: this(joinStart, typeof (GlsPartitionSensorJoinMap))
|
: this(joinStart, typeof(GlsPartitionSensorJoinMap))
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -139,3 +139,23 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Obsolete("use PepperDash.Essentials.Core.Bridges.JoinMaps version")]
|
||||||
|
public class GlsPartitionSensorJoinMap : PepperDash.Essentials.Core.Bridges.JoinMaps.GlsPartitionSensorJoinMap
|
||||||
|
{
|
||||||
|
public GlsPartitionSensorJoinMap(uint joinStart)
|
||||||
|
: this(joinStart, typeof(GlsPartitionSensorJoinMap))
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
protected GlsPartitionSensorJoinMap(uint joinStart, Type type) : base(joinStart, type)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,222 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
|
|
||||||
|
namespace PepperDash.Essentials.Core.Bridges
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Join map for IRBlurayBase devices
|
||||||
|
/// </summary>
|
||||||
|
public class IRBlurayBaseJoinMap : JoinMapBaseAdvanced
|
||||||
|
{
|
||||||
|
[JoinName("PowerOn")]
|
||||||
|
public JoinDataComplete PowerOn = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Power On", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("PowerOff")]
|
||||||
|
public JoinDataComplete PowerOff = new JoinDataComplete(new JoinData { JoinNumber = 2, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Power Off", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("PowerToggle")]
|
||||||
|
public JoinDataComplete PowerToggle = new JoinDataComplete(new JoinData { JoinNumber = 3, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Power Toggle", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Up")]
|
||||||
|
public JoinDataComplete Up = new JoinDataComplete(new JoinData { JoinNumber = 4, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Nav Up", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Down")]
|
||||||
|
public JoinDataComplete Down = new JoinDataComplete(new JoinData { JoinNumber = 5, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Nav Down", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Left")]
|
||||||
|
public JoinDataComplete Left = new JoinDataComplete(new JoinData { JoinNumber = 6, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Nav Left", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Right")]
|
||||||
|
public JoinDataComplete Right = new JoinDataComplete(new JoinData { JoinNumber = 7, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Nav Right", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Select")]
|
||||||
|
public JoinDataComplete Select = new JoinDataComplete(new JoinData { JoinNumber = 8, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Select", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Menu")]
|
||||||
|
public JoinDataComplete Menu = new JoinDataComplete(new JoinData { JoinNumber = 9, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Menu", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Exit")]
|
||||||
|
public JoinDataComplete Exit = new JoinDataComplete(new JoinData { JoinNumber = 10, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Exit", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit0")]
|
||||||
|
public JoinDataComplete Digit0 = new JoinDataComplete(new JoinData { JoinNumber = 11, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 0", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit1")]
|
||||||
|
public JoinDataComplete Digit1 = new JoinDataComplete(new JoinData { JoinNumber = 12, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 1", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit2")]
|
||||||
|
public JoinDataComplete Digit2 = new JoinDataComplete(new JoinData { JoinNumber = 13, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 2", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit3")]
|
||||||
|
public JoinDataComplete Digit3 = new JoinDataComplete(new JoinData { JoinNumber = 14, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 3", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit4")]
|
||||||
|
public JoinDataComplete Digit4 = new JoinDataComplete(new JoinData { JoinNumber = 15, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 4", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit5")]
|
||||||
|
public JoinDataComplete Digit5 = new JoinDataComplete(new JoinData { JoinNumber = 16, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 5", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit6")]
|
||||||
|
public JoinDataComplete Digit6 = new JoinDataComplete(new JoinData { JoinNumber = 17, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 6", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit7")]
|
||||||
|
public JoinDataComplete Digit7 = new JoinDataComplete(new JoinData { JoinNumber = 18, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 7", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit8")]
|
||||||
|
public JoinDataComplete Digit8 = new JoinDataComplete(new JoinData { JoinNumber = 19, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 8", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Digit9")]
|
||||||
|
public JoinDataComplete Digit9 = new JoinDataComplete(new JoinData { JoinNumber = 20, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Digit 9", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("KeypadClear")]
|
||||||
|
public JoinDataComplete KeypadClear = new JoinDataComplete(new JoinData { JoinNumber = 21, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Keypad Clear", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("KeypadEnter")]
|
||||||
|
public JoinDataComplete KeypadEnter = new JoinDataComplete(new JoinData { JoinNumber = 22, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Keypad Enter", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("ChannelUp")]
|
||||||
|
public JoinDataComplete ChannelUp = new JoinDataComplete(new JoinData { JoinNumber = 23, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "STB Channel Up", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("ChannelDown")]
|
||||||
|
public JoinDataComplete ChannelDown = new JoinDataComplete(new JoinData { JoinNumber = 24, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "STB Channel Down", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("LastChannel")]
|
||||||
|
public JoinDataComplete LastChannel = new JoinDataComplete(new JoinData { JoinNumber = 25, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Last Channel", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Guide")]
|
||||||
|
public JoinDataComplete Guide = new JoinDataComplete(new JoinData { JoinNumber = 26, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Guide", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Info")]
|
||||||
|
public JoinDataComplete Info = new JoinDataComplete(new JoinData { JoinNumber = 27, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Info", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Red")]
|
||||||
|
public JoinDataComplete Red = new JoinDataComplete(new JoinData { JoinNumber = 28, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Red", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Green")]
|
||||||
|
public JoinDataComplete Green = new JoinDataComplete(new JoinData { JoinNumber = 29, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Green", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Yellow")]
|
||||||
|
public JoinDataComplete Yellow = new JoinDataComplete(new JoinData { JoinNumber = 30, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Yellow", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Blue")]
|
||||||
|
public JoinDataComplete Blue = new JoinDataComplete(new JoinData { JoinNumber = 31, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Blue", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
|
||||||
|
[JoinName("Play")]
|
||||||
|
public JoinDataComplete Play = new JoinDataComplete(new JoinData { JoinNumber = 33, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Play", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Pause")]
|
||||||
|
public JoinDataComplete Pause = new JoinDataComplete(new JoinData { JoinNumber = 34, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Pause", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Stop")]
|
||||||
|
public JoinDataComplete Stop = new JoinDataComplete(new JoinData { JoinNumber = 35, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Stop", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("FFwd")]
|
||||||
|
public JoinDataComplete FFwd = new JoinDataComplete(new JoinData { JoinNumber = 36, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "FFwd", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Rewind")]
|
||||||
|
public JoinDataComplete Rewind = new JoinDataComplete(new JoinData { JoinNumber = 37, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Rewind", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("ChapPlus")]
|
||||||
|
public JoinDataComplete ChapPlus = new JoinDataComplete(new JoinData { JoinNumber = 38, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Chapter Plus", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("ChapMinus")]
|
||||||
|
public JoinDataComplete ChapMinus = new JoinDataComplete(new JoinData { JoinNumber = 39, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Chapter Minus", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Replay")]
|
||||||
|
public JoinDataComplete Replay = new JoinDataComplete(new JoinData { JoinNumber = 40, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Replay", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Record")]
|
||||||
|
public JoinDataComplete Record = new JoinDataComplete(new JoinData { JoinNumber = 41, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Record", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("HasKeypadAccessoryButton1")]
|
||||||
|
public JoinDataComplete HasKeypadAccessoryButton1 = new JoinDataComplete(new JoinData { JoinNumber = 42, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Has Keypad Accessory Button 1", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("HasKeypadAccessoryButton2")]
|
||||||
|
public JoinDataComplete HasKeypadAccessoryButton2 = new JoinDataComplete(new JoinData { JoinNumber = 43, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Has Keypad Accessory Button 2", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("KeypadAccessoryButton1Press")]
|
||||||
|
public JoinDataComplete KeypadAccessoryButton1Press = new JoinDataComplete(new JoinData { JoinNumber = 42, JoinSpan = 2 },
|
||||||
|
new JoinMetadata { Description = "Keypad Accessory Button 1 Press", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("KeypadAccessoryButton2Press")]
|
||||||
|
public JoinDataComplete KeypadAccessoryButton2Press = new JoinDataComplete(new JoinData { JoinNumber = 43, JoinSpan = 2 },
|
||||||
|
new JoinMetadata { Description = "Keypad Accessory Button 2 Press", JoinCapabilities = eJoinCapabilities.FromSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("Name")]
|
||||||
|
public JoinDataComplete Name = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Name", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||||
|
|
||||||
|
[JoinName("KeypadAccessoryButton1Label")]
|
||||||
|
public JoinDataComplete KeypadAccessoryButton1Label = new JoinDataComplete(new JoinData { JoinNumber = 42, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Keypad Accessory Button 1 Label", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
||||||
|
|
||||||
|
[JoinName("KeypadAccessoryButton2Label")]
|
||||||
|
public JoinDataComplete KeypadAccessoryButton2Label = new JoinDataComplete(new JoinData { JoinNumber = 43, JoinSpan = 1 },
|
||||||
|
new JoinMetadata { Description = "Keypad Accessory Button 1 Label", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor to use when instantiating this Join Map without inheriting from it
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="joinStart">Join this join map will start at</param>
|
||||||
|
public IRBlurayBaseJoinMap(uint joinStart)
|
||||||
|
: this(joinStart, typeof(IRBlurayBaseJoinMap))
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor to use when extending this Join map
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="joinStart">Join this join map will start at</param>
|
||||||
|
/// <param name="type">Type of the child join map</param>
|
||||||
|
protected IRBlurayBaseJoinMap(uint joinStart, Type type)
|
||||||
|
: base(joinStart, type)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,14 +1,14 @@
|
||||||
using System;
|
using System;
|
||||||
using PepperDash.Essentials.Core;
|
using PepperDash.Essentials.Core;
|
||||||
|
namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||||
namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
|
||||||
{
|
{
|
||||||
public class VideoCodecControllerJoinMap : JoinMapBaseAdvanced
|
public class VideoCodecControllerJoinMap : JoinMapBaseAdvanced
|
||||||
{
|
{
|
||||||
#region Status
|
#region Status
|
||||||
|
|
||||||
[JoinName("IsOnline")] public JoinDataComplete IsOnline =
|
[JoinName("IsOnline")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 1, JoinSpan = 1},
|
public JoinDataComplete IsOnline =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Device is Online",
|
Description = "Device is Online",
|
||||||
|
|
@ -18,8 +18,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
[JoinName("CallDirection")] public JoinDataComplete CallDirection =
|
[JoinName("CallDirection")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 22, JoinSpan = 1},
|
public JoinDataComplete CallDirection =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 22, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Call Direction",
|
Description = "Current Call Direction",
|
||||||
|
|
@ -27,8 +28,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraLayout")] public JoinDataComplete CameraLayout =
|
[JoinName("CameraLayout")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 142, JoinSpan = 1},
|
public JoinDataComplete CameraLayout =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 142, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Layout Toggle",
|
Description = "Camera Layout Toggle",
|
||||||
|
|
@ -36,8 +38,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraLayoutStringFb")] public JoinDataComplete CameraLayoutStringFb =
|
[JoinName("CameraLayoutStringFb")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 141, JoinSpan = 1},
|
public JoinDataComplete CameraLayoutStringFb =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 141, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Layout Fb",
|
Description = "Current Layout Fb",
|
||||||
|
|
@ -45,8 +48,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraModeAuto")] public JoinDataComplete CameraModeAuto =
|
[JoinName("CameraModeAuto")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 131, JoinSpan = 1},
|
public JoinDataComplete CameraModeAuto =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 131, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Mode Auto",
|
Description = "Camera Mode Auto",
|
||||||
|
|
@ -54,8 +58,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraModeManual")] public JoinDataComplete CameraModeManual =
|
[JoinName("CameraModeManual")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 132, JoinSpan = 1},
|
public JoinDataComplete CameraModeManual =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 132, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Mode Manual",
|
Description = "Camera Mode Manual",
|
||||||
|
|
@ -63,8 +68,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraModeOff")] public JoinDataComplete CameraModeOff =
|
[JoinName("CameraModeOff")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 133, JoinSpan = 1},
|
public JoinDataComplete CameraModeOff =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 133, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Mode Off",
|
Description = "Camera Mode Off",
|
||||||
|
|
@ -72,8 +78,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraNumberSelect")] public JoinDataComplete CameraNumberSelect =
|
[JoinName("CameraNumberSelect")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 60, JoinSpan = 1},
|
public JoinDataComplete CameraNumberSelect =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 60, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Number Select/FB",
|
Description = "Camera Number Select/FB",
|
||||||
|
|
@ -81,8 +88,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraPanLeft")] public JoinDataComplete CameraPanLeft =
|
[JoinName("CameraPanLeft")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 113, JoinSpan = 1},
|
public JoinDataComplete CameraPanLeft =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 113, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Pan Left",
|
Description = "Camera Pan Left",
|
||||||
|
|
@ -90,8 +98,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraPanRight")] public JoinDataComplete CameraPanRight =
|
[JoinName("CameraPanRight")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 114, JoinSpan = 1},
|
public JoinDataComplete CameraPanRight =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 114, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Pan Right",
|
Description = "Camera Pan Right",
|
||||||
|
|
@ -99,8 +108,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraPresetNames")] public JoinDataComplete CameraPresetNames =
|
[JoinName("CameraPresetNames")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 121, JoinSpan = 1},
|
public JoinDataComplete CameraPresetNames =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 121, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Preset Names - XSIG, max of 15",
|
Description = "Camera Preset Names - XSIG, max of 15",
|
||||||
|
|
@ -108,8 +118,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraPresetSelect")] public JoinDataComplete CameraPresetSelect =
|
[JoinName("CameraPresetSelect")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 121, JoinSpan = 1},
|
public JoinDataComplete CameraPresetSelect =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 121, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Preset Select",
|
Description = "Camera Preset Select",
|
||||||
|
|
@ -117,8 +128,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraPresetSave")] public JoinDataComplete CameraPresetSave =
|
[JoinName("CameraPresetSave")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 121, JoinSpan = 1},
|
public JoinDataComplete CameraPresetSave =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 121, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Save Selected Preset",
|
Description = "Save Selected Preset",
|
||||||
|
|
@ -126,8 +138,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraSelfView")] public JoinDataComplete CameraSelfView =
|
[JoinName("CameraSelfView")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 141, JoinSpan = 1},
|
public JoinDataComplete CameraSelfView =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 141, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Self View Toggle/FB",
|
Description = "Camera Self View Toggle/FB",
|
||||||
|
|
@ -135,8 +148,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraSupportsAutoMode")] public JoinDataComplete CameraSupportsAutoMode =
|
[JoinName("CameraSupportsAutoMode")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 143, JoinSpan = 1},
|
public JoinDataComplete CameraSupportsAutoMode =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 143, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Supports Auto Mode FB",
|
Description = "Camera Supports Auto Mode FB",
|
||||||
|
|
@ -144,8 +158,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraSupportsOffMode")] public JoinDataComplete CameraSupportsOffMode =
|
[JoinName("CameraSupportsOffMode")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 144, JoinSpan = 1},
|
public JoinDataComplete CameraSupportsOffMode =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 144, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Supports Off Mode FB",
|
Description = "Camera Supports Off Mode FB",
|
||||||
|
|
@ -153,8 +168,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraTiltDown")] public JoinDataComplete CameraTiltDown =
|
[JoinName("CameraTiltDown")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 112, JoinSpan = 1},
|
public JoinDataComplete CameraTiltDown =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 112, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Tilt Down",
|
Description = "Camera Tilt Down",
|
||||||
|
|
@ -162,8 +178,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraTiltUp")] public JoinDataComplete CameraTiltUp =
|
[JoinName("CameraTiltUp")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 111, JoinSpan = 1},
|
public JoinDataComplete CameraTiltUp =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 111, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Tilt Up",
|
Description = "Camera Tilt Up",
|
||||||
|
|
@ -171,8 +188,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraZoomIn")] public JoinDataComplete CameraZoomIn =
|
[JoinName("CameraZoomIn")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 115, JoinSpan = 1},
|
public JoinDataComplete CameraZoomIn =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 115, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Zoom In",
|
Description = "Camera Zoom In",
|
||||||
|
|
@ -180,8 +198,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CameraZoomOut")] public JoinDataComplete CameraZoomOut =
|
[JoinName("CameraZoomOut")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 116, JoinSpan = 1},
|
public JoinDataComplete CameraZoomOut =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 116, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Camera Zoom Out",
|
Description = "Camera Zoom Out",
|
||||||
|
|
@ -189,8 +208,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CurrentCallName")] public JoinDataComplete CurrentCallData =
|
[JoinName("CurrentCallName")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 2, JoinSpan = 1},
|
public JoinDataComplete CurrentCallData =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 2, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Call Data - XSIG",
|
Description = "Current Call Data - XSIG",
|
||||||
|
|
@ -198,8 +218,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CurrentDialString")] public JoinDataComplete CurrentDialString =
|
[JoinName("CurrentDialString")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 1, JoinSpan = 1},
|
public JoinDataComplete CurrentDialString =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Dial String",
|
Description = "Current Dial String",
|
||||||
|
|
@ -207,8 +228,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CurrentParticipants")] public JoinDataComplete CurrentParticipants =
|
[JoinName("CurrentParticipants")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 151, JoinSpan = 1},
|
public JoinDataComplete CurrentParticipants =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 151, JoinSpan = 1 },
|
||||||
new JoinMetadata()
|
new JoinMetadata()
|
||||||
{
|
{
|
||||||
Description = "Current Participants XSig",
|
Description = "Current Participants XSig",
|
||||||
|
|
@ -216,8 +238,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("CurrentSource")] public JoinDataComplete CurrentSource =
|
[JoinName("CurrentSource")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 201, JoinSpan = 1},
|
public JoinDataComplete CurrentSource =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 201, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Source",
|
Description = "Current Source",
|
||||||
|
|
@ -225,8 +248,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DialMeeting1")] public JoinDataComplete DialMeeting1 =
|
[JoinName("DialMeeting1")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 161, JoinSpan = 1},
|
public JoinDataComplete DialMeeting1 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 161, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Join first meeting",
|
Description = "Join first meeting",
|
||||||
|
|
@ -254,8 +278,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryDialSelectedLine")] public JoinDataComplete DirectoryDialSelectedLine =
|
[JoinName("DirectoryDialSelectedLine")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 106, JoinSpan = 1},
|
public JoinDataComplete DirectoryDialSelectedLine =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 106, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Dial selected directory line",
|
Description = "Dial selected directory line",
|
||||||
|
|
@ -263,8 +288,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryEntries")] public JoinDataComplete DirectoryEntries =
|
[JoinName("DirectoryEntries")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 101, JoinSpan = 1},
|
public JoinDataComplete DirectoryEntries =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 101, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Entries - XSig, 255 entries",
|
Description = "Directory Entries - XSig, 255 entries",
|
||||||
|
|
@ -272,8 +298,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryEntryIsContact")] public JoinDataComplete DirectoryEntryIsContact =
|
[JoinName("DirectoryEntryIsContact")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 101, JoinSpan = 1},
|
public JoinDataComplete DirectoryEntryIsContact =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 101, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Selected Entry Is Contact FB",
|
Description = "Directory Selected Entry Is Contact FB",
|
||||||
|
|
@ -281,8 +308,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryEntrySelectedName")] public JoinDataComplete DirectoryEntrySelectedName =
|
[JoinName("DirectoryEntrySelectedName")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 356, JoinSpan = 1},
|
public JoinDataComplete DirectoryEntrySelectedName =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 356, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Selected Directory Entry Name",
|
Description = "Selected Directory Entry Name",
|
||||||
|
|
@ -290,8 +318,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryEntrySelectedNumber")] public JoinDataComplete DirectoryEntrySelectedNumber =
|
[JoinName("DirectoryEntrySelectedNumber")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 357, JoinSpan = 1},
|
public JoinDataComplete DirectoryEntrySelectedNumber =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 357, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Selected Directory Entry Number",
|
Description = "Selected Directory Entry Number",
|
||||||
|
|
@ -299,8 +328,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryFolderBack")] public JoinDataComplete DirectoryFolderBack =
|
[JoinName("DirectoryFolderBack")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 105, JoinSpan = 1},
|
public JoinDataComplete DirectoryFolderBack =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 105, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Go back one directory level",
|
Description = "Go back one directory level",
|
||||||
|
|
@ -308,8 +338,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryHasChanged")] public JoinDataComplete DirectoryHasChanged =
|
[JoinName("DirectoryHasChanged")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 103, JoinSpan = 1},
|
public JoinDataComplete DirectoryHasChanged =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 103, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory has changed FB",
|
Description = "Directory has changed FB",
|
||||||
|
|
@ -317,8 +348,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryIsRoot")] public JoinDataComplete DirectoryIsRoot =
|
[JoinName("DirectoryIsRoot")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 102, JoinSpan = 1},
|
public JoinDataComplete DirectoryIsRoot =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 102, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory is on Root FB",
|
Description = "Directory is on Root FB",
|
||||||
|
|
@ -326,8 +358,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryLineSelected")] public JoinDataComplete DirectoryLineSelected =
|
[JoinName("DirectoryLineSelected")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 101, JoinSpan = 1},
|
public JoinDataComplete DirectoryLineSelected =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 101, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Line Selected FB",
|
Description = "Directory Line Selected FB",
|
||||||
|
|
@ -335,8 +368,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryRoot")] public JoinDataComplete DirectoryRoot =
|
[JoinName("DirectoryRoot")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 104, JoinSpan = 1},
|
public JoinDataComplete DirectoryRoot =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 104, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Go to Directory Root",
|
Description = "Go to Directory Root",
|
||||||
|
|
@ -344,8 +378,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectoryRowCount")] public JoinDataComplete DirectoryRowCount =
|
[JoinName("DirectoryRowCount")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 101, JoinSpan = 1},
|
public JoinDataComplete DirectoryRowCount =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 101, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Row Count FB",
|
Description = "Directory Row Count FB",
|
||||||
|
|
@ -353,8 +388,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectorySearchBusy")] public JoinDataComplete DirectorySearchBusy =
|
[JoinName("DirectorySearchBusy")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 100, JoinSpan = 1},
|
public JoinDataComplete DirectorySearchBusy =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 100, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Search Busy FB",
|
Description = "Directory Search Busy FB",
|
||||||
|
|
@ -362,8 +398,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectorySearchString")] public JoinDataComplete DirectorySearchString =
|
[JoinName("DirectorySearchString")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 100, JoinSpan = 1},
|
public JoinDataComplete DirectorySearchString =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 100, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Search String",
|
Description = "Directory Search String",
|
||||||
|
|
@ -371,8 +408,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectorySelectRow")] public JoinDataComplete DirectorySelectRow =
|
[JoinName("DirectorySelectRow")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 101, JoinSpan = 1},
|
public JoinDataComplete DirectorySelectRow =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 101, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Directory Select Row",
|
Description = "Directory Select Row",
|
||||||
|
|
@ -380,8 +418,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("DirectorySelectedFolderName")] public JoinDataComplete DirectorySelectedFolderName =
|
[JoinName("DirectorySelectedFolderName")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 358, JoinSpan = 1},
|
public JoinDataComplete DirectorySelectedFolderName =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 358, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Selected Directory Folder Name",
|
Description = "Selected Directory Folder Name",
|
||||||
|
|
@ -389,8 +428,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("0")] public JoinDataComplete Dtmf0 =
|
[JoinName("0")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 20, JoinSpan = 1},
|
public JoinDataComplete Dtmf0 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 20, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 0",
|
Description = "DTMF 0",
|
||||||
|
|
@ -398,8 +438,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("1")] public JoinDataComplete Dtmf1 =
|
[JoinName("1")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 11, JoinSpan = 1},
|
public JoinDataComplete Dtmf1 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 11, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 1",
|
Description = "DTMF 1",
|
||||||
|
|
@ -407,8 +448,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("2")] public JoinDataComplete Dtmf2 =
|
[JoinName("2")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 12, JoinSpan = 1},
|
public JoinDataComplete Dtmf2 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 12, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 2",
|
Description = "DTMF 2",
|
||||||
|
|
@ -416,8 +458,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("3")] public JoinDataComplete Dtmf3 =
|
[JoinName("3")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 13, JoinSpan = 1},
|
public JoinDataComplete Dtmf3 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 13, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 3",
|
Description = "DTMF 3",
|
||||||
|
|
@ -425,8 +468,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("4")] public JoinDataComplete Dtmf4 =
|
[JoinName("4")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 14, JoinSpan = 1},
|
public JoinDataComplete Dtmf4 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 14, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 4",
|
Description = "DTMF 4",
|
||||||
|
|
@ -434,8 +478,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("5")] public JoinDataComplete Dtmf5 =
|
[JoinName("5")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 15, JoinSpan = 1},
|
public JoinDataComplete Dtmf5 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 15, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 5",
|
Description = "DTMF 5",
|
||||||
|
|
@ -443,8 +488,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("6")] public JoinDataComplete Dtmf6 =
|
[JoinName("6")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 16, JoinSpan = 1},
|
public JoinDataComplete Dtmf6 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 16, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 6",
|
Description = "DTMF 6",
|
||||||
|
|
@ -452,8 +498,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("7")] public JoinDataComplete Dtmf7 =
|
[JoinName("7")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 17, JoinSpan = 1},
|
public JoinDataComplete Dtmf7 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 17, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 7",
|
Description = "DTMF 7",
|
||||||
|
|
@ -461,8 +508,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("8")] public JoinDataComplete Dtmf8 =
|
[JoinName("8")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 18, JoinSpan = 1},
|
public JoinDataComplete Dtmf8 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 18, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 8",
|
Description = "DTMF 8",
|
||||||
|
|
@ -470,8 +518,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("9")] public JoinDataComplete Dtmf9 =
|
[JoinName("9")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 19, JoinSpan = 1},
|
public JoinDataComplete Dtmf9 =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 19, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF 9",
|
Description = "DTMF 9",
|
||||||
|
|
@ -479,8 +528,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("#")] public JoinDataComplete DtmfPound =
|
[JoinName("#")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 22, JoinSpan = 1},
|
public JoinDataComplete DtmfPound =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 22, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF #",
|
Description = "DTMF #",
|
||||||
|
|
@ -488,8 +538,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("*")] public JoinDataComplete DtmfStar =
|
[JoinName("*")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 21, JoinSpan = 1},
|
public JoinDataComplete DtmfStar =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 21, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "DTMF *",
|
Description = "DTMF *",
|
||||||
|
|
@ -497,8 +548,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("EndCall")] public JoinDataComplete EndCall =
|
[JoinName("EndCall")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 24, JoinSpan = 1},
|
public JoinDataComplete EndCall =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 24, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Hang Up",
|
Description = "Hang Up",
|
||||||
|
|
@ -506,8 +558,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("HookState")] public JoinDataComplete HookState =
|
[JoinName("HookState")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 31, JoinSpan = 1},
|
public JoinDataComplete HookState =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 31, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Hook State",
|
Description = "Current Hook State",
|
||||||
|
|
@ -515,8 +568,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("IncomingAnswer")] public JoinDataComplete IncomingAnswer =
|
[JoinName("IncomingAnswer")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 51, JoinSpan = 1},
|
public JoinDataComplete IncomingAnswer =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 51, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Answer Incoming Call",
|
Description = "Answer Incoming Call",
|
||||||
|
|
@ -524,8 +578,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("IncomingCall")] public JoinDataComplete IncomingCall =
|
[JoinName("IncomingCall")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 50, JoinSpan = 1},
|
public JoinDataComplete IncomingCall =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 50, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Incoming Call",
|
Description = "Incoming Call",
|
||||||
|
|
@ -533,8 +588,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("IncomingCallName")] public JoinDataComplete IncomingCallName =
|
[JoinName("IncomingCallName")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 51, JoinSpan = 1},
|
public JoinDataComplete IncomingCallName =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 51, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Incoming Call Name",
|
Description = "Incoming Call Name",
|
||||||
|
|
@ -542,8 +598,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("IncomingCallNumber")] public JoinDataComplete IncomingCallNumber =
|
[JoinName("IncomingCallNumber")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 52, JoinSpan = 1},
|
public JoinDataComplete IncomingCallNumber =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 52, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Incoming Call Number",
|
Description = "Incoming Call Number",
|
||||||
|
|
@ -551,8 +608,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("IncomingReject")] public JoinDataComplete IncomingReject =
|
[JoinName("IncomingReject")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 52, JoinSpan = 1},
|
public JoinDataComplete IncomingReject =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 52, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Reject Incoming Call",
|
Description = "Reject Incoming Call",
|
||||||
|
|
@ -561,8 +619,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
[JoinName("ManualDial")] public JoinDataComplete ManualDial =
|
[JoinName("ManualDial")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 71, JoinSpan = 1},
|
public JoinDataComplete ManualDial =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 71, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Dial manual string",
|
Description = "Dial manual string",
|
||||||
|
|
@ -570,8 +629,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("Meeting Count Fb")] public JoinDataComplete MeetingCount =
|
[JoinName("Meeting Count Fb")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 161, JoinSpan = 1},
|
public JoinDataComplete MeetingCount =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 161, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Meeting Count",
|
Description = "Meeting Count",
|
||||||
|
|
@ -579,8 +639,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("MicMuteOff")] public JoinDataComplete MicMuteOff =
|
[JoinName("MicMuteOff")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 172, JoinSpan = 1},
|
public JoinDataComplete MicMuteOff =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 172, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Mic Mute Off",
|
Description = "Mic Mute Off",
|
||||||
|
|
@ -588,8 +649,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("MicMuteOn")] public JoinDataComplete MicMuteOn =
|
[JoinName("MicMuteOn")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 171, JoinSpan = 1},
|
public JoinDataComplete MicMuteOn =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 171, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Mic Mute On",
|
Description = "Mic Mute On",
|
||||||
|
|
@ -597,8 +659,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("MicMuteToggle")] public JoinDataComplete MicMuteToggle =
|
[JoinName("MicMuteToggle")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 173, JoinSpan = 1},
|
public JoinDataComplete MicMuteToggle =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 173, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Mic Mute Toggle",
|
Description = "Mic Mute Toggle",
|
||||||
|
|
@ -606,8 +669,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("MinutesBeforeMeetingStart")] public JoinDataComplete MinutesBeforeMeetingStart =
|
[JoinName("MinutesBeforeMeetingStart")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 41, JoinSpan = 1},
|
public JoinDataComplete MinutesBeforeMeetingStart =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 41, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Minutes before meeting start that a meeting is joinable",
|
Description = "Minutes before meeting start that a meeting is joinable",
|
||||||
|
|
@ -615,8 +679,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("ParticipantCount")] public JoinDataComplete ParticipantCount =
|
[JoinName("ParticipantCount")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 151, JoinSpan = 1},
|
public JoinDataComplete ParticipantCount =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 151, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Current Participant Count",
|
Description = "Current Participant Count",
|
||||||
|
|
@ -624,8 +689,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("Schedule")] public JoinDataComplete Schedule =
|
[JoinName("Schedule")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 102, JoinSpan = 1},
|
public JoinDataComplete Schedule =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 102, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Schedule Data - XSIG",
|
Description = "Schedule Data - XSIG",
|
||||||
|
|
@ -633,8 +699,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("AutoShareWhileInCall")] public JoinDataComplete SourceShareAutoStart =
|
[JoinName("AutoShareWhileInCall")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 203, JoinSpan = 1},
|
public JoinDataComplete SourceShareAutoStart =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 203, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "When high, will autostart sharing when a call is joined",
|
Description = "When high, will autostart sharing when a call is joined",
|
||||||
|
|
@ -642,8 +709,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("SourceShareEnd")] public JoinDataComplete SourceShareEnd =
|
[JoinName("SourceShareEnd")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 202, JoinSpan = 1},
|
public JoinDataComplete SourceShareEnd =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 202, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Stop Sharing & Feedback",
|
Description = "Stop Sharing & Feedback",
|
||||||
|
|
@ -651,8 +719,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("SourceShareStart")] public JoinDataComplete SourceShareStart =
|
[JoinName("SourceShareStart")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 201, JoinSpan = 1},
|
public JoinDataComplete SourceShareStart =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 201, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Start Sharing & Feedback",
|
Description = "Start Sharing & Feedback",
|
||||||
|
|
@ -660,8 +729,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("RecievingContent")] public JoinDataComplete RecievingContent =
|
[JoinName("RecievingContent")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 204, JoinSpan = 1},
|
public JoinDataComplete RecievingContent =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 204, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Recieving content from the far end",
|
Description = "Recieving content from the far end",
|
||||||
|
|
@ -669,8 +739,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinCapabilities = eJoinCapabilities.ToSIMPL
|
JoinCapabilities = eJoinCapabilities.ToSIMPL
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("SelfviewPosition")] public JoinDataComplete SelfviewPosition =
|
[JoinName("SelfviewPosition")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 211, JoinSpan = 1},
|
public JoinDataComplete SelfviewPosition =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 211, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "advance selfview position",
|
Description = "advance selfview position",
|
||||||
|
|
@ -688,8 +759,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("SpeedDialStart")] public JoinDataComplete SpeedDialStart =
|
[JoinName("SpeedDialStart")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 41, JoinSpan = 4},
|
public JoinDataComplete SpeedDialStart =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 41, JoinSpan = 4 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Speed Dial",
|
Description = "Speed Dial",
|
||||||
|
|
@ -697,8 +769,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("UpdateMeetings")] public JoinDataComplete UpdateMeetings =
|
[JoinName("UpdateMeetings")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 160, JoinSpan = 1},
|
public JoinDataComplete UpdateMeetings =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 160, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Update Meetings",
|
Description = "Update Meetings",
|
||||||
|
|
@ -706,8 +779,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("VolumeDown")] public JoinDataComplete VolumeDown =
|
[JoinName("VolumeDown")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 175, JoinSpan = 1},
|
public JoinDataComplete VolumeDown =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 175, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Volume Down",
|
Description = "Volume Down",
|
||||||
|
|
@ -715,8 +789,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("VolumeLevel")] public JoinDataComplete VolumeLevel =
|
[JoinName("VolumeLevel")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 174, JoinSpan = 1},
|
public JoinDataComplete VolumeLevel =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 174, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Volume Level",
|
Description = "Volume Level",
|
||||||
|
|
@ -724,8 +799,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("VolumeMuteOff")] public JoinDataComplete VolumeMuteOff =
|
[JoinName("VolumeMuteOff")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 177, JoinSpan = 1},
|
public JoinDataComplete VolumeMuteOff =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 177, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Volume Mute Off",
|
Description = "Volume Mute Off",
|
||||||
|
|
@ -733,8 +809,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("VolumeMuteOn")] public JoinDataComplete VolumeMuteOn =
|
[JoinName("VolumeMuteOn")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 176, JoinSpan = 1},
|
public JoinDataComplete VolumeMuteOn =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 176, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Volume Mute On",
|
Description = "Volume Mute On",
|
||||||
|
|
@ -742,8 +819,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("VolumeMuteToggle")] public JoinDataComplete VolumeMuteToggle =
|
[JoinName("VolumeMuteToggle")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 178, JoinSpan = 1},
|
public JoinDataComplete VolumeMuteToggle =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 178, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Volume Mute Toggle",
|
Description = "Volume Mute Toggle",
|
||||||
|
|
@ -751,8 +829,9 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Digital
|
JoinType = eJoinType.Digital
|
||||||
});
|
});
|
||||||
|
|
||||||
[JoinName("VolumeUp")] public JoinDataComplete VolumeUp =
|
[JoinName("VolumeUp")]
|
||||||
new JoinDataComplete(new JoinData {JoinNumber = 174, JoinSpan = 1},
|
public JoinDataComplete VolumeUp =
|
||||||
|
new JoinDataComplete(new JoinData { JoinNumber = 174, JoinSpan = 1 },
|
||||||
new JoinMetadata
|
new JoinMetadata
|
||||||
{
|
{
|
||||||
Description = "Volume Up",
|
Description = "Volume Up",
|
||||||
|
|
@ -800,7 +879,26 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
JoinType = eJoinType.Serial
|
JoinType = eJoinType.Serial
|
||||||
});
|
});
|
||||||
|
|
||||||
public VideoCodecControllerJoinMap(uint joinStart) : base(joinStart, typeof (VideoCodecControllerJoinMap))
|
public VideoCodecControllerJoinMap(uint joinStart)
|
||||||
|
: base(joinStart, typeof(VideoCodecControllerJoinMap))
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public VideoCodecControllerJoinMap(uint joinStart, Type type)
|
||||||
|
: base(joinStart, type)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Bridges.JoinMaps")]
|
||||||
|
public class VideoCodecControllerJoinMap : PepperDash.Essentials.Core.Bridges.JoinMaps.VideoCodecControllerJoinMap
|
||||||
|
{
|
||||||
|
|
||||||
|
public VideoCodecControllerJoinMap(uint joinStart) : this(joinStart, typeof (VideoCodecControllerJoinMap))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
using System;
|
||||||
|
|
||||||
|
namespace PepperDash.Essentials.Core.DeviceTypeInterfaces
|
||||||
{
|
{
|
||||||
public interface IHasBranding
|
public interface IHasBranding
|
||||||
{
|
{
|
||||||
|
|
@ -6,3 +8,12 @@
|
||||||
void InitializeBranding(string roomKey);
|
void InitializeBranding(string roomKey);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.DeviceTypeInterfaces")]
|
||||||
|
public interface IHasBranding:PepperDash.Essentials.Core.DeviceTypeInterfaces.IHasBranding
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
using PepperDash.Essentials.Core;
|
using System;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
namespace PepperDash.Essentials.Core.DeviceTypeInterfaces
|
||||||
{
|
{
|
||||||
public interface IHasPhoneDialing
|
public interface IHasPhoneDialing
|
||||||
{
|
{
|
||||||
|
|
@ -12,3 +12,11 @@ namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
void SendDtmfToPhone(string digit);
|
void SendDtmfToPhone(string digit);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.DeviceTypeInterfaces")]
|
||||||
|
public interface IHasPhoneDialing:PepperDash.Essentials.Core.DeviceTypeInterfaces.IHasPhoneDialing
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
namespace PepperDash.Essentials.Core.DeviceTypeInterfaces
|
||||||
{
|
{
|
||||||
public interface ILanguageDefinition
|
public interface ILanguageDefinition
|
||||||
{
|
{
|
||||||
|
|
@ -16,3 +16,11 @@ namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
List<LanguageLabel> RoomNames { get; set; }
|
List<LanguageLabel> RoomNames { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.DeviceTypeInterfaces")]
|
||||||
|
public interface ILanguageDefinition:PepperDash.Essentials.Core.DeviceTypeInterfaces.ILanguageDefinition
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
namespace PepperDash.Essentials.Core.DeviceTypeInterfaces
|
||||||
{
|
{
|
||||||
|
|
||||||
public interface ILanguageProvider
|
public interface ILanguageProvider
|
||||||
{
|
{
|
||||||
ILanguageDefinition CurrentLanguage { get; set; }
|
ILanguageDefinition CurrentLanguage { get; set; }
|
||||||
|
|
@ -11,3 +11,12 @@ namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.DeviceTypeInterfaces")]
|
||||||
|
public interface ILanguageProvider:PepperDash.Essentials.Core.DeviceTypeInterfaces.ILanguageProvider
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
using PepperDash.Core;
|
using System;
|
||||||
|
using PepperDash.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
namespace PepperDash.Essentials.Core.DeviceTypeInterfaces
|
||||||
{
|
{
|
||||||
public class LanguageLabel
|
public class LanguageLabel
|
||||||
{
|
{
|
||||||
|
|
@ -10,3 +11,11 @@ namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
public uint JoinNumber { get; set; }
|
public uint JoinNumber { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.DeviceTypeInterfaces
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.DeviceTypeInterfaces")]
|
||||||
|
public class LanguageLabel: PepperDash.Essentials.Core.DeviceTypeInterfaces.LanguageLabel
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -7,7 +7,7 @@ using PepperDash.Essentials.Core;
|
||||||
using PepperDash.Essentials.Core.Bridges;
|
using PepperDash.Essentials.Core.Bridges;
|
||||||
using PepperDash.Essentials.Core.Config;
|
using PepperDash.Essentials.Core.Config;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Devices
|
namespace PepperDash.Essentials.Core.Devices
|
||||||
{
|
{
|
||||||
public class GenericIrController: EssentialsBridgeableDevice
|
public class GenericIrController: EssentialsBridgeableDevice
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -67,13 +67,13 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static void AddFactoryForType(string typeName, Func<DeviceConfig, IKeyed> method)
|
public static void AddFactoryForType(string typeName, Func<DeviceConfig, IKeyed> method)
|
||||||
{
|
{
|
||||||
Debug.Console(0, Debug.ErrorLogLevel.Notice, "Adding factory method for type '{0}'", typeName);
|
Debug.Console(1, Debug.ErrorLogLevel.Notice, "Adding factory method for type '{0}'", typeName);
|
||||||
DeviceFactory.FactoryMethods.Add(typeName, new DeviceFactoryWrapper() { FactoryMethod = method});
|
DeviceFactory.FactoryMethods.Add(typeName, new DeviceFactoryWrapper() { FactoryMethod = method});
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void AddFactoryForType(string typeName, string description, CType cType, Func<DeviceConfig, IKeyed> method)
|
public static void AddFactoryForType(string typeName, string description, CType cType, Func<DeviceConfig, IKeyed> method)
|
||||||
{
|
{
|
||||||
Debug.Console(0, Debug.ErrorLogLevel.Notice, "Adding factory method for type '{0}'", typeName);
|
Debug.Console(1, Debug.ErrorLogLevel.Notice, "Adding factory method for type '{0}'", typeName);
|
||||||
|
|
||||||
if(FactoryMethods.ContainsKey(typeName))
|
if(FactoryMethods.ContainsKey(typeName))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,9 @@ using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using Crestron.SimplSharp;
|
using Crestron.SimplSharp;
|
||||||
|
using PepperDash.Essentials.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core
|
namespace PepperDash.Essentials.Core
|
||||||
{
|
{
|
||||||
public class IsReadyEventArgs : EventArgs
|
public class IsReadyEventArgs : EventArgs
|
||||||
{
|
{
|
||||||
|
|
@ -22,3 +23,19 @@ namespace PepperDash_Essentials_Core
|
||||||
bool IsReady { get; }
|
bool IsReady { get; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core")]
|
||||||
|
public class IsReadyEventArgs : PepperDash.Essentials.Core.IsReadyEventArgs
|
||||||
|
{
|
||||||
|
public IsReadyEventArgs(bool data) : base(data)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core")]
|
||||||
|
public interface IHasReady: PepperDash.Essentials.Core.IHasReady
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -10,9 +10,7 @@ using Crestron.SimplSharpPro.DeviceSupport;
|
||||||
|
|
||||||
|
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
using PepperDash.Essentials.Core;
|
|
||||||
using PepperDash.Essentials.Core.Config;
|
using PepperDash.Essentials.Core.Config;
|
||||||
using PepperDash_Essentials_Core;
|
|
||||||
|
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Core
|
namespace PepperDash.Essentials.Core
|
||||||
|
|
|
||||||
|
|
@ -233,8 +233,11 @@ namespace PepperDash.Essentials.Core
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (Debug.Level > 0)
|
||||||
|
{
|
||||||
PrintJoinMapInfo();
|
PrintJoinMapInfo();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Prints the join information to console
|
/// Prints the join information to console
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,9 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using Crestron.SimplSharp;
|
using Crestron.SimplSharp;
|
||||||
using Crestron.SimplSharpPro.DeviceSupport;
|
using Crestron.SimplSharpPro.DeviceSupport;
|
||||||
using Crestron.SimplSharpPro.GeneralIO;
|
using Crestron.SimplSharpPro.GeneralIO;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
using PepperDash.Essentials.Core;
|
|
||||||
using PepperDash.Essentials.Core.Config;
|
using PepperDash.Essentials.Core.Config;
|
||||||
using PepperDash.Essentials.Core.Bridges;
|
using PepperDash.Essentials.Core.Bridges;
|
||||||
|
|
||||||
|
|
@ -15,11 +11,11 @@ namespace PepperDash.Essentials.Core
|
||||||
{
|
{
|
||||||
[Description("Wrapper class for Single Technology GLS Occupancy Sensors")]
|
[Description("Wrapper class for Single Technology GLS Occupancy Sensors")]
|
||||||
[ConfigSnippet("\"properties\": {\"control\": {\"method\": \"cresnet\",\"cresnetId\": \"97\"},\"enablePir\": true,\"enableLedFlash\": true,\"enableRawStates\":true,\"remoteTimeout\": 30,\"internalPhotoSensorMinChange\": 0,\"externalPhotoSensorMinChange\": 0}")]
|
[ConfigSnippet("\"properties\": {\"control\": {\"method\": \"cresnet\",\"cresnetId\": \"97\"},\"enablePir\": true,\"enableLedFlash\": true,\"enableRawStates\":true,\"remoteTimeout\": 30,\"internalPhotoSensorMinChange\": 0,\"externalPhotoSensorMinChange\": 0}")]
|
||||||
public class GlsOccupancySensorBaseController : CrestronGenericBridgeableBaseDevice, IOccupancyStatusProvider
|
public abstract class GlsOccupancySensorBaseController : CrestronGenericBridgeableBaseDevice, IOccupancyStatusProvider
|
||||||
{
|
{
|
||||||
public GlsOccupancySensorPropertiesConfig PropertiesConfig { get; private set; }
|
public GlsOccupancySensorPropertiesConfig PropertiesConfig { get; private set; }
|
||||||
|
|
||||||
public GlsOccupancySensorBase OccSensor { get; private set; }
|
protected GlsOccupancySensorBase OccSensor;
|
||||||
|
|
||||||
public BoolFeedback RoomIsOccupiedFeedback { get; private set; }
|
public BoolFeedback RoomIsOccupiedFeedback { get; private set; }
|
||||||
|
|
||||||
|
|
@ -58,44 +54,12 @@ namespace PepperDash.Essentials.Core
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public GlsOccupancySensorBaseController(string key, Func<DeviceConfig, GlsOccupancySensorBase> preActivationFunc,
|
protected GlsOccupancySensorBaseController(string key, DeviceConfig config)
|
||||||
DeviceConfig config)
|
: this(key, config.Name, config)
|
||||||
: base(key, config.Name)
|
|
||||||
{
|
{
|
||||||
var props = config.Properties.ToObject<GlsOccupancySensorPropertiesConfig>();
|
|
||||||
|
|
||||||
if (props != null)
|
|
||||||
{
|
|
||||||
PropertiesConfig = props;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Debug.Console(1, this, "props are null. Unable to deserialize into GlsOccupancySensorPropertiesConfig");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
AddPreActivationAction(() =>
|
protected GlsOccupancySensorBaseController(string key, string name, DeviceConfig config)
|
||||||
{
|
|
||||||
OccSensor = preActivationFunc(config);
|
|
||||||
|
|
||||||
RegisterCrestronGenericBase(OccSensor);
|
|
||||||
|
|
||||||
RegisterGlsOdtSensorBaseController(OccSensor);
|
|
||||||
|
|
||||||
});
|
|
||||||
|
|
||||||
AddPostActivationAction(() =>
|
|
||||||
{
|
|
||||||
OccSensor.OnlineStatusChange += (o, a) =>
|
|
||||||
{
|
|
||||||
if (a.DeviceOnLine)
|
|
||||||
{
|
|
||||||
ApplySettingsToSensorFromConfig();
|
|
||||||
}
|
|
||||||
};
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
public GlsOccupancySensorBaseController(string key, string name, DeviceConfig config)
|
|
||||||
: base(key, name)
|
: base(key, name)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
@ -183,7 +147,7 @@ namespace PepperDash.Essentials.Core
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void RegisterGlsOdtSensorBaseController(GlsOccupancySensorBase occSensor)
|
protected void RegisterGlsOccupancySensorBaseController(GlsOccupancySensorBase occSensor)
|
||||||
{
|
{
|
||||||
OccSensor = occSensor;
|
OccSensor = occSensor;
|
||||||
|
|
||||||
|
|
@ -253,8 +217,8 @@ namespace PepperDash.Essentials.Core
|
||||||
|
|
||||||
switch (args.EventId)
|
switch (args.EventId)
|
||||||
{
|
{
|
||||||
case Crestron.SimplSharpPro.GeneralIO.GlsOccupancySensorBase.RoomVacantFeedbackEventId:
|
case GlsOccupancySensorBase.RoomVacantFeedbackEventId:
|
||||||
case Crestron.SimplSharpPro.GeneralIO.GlsOccupancySensorBase.RoomOccupiedFeedbackEventId:
|
case GlsOccupancySensorBase.RoomOccupiedFeedbackEventId:
|
||||||
Debug.Console(1, this, "Occupancy State: {0}", OccSensor.OccupancyDetectedFeedback.BoolValue);
|
Debug.Console(1, this, "Occupancy State: {0}", OccSensor.OccupancyDetectedFeedback.BoolValue);
|
||||||
RoomIsOccupiedFeedback.FireUpdate();
|
RoomIsOccupiedFeedback.FireUpdate();
|
||||||
break;
|
break;
|
||||||
|
|
@ -306,53 +270,29 @@ namespace PepperDash.Essentials.Core
|
||||||
{
|
{
|
||||||
Debug.Console(1, this, "Setting EnablePir to: {0}", state);
|
Debug.Console(1, this, "Setting EnablePir to: {0}", state);
|
||||||
|
|
||||||
if (state)
|
|
||||||
{
|
|
||||||
OccSensor.EnablePir.BoolValue = state;
|
OccSensor.EnablePir.BoolValue = state;
|
||||||
OccSensor.DisablePir.BoolValue = !state;
|
OccSensor.DisablePir.BoolValue = !state;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
OccSensor.EnablePir.BoolValue = state;
|
|
||||||
OccSensor.DisablePir.BoolValue = !state;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Enables or disables the LED Flash
|
/// Enables or disables the LED Flash
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="state"></param>
|
/// <param name="state"></param>
|
||||||
public void SetLedFlashEnable(bool state)
|
public void SetLedFlashEnable(bool state)
|
||||||
{
|
|
||||||
if (state)
|
|
||||||
{
|
{
|
||||||
OccSensor.EnableLedFlash.BoolValue = state;
|
OccSensor.EnableLedFlash.BoolValue = state;
|
||||||
OccSensor.DisableLedFlash.BoolValue = !state;
|
OccSensor.DisableLedFlash.BoolValue = !state;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
OccSensor.EnableLedFlash.BoolValue = state;
|
|
||||||
OccSensor.DisableLedFlash.BoolValue = !state;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Enables or disables short timeout based on state
|
/// Enables or disables short timeout based on state
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="state"></param>
|
/// <param name="state"></param>
|
||||||
public void SetShortTimeoutState(bool state)
|
public void SetShortTimeoutState(bool state)
|
||||||
{
|
|
||||||
if (state)
|
|
||||||
{
|
{
|
||||||
OccSensor.EnableShortTimeout.BoolValue = state;
|
OccSensor.EnableShortTimeout.BoolValue = state;
|
||||||
OccSensor.DisableShortTimeout.BoolValue = !state;
|
OccSensor.DisableShortTimeout.BoolValue = !state;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
OccSensor.EnableShortTimeout.BoolValue = state;
|
|
||||||
OccSensor.DisableShortTimeout.BoolValue = !state;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void IncrementPirSensitivityInOccupiedState(bool pressRelease)
|
public void IncrementPirSensitivityInOccupiedState(bool pressRelease)
|
||||||
{
|
{
|
||||||
|
|
@ -374,14 +314,40 @@ namespace PepperDash.Essentials.Core
|
||||||
OccSensor.DecrementPirSensitivityInVacantState.BoolValue = pressRelease;
|
OccSensor.DecrementPirSensitivityInVacantState.BoolValue = pressRelease;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Pulse ForceOccupied on the sensor for .5 seconds
|
||||||
|
/// </summary>
|
||||||
public void ForceOccupied()
|
public void ForceOccupied()
|
||||||
{
|
{
|
||||||
OccSensor.ForceOccupied.BoolValue = true;
|
CrestronInvoke.BeginInvoke((o) =>
|
||||||
|
{
|
||||||
|
ForceOccupied(true);
|
||||||
|
CrestronEnvironment.Sleep(500);
|
||||||
|
ForceOccupied(false);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void ForceOccupied(bool value)
|
||||||
|
{
|
||||||
|
OccSensor.ForceOccupied.BoolValue = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Pulse ForceVacant on the sensor for .5 seconds
|
||||||
|
/// </summary>
|
||||||
public void ForceVacant()
|
public void ForceVacant()
|
||||||
{
|
{
|
||||||
OccSensor.ForceVacant.BoolValue = true;
|
CrestronInvoke.BeginInvoke((o) =>
|
||||||
|
{
|
||||||
|
ForceVacant(true);
|
||||||
|
CrestronEnvironment.Sleep(500);
|
||||||
|
ForceVacant(false);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
public void ForceVacant(bool value)
|
||||||
|
{
|
||||||
|
OccSensor.ForceVacant.BoolValue = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void EnableRawStates(bool state)
|
public void EnableRawStates(bool state)
|
||||||
|
|
@ -409,7 +375,6 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Method to print current occ settings to console.
|
/// Method to print current occ settings to console.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="key"></param>
|
|
||||||
public virtual void GetSettings()
|
public virtual void GetSettings()
|
||||||
{
|
{
|
||||||
var dash = new string('*', 50);
|
var dash = new string('*', 50);
|
||||||
|
|
@ -454,7 +419,6 @@ namespace PepperDash.Essentials.Core
|
||||||
|
|
||||||
Debug.Console(1, occController, "Linking to Trilist '{0}'", trilist.ID.ToString("X"));
|
Debug.Console(1, occController, "Linking to Trilist '{0}'", trilist.ID.ToString("X"));
|
||||||
|
|
||||||
#region Single and Dual Sensor Stuff
|
|
||||||
occController.IsOnline.LinkInputSig(trilist.BooleanInput[joinMap.IsOnline.JoinNumber]);
|
occController.IsOnline.LinkInputSig(trilist.BooleanInput[joinMap.IsOnline.JoinNumber]);
|
||||||
trilist.StringInput[joinMap.Name.JoinNumber].StringValue = occController.Name;
|
trilist.StringInput[joinMap.Name.JoinNumber].StringValue = occController.Name;
|
||||||
|
|
||||||
|
|
@ -466,11 +430,69 @@ namespace PepperDash.Essentials.Core
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// Occupied status
|
LinkSingleTechSensorToApi(occController, trilist, joinMap);
|
||||||
trilist.SetSigTrueAction(joinMap.ForceOccupied.JoinNumber, occController.ForceOccupied);
|
|
||||||
trilist.SetSigTrueAction(joinMap.ForceVacant.JoinNumber, occController.ForceVacant);
|
LinkDualTechSensorToApi(occController, trilist, joinMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void LinkDualTechSensorToApi(GlsOccupancySensorBaseController occController, BasicTriList trilist,
|
||||||
|
GlsOccupancySensorBaseJoinMap joinMap)
|
||||||
|
{
|
||||||
|
var odtOccController = occController as GlsOdtOccupancySensorController;
|
||||||
|
|
||||||
|
if (odtOccController == null)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// OR When Vacated
|
||||||
|
trilist.SetBoolSigAction(joinMap.OrWhenVacated.JoinNumber, odtOccController.SetOrWhenVacatedState);
|
||||||
|
odtOccController.OrWhenVacatedFeedback.LinkInputSig(trilist.BooleanInput[joinMap.OrWhenVacated.JoinNumber]);
|
||||||
|
|
||||||
|
// AND When Vacated
|
||||||
|
trilist.SetBoolSigAction(joinMap.AndWhenVacated.JoinNumber, odtOccController.SetAndWhenVacatedState);
|
||||||
|
odtOccController.AndWhenVacatedFeedback.LinkInputSig(trilist.BooleanInput[joinMap.AndWhenVacated.JoinNumber]);
|
||||||
|
|
||||||
|
// Ultrasonic A Sensor
|
||||||
|
trilist.SetSigTrueAction(joinMap.EnableUsA.JoinNumber, () => odtOccController.SetUsAEnable(true));
|
||||||
|
trilist.SetSigTrueAction(joinMap.DisableUsA.JoinNumber, () => odtOccController.SetUsAEnable(false));
|
||||||
|
odtOccController.UltrasonicAEnabledFeedback.LinkInputSig(trilist.BooleanInput[joinMap.EnableUsA.JoinNumber]);
|
||||||
|
|
||||||
|
// Ultrasonic B Sensor
|
||||||
|
trilist.SetSigTrueAction(joinMap.EnableUsB.JoinNumber, () => odtOccController.SetUsBEnable(true));
|
||||||
|
trilist.SetSigTrueAction(joinMap.DisableUsB.JoinNumber, () => odtOccController.SetUsBEnable(false));
|
||||||
|
odtOccController.UltrasonicBEnabledFeedback.LinkInputSig(trilist.BooleanInput[joinMap.EnableUsB.JoinNumber]);
|
||||||
|
|
||||||
|
// US Sensitivity in Occupied State
|
||||||
|
trilist.SetBoolSigAction(joinMap.IncrementUsInOccupiedState.JoinNumber,
|
||||||
|
odtOccController.IncrementUsSensitivityInOccupiedState);
|
||||||
|
trilist.SetBoolSigAction(joinMap.DecrementUsInOccupiedState.JoinNumber,
|
||||||
|
odtOccController.DecrementUsSensitivityInOccupiedState);
|
||||||
|
odtOccController.UltrasonicSensitivityInOccupiedStateFeedback.LinkInputSig(
|
||||||
|
trilist.UShortInput[joinMap.UsSensitivityInOccupiedState.JoinNumber]);
|
||||||
|
|
||||||
|
// US Sensitivity in Vacant State
|
||||||
|
trilist.SetBoolSigAction(joinMap.IncrementUsInVacantState.JoinNumber,
|
||||||
|
odtOccController.IncrementUsSensitivityInVacantState);
|
||||||
|
trilist.SetBoolSigAction(joinMap.DecrementUsInVacantState.JoinNumber,
|
||||||
|
odtOccController.DecrementUsSensitivityInVacantState);
|
||||||
|
odtOccController.UltrasonicSensitivityInVacantStateFeedback.LinkInputSig(
|
||||||
|
trilist.UShortInput[joinMap.UsSensitivityInVacantState.JoinNumber]);
|
||||||
|
|
||||||
|
//Sensor Raw States
|
||||||
|
odtOccController.RawOccupancyPirFeedback.LinkInputSig(
|
||||||
|
trilist.BooleanInput[joinMap.RawOccupancyPirFeedback.JoinNumber]);
|
||||||
|
odtOccController.RawOccupancyUsFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RawOccupancyUsFeedback.JoinNumber]);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void LinkSingleTechSensorToApi(GlsOccupancySensorBaseController occController, BasicTriList trilist,
|
||||||
|
GlsOccupancySensorBaseJoinMap joinMap)
|
||||||
|
{
|
||||||
|
// Occupied status
|
||||||
|
trilist.SetBoolSigAction(joinMap.ForceOccupied.JoinNumber, occController.ForceOccupied);
|
||||||
|
trilist.SetBoolSigAction(joinMap.ForceVacant.JoinNumber, occController.ForceVacant);
|
||||||
occController.RoomIsOccupiedFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RoomOccupiedFeedback.JoinNumber]);
|
occController.RoomIsOccupiedFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RoomOccupiedFeedback.JoinNumber]);
|
||||||
occController.RoomIsOccupiedFeedback.LinkComplementInputSig(trilist.BooleanInput[joinMap.RoomVacantFeedback.JoinNumber]);
|
occController.RoomIsOccupiedFeedback.LinkComplementInputSig(
|
||||||
|
trilist.BooleanInput[joinMap.RoomVacantFeedback.JoinNumber]);
|
||||||
occController.RawOccupancyFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RawOccupancyFeedback.JoinNumber]);
|
occController.RawOccupancyFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RawOccupancyFeedback.JoinNumber]);
|
||||||
trilist.SetBoolSigAction(joinMap.EnableRawStates.JoinNumber, occController.EnableRawStates);
|
trilist.SetBoolSigAction(joinMap.EnableRawStates.JoinNumber, occController.EnableRawStates);
|
||||||
|
|
||||||
|
|
@ -495,101 +517,20 @@ namespace PepperDash.Essentials.Core
|
||||||
occController.PirSensorEnabledFeedback.LinkInputSig(trilist.BooleanInput[joinMap.EnablePir.JoinNumber]);
|
occController.PirSensorEnabledFeedback.LinkInputSig(trilist.BooleanInput[joinMap.EnablePir.JoinNumber]);
|
||||||
|
|
||||||
// PIR Sensitivity in Occupied State
|
// PIR Sensitivity in Occupied State
|
||||||
trilist.SetBoolSigAction(joinMap.IncrementPirInOccupiedState.JoinNumber, occController.IncrementPirSensitivityInOccupiedState);
|
trilist.SetBoolSigAction(joinMap.IncrementPirInOccupiedState.JoinNumber,
|
||||||
trilist.SetBoolSigAction(joinMap.DecrementPirInOccupiedState.JoinNumber, occController.DecrementPirSensitivityInOccupiedState);
|
occController.IncrementPirSensitivityInOccupiedState);
|
||||||
occController.PirSensitivityInOccupiedStateFeedback.LinkInputSig(trilist.UShortInput[joinMap.PirSensitivityInOccupiedState.JoinNumber]);
|
trilist.SetBoolSigAction(joinMap.DecrementPirInOccupiedState.JoinNumber,
|
||||||
|
occController.DecrementPirSensitivityInOccupiedState);
|
||||||
|
occController.PirSensitivityInOccupiedStateFeedback.LinkInputSig(
|
||||||
|
trilist.UShortInput[joinMap.PirSensitivityInOccupiedState.JoinNumber]);
|
||||||
|
|
||||||
// PIR Sensitivity in Vacant State
|
// PIR Sensitivity in Vacant State
|
||||||
trilist.SetBoolSigAction(joinMap.IncrementPirInVacantState.JoinNumber, occController.IncrementPirSensitivityInVacantState);
|
trilist.SetBoolSigAction(joinMap.IncrementPirInVacantState.JoinNumber,
|
||||||
trilist.SetBoolSigAction(joinMap.DecrementPirInVacantState.JoinNumber, occController.DecrementPirSensitivityInVacantState);
|
occController.IncrementPirSensitivityInVacantState);
|
||||||
occController.PirSensitivityInVacantStateFeedback.LinkInputSig(trilist.UShortInput[joinMap.PirSensitivityInVacantState.JoinNumber]);
|
trilist.SetBoolSigAction(joinMap.DecrementPirInVacantState.JoinNumber,
|
||||||
#endregion
|
occController.DecrementPirSensitivityInVacantState);
|
||||||
|
occController.PirSensitivityInVacantStateFeedback.LinkInputSig(
|
||||||
#region Dual Technology Sensor Stuff
|
trilist.UShortInput[joinMap.PirSensitivityInVacantState.JoinNumber]);
|
||||||
var odtOccController = occController as GlsOdtOccupancySensorController;
|
|
||||||
|
|
||||||
if (odtOccController == null) return;
|
|
||||||
// OR When Vacated
|
|
||||||
trilist.SetBoolSigAction(joinMap.OrWhenVacated.JoinNumber, odtOccController.SetOrWhenVacatedState);
|
|
||||||
odtOccController.OrWhenVacatedFeedback.LinkInputSig(trilist.BooleanInput[joinMap.OrWhenVacated.JoinNumber]);
|
|
||||||
|
|
||||||
// AND When Vacated
|
|
||||||
trilist.SetBoolSigAction(joinMap.AndWhenVacated.JoinNumber, odtOccController.SetAndWhenVacatedState);
|
|
||||||
odtOccController.AndWhenVacatedFeedback.LinkInputSig(trilist.BooleanInput[joinMap.AndWhenVacated.JoinNumber]);
|
|
||||||
|
|
||||||
// Ultrasonic A Sensor
|
|
||||||
trilist.SetSigTrueAction(joinMap.EnableUsA.JoinNumber, () => odtOccController.SetUsAEnable(true));
|
|
||||||
trilist.SetSigTrueAction(joinMap.DisableUsA.JoinNumber, () => odtOccController.SetUsAEnable(false));
|
|
||||||
odtOccController.UltrasonicAEnabledFeedback.LinkInputSig(trilist.BooleanInput[joinMap.EnableUsA.JoinNumber]);
|
|
||||||
|
|
||||||
// Ultrasonic B Sensor
|
|
||||||
trilist.SetSigTrueAction(joinMap.EnableUsB.JoinNumber, () => odtOccController.SetUsBEnable(true));
|
|
||||||
trilist.SetSigTrueAction(joinMap.DisableUsB.JoinNumber, () => odtOccController.SetUsBEnable(false));
|
|
||||||
odtOccController.UltrasonicAEnabledFeedback.LinkInputSig(trilist.BooleanInput[joinMap.EnableUsB.JoinNumber]);
|
|
||||||
|
|
||||||
// US Sensitivity in Occupied State
|
|
||||||
trilist.SetBoolSigAction(joinMap.IncrementUsInOccupiedState.JoinNumber, odtOccController.IncrementUsSensitivityInOccupiedState);
|
|
||||||
trilist.SetBoolSigAction(joinMap.DecrementUsInOccupiedState.JoinNumber, odtOccController.DecrementUsSensitivityInOccupiedState);
|
|
||||||
odtOccController.UltrasonicSensitivityInOccupiedStateFeedback.LinkInputSig(trilist.UShortInput[joinMap.UsSensitivityInOccupiedState.JoinNumber]);
|
|
||||||
|
|
||||||
// US Sensitivity in Vacant State
|
|
||||||
trilist.SetBoolSigAction(joinMap.IncrementUsInVacantState.JoinNumber, odtOccController.IncrementUsSensitivityInVacantState);
|
|
||||||
trilist.SetBoolSigAction(joinMap.DecrementUsInVacantState.JoinNumber, odtOccController.DecrementUsSensitivityInVacantState);
|
|
||||||
odtOccController.UltrasonicSensitivityInVacantStateFeedback.LinkInputSig(trilist.UShortInput[joinMap.UsSensitivityInVacantState.JoinNumber]);
|
|
||||||
|
|
||||||
//Sensor Raw States
|
|
||||||
odtOccController.RawOccupancyPirFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RawOccupancyPirFeedback.JoinNumber]);
|
|
||||||
odtOccController.RawOccupancyUsFeedback.LinkInputSig(trilist.BooleanInput[joinMap.RawOccupancyUsFeedback.JoinNumber]);
|
|
||||||
|
|
||||||
#endregion
|
|
||||||
}
|
|
||||||
|
|
||||||
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
|
||||||
{
|
|
||||||
LinkOccSensorToApi(this, trilist, joinStart, joinMapKey, bridge);
|
|
||||||
}
|
|
||||||
|
|
||||||
#region PreActivation
|
|
||||||
|
|
||||||
private static GlsOirCCn GetGlsOirCCn(DeviceConfig dc)
|
|
||||||
{
|
|
||||||
var control = CommFactory.GetControlPropertiesConfig(dc);
|
|
||||||
var cresnetId = control.CresnetIdInt;
|
|
||||||
var branchId = control.ControlPortNumber;
|
|
||||||
var parentKey = string.IsNullOrEmpty(control.ControlPortDevKey) ? "processor" : control.ControlPortDevKey;
|
|
||||||
|
|
||||||
if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase))
|
|
||||||
{
|
|
||||||
Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn", parentKey);
|
|
||||||
return new GlsOirCCn(cresnetId, Global.ControlSystem);
|
|
||||||
}
|
|
||||||
var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as IHasCresnetBranches;
|
|
||||||
|
|
||||||
if (cresnetBridge != null)
|
|
||||||
{
|
|
||||||
Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn", parentKey);
|
|
||||||
return new GlsOirCCn(cresnetId, cresnetBridge.CresnetBranches[branchId]);
|
|
||||||
}
|
|
||||||
Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey);
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
#endregion
|
|
||||||
|
|
||||||
public class GlsOccupancySensorBaseControllerFactory : EssentialsDeviceFactory<GlsOccupancySensorBaseController>
|
|
||||||
{
|
|
||||||
public GlsOccupancySensorBaseControllerFactory()
|
|
||||||
{
|
|
||||||
TypeNames = new List<string>() { "glsoirccn" };
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
public override EssentialsDevice BuildDevice(DeviceConfig dc)
|
|
||||||
{
|
|
||||||
Debug.Console(1, "Factory Attempting to create new GlsOccupancySensorBaseController Device");
|
|
||||||
|
|
||||||
return new GlsOccupancySensorBaseController(dc.Key, GetGlsOirCCn, dc);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,10 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using Crestron.SimplSharp;
|
using Crestron.SimplSharp;
|
||||||
using Crestron.SimplSharpPro.DeviceSupport;
|
using Crestron.SimplSharpPro.DeviceSupport;
|
||||||
using Crestron.SimplSharpPro.GeneralIO;
|
using Crestron.SimplSharpPro.GeneralIO;
|
||||||
|
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
using PepperDash.Essentials.Core;
|
|
||||||
using PepperDash.Essentials.Core.Config;
|
using PepperDash.Essentials.Core.Config;
|
||||||
using PepperDash.Essentials.Core.Bridges;
|
using PepperDash.Essentials.Core.Bridges;
|
||||||
|
|
||||||
|
|
@ -17,7 +14,7 @@ namespace PepperDash.Essentials.Core
|
||||||
[ConfigSnippet("\"properties\": {\"control\": {\"method\": \"cresnet\",\"cresnetId\": \"97\"},\"enablePir\": true,\"enableLedFlash\": true,\"enableRawStates\":true,\"remoteTimeout\": 30,\"internalPhotoSensorMinChange\": 0,\"externalPhotoSensorMinChange\": 0,\"enableUsA\": true,\"enableUsB\": true,\"orWhenVacatedState\": true}")]
|
[ConfigSnippet("\"properties\": {\"control\": {\"method\": \"cresnet\",\"cresnetId\": \"97\"},\"enablePir\": true,\"enableLedFlash\": true,\"enableRawStates\":true,\"remoteTimeout\": 30,\"internalPhotoSensorMinChange\": 0,\"externalPhotoSensorMinChange\": 0,\"enableUsA\": true,\"enableUsB\": true,\"orWhenVacatedState\": true}")]
|
||||||
public class GlsOdtOccupancySensorController : GlsOccupancySensorBaseController
|
public class GlsOdtOccupancySensorController : GlsOccupancySensorBaseController
|
||||||
{
|
{
|
||||||
public new GlsOdtCCn OccSensor { get; private set; }
|
private GlsOdtCCn _occSensor;
|
||||||
|
|
||||||
public BoolFeedback OrWhenVacatedFeedback { get; private set; }
|
public BoolFeedback OrWhenVacatedFeedback { get; private set; }
|
||||||
|
|
||||||
|
|
@ -42,31 +39,29 @@ namespace PepperDash.Essentials.Core
|
||||||
{
|
{
|
||||||
AddPreActivationAction(() =>
|
AddPreActivationAction(() =>
|
||||||
{
|
{
|
||||||
OccSensor = preActivationFunc(config);
|
_occSensor = preActivationFunc(config);
|
||||||
|
|
||||||
RegisterCrestronGenericBase(OccSensor);
|
RegisterCrestronGenericBase(_occSensor);
|
||||||
|
|
||||||
RegisterGlsOdtSensorBaseController(OccSensor);
|
RegisterGlsOccupancySensorBaseController(_occSensor);
|
||||||
|
|
||||||
AndWhenVacatedFeedback = new BoolFeedback(() => OccSensor.AndWhenVacatedFeedback.BoolValue);
|
AndWhenVacatedFeedback = new BoolFeedback(() => _occSensor.AndWhenVacatedFeedback.BoolValue);
|
||||||
|
|
||||||
OrWhenVacatedFeedback = new BoolFeedback(() => OccSensor.OrWhenVacatedFeedback.BoolValue);
|
OrWhenVacatedFeedback = new BoolFeedback(() => _occSensor.OrWhenVacatedFeedback.BoolValue);
|
||||||
|
|
||||||
UltrasonicAEnabledFeedback = new BoolFeedback(() => OccSensor.UsAEnabledFeedback.BoolValue);
|
UltrasonicAEnabledFeedback = new BoolFeedback(() => _occSensor.UsAEnabledFeedback.BoolValue);
|
||||||
|
|
||||||
UltrasonicBEnabledFeedback = new BoolFeedback(() => OccSensor.UsBEnabledFeedback.BoolValue);
|
UltrasonicBEnabledFeedback = new BoolFeedback(() => _occSensor.UsBEnabledFeedback.BoolValue);
|
||||||
|
|
||||||
RawOccupancyPirFeedback = new BoolFeedback(() => OccSensor.RawOccupancyPirFeedback.BoolValue);
|
RawOccupancyPirFeedback = new BoolFeedback(() => _occSensor.RawOccupancyPirFeedback.BoolValue);
|
||||||
|
|
||||||
RawOccupancyUsFeedback = new BoolFeedback(() => OccSensor.RawOccupancyUsFeedback.BoolValue);
|
RawOccupancyUsFeedback = new BoolFeedback(() => _occSensor.RawOccupancyUsFeedback.BoolValue);
|
||||||
|
|
||||||
UltrasonicSensitivityInVacantStateFeedback = new IntFeedback(() => OccSensor.UsSensitivityInVacantStateFeedback.UShortValue);
|
UltrasonicSensitivityInVacantStateFeedback = new IntFeedback(() => _occSensor.UsSensitivityInVacantStateFeedback.UShortValue);
|
||||||
|
|
||||||
UltrasonicSensitivityInOccupiedStateFeedback = new IntFeedback(() => OccSensor.UsSensitivityInOccupiedStateFeedback.UShortValue);
|
UltrasonicSensitivityInOccupiedStateFeedback = new IntFeedback(() => _occSensor.UsSensitivityInOccupiedStateFeedback.UShortValue);
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void ApplySettingsToSensorFromConfig()
|
protected override void ApplySettingsToSensorFromConfig()
|
||||||
|
|
@ -114,18 +109,27 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <param name="args"></param>
|
/// <param name="args"></param>
|
||||||
protected override void OccSensor_GlsOccupancySensorChange(GlsOccupancySensorBase device, GlsOccupancySensorChangeEventArgs args)
|
protected override void OccSensor_GlsOccupancySensorChange(GlsOccupancySensorBase device, GlsOccupancySensorChangeEventArgs args)
|
||||||
{
|
{
|
||||||
if (args.EventId == GlsOccupancySensorBase.AndWhenVacatedFeedbackEventId)
|
switch (args.EventId)
|
||||||
|
{
|
||||||
|
case GlsOccupancySensorBase.AndWhenVacatedFeedbackEventId:
|
||||||
AndWhenVacatedFeedback.FireUpdate();
|
AndWhenVacatedFeedback.FireUpdate();
|
||||||
else if (args.EventId == GlsOccupancySensorBase.OrWhenVacatedFeedbackEventId)
|
break;
|
||||||
|
case GlsOccupancySensorBase.OrWhenVacatedFeedbackEventId:
|
||||||
OrWhenVacatedFeedback.FireUpdate();
|
OrWhenVacatedFeedback.FireUpdate();
|
||||||
else if (args.EventId == GlsOccupancySensorBase.UsAEnabledFeedbackEventId)
|
break;
|
||||||
|
case GlsOccupancySensorBase.UsAEnabledFeedbackEventId:
|
||||||
UltrasonicAEnabledFeedback.FireUpdate();
|
UltrasonicAEnabledFeedback.FireUpdate();
|
||||||
else if (args.EventId == GlsOccupancySensorBase.UsBEnabledFeedbackEventId)
|
break;
|
||||||
|
case GlsOccupancySensorBase.UsBEnabledFeedbackEventId:
|
||||||
UltrasonicBEnabledFeedback.FireUpdate();
|
UltrasonicBEnabledFeedback.FireUpdate();
|
||||||
else if (args.EventId == GlsOccupancySensorBase.UsSensitivityInOccupiedStateFeedbackEventId)
|
break;
|
||||||
|
case GlsOccupancySensorBase.UsSensitivityInOccupiedStateFeedbackEventId:
|
||||||
UltrasonicSensitivityInOccupiedStateFeedback.FireUpdate();
|
UltrasonicSensitivityInOccupiedStateFeedback.FireUpdate();
|
||||||
else if (args.EventId == GlsOccupancySensorBase.UsSensitivityInVacantStateFeedbackEventId)
|
break;
|
||||||
|
case GlsOccupancySensorBase.UsSensitivityInVacantStateFeedbackEventId:
|
||||||
UltrasonicSensitivityInVacantStateFeedback.FireUpdate();
|
UltrasonicSensitivityInVacantStateFeedback.FireUpdate();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
base.OccSensor_GlsOccupancySensorChange(device, args);
|
base.OccSensor_GlsOccupancySensorChange(device, args);
|
||||||
}
|
}
|
||||||
|
|
@ -138,10 +142,15 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <param name="args"></param>
|
/// <param name="args"></param>
|
||||||
protected override void OccSensor_BaseEvent(Crestron.SimplSharpPro.GenericBase device, Crestron.SimplSharpPro.BaseEventArgs args)
|
protected override void OccSensor_BaseEvent(Crestron.SimplSharpPro.GenericBase device, Crestron.SimplSharpPro.BaseEventArgs args)
|
||||||
{
|
{
|
||||||
if (args.EventId == GlsOccupancySensorBase.RawOccupancyPirFeedbackEventId)
|
switch (args.EventId)
|
||||||
|
{
|
||||||
|
case GlsOccupancySensorBase.RawOccupancyPirFeedbackEventId:
|
||||||
RawOccupancyPirFeedback.FireUpdate();
|
RawOccupancyPirFeedback.FireUpdate();
|
||||||
else if (args.EventId == GlsOccupancySensorBase.RawOccupancyUsFeedbackEventId)
|
break;
|
||||||
|
case GlsOccupancySensorBase.RawOccupancyUsFeedbackEventId:
|
||||||
RawOccupancyUsFeedback.FireUpdate();
|
RawOccupancyUsFeedback.FireUpdate();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
base.OccSensor_BaseEvent(device, args);
|
base.OccSensor_BaseEvent(device, args);
|
||||||
}
|
}
|
||||||
|
|
@ -152,7 +161,7 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <param name="state"></param>
|
/// <param name="state"></param>
|
||||||
public void SetOrWhenVacatedState(bool state)
|
public void SetOrWhenVacatedState(bool state)
|
||||||
{
|
{
|
||||||
OccSensor.OrWhenVacated.BoolValue = state;
|
_occSensor.OrWhenVacated.BoolValue = state;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -161,7 +170,7 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <param name="state"></param>
|
/// <param name="state"></param>
|
||||||
public void SetAndWhenVacatedState(bool state)
|
public void SetAndWhenVacatedState(bool state)
|
||||||
{
|
{
|
||||||
OccSensor.AndWhenVacated.BoolValue = state;
|
_occSensor.AndWhenVacated.BoolValue = state;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -170,8 +179,8 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <param name="state"></param>
|
/// <param name="state"></param>
|
||||||
public void SetUsAEnable(bool state)
|
public void SetUsAEnable(bool state)
|
||||||
{
|
{
|
||||||
OccSensor.EnableUsA.BoolValue = state;
|
_occSensor.EnableUsA.BoolValue = state;
|
||||||
OccSensor.DisableUsA.BoolValue = !state;
|
_occSensor.DisableUsA.BoolValue = !state;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -181,28 +190,28 @@ namespace PepperDash.Essentials.Core
|
||||||
/// <param name="state"></param>
|
/// <param name="state"></param>
|
||||||
public void SetUsBEnable(bool state)
|
public void SetUsBEnable(bool state)
|
||||||
{
|
{
|
||||||
OccSensor.EnableUsB.BoolValue = state;
|
_occSensor.EnableUsB.BoolValue = state;
|
||||||
OccSensor.DisableUsB.BoolValue = !state;
|
_occSensor.DisableUsB.BoolValue = !state;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void IncrementUsSensitivityInOccupiedState(bool pressRelease)
|
public void IncrementUsSensitivityInOccupiedState(bool pressRelease)
|
||||||
{
|
{
|
||||||
OccSensor.IncrementUsSensitivityInOccupiedState.BoolValue = pressRelease;
|
_occSensor.IncrementUsSensitivityInOccupiedState.BoolValue = pressRelease;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void DecrementUsSensitivityInOccupiedState(bool pressRelease)
|
public void DecrementUsSensitivityInOccupiedState(bool pressRelease)
|
||||||
{
|
{
|
||||||
OccSensor.DecrementUsSensitivityInOccupiedState.BoolValue = pressRelease;
|
_occSensor.DecrementUsSensitivityInOccupiedState.BoolValue = pressRelease;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void IncrementUsSensitivityInVacantState(bool pressRelease)
|
public void IncrementUsSensitivityInVacantState(bool pressRelease)
|
||||||
{
|
{
|
||||||
OccSensor.IncrementUsSensitivityInVacantState.BoolValue = pressRelease;
|
_occSensor.IncrementUsSensitivityInVacantState.BoolValue = pressRelease;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void DecrementUsSensitivityInVacantState(bool pressRelease)
|
public void DecrementUsSensitivityInVacantState(bool pressRelease)
|
||||||
{
|
{
|
||||||
OccSensor.DecrementUsSensitivityInVacantState.BoolValue = pressRelease;
|
_occSensor.DecrementUsSensitivityInVacantState.BoolValue = pressRelease;
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
||||||
|
|
@ -218,26 +227,40 @@ namespace PepperDash.Essentials.Core
|
||||||
base.GetSettings();
|
base.GetSettings();
|
||||||
|
|
||||||
Debug.Console(0, this, "Ultrasonic Enabled A: {0} | B: {1}",
|
Debug.Console(0, this, "Ultrasonic Enabled A: {0} | B: {1}",
|
||||||
OccSensor.UsAEnabledFeedback.BoolValue,
|
_occSensor.UsAEnabledFeedback.BoolValue,
|
||||||
OccSensor.UsBEnabledFeedback.BoolValue);
|
_occSensor.UsBEnabledFeedback.BoolValue);
|
||||||
|
|
||||||
Debug.Console(0, this, "Ultrasonic Sensitivity Occupied: {0} | Vacant: {1}",
|
Debug.Console(0, this, "Ultrasonic Sensitivity Occupied: {0} | Vacant: {1}",
|
||||||
OccSensor.UsSensitivityInOccupiedStateFeedback.UShortValue,
|
_occSensor.UsSensitivityInOccupiedStateFeedback.UShortValue,
|
||||||
OccSensor.UsSensitivityInVacantStateFeedback.UShortValue);
|
_occSensor.UsSensitivityInVacantStateFeedback.UShortValue);
|
||||||
|
|
||||||
var dash = new string('*', 50);
|
var dash = new string('*', 50);
|
||||||
CrestronConsole.PrintLine(string.Format("{0}\n", dash));
|
CrestronConsole.PrintLine(string.Format("{0}\n", dash));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
#region PreActivation
|
public class GlsOdtOccupancySensorControllerFactory : EssentialsDeviceFactory<GlsOdtOccupancySensorController>
|
||||||
|
{
|
||||||
|
public GlsOdtOccupancySensorControllerFactory()
|
||||||
|
{
|
||||||
|
TypeNames = new List<string> { "glsodtccn" };
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public override EssentialsDevice BuildDevice(DeviceConfig dc)
|
||||||
|
{
|
||||||
|
Debug.Console(1, "Factory Attempting to create new GlsOccupancySensorBaseController Device");
|
||||||
|
|
||||||
|
return new GlsOdtOccupancySensorController(dc.Key, GetGlsOdtCCn, dc);
|
||||||
|
}
|
||||||
|
|
||||||
private static GlsOdtCCn GetGlsOdtCCn(DeviceConfig dc)
|
private static GlsOdtCCn GetGlsOdtCCn(DeviceConfig dc)
|
||||||
{
|
{
|
||||||
var control = CommFactory.GetControlPropertiesConfig(dc);
|
var control = CommFactory.GetControlPropertiesConfig(dc);
|
||||||
var cresnetId = control.CresnetIdInt;
|
var cresnetId = control.CresnetIdInt;
|
||||||
var branchId = control.ControlPortNumber;
|
var branchId = control.ControlPortNumber;
|
||||||
var parentKey = string.IsNullOrEmpty(control.ControlPortDevKey) ? "processor" : control.ControlPortDevKey;
|
var parentKey = String.IsNullOrEmpty(control.ControlPortDevKey) ? "processor" : control.ControlPortDevKey;
|
||||||
|
|
||||||
if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase))
|
if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase))
|
||||||
{
|
{
|
||||||
|
|
@ -254,24 +277,6 @@ namespace PepperDash.Essentials.Core
|
||||||
Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey);
|
Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
#endregion
|
|
||||||
|
|
||||||
public class GlsOdtOccupancySensorControllerFactory : EssentialsDeviceFactory<GlsOdtOccupancySensorController>
|
|
||||||
{
|
|
||||||
public GlsOdtOccupancySensorControllerFactory()
|
|
||||||
{
|
|
||||||
TypeNames = new List<string>() { "glsodtccn" };
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
public override EssentialsDevice BuildDevice(DeviceConfig dc)
|
|
||||||
{
|
|
||||||
Debug.Console(1, "Factory Attempting to create new GlsOccupancySensorBaseController Device");
|
|
||||||
|
|
||||||
return new GlsOdtOccupancySensorController(dc.Key, GetGlsOdtCCn, dc);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,80 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Crestron.SimplSharpPro.DeviceSupport;
|
||||||
|
using Crestron.SimplSharpPro.GeneralIO;
|
||||||
|
using PepperDash.Core;
|
||||||
|
using PepperDash.Essentials.Core.Bridges;
|
||||||
|
using PepperDash.Essentials.Core.Config;
|
||||||
|
|
||||||
|
namespace PepperDash.Essentials.Core
|
||||||
|
{
|
||||||
|
public class GlsOirOccupancySensorController:GlsOccupancySensorBaseController
|
||||||
|
{
|
||||||
|
private GlsOirCCn _occSensor;
|
||||||
|
|
||||||
|
public GlsOirOccupancySensorController(string key, Func<DeviceConfig, GlsOirCCn> preActivationFunc,DeviceConfig config) : this(key,config.Name, preActivationFunc, config)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public GlsOirOccupancySensorController(string key, string name, Func<DeviceConfig, GlsOirCCn> preActivationFunc, DeviceConfig config) : base(key, name, config)
|
||||||
|
{
|
||||||
|
AddPreActivationAction(() =>
|
||||||
|
{
|
||||||
|
_occSensor = preActivationFunc(config);
|
||||||
|
|
||||||
|
RegisterCrestronGenericBase(_occSensor);
|
||||||
|
|
||||||
|
RegisterGlsOccupancySensorBaseController(_occSensor);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
#region Overrides of CrestronGenericBridgeableBaseDevice
|
||||||
|
|
||||||
|
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
||||||
|
{
|
||||||
|
LinkOccSensorToApi(this, trilist, joinStart, joinMapKey, bridge);
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
}
|
||||||
|
|
||||||
|
public class GlsOccupancySensorBaseControllerFactory : EssentialsDeviceFactory<GlsOccupancySensorBaseController>
|
||||||
|
{
|
||||||
|
public GlsOccupancySensorBaseControllerFactory()
|
||||||
|
{
|
||||||
|
TypeNames = new List<string> { "glsoirccn" };
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public override EssentialsDevice BuildDevice(DeviceConfig dc)
|
||||||
|
{
|
||||||
|
Debug.Console(1, "Factory Attempting to create new GlsOirOccupancySensorController Device");
|
||||||
|
|
||||||
|
return new GlsOirOccupancySensorController(dc.Key, GetGlsOirCCn, dc);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static GlsOirCCn GetGlsOirCCn(DeviceConfig dc)
|
||||||
|
{
|
||||||
|
var control = CommFactory.GetControlPropertiesConfig(dc);
|
||||||
|
var cresnetId = control.CresnetIdInt;
|
||||||
|
var branchId = control.ControlPortNumber;
|
||||||
|
var parentKey = string.IsNullOrEmpty(control.ControlPortDevKey) ? "processor" : control.ControlPortDevKey;
|
||||||
|
|
||||||
|
if (parentKey.Equals("processor", StringComparison.CurrentCultureIgnoreCase))
|
||||||
|
{
|
||||||
|
Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn", parentKey);
|
||||||
|
return new GlsOirCCn(cresnetId, Global.ControlSystem);
|
||||||
|
}
|
||||||
|
var cresnetBridge = DeviceManager.GetDeviceForKey(parentKey) as IHasCresnetBranches;
|
||||||
|
|
||||||
|
if (cresnetBridge != null)
|
||||||
|
{
|
||||||
|
Debug.Console(0, "Device {0} is a valid cresnet master - creating new GlsOirCCn", parentKey);
|
||||||
|
return new GlsOirCCn(cresnetId, cresnetBridge.CresnetBranches[branchId]);
|
||||||
|
}
|
||||||
|
Debug.Console(0, "Device {0} is not a valid cresnet master", parentKey);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -4,7 +4,7 @@ using Crestron.SimplSharpPro.GeneralIO;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
using PepperDash.Essentials.Core.Bridges;
|
using PepperDash.Essentials.Core.Bridges;
|
||||||
using PepperDash_Essentials_Core.Bridges.JoinMaps;
|
using PepperDash.Essentials.Core.Bridges.JoinMaps;
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
|
|
||||||
|
|
@ -143,6 +143,7 @@
|
||||||
<Compile Include="Bridges\JoinMaps\Hrxxx0WirelessRemoteControllerJoinMap.cs" />
|
<Compile Include="Bridges\JoinMaps\Hrxxx0WirelessRemoteControllerJoinMap.cs" />
|
||||||
<Compile Include="Bridges\JoinMaps\IBasicCommunicationJoinMap.cs" />
|
<Compile Include="Bridges\JoinMaps\IBasicCommunicationJoinMap.cs" />
|
||||||
<Compile Include="Bridges\JoinMaps\IDigitalInputJoinMap.cs" />
|
<Compile Include="Bridges\JoinMaps\IDigitalInputJoinMap.cs" />
|
||||||
|
<Compile Include="Bridges\JoinMaps\IRBlurayBaseJoinMap.cs" />
|
||||||
<Compile Include="Bridges\JoinMaps\SetTopBoxControllerJoinMap.cs" />
|
<Compile Include="Bridges\JoinMaps\SetTopBoxControllerJoinMap.cs" />
|
||||||
<Compile Include="Bridges\JoinMaps\StatusSignControllerJoinMap.cs" />
|
<Compile Include="Bridges\JoinMaps\StatusSignControllerJoinMap.cs" />
|
||||||
<Compile Include="Bridges\JoinMaps\SystemMonitorJoinMap.cs" />
|
<Compile Include="Bridges\JoinMaps\SystemMonitorJoinMap.cs" />
|
||||||
|
|
@ -228,6 +229,7 @@
|
||||||
<Compile Include="Interfaces\ILogStrings.cs" />
|
<Compile Include="Interfaces\ILogStrings.cs" />
|
||||||
<Compile Include="Interfaces\ILogStringsWithLevel.cs" />
|
<Compile Include="Interfaces\ILogStringsWithLevel.cs" />
|
||||||
<Compile Include="Occupancy\GlsOccupancySensorPropertiesConfig.cs" />
|
<Compile Include="Occupancy\GlsOccupancySensorPropertiesConfig.cs" />
|
||||||
|
<Compile Include="Occupancy\GlsOirOccupancySensorController.cs" />
|
||||||
<Compile Include="Queues\ComsMessage.cs" />
|
<Compile Include="Queues\ComsMessage.cs" />
|
||||||
<Compile Include="Queues\ProcessStringMessage.cs" />
|
<Compile Include="Queues\ProcessStringMessage.cs" />
|
||||||
<Compile Include="Queues\GenericQueue.cs" />
|
<Compile Include="Queues\GenericQueue.cs" />
|
||||||
|
|
@ -327,6 +329,7 @@
|
||||||
<Compile Include="Routing\TieLine.cs" />
|
<Compile Include="Routing\TieLine.cs" />
|
||||||
<Compile Include="Queues\StringResponseProcessor.cs" />
|
<Compile Include="Queues\StringResponseProcessor.cs" />
|
||||||
<Compile Include="Timers\CountdownTimer.cs" />
|
<Compile Include="Timers\CountdownTimer.cs" />
|
||||||
|
<Compile Include="Timers\RetriggerableTimer.cs" />
|
||||||
<Compile Include="Touchpanels\CrestronTouchpanelPropertiesConfig.cs" />
|
<Compile Include="Touchpanels\CrestronTouchpanelPropertiesConfig.cs" />
|
||||||
<Compile Include="Touchpanels\Interfaces.cs" />
|
<Compile Include="Touchpanels\Interfaces.cs" />
|
||||||
<Compile Include="Touchpanels\Keyboards\HabaneroKeyboardController.cs" />
|
<Compile Include="Touchpanels\Keyboards\HabaneroKeyboardController.cs" />
|
||||||
|
|
@ -337,6 +340,7 @@
|
||||||
<Compile Include="UI PageManagers\SinglePageManager.cs" />
|
<Compile Include="UI PageManagers\SinglePageManager.cs" />
|
||||||
<Compile Include="UI PageManagers\PageManager.cs" />
|
<Compile Include="UI PageManagers\PageManager.cs" />
|
||||||
<Compile Include="UI PageManagers\SetTopBoxTwoPanelPageManager.cs" />
|
<Compile Include="UI PageManagers\SetTopBoxTwoPanelPageManager.cs" />
|
||||||
|
<Compile Include="Utilities\ActionSequence.cs" />
|
||||||
<Compile Include="VideoStatus\VideoStatusOutputs.cs" />
|
<Compile Include="VideoStatus\VideoStatusOutputs.cs" />
|
||||||
<Compile Include="Crestron\CrestronGenericBaseDevice.cs" />
|
<Compile Include="Crestron\CrestronGenericBaseDevice.cs" />
|
||||||
<Compile Include="DeviceControlsParentInterfaces\IPresentationSource.cs" />
|
<Compile Include="DeviceControlsParentInterfaces\IPresentationSource.cs" />
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
using System;
|
using System;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Queues
|
namespace PepperDash.Essentials.Core.Queues
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// IBasicCommunication Message for IQueue
|
/// IBasicCommunication Message for IQueue
|
||||||
|
|
@ -71,3 +71,31 @@ namespace PepperDash_Essentials_Core.Queues
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Queues
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// IBasicCommunication Message for IQueue
|
||||||
|
/// </summary>
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Queues")]
|
||||||
|
public class ComsMessage : PepperDash.Essentials.Core.Queues.ComsMessage
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor for a string message
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="coms">IBasicCommunication to send the message</param>
|
||||||
|
/// <param name="message">Message to send</param>
|
||||||
|
public ComsMessage(IBasicCommunication coms, string message):base(coms, message)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor for a byte message
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="coms">IBasicCommunication to send the message</param>
|
||||||
|
/// <param name="message">Message to send</param>
|
||||||
|
public ComsMessage(IBasicCommunication coms, byte[] message):base(coms, message)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -3,7 +3,7 @@ using Crestron.SimplSharp;
|
||||||
using Crestron.SimplSharpPro.CrestronThread;
|
using Crestron.SimplSharpPro.CrestronThread;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Queues
|
namespace PepperDash.Essentials.Core.Queues
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Threadsafe processing of queued items with pacing if required
|
/// Threadsafe processing of queued items with pacing if required
|
||||||
|
|
@ -126,7 +126,9 @@ namespace PepperDash_Essentials_Core.Queues
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="key">Key</param>
|
/// <param name="key">Key</param>
|
||||||
/// <param name="priority"></param>
|
/// <param name="priority"></param>
|
||||||
private GenericQueue(string key, Thread.eThreadPriority priority, int capacity, int pacing)
|
/// <param name="capacity"></param>
|
||||||
|
/// <param name="pacing"></param>
|
||||||
|
protected GenericQueue(string key, Thread.eThreadPriority priority, int capacity, int pacing)
|
||||||
{
|
{
|
||||||
_key = key;
|
_key = key;
|
||||||
int cap = 25; // sets default
|
int cap = 25; // sets default
|
||||||
|
|
@ -245,3 +247,105 @@ namespace PepperDash_Essentials_Core.Queues
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Queues
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Threadsafe processing of queued items with pacing if required
|
||||||
|
/// </summary>
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Queues")]
|
||||||
|
public class GenericQueue : PepperDash.Essentials.Core.Queues.GenericQueue
|
||||||
|
{
|
||||||
|
private bool _delayEnabled;
|
||||||
|
private int _delayTime;
|
||||||
|
|
||||||
|
private const Thread.eThreadPriority _defaultPriority = Thread.eThreadPriority.MediumPriority;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor with no thread priority
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
public GenericQueue(string key)
|
||||||
|
: this(key, _defaultPriority, 0, 0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor with queue size
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="capacity">Fixed size for the queue to hold</param>
|
||||||
|
public GenericQueue(string key, int capacity)
|
||||||
|
: this(key, _defaultPriority, capacity, 0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor for generic queue with no pacing
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key">Key</param>
|
||||||
|
/// <param name="pacing">Pacing in ms between actions</param>
|
||||||
|
public GenericQueue(int pacing, string key)
|
||||||
|
: this(key, _defaultPriority, 0, pacing)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor with pacing and capacity
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="pacing"></param>
|
||||||
|
/// <param name="capacity"></param>
|
||||||
|
public GenericQueue(string key, int pacing, int capacity)
|
||||||
|
: this(key, _defaultPriority, capacity, pacing)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor with pacing and priority
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="pacing"></param>
|
||||||
|
/// <param name="priority"></param>
|
||||||
|
public GenericQueue(string key, int pacing, Thread.eThreadPriority priority)
|
||||||
|
: this(key, priority, 0, pacing)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor with pacing, priority and capacity
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="priority"></param>
|
||||||
|
/// <param name="capacity"></param>
|
||||||
|
public GenericQueue(string key, Thread.eThreadPriority priority, int capacity)
|
||||||
|
: this(key, priority, capacity, 0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor with pacing, priority and capacity
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key"></param>
|
||||||
|
/// <param name="pacing"></param>
|
||||||
|
/// <param name="priority"></param>
|
||||||
|
/// <param name="capacity"></param>
|
||||||
|
public GenericQueue(string key, int pacing, Thread.eThreadPriority priority, int capacity)
|
||||||
|
: this(key, priority, capacity, pacing)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor for generic queue with no pacing
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="key">Key</param>
|
||||||
|
/// <param name="priority"></param>
|
||||||
|
/// <param name="capacity"></param>
|
||||||
|
/// <param name="pacing"></param>
|
||||||
|
private GenericQueue(string key, Thread.eThreadPriority priority, int capacity, int pacing):base(key, priority, capacity, pacing)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -5,7 +5,7 @@ using System.Text;
|
||||||
using Crestron.SimplSharp;
|
using Crestron.SimplSharp;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Queues
|
namespace PepperDash.Essentials.Core.Queues
|
||||||
{
|
{
|
||||||
public interface IQueue<T> : IKeyed, IDisposable where T : class
|
public interface IQueue<T> : IKeyed, IDisposable where T : class
|
||||||
{
|
{
|
||||||
|
|
@ -13,3 +13,11 @@ namespace PepperDash_Essentials_Core.Queues
|
||||||
bool Disposed { get; }
|
bool Disposed { get; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Queues
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Queues")]
|
||||||
|
public interface IQueue<T> : PepperDash.Essentials.Core.Queues.IQueue<T> where T: class
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,7 +1,17 @@
|
||||||
namespace PepperDash_Essentials_Core.Queues
|
using System;
|
||||||
|
|
||||||
|
namespace PepperDash.Essentials.Core.Queues
|
||||||
{
|
{
|
||||||
public interface IQueueMessage
|
public interface IQueueMessage
|
||||||
{
|
{
|
||||||
void Dispatch();
|
void Dispatch();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Queues
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Queues")]
|
||||||
|
public interface IQueueMessage:PepperDash.Essentials.Core.Queues.IQueueMessage
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
using System;
|
using System;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Queues
|
namespace PepperDash.Essentials.Core.Queues
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Message class for processing strings via an IQueue
|
/// Message class for processing strings via an IQueue
|
||||||
|
|
@ -42,3 +42,20 @@ namespace PepperDash_Essentials_Core.Queues
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Queues
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Message class for processing strings via an IQueue
|
||||||
|
/// </summary>
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Queues")]
|
||||||
|
public class ProcessStringMessage : PepperDash.Essentials.Core.Queues.ProcessStringMessage
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="message">Message to be processed</param>
|
||||||
|
/// <param name="action">Action to invoke on the message</param>
|
||||||
|
public ProcessStringMessage(string message, Action<string> action) : base(message, action){}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
using Crestron.SimplSharp;
|
using Crestron.SimplSharp;
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
|
|
||||||
namespace PepperDash_Essentials_Core.Queues
|
namespace PepperDash.Essentials.Core.Queues
|
||||||
{
|
{
|
||||||
public sealed class StringResponseProcessor : IKeyed, IDisposable
|
public sealed class StringResponseProcessor : IKeyed, IDisposable
|
||||||
{
|
{
|
||||||
|
|
@ -104,3 +104,107 @@ namespace PepperDash_Essentials_Core.Queues
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace PepperDash_Essentials_Core.Queues
|
||||||
|
{
|
||||||
|
[Obsolete("Use PepperDash.Essentials.Core.Queues")]
|
||||||
|
public sealed class StringResponseProcessor : IKeyed, IDisposable
|
||||||
|
{
|
||||||
|
private readonly Action<string> _processStringAction;
|
||||||
|
private readonly PepperDash.Essentials.Core.Queues.IQueue<PepperDash.Essentials.Core.Queues.IQueueMessage> _queue;
|
||||||
|
private readonly IBasicCommunication _coms;
|
||||||
|
private readonly CommunicationGather _gather;
|
||||||
|
|
||||||
|
private StringResponseProcessor(string key, Action<string> processStringAction)
|
||||||
|
{
|
||||||
|
_processStringAction = processStringAction;
|
||||||
|
_queue = new PepperDash.Essentials.Core.Queues.GenericQueue(key);
|
||||||
|
|
||||||
|
CrestronEnvironment.ProgramStatusEventHandler += programEvent =>
|
||||||
|
{
|
||||||
|
if (programEvent != eProgramStatusEventType.Stopping)
|
||||||
|
return;
|
||||||
|
|
||||||
|
Dispose();
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor that builds an instance and subscribes to coms TextReceived for processing
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="coms">Com port to process strings from</param>
|
||||||
|
/// <param name="processStringAction">Action to process the incoming strings</param>
|
||||||
|
public StringResponseProcessor(IBasicCommunication coms, Action<string> processStringAction)
|
||||||
|
: this(coms.Key, processStringAction)
|
||||||
|
{
|
||||||
|
_coms = coms;
|
||||||
|
coms.TextReceived += OnResponseReceived;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Constructor that builds an instance and subscribes to gather Line Received for processing
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="gather">Gather to process strings from</param>
|
||||||
|
/// <param name="processStringAction">Action to process the incoming strings</param>
|
||||||
|
public StringResponseProcessor(CommunicationGather gather, Action<string> processStringAction)
|
||||||
|
: this(gather.Port.Key, processStringAction)
|
||||||
|
{
|
||||||
|
_gather = gather;
|
||||||
|
gather.LineReceived += OnResponseReceived;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnResponseReceived(object sender, GenericCommMethodReceiveTextArgs args)
|
||||||
|
{
|
||||||
|
_queue.Enqueue(new ProcessStringMessage(args.Text, _processStringAction));
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Key
|
||||||
|
/// </summary>
|
||||||
|
public string Key
|
||||||
|
{
|
||||||
|
get { return _queue.Key; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Disposes the instance and cleans up resources.
|
||||||
|
/// </summary>
|
||||||
|
public void Dispose()
|
||||||
|
{
|
||||||
|
Dispose(true);
|
||||||
|
CrestronEnvironment.GC.SuppressFinalize(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Dispose(bool disposing)
|
||||||
|
{
|
||||||
|
if (Disposed)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (disposing)
|
||||||
|
{
|
||||||
|
if (_coms != null)
|
||||||
|
_coms.TextReceived -= OnResponseReceived;
|
||||||
|
|
||||||
|
if (_gather != null)
|
||||||
|
{
|
||||||
|
_gather.LineReceived -= OnResponseReceived;
|
||||||
|
_gather.Stop();
|
||||||
|
}
|
||||||
|
|
||||||
|
_queue.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
Disposed = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// If the instance has been disposed or not. If it has, you can not use it anymore
|
||||||
|
/// </summary>
|
||||||
|
public bool Disposed { get; private set; }
|
||||||
|
|
||||||
|
~StringResponseProcessor()
|
||||||
|
{
|
||||||
|
Dispose(false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -83,7 +83,7 @@ namespace PepperDash.Essentials.Core
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void _gateway_IsReadyEvent(object sender, PepperDash_Essentials_Core.IsReadyEventArgs e)
|
void _gateway_IsReadyEvent(object sender, IsReadyEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.IsReady != true) return;
|
if (e.IsReady != true) return;
|
||||||
_remote = GetHr1x0WirelessRemote(_config);
|
_remote = GetHr1x0WirelessRemote(_config);
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ namespace PepperDash.Essentials.Core
|
||||||
public string Key { get; private set; }
|
public string Key { get; private set; }
|
||||||
|
|
||||||
public BoolFeedback IsRunningFeedback { get; private set; }
|
public BoolFeedback IsRunningFeedback { get; private set; }
|
||||||
bool _IsRunning;
|
bool _isRunning;
|
||||||
|
|
||||||
public IntFeedback PercentFeedback { get; private set; }
|
public IntFeedback PercentFeedback { get; private set; }
|
||||||
public StringFeedback TimeRemainingFeedback { get; private set; }
|
public StringFeedback TimeRemainingFeedback { get; private set; }
|
||||||
|
|
@ -32,7 +32,7 @@ namespace PepperDash.Essentials.Core
|
||||||
public DateTime StartTime { get; private set; }
|
public DateTime StartTime { get; private set; }
|
||||||
public DateTime FinishTime { get; private set; }
|
public DateTime FinishTime { get; private set; }
|
||||||
|
|
||||||
CTimer SecondTimer;
|
private CTimer _secondTimer;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Constructor
|
/// Constructor
|
||||||
|
|
@ -41,38 +41,34 @@ namespace PepperDash.Essentials.Core
|
||||||
public SecondsCountdownTimer(string key)
|
public SecondsCountdownTimer(string key)
|
||||||
{
|
{
|
||||||
Key = key;
|
Key = key;
|
||||||
IsRunningFeedback = new BoolFeedback(() => _IsRunning);
|
IsRunningFeedback = new BoolFeedback(() => _isRunning);
|
||||||
|
|
||||||
TimeRemainingFeedback = new StringFeedback(() =>
|
TimeRemainingFeedback = new StringFeedback(() =>
|
||||||
{
|
{
|
||||||
// Need to handle up and down here.
|
// Need to handle up and down here.
|
||||||
|
|
||||||
if (StartTime == null || FinishTime == null)
|
|
||||||
return "";
|
|
||||||
var timeSpan = FinishTime - DateTime.Now;
|
var timeSpan = FinishTime - DateTime.Now;
|
||||||
|
|
||||||
if (timeSpan.TotalSeconds < 60)
|
Debug.Console(2, this,
|
||||||
|
"timeSpan.Minutes == {0}, timeSpan.Seconds == {1}, timeSpan.TotalSeconds == {2}",
|
||||||
|
timeSpan.Minutes, timeSpan.Seconds, timeSpan.TotalSeconds);
|
||||||
|
|
||||||
|
if (Math.Floor(timeSpan.TotalSeconds) < 60 && Math.Floor(timeSpan.TotalSeconds) >= 0) //ignore milliseconds
|
||||||
{
|
{
|
||||||
return Math.Round(timeSpan.TotalSeconds).ToString();
|
return String.Format("{0:00}", timeSpan.Seconds);
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Debug.Console(2, this, "timeSpan.Minutes == {0}, timeSpan.Seconds == {1}", timeSpan.Minutes, timeSpan.Seconds);
|
|
||||||
return String.Format("{0:D2}:{1:D2}",
|
|
||||||
timeSpan.Minutes,
|
|
||||||
timeSpan.Seconds);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return Math.Floor(timeSpan.TotalSeconds) < 0
|
||||||
|
? "00"
|
||||||
|
: String.Format("{0:00}:{1:00}", timeSpan.Minutes, timeSpan.Seconds);
|
||||||
});
|
});
|
||||||
|
|
||||||
PercentFeedback = new IntFeedback(() =>
|
PercentFeedback =
|
||||||
{
|
new IntFeedback(
|
||||||
if (StartTime == null || FinishTime == null)
|
() =>
|
||||||
return 0;
|
(int)
|
||||||
double percent = (FinishTime - DateTime.Now).TotalSeconds
|
(Math.Floor((FinishTime - DateTime.Now).TotalSeconds)/
|
||||||
/ (FinishTime - StartTime).TotalSeconds
|
Math.Floor((FinishTime - StartTime).TotalSeconds)*100));
|
||||||
* 100;
|
|
||||||
return (int)percent;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -80,15 +76,15 @@ namespace PepperDash.Essentials.Core
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void Start()
|
public void Start()
|
||||||
{
|
{
|
||||||
if (_IsRunning)
|
if (_isRunning)
|
||||||
return;
|
return;
|
||||||
StartTime = DateTime.Now;
|
StartTime = DateTime.Now;
|
||||||
FinishTime = StartTime + TimeSpan.FromSeconds(SecondsToCount);
|
FinishTime = StartTime + TimeSpan.FromSeconds(SecondsToCount);
|
||||||
|
|
||||||
if (SecondTimer != null)
|
if (_secondTimer != null)
|
||||||
SecondTimer.Stop();
|
_secondTimer.Stop();
|
||||||
SecondTimer = new CTimer(SecondElapsedTimerCallback, null, 0, 1000);
|
_secondTimer = new CTimer(SecondElapsedTimerCallback, null, 0, 1000);
|
||||||
_IsRunning = true;
|
_isRunning = true;
|
||||||
IsRunningFeedback.FireUpdate();
|
IsRunningFeedback.FireUpdate();
|
||||||
|
|
||||||
var handler = HasStarted;
|
var handler = HasStarted;
|
||||||
|
|
@ -101,7 +97,7 @@ namespace PepperDash.Essentials.Core
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void Reset()
|
public void Reset()
|
||||||
{
|
{
|
||||||
_IsRunning = false;
|
_isRunning = false;
|
||||||
Start();
|
Start();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -131,19 +127,22 @@ namespace PepperDash.Essentials.Core
|
||||||
|
|
||||||
void StopHelper()
|
void StopHelper()
|
||||||
{
|
{
|
||||||
if (SecondTimer != null)
|
if (_secondTimer != null)
|
||||||
SecondTimer.Stop();
|
_secondTimer.Stop();
|
||||||
_IsRunning = false;
|
_isRunning = false;
|
||||||
IsRunningFeedback.FireUpdate();
|
IsRunningFeedback.FireUpdate();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SecondElapsedTimerCallback(object o)
|
void SecondElapsedTimerCallback(object o)
|
||||||
{
|
{
|
||||||
|
if (DateTime.Now >= FinishTime)
|
||||||
|
{
|
||||||
|
Finish();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
PercentFeedback.FireUpdate();
|
PercentFeedback.FireUpdate();
|
||||||
TimeRemainingFeedback.FireUpdate();
|
TimeRemainingFeedback.FireUpdate();
|
||||||
|
|
||||||
if (DateTime.Now >= FinishTime)
|
|
||||||
Finish();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -0,0 +1,177 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
|
|
||||||
|
using PepperDash.Core;
|
||||||
|
using PepperDash.Essentials.Core;
|
||||||
|
using PepperDash.Essentials.Core.Config;
|
||||||
|
|
||||||
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
|
|
||||||
|
namespace PepperDash.Essentials.Core.Timers
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A device that runs a retriggerable timer and can execute actions specified in config
|
||||||
|
/// </summary>
|
||||||
|
[Description("A retriggerable timer device")]
|
||||||
|
public class RetriggerableTimer : EssentialsDevice
|
||||||
|
{
|
||||||
|
private RetriggerableTimerPropertiesConfig _propertiesConfig;
|
||||||
|
|
||||||
|
private CTimer _timer;
|
||||||
|
private long _timerIntervalMs;
|
||||||
|
|
||||||
|
public RetriggerableTimer(string key, DeviceConfig config)
|
||||||
|
: base(key, config.Name)
|
||||||
|
{
|
||||||
|
var props = config.Properties.ToObject<RetriggerableTimerPropertiesConfig>();
|
||||||
|
_propertiesConfig = props;
|
||||||
|
|
||||||
|
if (_propertiesConfig != null)
|
||||||
|
{
|
||||||
|
_timerIntervalMs = _propertiesConfig.TimerIntervalMs;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public override bool CustomActivate()
|
||||||
|
{
|
||||||
|
if (_propertiesConfig.StartTimerOnActivation)
|
||||||
|
{
|
||||||
|
StartTimer();
|
||||||
|
}
|
||||||
|
|
||||||
|
return base.CustomActivate();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void CleanUpTimer()
|
||||||
|
{
|
||||||
|
if (_timer != null)
|
||||||
|
{
|
||||||
|
_timer.Stop();
|
||||||
|
_timer.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
_timer = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void StartTimer()
|
||||||
|
{
|
||||||
|
CleanUpTimer();
|
||||||
|
Debug.Console(0, this, "Starting Timer");
|
||||||
|
|
||||||
|
_timer = new CTimer(TimerElapsedCallback, GetActionFromConfig(eRetriggerableTimerEvents.Elapsed), _timerIntervalMs, _timerIntervalMs);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void StopTimer()
|
||||||
|
{
|
||||||
|
Debug.Console(0, this, "Stopping Timer");
|
||||||
|
_timer.Stop();
|
||||||
|
|
||||||
|
ExecuteAction(GetActionFromConfig(eRetriggerableTimerEvents.Stopped));
|
||||||
|
}
|
||||||
|
|
||||||
|
private DeviceActionWrapper GetActionFromConfig(eRetriggerableTimerEvents eventType)
|
||||||
|
{
|
||||||
|
var action = _propertiesConfig.Events[eRetriggerableTimerEvents.Elapsed];
|
||||||
|
|
||||||
|
if (action != null)
|
||||||
|
return action;
|
||||||
|
else return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Executes the Elapsed action from confing when the timer elapses
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="o"></param>
|
||||||
|
private void TimerElapsedCallback(object action)
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, Debug.ErrorLogLevel.Notice, "Timer Elapsed. Executing Action");
|
||||||
|
|
||||||
|
if (action == null)
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, "Timer elapsed but unable to execute action. Action is null.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
var devAction = action as DeviceActionWrapper;
|
||||||
|
if (devAction != null)
|
||||||
|
ExecuteAction(devAction);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.Console(2, this, "Unable to cast action as DeviceActionWrapper. Cannot Execute");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ExecuteAction(DeviceActionWrapper action)
|
||||||
|
{
|
||||||
|
if (action == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
DeviceJsonApi.DoDeviceAction(action);
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Debug.Console(2, this, "Error Executing Action: {0}", e);
|
||||||
|
}
|
||||||
|
//finally // Not sure this is needed
|
||||||
|
//{
|
||||||
|
// _Timer.Reset(0, _TimerIntervalMs);
|
||||||
|
//}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Configuration Properties for RetriggerableTimer
|
||||||
|
/// </summary>
|
||||||
|
public class RetriggerableTimerPropertiesConfig
|
||||||
|
{
|
||||||
|
[JsonProperty("startTimerOnActivation")]
|
||||||
|
public bool StartTimerOnActivation { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("timerIntervalMs")]
|
||||||
|
public long TimerIntervalMs { get; set; }
|
||||||
|
|
||||||
|
[JsonProperty("events")]
|
||||||
|
public Dictionary<eRetriggerableTimerEvents, DeviceActionWrapper> Events { get; set; }
|
||||||
|
|
||||||
|
public RetriggerableTimerPropertiesConfig()
|
||||||
|
{
|
||||||
|
Events = new Dictionary<eRetriggerableTimerEvents, DeviceActionWrapper>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The set of values describing events on the timer
|
||||||
|
/// </summary>
|
||||||
|
public enum eRetriggerableTimerEvents
|
||||||
|
{
|
||||||
|
Elapsed,
|
||||||
|
Stopped,
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Factory class
|
||||||
|
/// </summary>
|
||||||
|
public class RetriggerableTimerFactory : EssentialsDeviceFactory<RetriggerableTimer>
|
||||||
|
{
|
||||||
|
public RetriggerableTimerFactory()
|
||||||
|
{
|
||||||
|
TypeNames = new List<string>() { "retriggerabletimer" };
|
||||||
|
}
|
||||||
|
|
||||||
|
public override EssentialsDevice BuildDevice(DeviceConfig dc)
|
||||||
|
{
|
||||||
|
Debug.Console(1, "Factory Attempting to create new RetriggerableTimer Device");
|
||||||
|
|
||||||
|
return new RetriggerableTimer(dc.Key, dc);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,159 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using Crestron.SimplSharp;
|
||||||
|
using Crestron.SimplSharpPro.CrestronThread;
|
||||||
|
|
||||||
|
using PepperDash.Core;
|
||||||
|
using PepperDash.Essentials.Core;
|
||||||
|
using PepperDash.Essentials.Core.Config;
|
||||||
|
|
||||||
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
|
namespace PepperDash.Essentials.Core.Utilities
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A device that executes a sequence of actions with optional delays between actions
|
||||||
|
/// </summary>
|
||||||
|
[Description("A device that executes a sequence of actions with optional delays between actions")]
|
||||||
|
public class ActionSequence : EssentialsDevice
|
||||||
|
{
|
||||||
|
private ActionSequencePropertiesConfig _propertiesConfig;
|
||||||
|
|
||||||
|
private CrestronQueue<SequencedDeviceActionWrapper> _actionQueue;
|
||||||
|
|
||||||
|
private Thread _worker;
|
||||||
|
|
||||||
|
private bool _allowActionsToExecute;
|
||||||
|
|
||||||
|
public ActionSequence(string key, DeviceConfig config)
|
||||||
|
: base(key, config.Name)
|
||||||
|
{
|
||||||
|
var props = config.Properties.ToObject<ActionSequencePropertiesConfig>();
|
||||||
|
_propertiesConfig = props;
|
||||||
|
|
||||||
|
if (_propertiesConfig != null)
|
||||||
|
{
|
||||||
|
if (_propertiesConfig.ActionSequence.Count > 0)
|
||||||
|
{
|
||||||
|
_actionQueue = new CrestronQueue<SequencedDeviceActionWrapper>(_propertiesConfig.ActionSequence.Count);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Starts executing the sequenced actions
|
||||||
|
/// </summary>
|
||||||
|
public void StartSequence()
|
||||||
|
{
|
||||||
|
if (_worker !=null && _worker.ThreadState == Thread.eThreadStates.ThreadRunning)
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, "Thread already running. Cannot Start Sequence");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
Debug.Console(1, this, "Starting Action Sequence");
|
||||||
|
_allowActionsToExecute = true;
|
||||||
|
AddActionsToQueue();
|
||||||
|
_worker = new Thread(ProcessActions, null, Thread.eThreadStartOptions.Running);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Stops executing the sequenced actions
|
||||||
|
/// </summary>
|
||||||
|
public void StopSequence()
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, "Stopping Action Sequence");
|
||||||
|
_allowActionsToExecute = false;
|
||||||
|
_worker.Abort();
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Populates the queue from the configuration information
|
||||||
|
/// </summary>
|
||||||
|
private void AddActionsToQueue()
|
||||||
|
{
|
||||||
|
Debug.Console(1, this, "Adding {0} actions to queue", _propertiesConfig.ActionSequence.Count);
|
||||||
|
|
||||||
|
for (int i = 0; i < _propertiesConfig.ActionSequence.Count; i++)
|
||||||
|
{
|
||||||
|
_actionQueue.Enqueue(_propertiesConfig.ActionSequence[i]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private object ProcessActions(object obj)
|
||||||
|
{
|
||||||
|
while (_allowActionsToExecute && _actionQueue.Count > 0)
|
||||||
|
{
|
||||||
|
SequencedDeviceActionWrapper action = null;
|
||||||
|
|
||||||
|
action = _actionQueue.Dequeue();
|
||||||
|
if (action == null)
|
||||||
|
break;
|
||||||
|
|
||||||
|
// Delay before executing
|
||||||
|
if (action.DelayMs > 0)
|
||||||
|
Thread.Sleep(action.DelayMs);
|
||||||
|
|
||||||
|
ExecuteAction(action);
|
||||||
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ExecuteAction(DeviceActionWrapper action)
|
||||||
|
{
|
||||||
|
if (action == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
DeviceJsonApi.DoDeviceAction(action);
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Debug.Console(2, this, "Error Executing Action: {0}", e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Configuration Properties for ActionSequence
|
||||||
|
/// </summary>
|
||||||
|
public class ActionSequencePropertiesConfig
|
||||||
|
{
|
||||||
|
[JsonProperty("actionSequence")]
|
||||||
|
public List<SequencedDeviceActionWrapper> ActionSequence { get; set; }
|
||||||
|
|
||||||
|
public ActionSequencePropertiesConfig()
|
||||||
|
{
|
||||||
|
ActionSequence = new List<SequencedDeviceActionWrapper>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class SequencedDeviceActionWrapper : DeviceActionWrapper
|
||||||
|
{
|
||||||
|
[JsonProperty("delayMs")]
|
||||||
|
public int DelayMs { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Factory class
|
||||||
|
/// </summary>
|
||||||
|
public class ActionSequenceFactory : EssentialsDeviceFactory<ActionSequence>
|
||||||
|
{
|
||||||
|
public ActionSequenceFactory()
|
||||||
|
{
|
||||||
|
TypeNames = new List<string>() { "actionsequence" };
|
||||||
|
}
|
||||||
|
|
||||||
|
public override EssentialsDevice BuildDevice(DeviceConfig dc)
|
||||||
|
{
|
||||||
|
Debug.Console(1, "Factory Attempting to create new ActionSequence Device");
|
||||||
|
|
||||||
|
return new ActionSequence(dc.Key, dc);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -23,6 +23,8 @@ namespace PepperDash.Essentials.DM {
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class DmBladeChassisController : CrestronGenericBridgeableBaseDevice, IDmSwitch, IRoutingNumericWithFeedback
|
public class DmBladeChassisController : CrestronGenericBridgeableBaseDevice, IDmSwitch, IRoutingNumericWithFeedback
|
||||||
{
|
{
|
||||||
|
private const string NonePortKey = "inputCard0--None";
|
||||||
|
|
||||||
public DMChassisPropertiesConfig PropertiesConfig { get; set; }
|
public DMChassisPropertiesConfig PropertiesConfig { get; set; }
|
||||||
|
|
||||||
public Switch Chassis { get; private set; }
|
public Switch Chassis { get; private set; }
|
||||||
|
|
@ -112,6 +114,10 @@ namespace PepperDash.Essentials.DM {
|
||||||
controller.AddVolumeControl(outNum, audio);
|
controller.AddVolumeControl(outNum, audio);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
controller.InputPorts.Add(new RoutingInputPort(NonePortKey, eRoutingSignalType.Video,
|
||||||
|
eRoutingPortConnectionType.None, null, controller));
|
||||||
|
|
||||||
|
|
||||||
controller.InputNames = properties.InputNames;
|
controller.InputNames = properties.InputNames;
|
||||||
controller.OutputNames = properties.OutputNames;
|
controller.OutputNames = properties.OutputNames;
|
||||||
controller.PropertiesConfig = properties;
|
controller.PropertiesConfig = properties;
|
||||||
|
|
@ -367,34 +373,28 @@ namespace PepperDash.Essentials.DM {
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddHdmiOutBladePorts(uint number) {
|
void AddHdmiOutBladePorts(uint number) {
|
||||||
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("hdmiOut{0}", number) , eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, number);
|
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("hdmiOut{0}", number) , eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, Chassis.Outputs[number]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddDmOutBladePorts(uint number) {
|
void AddDmOutBladePorts(uint number) {
|
||||||
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("dmOut{0}", number), eRoutingSignalType.Video, eRoutingPortConnectionType.DmCat, number);
|
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("dmOut{0}", number), eRoutingSignalType.Video, eRoutingPortConnectionType.DmCat, Chassis.Outputs[number]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddDmOutMmFiberBladePorts(uint number) {
|
void AddDmOutMmFiberBladePorts(uint number) {
|
||||||
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("dmOut{0}", number), eRoutingSignalType.Video, eRoutingPortConnectionType.DmMmFiber, number);
|
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("dmOut{0}", number), eRoutingSignalType.Video, eRoutingPortConnectionType.DmMmFiber, Chassis.Outputs[number]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddDmOutSmFiberBladePorts(uint number) {
|
void AddDmOutSmFiberBladePorts(uint number) {
|
||||||
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("dmOut{0}", number), eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber, number);
|
AddOutputPortWithDebug(String.Format("outputBlade{0}", (number / 8 > 0 ? 1 : number / 8)), String.Format("dmOut{0}", number), eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber, Chassis.Outputs[number]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Adds InputPort
|
/// Adds InputPort
|
||||||
/// </summary>
|
/// </summary>
|
||||||
void AddInputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType) {
|
void AddInputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType)
|
||||||
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
|
||||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
|
||||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this)
|
|
||||||
{
|
{
|
||||||
FeedbackMatchObject = Chassis.Inputs[cardNum]
|
AddInputPortWithDebug(cardNum, portName, sigType, portType, null);
|
||||||
};
|
|
||||||
|
|
||||||
InputPorts.Add(inputPort);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -405,7 +405,7 @@ namespace PepperDash.Essentials.DM {
|
||||||
{
|
{
|
||||||
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
||||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
||||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this)
|
var inputPort = new RoutingInputPort(portKey, sigType, portType, Chassis.Inputs[cardNum], this)
|
||||||
{
|
{
|
||||||
FeedbackMatchObject = Chassis.Inputs[cardNum]
|
FeedbackMatchObject = Chassis.Inputs[cardNum]
|
||||||
};
|
};
|
||||||
|
|
@ -567,9 +567,7 @@ namespace PepperDash.Essentials.DM {
|
||||||
void StartOffTimer(PortNumberType pnt) {
|
void StartOffTimer(PortNumberType pnt) {
|
||||||
if (RouteOffTimers.ContainsKey(pnt))
|
if (RouteOffTimers.ContainsKey(pnt))
|
||||||
return;
|
return;
|
||||||
RouteOffTimers[pnt] = new CTimer(o => {
|
RouteOffTimers[pnt] = new CTimer(o => ExecuteSwitch(null, pnt.Selector, pnt.Type), RouteOffTime);
|
||||||
ExecuteSwitch(0, pnt.Number, pnt.Type);
|
|
||||||
}, RouteOffTime);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -592,11 +590,22 @@ namespace PepperDash.Essentials.DM {
|
||||||
public void ExecuteSwitch(object inputSelector, object outputSelector, eRoutingSignalType sigType) {
|
public void ExecuteSwitch(object inputSelector, object outputSelector, eRoutingSignalType sigType) {
|
||||||
Debug.Console(2, this, "Making an awesome DM route from {0} to {1} {2}", inputSelector, outputSelector, sigType);
|
Debug.Console(2, this, "Making an awesome DM route from {0} to {1} {2}", inputSelector, outputSelector, sigType);
|
||||||
|
|
||||||
var input = Convert.ToUInt32(inputSelector); // Cast can sometimes fail
|
var input = inputSelector as DMInput; // Cast can sometimes fail
|
||||||
var output = Convert.ToUInt32(outputSelector);
|
var output = outputSelector as DMOutput;
|
||||||
|
|
||||||
|
|
||||||
|
if (output == null)
|
||||||
|
{
|
||||||
|
Debug.Console(0, this, Debug.ErrorLogLevel.Warning,
|
||||||
|
"Unable to execute switch for inputSelector {0} to outputSelector {1}", inputSelector,
|
||||||
|
outputSelector);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// Check to see if there's an off timer waiting on this and if so, cancel
|
// Check to see if there's an off timer waiting on this and if so, cancel
|
||||||
var key = new PortNumberType(output, sigType);
|
var key = new PortNumberType(output, sigType);
|
||||||
if (input == 0) {
|
|
||||||
|
if (input == null) {
|
||||||
StartOffTimer(key);
|
StartOffTimer(key);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
@ -609,13 +618,13 @@ namespace PepperDash.Essentials.DM {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
var inCard = input == 0 ? null : Chassis.Inputs[input];
|
/*var inCard = input == 0 ? null : Chassis.Inputs[input];
|
||||||
var outCard = input == 0 ? null : Chassis.Outputs[output];
|
var outCard = input == 0 ? null : Chassis.Outputs[output];*/
|
||||||
|
|
||||||
// NOTE THAT BITWISE COMPARISONS - TO CATCH ALL ROUTING TYPES
|
// NOTE THAT BITWISE COMPARISONS - TO CATCH ALL ROUTING TYPES
|
||||||
if ((sigType | eRoutingSignalType.Video) != eRoutingSignalType.Video) return;
|
if ((sigType & eRoutingSignalType.Video) != eRoutingSignalType.Video) return;
|
||||||
Chassis.VideoEnter.BoolValue = true;
|
Chassis.VideoEnter.BoolValue = true;
|
||||||
Chassis.Outputs[output].VideoOut = inCard;
|
output.VideoOut = input;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
@ -624,7 +633,10 @@ namespace PepperDash.Essentials.DM {
|
||||||
|
|
||||||
public void ExecuteNumericSwitch(ushort inputSelector, ushort outputSelector, eRoutingSignalType sigType)
|
public void ExecuteNumericSwitch(ushort inputSelector, ushort outputSelector, eRoutingSignalType sigType)
|
||||||
{
|
{
|
||||||
ExecuteSwitch(inputSelector, outputSelector, sigType);
|
var input = inputSelector == 0 ? null : Chassis.Inputs[inputSelector];
|
||||||
|
var output = Chassis.Outputs[outputSelector];
|
||||||
|
|
||||||
|
ExecuteSwitch(input, output, sigType);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,7 @@ namespace PepperDash.Essentials.DM
|
||||||
[Description("Wrapper class for all DM-MD chassis variants from 8x8 to 32x32")]
|
[Description("Wrapper class for all DM-MD chassis variants from 8x8 to 32x32")]
|
||||||
public class DmChassisController : CrestronGenericBridgeableBaseDevice, IDmSwitch, IRoutingNumericWithFeedback
|
public class DmChassisController : CrestronGenericBridgeableBaseDevice, IDmSwitch, IRoutingNumericWithFeedback
|
||||||
{
|
{
|
||||||
|
private const string NonePortKey = "inputCard0--None";
|
||||||
public DMChassisPropertiesConfig PropertiesConfig { get; set; }
|
public DMChassisPropertiesConfig PropertiesConfig { get; set; }
|
||||||
|
|
||||||
public Switch Chassis { get; private set; }
|
public Switch Chassis { get; private set; }
|
||||||
|
|
@ -133,6 +134,12 @@ namespace PepperDash.Essentials.DM
|
||||||
|
|
||||||
var controller = new DmChassisController(key, name, chassis);
|
var controller = new DmChassisController(key, name, chassis);
|
||||||
|
|
||||||
|
//
|
||||||
|
var clearInputPort = new RoutingInputPort(NonePortKey, eRoutingSignalType.AudioVideo,
|
||||||
|
eRoutingPortConnectionType.None, null, controller);
|
||||||
|
|
||||||
|
controller.InputPorts.Add(clearInputPort);
|
||||||
|
|
||||||
// add the cards and port names
|
// add the cards and port names
|
||||||
foreach (var kvp in properties.InputSlots)
|
foreach (var kvp in properties.InputSlots)
|
||||||
controller.AddInputCard(kvp.Value, kvp.Key);
|
controller.AddInputCard(kvp.Value, kvp.Key);
|
||||||
|
|
@ -485,169 +492,170 @@ namespace PepperDash.Essentials.DM
|
||||||
|
|
||||||
type = type.ToLower();
|
type = type.ToLower();
|
||||||
|
|
||||||
if (type == "dmchd")
|
switch (type)
|
||||||
|
{
|
||||||
|
case "dmchd":
|
||||||
{
|
{
|
||||||
var inputCard = new DmcHd(number, this.Chassis);
|
var inputCard = new DmcHd(number, this.Chassis);
|
||||||
var cecPort = inputCard.HdmiInput as ICec;
|
var cecPort = inputCard.HdmiInput as ICec;
|
||||||
AddHdmiInCardPorts(number, cecPort);
|
AddHdmiInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmchddsp")
|
break;
|
||||||
|
case "dmchddsp":
|
||||||
{
|
{
|
||||||
var inputCard = new DmcHdDsp(number, this.Chassis);
|
var inputCard = new DmcHdDsp(number, this.Chassis);
|
||||||
var cecPort = inputCard.HdmiInput as ICec;
|
var cecPort = inputCard.HdmiInput as ICec;
|
||||||
AddHdmiInCardPorts(number, cecPort);
|
AddHdmiInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4khd")
|
break;
|
||||||
|
case "dmc4khd":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kHd(number, this.Chassis);
|
var inputCard = new Dmc4kHd(number, this.Chassis);
|
||||||
var cecPort = inputCard.HdmiInput as ICec;
|
var cecPort = inputCard.HdmiInput as ICec;
|
||||||
AddHdmiInCardPorts(number, cecPort);
|
AddHdmiInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4khddsp")
|
break;
|
||||||
|
case "dmc4khddsp":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kHdDsp(number, this.Chassis);
|
var inputCard = new Dmc4kHdDsp(number, this.Chassis);
|
||||||
var cecPort = inputCard.HdmiInput as ICec;
|
var cecPort = inputCard.HdmiInput as ICec;
|
||||||
AddHdmiInCardPorts(number, cecPort);
|
AddHdmiInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kzhd")
|
break;
|
||||||
|
case "dmc4kzhd":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kzHd(number, this.Chassis);
|
var inputCard = new Dmc4kzHd(number, this.Chassis);
|
||||||
var cecPort = inputCard.HdmiInput as ICec;
|
var cecPort = inputCard.HdmiInput as ICec;
|
||||||
AddHdmiInCardPorts(number, cecPort);
|
AddHdmiInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kzhddsp")
|
break;
|
||||||
|
case "dmc4kzhddsp":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kzHdDsp(number, this.Chassis);
|
var inputCard = new Dmc4kzHdDsp(number, this.Chassis);
|
||||||
var cecPort = inputCard.HdmiInput as ICec;
|
var cecPort = inputCard.HdmiInput as ICec;
|
||||||
AddHdmiInCardPorts(number, cecPort);
|
AddHdmiInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmcc")
|
break;
|
||||||
|
case "dmcc":
|
||||||
{
|
{
|
||||||
var inputCard = new DmcC(number, this.Chassis);
|
var inputCard = new DmcC(number, this.Chassis);
|
||||||
var cecPort = inputCard.DmInput as ICec;
|
var cecPort = inputCard.DmInput as ICec;
|
||||||
AddDmInCardPorts(number, cecPort);
|
AddDmInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmccdsp")
|
break;
|
||||||
|
case "dmccdsp":
|
||||||
{
|
{
|
||||||
var inputCard = new DmcCDsp(number, this.Chassis);
|
var inputCard = new DmcCDsp(number, this.Chassis);
|
||||||
var cecPort = inputCard.DmInput as ICec;
|
var cecPort = inputCard.DmInput as ICec;
|
||||||
AddDmInCardPorts(number, cecPort);
|
AddDmInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kc")
|
break;
|
||||||
|
case "dmc4kc":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kC(number, this.Chassis);
|
var inputCard = new Dmc4kC(number, this.Chassis);
|
||||||
var cecPort = inputCard.DmInput as ICec;
|
var cecPort = inputCard.DmInput as ICec;
|
||||||
AddDmInCardPorts(number, cecPort);
|
AddDmInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kcdsp")
|
break;
|
||||||
|
case "dmc4kcdsp":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kCDsp(number, this.Chassis);
|
var inputCard = new Dmc4kCDsp(number, this.Chassis);
|
||||||
var cecPort = inputCard.DmInput as ICec;
|
var cecPort = inputCard.DmInput as ICec;
|
||||||
AddDmInCardPorts(number, cecPort);
|
AddDmInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kzc")
|
break;
|
||||||
|
case "dmc4kzc":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kzC(number, this.Chassis);
|
var inputCard = new Dmc4kzC(number, this.Chassis);
|
||||||
var cecPort = inputCard.DmInput as ICec;
|
var cecPort = inputCard.DmInput as ICec;
|
||||||
AddDmInCardPorts(number, cecPort);
|
AddDmInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kzcdsp")
|
break;
|
||||||
|
case "dmc4kzcdsp":
|
||||||
{
|
{
|
||||||
var inputCard = new Dmc4kzCDsp(number, this.Chassis);
|
var inputCard = new Dmc4kzCDsp(number, this.Chassis);
|
||||||
var cecPort = inputCard.DmInput as ICec;
|
var cecPort = inputCard.DmInput as ICec;
|
||||||
AddDmInCardPorts(number, cecPort);
|
AddDmInCardPorts(number, cecPort);
|
||||||
}
|
}
|
||||||
else if (type == "dmccat")
|
break;
|
||||||
{
|
case "dmccat":
|
||||||
new DmcCat(number, this.Chassis);
|
new DmcCat(number, this.Chassis);
|
||||||
AddDmInCardPorts(number);
|
AddDmInCardPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmccatdsp")
|
case "dmccatdsp":
|
||||||
{
|
|
||||||
new DmcCatDsp(number, this.Chassis);
|
new DmcCatDsp(number, this.Chassis);
|
||||||
AddDmInCardPorts(number);
|
AddDmInCardPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcs")
|
case "dmcs":
|
||||||
{
|
|
||||||
new DmcS(number, Chassis);
|
new DmcS(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmMmFiber);
|
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmMmFiber);
|
||||||
AddInCardHdmiAndAudioLoopPorts(number);
|
AddInCardHdmiAndAudioLoopPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcsdsp")
|
case "dmcsdsp":
|
||||||
{
|
|
||||||
new DmcSDsp(number, Chassis);
|
new DmcSDsp(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmMmFiber);
|
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmMmFiber);
|
||||||
AddInCardHdmiAndAudioLoopPorts(number);
|
AddInCardHdmiAndAudioLoopPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcs2")
|
case "dmcs2":
|
||||||
{
|
|
||||||
new DmcS2(number, Chassis);
|
new DmcS2(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber);
|
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber);
|
||||||
AddInCardHdmiAndAudioLoopPorts(number);
|
AddInCardHdmiAndAudioLoopPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcs2dsp")
|
case "dmcs2dsp":
|
||||||
{
|
|
||||||
new DmcS2Dsp(number, Chassis);
|
new DmcS2Dsp(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber);
|
AddInputPortWithDebug(number, "dmIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmSmFiber);
|
||||||
AddInCardHdmiAndAudioLoopPorts(number);
|
AddInCardHdmiAndAudioLoopPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcsdi")
|
case "dmcsdi":
|
||||||
{
|
|
||||||
new DmcSdi(number, Chassis);
|
new DmcSdi(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "sdiIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Sdi);
|
AddInputPortWithDebug(number, "sdiIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Sdi);
|
||||||
AddOutputPortWithDebug(string.Format("inputCard{0}", number), "sdiOut", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("inputCard{0}", number), "sdiOut", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Sdi, null);
|
eRoutingPortConnectionType.Sdi, null);
|
||||||
AddInCardHdmiAndAudioLoopPorts(number);
|
AddInCardHdmiAndAudioLoopPorts(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcdvi")
|
case "dmcdvi":
|
||||||
{
|
|
||||||
new DmcDvi(number, Chassis);
|
new DmcDvi(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "dviIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Dvi);
|
AddInputPortWithDebug(number, "dviIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Dvi);
|
||||||
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
||||||
AddInCardHdmiLoopPort(number);
|
AddInCardHdmiLoopPort(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcvga")
|
case "dmcvga":
|
||||||
{
|
|
||||||
new DmcVga(number, Chassis);
|
new DmcVga(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "vgaIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Vga);
|
AddInputPortWithDebug(number, "vgaIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Vga);
|
||||||
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
||||||
AddInCardHdmiLoopPort(number);
|
AddInCardHdmiLoopPort(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcvidbnc")
|
case "dmcvidbnc":
|
||||||
{
|
|
||||||
new DmcVidBnc(number, Chassis);
|
new DmcVidBnc(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "componentIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Component);
|
AddInputPortWithDebug(number, "componentIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Component);
|
||||||
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
||||||
AddInCardHdmiLoopPort(number);
|
AddInCardHdmiLoopPort(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcvidrcaa")
|
case "dmcvidrcaa":
|
||||||
{
|
|
||||||
new DmcVidRcaA(number, Chassis);
|
new DmcVidRcaA(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "componentIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Component);
|
AddInputPortWithDebug(number, "componentIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Component);
|
||||||
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio);
|
||||||
AddInCardHdmiLoopPort(number);
|
AddInCardHdmiLoopPort(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcvidrcad")
|
case "dmcvidrcad":
|
||||||
{
|
|
||||||
new DmcVidRcaD(number, Chassis);
|
new DmcVidRcaD(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "componentIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Component);
|
AddInputPortWithDebug(number, "componentIn", eRoutingSignalType.Video, eRoutingPortConnectionType.Component);
|
||||||
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.DigitalAudio);
|
AddInputPortWithDebug(number, "audioIn", eRoutingSignalType.Audio, eRoutingPortConnectionType.DigitalAudio);
|
||||||
AddInCardHdmiLoopPort(number);
|
AddInCardHdmiLoopPort(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcvid4")
|
case "dmcvid4":
|
||||||
{
|
|
||||||
new DmcVid4(number, Chassis);
|
new DmcVid4(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "compositeIn1", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
AddInputPortWithDebug(number, "compositeIn1", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
||||||
AddInputPortWithDebug(number, "compositeIn2", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
AddInputPortWithDebug(number, "compositeIn2", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
||||||
AddInputPortWithDebug(number, "compositeIn3", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
AddInputPortWithDebug(number, "compositeIn3", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
||||||
AddInputPortWithDebug(number, "compositeIn4", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
AddInputPortWithDebug(number, "compositeIn4", eRoutingSignalType.Video, eRoutingPortConnectionType.Composite);
|
||||||
AddInCardHdmiLoopPort(number);
|
AddInCardHdmiLoopPort(number);
|
||||||
}
|
break;
|
||||||
else if (type == "dmcstr")
|
case "dmcstr":
|
||||||
{
|
|
||||||
new DmcStr(number, Chassis);
|
new DmcStr(number, Chassis);
|
||||||
AddInputPortWithDebug(number, "streamIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Streaming);
|
AddInputPortWithDebug(number, "streamIn", eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Streaming);
|
||||||
AddInCardHdmiAndAudioLoopPorts(number);
|
AddInCardHdmiAndAudioLoopPorts(number);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -692,104 +700,114 @@ namespace PepperDash.Essentials.DM
|
||||||
type = type.ToLower();
|
type = type.ToLower();
|
||||||
|
|
||||||
Debug.Console(2, this, "Adding output card '{0}', slot {1}", type, number);
|
Debug.Console(2, this, "Adding output card '{0}', slot {1}", type, number);
|
||||||
if (type == "dmc4khdo")
|
switch (type)
|
||||||
|
{
|
||||||
|
case "dmc4khdo":
|
||||||
{
|
{
|
||||||
var outputCard = new Dmc4kHdoSingle(number, Chassis);
|
var outputCard = new Dmc4kHdoSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
var cecPort2 = outputCard.Card2.HdmiOutput;
|
var cecPort2 = outputCard.Card2.HdmiOutput;
|
||||||
AddDmcHdoPorts(number, cecPort1, cecPort2);
|
AddDmcHdoPorts(number, cecPort1, cecPort2);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kzhdo")
|
break;
|
||||||
|
case "dmc4kzhdo":
|
||||||
{
|
{
|
||||||
var outputCard = new Dmc4kzHdoSingle(number, Chassis);
|
var outputCard = new Dmc4kzHdoSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
var cecPort2 = outputCard.Card2.HdmiOutput;
|
var cecPort2 = outputCard.Card2.HdmiOutput;
|
||||||
AddDmcHdoPorts(number, cecPort1, cecPort2);
|
AddDmcHdoPorts(number, cecPort1, cecPort2);
|
||||||
}
|
}
|
||||||
else if (type == "dmchdo")
|
break;
|
||||||
|
case "dmchdo":
|
||||||
{
|
{
|
||||||
var outputCard = new DmcHdoSingle(number, Chassis);
|
var outputCard = new DmcHdoSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
var cecPort2 = outputCard.Card2.HdmiOutput;
|
var cecPort2 = outputCard.Card2.HdmiOutput;
|
||||||
AddDmcHdoPorts(number, cecPort1, cecPort2);
|
AddDmcHdoPorts(number, cecPort1, cecPort2);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kcohd")
|
break;
|
||||||
|
case "dmc4kcohd":
|
||||||
{
|
{
|
||||||
var outputCard = new Dmc4kCoHdSingle(number, Chassis);
|
var outputCard = new Dmc4kCoHdSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
AddDmcCoPorts(number, cecPort1);
|
AddDmcCoPorts(number, cecPort1);
|
||||||
}
|
}
|
||||||
else if (type == "dmc4kzcohd")
|
break;
|
||||||
|
case "dmc4kzcohd":
|
||||||
{
|
{
|
||||||
var outputCard = new Dmc4kzCoHdSingle(number, Chassis);
|
var outputCard = new Dmc4kzCoHdSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
AddDmcCoPorts(number, cecPort1);
|
AddDmcCoPorts(number, cecPort1);
|
||||||
}
|
}
|
||||||
else if (type == "dmccohd")
|
break;
|
||||||
|
case "dmccohd":
|
||||||
{
|
{
|
||||||
var outputCard = new DmcCoHdSingle(number, Chassis);
|
var outputCard = new DmcCoHdSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
AddDmcCoPorts(number, cecPort1);
|
AddDmcCoPorts(number, cecPort1);
|
||||||
}
|
}
|
||||||
else if (type == "dmccatohd")
|
break;
|
||||||
|
case "dmccatohd":
|
||||||
{
|
{
|
||||||
var outputCard = new DmcCatoHdSingle(number, Chassis);
|
var outputCard = new DmcCatoHdSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
AddDmcCoPorts(number, cecPort1);
|
AddDmcCoPorts(number, cecPort1);
|
||||||
}
|
}
|
||||||
else if (type == "dmcsohd")
|
break;
|
||||||
|
case "dmcsohd":
|
||||||
{
|
{
|
||||||
var outputCard = new DmcSoHdSingle(number, Chassis);
|
var outputCard = new DmcSoHdSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.DmMmFiber, 2 * (number - 1) + 1);
|
eRoutingPortConnectionType.DmMmFiber, Chassis.Outputs[2 * (number - 1) + 1]);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Hdmi, 2 * (number - 1) + 1, cecPort1);
|
eRoutingPortConnectionType.Hdmi, Chassis.Outputs[2 * (number - 1) + 1], cecPort1);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.DmMmFiber, 2 * (number - 1) + 2);
|
eRoutingPortConnectionType.DmMmFiber, Chassis.Outputs[2 * (number - 1) + 2]);
|
||||||
}
|
}
|
||||||
else if (type == "dmcs2ohd")
|
break;
|
||||||
|
case "dmcs2ohd":
|
||||||
{
|
{
|
||||||
var outputCard = new DmcS2oHdSingle(number, Chassis);
|
var outputCard = new DmcS2oHdSingle(number, Chassis);
|
||||||
var cecPort1 = outputCard.Card1.HdmiOutput;
|
var cecPort1 = outputCard.Card1.HdmiOutput;
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.DmSmFiber, 2 * (number - 1) + 1);
|
eRoutingPortConnectionType.DmSmFiber, Chassis.Outputs[2 * (number - 1) + 1]);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Hdmi, 2 * (number - 1) + 1, cecPort1);
|
eRoutingPortConnectionType.Hdmi, Chassis.Outputs[2 * (number - 1) + 1], cecPort1);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.DmSmFiber, 2 * (number - 1) + 2);
|
eRoutingPortConnectionType.DmSmFiber, Chassis.Outputs[2 * (number - 1) + 2]);
|
||||||
}
|
}
|
||||||
else if (type == "dmcstro")
|
break;
|
||||||
{
|
case "dmcstro":
|
||||||
var outputCard = new DmcStroSingle(number, Chassis);
|
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "streamOut", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "streamOut", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Streaming, 2 * (number - 1) + 1);
|
eRoutingPortConnectionType.Streaming, Chassis.Outputs[2 * (number - 1) + 1]);
|
||||||
}
|
break;
|
||||||
|
default:
|
||||||
else
|
|
||||||
Debug.Console(1, this, " WARNING: Output card type '{0}' is not available", type);
|
Debug.Console(1, this, " WARNING: Output card type '{0}' is not available", type);
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddDmcHdoPorts(uint number, ICec cecPort1, ICec cecPort2)
|
void AddDmcHdoPorts(uint number, ICec cecPort1, ICec cecPort2)
|
||||||
{
|
{
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Hdmi, 2 * (number - 1) + 1, cecPort1);
|
eRoutingPortConnectionType.Hdmi, Chassis.Outputs[2 * (number - 1) + 1], cecPort1);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "audioOut1", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "audioOut1", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio,
|
||||||
2 * (number - 1) + 1);
|
Chassis.Outputs[2 * (number - 1) + 1]);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Hdmi, 2 * (number - 1) + 2, cecPort2);
|
eRoutingPortConnectionType.Hdmi, Chassis.Outputs[2 * (number - 1) + 2], cecPort2);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "audioOut2", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "audioOut2", eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio,
|
||||||
2 * (number - 1) + 2);
|
Chassis.Outputs[2 * (number - 1) + 2]);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddDmcCoPorts(uint number, ICec cecPort1)
|
void AddDmcCoPorts(uint number, ICec cecPort1)
|
||||||
{
|
{
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.DmCat, 2 * (number - 1) + 1);
|
eRoutingPortConnectionType.DmCat, Chassis.Outputs[2 * (number - 1) + 1]);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "hdmiOut1", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Hdmi, 2 * (number - 1) + 1, cecPort1);
|
eRoutingPortConnectionType.Hdmi, Chassis.Outputs[2 * (number - 1) + 1], cecPort1);
|
||||||
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
AddOutputPortWithDebug(string.Format("outputCard{0}", number), "dmOut2", eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.DmCat, 2 * (number - 1) + 2);
|
eRoutingPortConnectionType.DmCat, Chassis.Outputs[2 * (number - 1) + 2]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -797,14 +815,7 @@ namespace PepperDash.Essentials.DM
|
||||||
/// </summary>
|
/// </summary>
|
||||||
void AddInputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType)
|
void AddInputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType)
|
||||||
{
|
{
|
||||||
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
AddInputPortWithDebug(cardNum, portName, sigType, portType, null);
|
||||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
|
||||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this)
|
|
||||||
{
|
|
||||||
FeedbackMatchObject = Chassis.Inputs[cardNum]
|
|
||||||
};
|
|
||||||
|
|
||||||
InputPorts.Add(inputPort);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -814,7 +825,7 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
||||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
||||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this)
|
var inputPort = new RoutingInputPort(portKey, sigType, portType, Chassis.Inputs[cardNum], this)
|
||||||
{
|
{
|
||||||
FeedbackMatchObject = Chassis.Inputs[cardNum]
|
FeedbackMatchObject = Chassis.Inputs[cardNum]
|
||||||
}; ;
|
}; ;
|
||||||
|
|
@ -830,17 +841,7 @@ namespace PepperDash.Essentials.DM
|
||||||
/// </summary>
|
/// </summary>
|
||||||
void AddOutputPortWithDebug(string cardName, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType, object selector)
|
void AddOutputPortWithDebug(string cardName, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType, object selector)
|
||||||
{
|
{
|
||||||
var portKey = string.Format("{0}--{1}", cardName, portName);
|
AddOutputPortWithDebug(cardName, portName, sigType, portType, selector, null);
|
||||||
Debug.Console(2, this, "Adding output port '{0}'", portKey);
|
|
||||||
|
|
||||||
var outputPort = new RoutingOutputPort(portKey, sigType, portType, selector, this);
|
|
||||||
|
|
||||||
if (portName.IndexOf("Loop", StringComparison.InvariantCultureIgnoreCase) < 0)
|
|
||||||
{
|
|
||||||
outputPort.FeedbackMatchObject = Chassis.Outputs[(uint) selector];
|
|
||||||
}
|
|
||||||
|
|
||||||
OutputPorts.Add(outputPort);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -854,7 +855,7 @@ namespace PepperDash.Essentials.DM
|
||||||
|
|
||||||
if (portName.IndexOf("Loop", StringComparison.InvariantCultureIgnoreCase) < 0)
|
if (portName.IndexOf("Loop", StringComparison.InvariantCultureIgnoreCase) < 0)
|
||||||
{
|
{
|
||||||
outputPort.FeedbackMatchObject = Chassis.Outputs[(uint)selector];
|
outputPort.FeedbackMatchObject = selector;
|
||||||
}
|
}
|
||||||
if (cecPort != null)
|
if (cecPort != null)
|
||||||
outputPort.Port = cecPort;
|
outputPort.Port = cecPort;
|
||||||
|
|
@ -1144,7 +1145,7 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
if (RouteOffTimers.ContainsKey(pnt))
|
if (RouteOffTimers.ContainsKey(pnt))
|
||||||
return;
|
return;
|
||||||
RouteOffTimers[pnt] = new CTimer(o => { ExecuteSwitch(0, pnt.Number, pnt.Type); }, RouteOffTime);
|
RouteOffTimers[pnt] = new CTimer(o => ExecuteSwitch(null, pnt.Selector, pnt.Type), RouteOffTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Send out sigs when coming online
|
// Send out sigs when coming online
|
||||||
|
|
@ -1173,16 +1174,22 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
Debug.Console(2, this, "Making an awesome DM route from {0} to {1} {2}", inputSelector, outputSelector, sigType);
|
Debug.Console(2, this, "Making an awesome DM route from {0} to {1} {2}", inputSelector, outputSelector, sigType);
|
||||||
|
|
||||||
var input = Convert.ToUInt32(inputSelector); // Cast can sometimes fail
|
var input = inputSelector as DMInput;//Input Selector could be null...
|
||||||
var output = Convert.ToUInt32(outputSelector);
|
|
||||||
|
|
||||||
var chassisSize = (uint) Chassis.NumberOfInputs; //need this to determine USB routing values 8x8 -> 1-8 is inputs 1-8, 17-24 is outputs 1-8
|
var output = outputSelector as DMOutput;
|
||||||
//16x16 1-16 is inputs 1-16, 17-32 is outputs 1-16
|
|
||||||
//32x32 1-32 is inputs 1-32, 33-64 is outputs 1-32
|
if (output == null)
|
||||||
|
{
|
||||||
|
Debug.Console(0, this, Debug.ErrorLogLevel.Warning,
|
||||||
|
"Unable to execute switch for inputSelector {0} to outputSelector {1}", inputSelector,
|
||||||
|
outputSelector);
|
||||||
|
return;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
// Check to see if there's an off timer waiting on this and if so, cancel
|
// Check to see if there's an off timer waiting on this and if so, cancel
|
||||||
var key = new PortNumberType(output, sigType);
|
var key = new PortNumberType(output, sigType);
|
||||||
if (input == 0)
|
if (input == null)
|
||||||
{
|
{
|
||||||
StartOffTimer(key);
|
StartOffTimer(key);
|
||||||
}
|
}
|
||||||
|
|
@ -1196,30 +1203,75 @@ namespace PepperDash.Essentials.DM
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var inCard = input == 0 ? null : Chassis.Inputs[input];
|
//var inCard = input == 0 ? null : Chassis.Inputs[input];
|
||||||
var outCard = input == 0 ? null : Chassis.Outputs[output];
|
//var outCard = input == 0 ? null : Chassis.Outputs[output];
|
||||||
|
|
||||||
// NOTE THAT BITWISE COMPARISONS - TO CATCH ALL ROUTING TYPES
|
// NOTE THAT BITWISE COMPARISONS - TO CATCH ALL ROUTING TYPES
|
||||||
if ((sigType & eRoutingSignalType.Video) == eRoutingSignalType.Video)
|
if ((sigType & eRoutingSignalType.Video) == eRoutingSignalType.Video)
|
||||||
{
|
{
|
||||||
Chassis.VideoEnter.BoolValue = true;
|
Chassis.VideoEnter.BoolValue = true;
|
||||||
Chassis.Outputs[output].VideoOut = inCard;
|
output.VideoOut = input; //Chassis.Outputs[output].VideoOut = inCard;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((sigType & eRoutingSignalType.Audio) == eRoutingSignalType.Audio)
|
if ((sigType & eRoutingSignalType.Audio) == eRoutingSignalType.Audio)
|
||||||
{
|
{
|
||||||
(Chassis as DmMDMnxn).AudioEnter.BoolValue = true;
|
var dmMdMnxn = Chassis as DmMDMnxn;
|
||||||
Chassis.Outputs[output].AudioOut = inCard;
|
if (dmMdMnxn != null)
|
||||||
|
{
|
||||||
|
dmMdMnxn.AudioEnter.BoolValue = true;
|
||||||
|
}
|
||||||
|
output.VideoOut = input;
|
||||||
|
//Chassis.Outputs[output].AudioOut = inCard;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput)
|
if ((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput || (sigType & eRoutingSignalType.UsbInput) == eRoutingSignalType.UsbInput)
|
||||||
{
|
{
|
||||||
//using base here because USB can be routed between 2 output cards or 2 input cards
|
Chassis.USBEnter.BoolValue = true;
|
||||||
|
output.USBRoutedTo = input;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
#region IRoutingNumeric Members
|
||||||
|
|
||||||
|
public void ExecuteNumericSwitch(ushort inputSelector, ushort outputSelector, eRoutingSignalType sigType)
|
||||||
|
{
|
||||||
|
var chassisSize = (uint)Chassis.NumberOfInputs; //need this to determine USB routing values 8x8 -> 1-8 is inputs 1-8, 17-24 is outputs 1-8
|
||||||
|
//16x16 1-16 is inputs 1-16, 17-32 is outputs 1-16
|
||||||
|
//32x32 1-32 is inputs 1-32, 33-64 is outputs 1-32
|
||||||
|
|
||||||
DMInputOutputBase dmCard;
|
DMInputOutputBase dmCard;
|
||||||
|
|
||||||
Debug.Console(2, this, "Executing USB Output switch.\r\n in:{0} output: {1}", input, output);
|
if ((sigType & eRoutingSignalType.UsbInput) == eRoutingSignalType.UsbInput)
|
||||||
|
{
|
||||||
|
if (outputSelector > chassisSize)
|
||||||
|
{
|
||||||
|
uint outputIndex;
|
||||||
|
|
||||||
if (input > chassisSize)
|
if (chassisSize == 8)
|
||||||
|
{
|
||||||
|
outputIndex = (uint) inputSelector - 16;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
outputIndex = inputSelector - chassisSize;
|
||||||
|
}
|
||||||
|
dmCard = Chassis.Outputs[outputIndex];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dmCard = Chassis.Inputs[inputSelector];
|
||||||
|
}
|
||||||
|
|
||||||
|
ExecuteSwitch(dmCard, Chassis.Outputs[outputSelector], sigType);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput)
|
||||||
|
{
|
||||||
|
Debug.Console(2, this, "Executing USB Output switch.\r\n in:{0} output: {1}", inputSelector, outputSelector);
|
||||||
|
|
||||||
|
if (inputSelector > chassisSize)
|
||||||
{
|
{
|
||||||
//wanting to route an output to an output. Subtract chassis size and get output, unless it's 8x8
|
//wanting to route an output to an output. Subtract chassis size and get output, unless it's 8x8
|
||||||
//need this to determine USB routing values
|
//need this to determine USB routing values
|
||||||
|
|
@ -1230,76 +1282,30 @@ namespace PepperDash.Essentials.DM
|
||||||
|
|
||||||
if (chassisSize == 8)
|
if (chassisSize == 8)
|
||||||
{
|
{
|
||||||
outputIndex = input - 16;
|
outputIndex = (uint) inputSelector - 16;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
outputIndex = input - chassisSize;
|
outputIndex = inputSelector - chassisSize;
|
||||||
}
|
}
|
||||||
|
|
||||||
dmCard = Chassis.Outputs[outputIndex];
|
dmCard = Chassis.Outputs[outputIndex];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
dmCard = inCard;
|
dmCard = Chassis.Inputs[inputSelector];
|
||||||
}
|
}
|
||||||
Chassis.USBEnter.BoolValue = true;
|
Chassis.USBEnter.BoolValue = true;
|
||||||
if (Chassis.Outputs[output] != null)
|
|
||||||
{
|
|
||||||
Debug.Console(2, this, "Routing USB for input {0} to {1}", Chassis.Outputs[input], dmCard);
|
|
||||||
Chassis.Outputs[output].USBRoutedTo = dmCard;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((sigType & eRoutingSignalType.UsbInput) == eRoutingSignalType.UsbInput)
|
Debug.Console(2, this, "Routing USB for input {0} to {1}", inputSelector, dmCard);
|
||||||
{
|
ExecuteSwitch(dmCard, Chassis.Outputs[outputSelector], sigType);
|
||||||
//using base here because USB can be routed between 2 output cards or 2 input cards
|
|
||||||
DMInputOutputBase dmCard;
|
|
||||||
|
|
||||||
Debug.Console(2, this, "Executing USB Input switch.\r\n in:{0} output: {1}", input, output);
|
|
||||||
|
|
||||||
if (output > chassisSize)
|
|
||||||
{
|
|
||||||
//wanting to route an input to an output. Subtract chassis size and get output, unless it's 8x8
|
|
||||||
//need this to determine USB routing values
|
|
||||||
//8x8 -> 1-8 is inputs 1-8, 17-24 is outputs 1-8
|
|
||||||
//16x16 1-16 is inputs 1-16, 17-32 is outputs 1-16
|
|
||||||
//32x32 1-32 is inputs 1-32, 33-64 is outputs 1-32
|
|
||||||
uint outputIndex;
|
|
||||||
|
|
||||||
if (chassisSize == 8)
|
|
||||||
{
|
|
||||||
outputIndex = input - 16;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
outputIndex = input - chassisSize;
|
|
||||||
}
|
|
||||||
dmCard = Chassis.Outputs[outputIndex];
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
dmCard = Chassis.Inputs[input];
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Chassis.USBEnter.BoolValue = true;
|
|
||||||
|
|
||||||
if (Chassis.Inputs[output] == null)
|
|
||||||
{
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Debug.Console(2, this, "Routing USB for input {0} to {1}", Chassis.Inputs[output], dmCard);
|
|
||||||
Chassis.Inputs[output].USBRoutedTo = dmCard;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endregion
|
|
||||||
|
|
||||||
#region IRoutingNumeric Members
|
var inputCard = inputSelector == 0 ? null : Chassis.Inputs[inputSelector];
|
||||||
|
var outputCard = Chassis.Outputs[outputSelector];
|
||||||
|
|
||||||
public void ExecuteNumericSwitch(ushort inputSelector, ushort outputSelector, eRoutingSignalType sigType)
|
ExecuteSwitch(inputCard, outputCard, sigType);
|
||||||
{
|
|
||||||
ExecuteSwitch(inputSelector, outputSelector, sigType);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
@ -1850,13 +1856,23 @@ namespace PepperDash.Essentials.DM
|
||||||
public struct PortNumberType
|
public struct PortNumberType
|
||||||
{
|
{
|
||||||
public uint Number { get; private set; }
|
public uint Number { get; private set; }
|
||||||
|
public object Selector { get; private set; }
|
||||||
public eRoutingSignalType Type { get; private set; }
|
public eRoutingSignalType Type { get; private set; }
|
||||||
|
|
||||||
public PortNumberType(uint number, eRoutingSignalType type)
|
public PortNumberType(object selector, eRoutingSignalType type)
|
||||||
: this()
|
: this()
|
||||||
{
|
{
|
||||||
Number = number;
|
Selector = selector;
|
||||||
Type = type;
|
Type = type;
|
||||||
|
|
||||||
|
if (Selector is DMOutput)
|
||||||
|
{
|
||||||
|
Number = (selector as DMOutput).Number;
|
||||||
|
}
|
||||||
|
else if (Selector is uint)
|
||||||
|
{
|
||||||
|
Number = (uint) selector;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -21,6 +21,8 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
public class DmpsRoutingController : EssentialsBridgeableDevice, IRoutingNumericWithFeedback, IHasFeedback
|
public class DmpsRoutingController : EssentialsBridgeableDevice, IRoutingNumericWithFeedback, IHasFeedback
|
||||||
{
|
{
|
||||||
|
private const string NonePortKey = "none";
|
||||||
|
|
||||||
public CrestronControlSystem Dmps { get; set; }
|
public CrestronControlSystem Dmps { get; set; }
|
||||||
public ISystemControl SystemControl { get; private set; }
|
public ISystemControl SystemControl { get; private set; }
|
||||||
|
|
||||||
|
|
@ -75,20 +77,18 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
var systemControl = Global.ControlSystem.SystemControl;
|
||||||
ISystemControl systemControl = null;
|
|
||||||
|
|
||||||
systemControl = Global.ControlSystem.SystemControl as ISystemControl;
|
|
||||||
|
|
||||||
if (systemControl == null)
|
if (systemControl == null)
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
var controller = new DmpsRoutingController(key, name, systemControl);
|
var controller = new DmpsRoutingController(key, name, systemControl)
|
||||||
|
{
|
||||||
controller.InputNames = properties.InputNames;
|
InputNames = properties.InputNames,
|
||||||
controller.OutputNames = properties.OutputNames;
|
OutputNames = properties.OutputNames
|
||||||
|
};
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(properties.NoRouteText))
|
if (!string.IsNullOrEmpty(properties.NoRouteText))
|
||||||
controller.NoRouteText = properties.NoRouteText;
|
controller.NoRouteText = properties.NoRouteText;
|
||||||
|
|
@ -96,9 +96,9 @@ namespace PepperDash.Essentials.DM
|
||||||
return controller;
|
return controller;
|
||||||
|
|
||||||
}
|
}
|
||||||
catch (System.Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Debug.Console(0, "Error getting DMPS Controller:\r{0}", e);
|
Debug.Console(0, "Error getting DMPS Controller:\r\n{0}", e);
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
@ -113,6 +113,7 @@ namespace PepperDash.Essentials.DM
|
||||||
public DmpsRoutingController(string key, string name, ISystemControl systemControl)
|
public DmpsRoutingController(string key, string name, ISystemControl systemControl)
|
||||||
: base(key, name)
|
: base(key, name)
|
||||||
{
|
{
|
||||||
|
|
||||||
Dmps = Global.ControlSystem;
|
Dmps = Global.ControlSystem;
|
||||||
SystemControl = systemControl;
|
SystemControl = systemControl;
|
||||||
|
|
||||||
|
|
@ -427,14 +428,11 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
Debug.Console(1, this, "Adding Input Card Number {0} Type: {1}", inputCard.Number, inputCard.CardInputOutputType.ToString());
|
Debug.Console(1, this, "Adding Input Card Number {0} Type: {1}", inputCard.Number, inputCard.CardInputOutputType.ToString());
|
||||||
|
|
||||||
InputEndpointOnlineFeedbacks[inputCard.Number] = new BoolFeedback(() => { return inputCard.EndpointOnlineFeedback; });
|
InputEndpointOnlineFeedbacks[inputCard.Number] = new BoolFeedback(() => inputCard.EndpointOnlineFeedback);
|
||||||
|
|
||||||
if (inputCard.VideoDetectedFeedback != null)
|
if (inputCard.VideoDetectedFeedback != null)
|
||||||
{
|
{
|
||||||
VideoInputSyncFeedbacks[inputCard.Number] = new BoolFeedback(() =>
|
VideoInputSyncFeedbacks[inputCard.Number] = new BoolFeedback(() => inputCard.VideoDetectedFeedback.BoolValue);
|
||||||
{
|
|
||||||
return inputCard.VideoDetectedFeedback.BoolValue;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
InputNameFeedbacks[inputCard.Number] = new StringFeedback(() =>
|
InputNameFeedbacks[inputCard.Number] = new StringFeedback(() =>
|
||||||
|
|
@ -443,13 +441,10 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
Debug.Console(2, this, "Input Card {0} Name: {1}", inputCard.Number, inputCard.NameFeedback.StringValue);
|
Debug.Console(2, this, "Input Card {0} Name: {1}", inputCard.Number, inputCard.NameFeedback.StringValue);
|
||||||
return inputCard.NameFeedback.StringValue;
|
return inputCard.NameFeedback.StringValue;
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
Debug.Console(2, this, "Input Card {0} Name is null", inputCard.Number);
|
Debug.Console(2, this, "Input Card {0} Name is null", inputCard.Number);
|
||||||
return "";
|
return "";
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
AddInputCard(inputCard.Number, inputCard);
|
AddInputCard(inputCard.Number, inputCard);
|
||||||
|
|
@ -459,6 +454,9 @@ namespace PepperDash.Essentials.DM
|
||||||
Debug.Console(2, this, "***********Input Card of type {0} is cannot be cast as DMInput*************", card.CardInputOutputType);
|
Debug.Console(2, this, "***********Input Card of type {0} is cannot be cast as DMInput*************", card.CardInputOutputType);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
InputPorts.Add(new RoutingInputPort(NonePortKey, eRoutingSignalType.AudioVideo,
|
||||||
|
eRoutingPortConnectionType.None, null, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -531,15 +529,7 @@ namespace PepperDash.Essentials.DM
|
||||||
private void AddInputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType,
|
private void AddInputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType,
|
||||||
eRoutingPortConnectionType portType)
|
eRoutingPortConnectionType portType)
|
||||||
{
|
{
|
||||||
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
AddInputPortWithDebug(cardNum, portName, sigType, portType, null);
|
||||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
|
||||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this)
|
|
||||||
{
|
|
||||||
FeedbackMatchObject = Dmps.SwitcherInputs[cardNum]
|
|
||||||
};
|
|
||||||
;
|
|
||||||
|
|
||||||
InputPorts.Add(inputPort);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -549,11 +539,10 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
var portKey = string.Format("inputCard{0}--{1}", cardNum, portName);
|
||||||
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
Debug.Console(2, this, "Adding input port '{0}'", portKey);
|
||||||
var inputPort = new RoutingInputPort(portKey, sigType, portType, cardNum, this)
|
var inputPort = new RoutingInputPort(portKey, sigType, portType, Dmps.SwitcherInputs[cardNum], this)
|
||||||
{
|
{
|
||||||
FeedbackMatchObject = Dmps.SwitcherInputs[cardNum]
|
FeedbackMatchObject = Dmps.SwitcherInputs[cardNum]
|
||||||
};
|
};
|
||||||
;
|
|
||||||
|
|
||||||
if (cecPort != null)
|
if (cecPort != null)
|
||||||
inputPort.Port = cecPort;
|
inputPort.Port = cecPort;
|
||||||
|
|
@ -672,7 +661,7 @@ namespace PepperDash.Essentials.DM
|
||||||
/// <param name="number"></param>
|
/// <param name="number"></param>
|
||||||
void AddAudioOnlyOutputPort(uint number, string portName)
|
void AddAudioOnlyOutputPort(uint number, string portName)
|
||||||
{
|
{
|
||||||
AddOutputPortWithDebug(number, portName, eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio, number);
|
AddOutputPortWithDebug(number, portName, eRoutingSignalType.Audio, eRoutingPortConnectionType.LineAudio, Dmps.SwitcherOutputs[number]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -682,7 +671,7 @@ namespace PepperDash.Essentials.DM
|
||||||
/// <param name="cecPort"></param>
|
/// <param name="cecPort"></param>
|
||||||
void AddHdmiOutputPort(uint number, ICec cecPort)
|
void AddHdmiOutputPort(uint number, ICec cecPort)
|
||||||
{
|
{
|
||||||
AddOutputPortWithDebug(number, string.Format("hdmiOut{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, number, cecPort);
|
AddOutputPortWithDebug(number, string.Format("hdmiOut{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.Hdmi, Dmps.SwitcherOutputs[number], cecPort);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -691,7 +680,7 @@ namespace PepperDash.Essentials.DM
|
||||||
/// <param name="number"></param>
|
/// <param name="number"></param>
|
||||||
void AddDmOutputPort(uint number)
|
void AddDmOutputPort(uint number)
|
||||||
{
|
{
|
||||||
AddOutputPortWithDebug(number, string.Format("dmOut{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmCat, number);
|
AddOutputPortWithDebug(number, string.Format("dmOut{0}", number), eRoutingSignalType.Audio | eRoutingSignalType.Video, eRoutingPortConnectionType.DmCat, Dmps.SwitcherOutputs[number]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -699,12 +688,7 @@ namespace PepperDash.Essentials.DM
|
||||||
/// </summary>
|
/// </summary>
|
||||||
void AddOutputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType, object selector)
|
void AddOutputPortWithDebug(uint cardNum, string portName, eRoutingSignalType sigType, eRoutingPortConnectionType portType, object selector)
|
||||||
{
|
{
|
||||||
var portKey = string.Format("outputCard{0}--{1}", cardNum, portName);
|
AddOutputPortWithDebug(cardNum, portName, sigType, portType, selector, null);
|
||||||
Debug.Console(2, this, "Adding output port '{0}'", portKey);
|
|
||||||
OutputPorts.Add(new RoutingOutputPort(portKey, sigType, portType, selector, this)
|
|
||||||
{
|
|
||||||
FeedbackMatchObject = Dmps.SwitcherOutputs[cardNum]
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -836,7 +820,7 @@ namespace PepperDash.Essentials.DM
|
||||||
{
|
{
|
||||||
if (RouteOffTimers.ContainsKey(pnt))
|
if (RouteOffTimers.ContainsKey(pnt))
|
||||||
return;
|
return;
|
||||||
RouteOffTimers[pnt] = new CTimer(o => ExecuteSwitch(0, pnt.Number, pnt.Type), RouteOffTime);
|
RouteOffTimers[pnt] = new CTimer(o => ExecuteSwitch(null, pnt.Selector, pnt.Type), RouteOffTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
#region IRouting Members
|
#region IRouting Members
|
||||||
|
|
@ -848,21 +832,32 @@ namespace PepperDash.Essentials.DM
|
||||||
|
|
||||||
Debug.Console(2, this, "Attempting a DM route from input {0} to output {1} {2}", inputSelector, outputSelector, sigType);
|
Debug.Console(2, this, "Attempting a DM route from input {0} to output {1} {2}", inputSelector, outputSelector, sigType);
|
||||||
|
|
||||||
var input = Convert.ToUInt32(inputSelector); // Cast can sometimes fail
|
//var input = Convert.ToUInt32(inputSelector); // Cast can sometimes fail
|
||||||
var output = Convert.ToUInt32(outputSelector);
|
//var output = Convert.ToUInt32(outputSelector);
|
||||||
|
|
||||||
|
var input = inputSelector as DMInput;
|
||||||
|
var output = outputSelector as DMOutput;
|
||||||
|
|
||||||
|
if (output == null)
|
||||||
|
{
|
||||||
|
Debug.Console(0, this, Debug.ErrorLogLevel.Warning,
|
||||||
|
"Unable to execute switch for inputSelector {0} to outputSelector {1}", inputSelector,
|
||||||
|
outputSelector);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
var sigTypeIsUsbOrVideo = ((sigType & eRoutingSignalType.Video) == eRoutingSignalType.Video) ||
|
var sigTypeIsUsbOrVideo = ((sigType & eRoutingSignalType.Video) == eRoutingSignalType.Video) ||
|
||||||
((sigType & eRoutingSignalType.UsbInput) == eRoutingSignalType.UsbInput) ||
|
((sigType & eRoutingSignalType.UsbInput) == eRoutingSignalType.UsbInput) ||
|
||||||
((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput);
|
((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput);
|
||||||
|
|
||||||
if ((input <= Dmps.NumberOfSwitcherInputs && output <= Dmps.NumberOfSwitcherOutputs &&
|
if (input == null || (input.Number <= Dmps.NumberOfSwitcherInputs && output.Number <= Dmps.NumberOfSwitcherOutputs &&
|
||||||
sigTypeIsUsbOrVideo) ||
|
sigTypeIsUsbOrVideo) ||
|
||||||
(input <= Dmps.NumberOfSwitcherInputs + 5 && output <= Dmps.NumberOfSwitcherOutputs &&
|
(input.Number <= Dmps.NumberOfSwitcherInputs + 5 && output.Number <= Dmps.NumberOfSwitcherOutputs &&
|
||||||
(sigType & eRoutingSignalType.Audio) == eRoutingSignalType.Audio))
|
(sigType & eRoutingSignalType.Audio) == eRoutingSignalType.Audio))
|
||||||
{
|
{
|
||||||
// Check to see if there's an off timer waiting on this and if so, cancel
|
// Check to see if there's an off timer waiting on this and if so, cancel
|
||||||
var key = new PortNumberType(output, sigType);
|
var key = new PortNumberType(output, sigType);
|
||||||
if (input == 0)
|
if (input == null)
|
||||||
{
|
{
|
||||||
StartOffTimer(key);
|
StartOffTimer(key);
|
||||||
}
|
}
|
||||||
|
|
@ -877,60 +872,47 @@ namespace PepperDash.Essentials.DM
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
DMOutput dmOutputCard = output == 0 ? null : Dmps.SwitcherOutputs[output] as DMOutput;
|
//DMOutput dmOutputCard = output == 0 ? null : Dmps.SwitcherOutputs[output] as DMOutput;
|
||||||
|
|
||||||
//if (inCard != null)
|
//if (inCard != null)
|
||||||
//{
|
//{
|
||||||
// NOTE THAT BITWISE COMPARISONS - TO CATCH ALL ROUTING TYPES
|
// NOTE THAT BITWISE COMPARISONS - TO CATCH ALL ROUTING TYPES
|
||||||
if ((sigType & eRoutingSignalType.Video) == eRoutingSignalType.Video)
|
if ((sigType & eRoutingSignalType.Video) == eRoutingSignalType.Video)
|
||||||
{
|
{
|
||||||
DMInput dmInputCard = input == 0 ? null : Dmps.SwitcherInputs[input] as DMInput;
|
|
||||||
//SystemControl.VideoEnter.BoolValue = true;
|
output.VideoOut = input;
|
||||||
if (dmOutputCard != null)
|
|
||||||
dmOutputCard.VideoOut = dmInputCard;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((sigType & eRoutingSignalType.Audio) == eRoutingSignalType.Audio)
|
if ((sigType & eRoutingSignalType.Audio) == eRoutingSignalType.Audio)
|
||||||
{
|
{
|
||||||
DMInput dmInputCard = null;
|
|
||||||
if (input <= Dmps.NumberOfSwitcherInputs)
|
|
||||||
{
|
|
||||||
dmInputCard = input == 0 ? null : Dmps.SwitcherInputs[input] as DMInput;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (dmOutputCard != null)
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
dmOutputCard.AudioOut = dmInputCard;
|
output.AudioOut = input;
|
||||||
}
|
}
|
||||||
catch (NotSupportedException)
|
catch (NotSupportedException)
|
||||||
{
|
{
|
||||||
Debug.Console(1, this, "Routing input {0} audio to output {1}",
|
Debug.Console(1, this, "Routing input {0} audio to output {1}",
|
||||||
(eDmps34KAudioOutSource) input, (CrestronControlSystem.eDmps34K350COutputs) output);
|
(eDmps34KAudioOutSource) (input == null ? 0 : input.Number),
|
||||||
|
(CrestronControlSystem.eDmps34K350COutputs) output.Number);
|
||||||
|
|
||||||
dmOutputCard.AudioOutSource = (eDmps34KAudioOutSource) input;
|
output.AudioOutSource = input == null
|
||||||
|
? eDmps34KAudioOutSource.NoRoute
|
||||||
|
: (eDmps34KAudioOutSource)input.Number;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput)
|
if ((sigType & eRoutingSignalType.UsbOutput) == eRoutingSignalType.UsbOutput)
|
||||||
{
|
{
|
||||||
DMInput dmInputCard = input == 0 ? null : Dmps.SwitcherInputs[input] as DMInput;
|
|
||||||
if (dmOutputCard != null)
|
output.USBRoutedTo = input;
|
||||||
dmOutputCard.USBRoutedTo = dmInputCard;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((sigType & eRoutingSignalType.UsbInput) == eRoutingSignalType.UsbInput)
|
if ((sigType & eRoutingSignalType.UsbInput) != eRoutingSignalType.UsbInput)
|
||||||
{
|
{
|
||||||
DMInput dmInputCard = input == 0 ? null : Dmps.SwitcherInputs[input] as DMInput;
|
return;
|
||||||
if (dmInputCard != null)
|
|
||||||
dmInputCard.USBRoutedTo = dmOutputCard;
|
|
||||||
}
|
}
|
||||||
//}
|
if (input != null)
|
||||||
//else
|
input.USBRoutedTo = output;
|
||||||
//{
|
|
||||||
// Debug.Console(1, this, "Unable to execute route from input {0} to output {1}. Input card not available", inputSelector, outputSelector);
|
|
||||||
//}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
@ -950,7 +932,10 @@ namespace PepperDash.Essentials.DM
|
||||||
|
|
||||||
public void ExecuteNumericSwitch(ushort inputSelector, ushort outputSelector, eRoutingSignalType sigType)
|
public void ExecuteNumericSwitch(ushort inputSelector, ushort outputSelector, eRoutingSignalType sigType)
|
||||||
{
|
{
|
||||||
ExecuteSwitch(inputSelector, outputSelector, sigType);
|
var input = inputSelector == 0 ? null : Dmps.SwitcherInputs[inputSelector];
|
||||||
|
var output = Dmps.SwitcherOutputs[outputSelector];
|
||||||
|
|
||||||
|
ExecuteSwitch(input, output, sigType);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,17 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||||
void CameraOff();
|
void CameraOff();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Describes the ability to mute and unmute camera video
|
||||||
|
/// </summary>
|
||||||
|
public interface IHasCameraMute
|
||||||
|
{
|
||||||
|
BoolFeedback CameraIsMutedFeedback { get; }
|
||||||
|
void CameraMuteOn();
|
||||||
|
void CameraMuteOff();
|
||||||
|
void CameraMuteToggle();
|
||||||
|
}
|
||||||
|
|
||||||
public class CameraSelectedEventArgs : EventArgs
|
public class CameraSelectedEventArgs : EventArgs
|
||||||
{
|
{
|
||||||
public CameraBase SelectedCamera { get; private set; }
|
public CameraBase SelectedCamera { get; private set; }
|
||||||
|
|
|
||||||
|
|
@ -4,19 +4,20 @@ using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using Crestron.SimplSharp;
|
using Crestron.SimplSharp;
|
||||||
using Crestron.SimplSharpPro;
|
using Crestron.SimplSharpPro;
|
||||||
|
using Crestron.SimplSharpPro.DeviceSupport;
|
||||||
|
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using Newtonsoft.Json.Linq;
|
using Newtonsoft.Json.Linq;
|
||||||
|
|
||||||
|
|
||||||
using PepperDash.Core;
|
using PepperDash.Core;
|
||||||
using PepperDash.Essentials.Core;
|
using PepperDash.Essentials.Core;
|
||||||
using PepperDash.Essentials.Core.Routing;
|
using PepperDash.Essentials.Core.Routing;
|
||||||
using PepperDash.Essentials.Core.Config;
|
using PepperDash.Essentials.Core.Config;
|
||||||
|
using PepperDash.Essentials.Core.Bridges;
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Devices.Common
|
namespace PepperDash.Essentials.Devices.Common
|
||||||
{
|
{
|
||||||
public class IRBlurayBase : EssentialsDevice, IDiscPlayerControls, IUiDisplayInfo, IRoutingOutputs, IUsageTracking
|
public class IRBlurayBase : EssentialsBridgeableDevice, IDiscPlayerControls, IUiDisplayInfo, IRoutingOutputs, IUsageTracking
|
||||||
{
|
{
|
||||||
public IrOutputPortController IrPort { get; private set; }
|
public IrOutputPortController IrPort { get; private set; }
|
||||||
|
|
||||||
|
|
@ -45,6 +46,113 @@ namespace PepperDash.Essentials.Devices.Common
|
||||||
OutputPorts = new RoutingPortCollection<RoutingOutputPort> { HdmiOut, AnyAudioOut };
|
OutputPorts = new RoutingPortCollection<RoutingOutputPort> { HdmiOut, AnyAudioOut };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
||||||
|
{
|
||||||
|
var joinMap = new IRBlurayBaseJoinMap(joinStart);
|
||||||
|
var joinMapSerialized = JoinMapHelper.GetSerializedJoinMapForDevice(joinMapKey);
|
||||||
|
|
||||||
|
if (!string.IsNullOrEmpty(joinMapSerialized))
|
||||||
|
joinMap = JsonConvert.DeserializeObject<IRBlurayBaseJoinMap>(joinMapSerialized);
|
||||||
|
|
||||||
|
if (bridge != null)
|
||||||
|
{
|
||||||
|
bridge.AddJoinMap(Key, joinMap);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.Console(0, this, "Please update config to use 'eiscapiadvanced' to get all join map features for this device.");
|
||||||
|
}
|
||||||
|
|
||||||
|
Debug.Console(1, "Linking to Trilist '{0}'", trilist.ID.ToString("X"));
|
||||||
|
Debug.Console(0, "Linking to SetTopBox: {0}", Name);
|
||||||
|
|
||||||
|
|
||||||
|
trilist.OnlineStatusChange += new OnlineStatusChangeEventHandler((o, a) =>
|
||||||
|
{
|
||||||
|
if (a.DeviceOnLine)
|
||||||
|
{
|
||||||
|
trilist.StringInput[joinMap.Name.JoinNumber].StringValue = Name;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
var powerDev = this as IHasPowerControl;
|
||||||
|
if (powerDev != null)
|
||||||
|
{
|
||||||
|
trilist.SetSigTrueAction(joinMap.PowerOn.JoinNumber, powerDev.PowerOn);
|
||||||
|
trilist.SetSigTrueAction(joinMap.PowerOff.JoinNumber, powerDev.PowerOff);
|
||||||
|
trilist.SetSigTrueAction(joinMap.PowerToggle.JoinNumber, powerDev.PowerToggle);
|
||||||
|
}
|
||||||
|
|
||||||
|
var dpadDev = this as IDPad;
|
||||||
|
if (dpadDev != null)
|
||||||
|
{
|
||||||
|
trilist.SetBoolSigAction(joinMap.Up.JoinNumber, dpadDev.Up);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Down.JoinNumber, dpadDev.Down);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Left.JoinNumber, dpadDev.Left);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Right.JoinNumber, dpadDev.Right);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Select.JoinNumber, dpadDev.Select);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Menu.JoinNumber, dpadDev.Menu);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Exit.JoinNumber, dpadDev.Exit);
|
||||||
|
}
|
||||||
|
|
||||||
|
var channelDev = this as IChannel;
|
||||||
|
if (channelDev != null)
|
||||||
|
{
|
||||||
|
trilist.SetBoolSigAction(joinMap.ChannelUp.JoinNumber, channelDev.ChannelUp);
|
||||||
|
trilist.SetBoolSigAction(joinMap.ChannelDown.JoinNumber, channelDev.ChannelDown);
|
||||||
|
trilist.SetBoolSigAction(joinMap.LastChannel.JoinNumber, channelDev.LastChannel);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Guide.JoinNumber, channelDev.Guide);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Info.JoinNumber, channelDev.Info);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Exit.JoinNumber, channelDev.Exit);
|
||||||
|
}
|
||||||
|
|
||||||
|
var colorDev = this as IColor;
|
||||||
|
if (colorDev != null)
|
||||||
|
{
|
||||||
|
trilist.SetBoolSigAction(joinMap.Red.JoinNumber, colorDev.Red);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Green.JoinNumber, colorDev.Green);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Yellow.JoinNumber, colorDev.Yellow);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Blue.JoinNumber, colorDev.Blue);
|
||||||
|
}
|
||||||
|
|
||||||
|
var keypadDev = this as ISetTopBoxNumericKeypad;
|
||||||
|
if (keypadDev != null)
|
||||||
|
{
|
||||||
|
trilist.StringInput[joinMap.KeypadAccessoryButton1Label.JoinNumber].StringValue = keypadDev.KeypadAccessoryButton1Label;
|
||||||
|
trilist.StringInput[joinMap.KeypadAccessoryButton2Label.JoinNumber].StringValue = keypadDev.KeypadAccessoryButton2Label;
|
||||||
|
|
||||||
|
trilist.BooleanInput[joinMap.HasKeypadAccessoryButton1.JoinNumber].BoolValue = keypadDev.HasKeypadAccessoryButton1;
|
||||||
|
trilist.BooleanInput[joinMap.HasKeypadAccessoryButton2.JoinNumber].BoolValue = keypadDev.HasKeypadAccessoryButton2;
|
||||||
|
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit0.JoinNumber, keypadDev.Digit0);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit1.JoinNumber, keypadDev.Digit1);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit2.JoinNumber, keypadDev.Digit2);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit3.JoinNumber, keypadDev.Digit3);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit4.JoinNumber, keypadDev.Digit4);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit5.JoinNumber, keypadDev.Digit5);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit6.JoinNumber, keypadDev.Digit6);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit7.JoinNumber, keypadDev.Digit7);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit8.JoinNumber, keypadDev.Digit8);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Digit9.JoinNumber, keypadDev.Digit9);
|
||||||
|
trilist.SetBoolSigAction(joinMap.KeypadAccessoryButton1Press.JoinNumber, keypadDev.KeypadAccessoryButton1);
|
||||||
|
trilist.SetBoolSigAction(joinMap.KeypadAccessoryButton2Press.JoinNumber, keypadDev.KeypadAccessoryButton1);
|
||||||
|
trilist.SetBoolSigAction(joinMap.KeypadEnter.JoinNumber, keypadDev.KeypadEnter);
|
||||||
|
}
|
||||||
|
|
||||||
|
var transportDev = this as ITransport;
|
||||||
|
if (transportDev != null)
|
||||||
|
{
|
||||||
|
trilist.SetBoolSigAction(joinMap.Play.JoinNumber, transportDev.Play);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Pause.JoinNumber, transportDev.Pause);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Rewind.JoinNumber, transportDev.Rewind);
|
||||||
|
trilist.SetBoolSigAction(joinMap.FFwd.JoinNumber, transportDev.FFwd);
|
||||||
|
trilist.SetBoolSigAction(joinMap.ChapMinus.JoinNumber, transportDev.ChapMinus);
|
||||||
|
trilist.SetBoolSigAction(joinMap.ChapPlus.JoinNumber, transportDev.ChapPlus);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Stop.JoinNumber, transportDev.Stop);
|
||||||
|
trilist.SetBoolSigAction(joinMap.Record.JoinNumber, transportDev.Record);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
#region IDPad Members
|
#region IDPad Members
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -388,9 +388,16 @@ namespace PepperDash.Essentials.Devices.Common
|
||||||
}
|
}
|
||||||
|
|
||||||
Debug.Console(1, "Linking to Trilist '{0}'", trilist.ID.ToString("X"));
|
Debug.Console(1, "Linking to Trilist '{0}'", trilist.ID.ToString("X"));
|
||||||
Debug.Console(0, "Linking to Display: {0}", Name);
|
Debug.Console(0, "Linking to SetTopBox: {0}", Name);
|
||||||
|
|
||||||
|
trilist.OnlineStatusChange += new OnlineStatusChangeEventHandler((o, a) =>
|
||||||
|
{
|
||||||
|
if (a.DeviceOnLine)
|
||||||
|
{
|
||||||
trilist.StringInput[joinMap.Name.JoinNumber].StringValue = Name;
|
trilist.StringInput[joinMap.Name.JoinNumber].StringValue = Name;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
var stbBase = this as ISetTopBoxControls;
|
var stbBase = this as ISetTopBoxControls;
|
||||||
if (stbBase != null)
|
if (stbBase != null)
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ using PepperDash.Essentials.Core.Routing;
|
||||||
using PepperDash.Essentials.Devices.Common.Cameras;
|
using PepperDash.Essentials.Devices.Common.Cameras;
|
||||||
using PepperDash.Essentials.Devices.Common.Codec;
|
using PepperDash.Essentials.Devices.Common.Codec;
|
||||||
using PepperDash.Essentials.Devices.Common.VideoCodec;
|
using PepperDash.Essentials.Devices.Common.VideoCodec;
|
||||||
using PepperDash_Essentials_Core.DeviceTypeInterfaces;
|
using PepperDash.Essentials.Core.Queues;
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
{
|
{
|
||||||
|
|
@ -28,7 +28,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
|
|
||||||
public class CiscoSparkCodec : VideoCodecBase, IHasCallHistory, IHasCallFavorites, IHasDirectory,
|
public class CiscoSparkCodec : VideoCodecBase, IHasCallHistory, IHasCallFavorites, IHasDirectory,
|
||||||
IHasScheduleAwareness, IOccupancyStatusProvider, IHasCodecLayouts, IHasCodecSelfView,
|
IHasScheduleAwareness, IOccupancyStatusProvider, IHasCodecLayouts, IHasCodecSelfView,
|
||||||
ICommunicationMonitor, IRouting, IHasCodecCameras, IHasCameraAutoMode, IHasCodecRoomPresets, IHasExternalSourceSwitching, IHasBranding
|
ICommunicationMonitor, IRouting, IHasCodecCameras, IHasCameraAutoMode, IHasCodecRoomPresets, IHasExternalSourceSwitching, IHasBranding, IHasCameraOff, IHasCameraMute
|
||||||
{
|
{
|
||||||
public event EventHandler<DirectoryEventArgs> DirectoryResultReturned;
|
public event EventHandler<DirectoryEventArgs> DirectoryResultReturned;
|
||||||
|
|
||||||
|
|
@ -38,9 +38,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
|
|
||||||
public StatusMonitorBase CommunicationMonitor { get; private set; }
|
public StatusMonitorBase CommunicationMonitor { get; private set; }
|
||||||
|
|
||||||
private CrestronQueue<string> ReceiveQueue;
|
private GenericQueue ReceiveQueue;
|
||||||
|
|
||||||
private Thread ReceiveThread;
|
|
||||||
|
|
||||||
public BoolFeedback PresentationViewMaximizedFeedback { get; private set; }
|
public BoolFeedback PresentationViewMaximizedFeedback { get; private set; }
|
||||||
|
|
||||||
|
|
@ -302,12 +300,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
}
|
}
|
||||||
|
|
||||||
// The queue that will collect the repsonses in the order they are received
|
// The queue that will collect the repsonses in the order they are received
|
||||||
ReceiveQueue = new CrestronQueue<string>(25);
|
ReceiveQueue = new GenericQueue(this.Key + "-rxQueue", 25);
|
||||||
|
|
||||||
// The thread responsible for dequeuing and processing the messages
|
|
||||||
ReceiveThread = new Thread((o) => ProcessQueue(), null);
|
|
||||||
ReceiveThread.Priority = Thread.eThreadPriority.MediumPriority;
|
|
||||||
|
|
||||||
|
|
||||||
RoomIsOccupiedFeedback = new BoolFeedback(RoomIsOccupiedFeedbackFunc);
|
RoomIsOccupiedFeedback = new BoolFeedback(RoomIsOccupiedFeedbackFunc);
|
||||||
PeopleCountFeedback = new IntFeedback(PeopleCountFeedbackFunc);
|
PeopleCountFeedback = new IntFeedback(PeopleCountFeedbackFunc);
|
||||||
|
|
@ -317,6 +310,9 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
LocalLayoutFeedback = new StringFeedback(LocalLayoutFeedbackFunc);
|
LocalLayoutFeedback = new StringFeedback(LocalLayoutFeedbackFunc);
|
||||||
LocalLayoutIsProminentFeedback = new BoolFeedback(LocalLayoutIsProminentFeedbackFunc);
|
LocalLayoutIsProminentFeedback = new BoolFeedback(LocalLayoutIsProminentFeedbackFunc);
|
||||||
FarEndIsSharingContentFeedback = new BoolFeedback(FarEndIsSharingContentFeedbackFunc);
|
FarEndIsSharingContentFeedback = new BoolFeedback(FarEndIsSharingContentFeedbackFunc);
|
||||||
|
CameraIsOffFeedback = new BoolFeedback(() => CodecStatus.Status.Video.Input.MainVideoMute.BoolValue);
|
||||||
|
CameraIsMutedFeedback = CameraIsOffFeedback;
|
||||||
|
|
||||||
|
|
||||||
PresentationViewMaximizedFeedback = new BoolFeedback(() => CurrentPresentationView == "Maximized");
|
PresentationViewMaximizedFeedback = new BoolFeedback(() => CurrentPresentationView == "Maximized");
|
||||||
|
|
||||||
|
|
@ -382,8 +378,9 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
CodecStatus.Status.Video.Selfview.Mode.ValueChangedAction = SelfviewIsOnFeedback.FireUpdate;
|
CodecStatus.Status.Video.Selfview.Mode.ValueChangedAction = SelfviewIsOnFeedback.FireUpdate;
|
||||||
CodecStatus.Status.Video.Selfview.PIPPosition.ValueChangedAction = ComputeSelfviewPipStatus;
|
CodecStatus.Status.Video.Selfview.PIPPosition.ValueChangedAction = ComputeSelfviewPipStatus;
|
||||||
CodecStatus.Status.Video.Layout.LayoutFamily.Local.ValueChangedAction = ComputeLocalLayout;
|
CodecStatus.Status.Video.Layout.LayoutFamily.Local.ValueChangedAction = ComputeLocalLayout;
|
||||||
CodecStatus.Status.Conference.Presentation.Mode.ValueChangedAction += SharingContentIsOnFeedback.FireUpdate;
|
CodecStatus.Status.Conference.Presentation.Mode.ValueChangedAction = SharingContentIsOnFeedback.FireUpdate;
|
||||||
CodecStatus.Status.Conference.Presentation.Mode.ValueChangedAction += FarEndIsSharingContentFeedback.FireUpdate;
|
CodecStatus.Status.Conference.Presentation.Mode.ValueChangedAction = FarEndIsSharingContentFeedback.FireUpdate;
|
||||||
|
CodecStatus.Status.Video.Input.MainVideoMute.ValueChangedAction = CameraIsOffFeedback.FireUpdate;
|
||||||
|
|
||||||
CodecOsdIn = new RoutingInputPort(RoutingPortNames.CodecOsd, eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
CodecOsdIn = new RoutingInputPort(RoutingPortNames.CodecOsd, eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||||
eRoutingPortConnectionType.Hdmi, new Action(StopSharing), this);
|
eRoutingPortConnectionType.Hdmi, new Action(StopSharing), this);
|
||||||
|
|
@ -421,29 +418,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
_brandingUrl = props.UiBranding.BrandingUrl;
|
_brandingUrl = props.UiBranding.BrandingUrl;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Runs in it's own thread to dequeue messages in the order they were received to be processed
|
|
||||||
/// </summary>
|
|
||||||
/// <returns></returns>
|
|
||||||
object ProcessQueue()
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
while (true)
|
|
||||||
{
|
|
||||||
var message = ReceiveQueue.Dequeue();
|
|
||||||
|
|
||||||
DeserializeResponse(message);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
catch (Exception e)
|
|
||||||
{
|
|
||||||
Debug.Console(1, this, "Error Processing Queue: {0}", e);
|
|
||||||
}
|
|
||||||
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Creates the fake OSD source, and connects it's AudioVideo output to the CodecOsdIn input
|
/// Creates the fake OSD source, and connects it's AudioVideo output to the CodecOsdIn input
|
||||||
/// to enable routing
|
/// to enable routing
|
||||||
|
|
@ -687,11 +661,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
|
|
||||||
// Enqueue the complete message to be deserialized
|
// Enqueue the complete message to be deserialized
|
||||||
|
|
||||||
ReceiveQueue.Enqueue(JsonMessage.ToString());
|
ReceiveQueue.Enqueue(new ProcessStringMessage(JsonMessage.ToString(), DeserializeResponse));
|
||||||
//DeserializeResponse(JsonMessage.ToString());
|
|
||||||
|
|
||||||
if (ReceiveThread.ThreadState != Thread.eThreadStates.ThreadRunning)
|
|
||||||
ReceiveThread.Start();
|
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -1481,7 +1451,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
|
|
||||||
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
public override void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
||||||
{
|
{
|
||||||
throw new NotImplementedException();
|
LinkVideoCodecToApi(this, trilist, joinStart, joinMapKey, bridge);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -1664,6 +1634,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
public void CameraAutoModeOn()
|
public void CameraAutoModeOn()
|
||||||
{
|
{
|
||||||
SendText("xCommand Cameras SpeakerTrack Activate");
|
SendText("xCommand Cameras SpeakerTrack Activate");
|
||||||
|
CameraMuteOff();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CameraAutoModeOff()
|
public void CameraAutoModeOff()
|
||||||
|
|
@ -1739,6 +1710,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
_selectedCamera = value;
|
_selectedCamera = value;
|
||||||
SelectedCameraFeedback.FireUpdate();
|
SelectedCameraFeedback.FireUpdate();
|
||||||
ControllingFarEndCameraFeedback.FireUpdate();
|
ControllingFarEndCameraFeedback.FireUpdate();
|
||||||
|
if (CameraIsOffFeedback.BoolValue)
|
||||||
|
CameraMuteOff();
|
||||||
|
|
||||||
var handler = CameraSelected;
|
var handler = CameraSelected;
|
||||||
if (handler != null)
|
if (handler != null)
|
||||||
|
|
@ -2002,6 +1975,46 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
|
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
#region IHasCameraOff Members
|
||||||
|
|
||||||
|
public BoolFeedback CameraIsOffFeedback { get; private set; }
|
||||||
|
|
||||||
|
public void CameraOff()
|
||||||
|
{
|
||||||
|
CameraMuteOn();
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
public BoolFeedback CameraIsMutedFeedback { get; private set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Mutes the outgoing camera video
|
||||||
|
/// </summary>
|
||||||
|
public void CameraMuteOn()
|
||||||
|
{
|
||||||
|
SendText("xCommand Video InputMainVideo Mute");
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Unmutes the outgoing camera video
|
||||||
|
/// </summary>
|
||||||
|
public void CameraMuteOff()
|
||||||
|
{
|
||||||
|
SendText("xCommand Video InputMainVideo Unmute");
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Toggles the camera mute state
|
||||||
|
/// </summary>
|
||||||
|
public void CameraMuteToggle()
|
||||||
|
{
|
||||||
|
if (CameraIsMutedFeedback.BoolValue)
|
||||||
|
CameraMuteOff();
|
||||||
|
else
|
||||||
|
CameraMuteOn();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1606,6 +1606,22 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
public string Value { get; set; }
|
public string Value { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public class MainVideoMute : ValueProperty
|
||||||
|
{
|
||||||
|
public bool BoolValue { get; private set; }
|
||||||
|
|
||||||
|
public string Value
|
||||||
|
{
|
||||||
|
set
|
||||||
|
{
|
||||||
|
// If the incoming value is "On" it sets the BoolValue true, otherwise sets it false
|
||||||
|
BoolValue = value == "On";
|
||||||
|
OnValueChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public class ConnectorId
|
public class ConnectorId
|
||||||
{
|
{
|
||||||
public string Value { get; set; }
|
public string Value { get; set; }
|
||||||
|
|
@ -1662,6 +1678,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||||
{
|
{
|
||||||
public List<Connector> Connector { get; set; }
|
public List<Connector> Connector { get; set; }
|
||||||
public MainVideoSource MainVideoSource { get; set; }
|
public MainVideoSource MainVideoSource { get; set; }
|
||||||
|
public MainVideoMute MainVideoMute { get; set; }
|
||||||
public List<Source> Source { get; set; }
|
public List<Source> Source { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -19,8 +19,7 @@ using PepperDash.Essentials.Core.Routing;
|
||||||
using PepperDash.Essentials.Devices.Common.Cameras;
|
using PepperDash.Essentials.Devices.Common.Cameras;
|
||||||
using PepperDash.Essentials.Devices.Common.Codec;
|
using PepperDash.Essentials.Devices.Common.Codec;
|
||||||
using PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces;
|
using PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces;
|
||||||
using PepperDash_Essentials_Core.Bridges.JoinMaps;
|
using PepperDash.Essentials.Core.Bridges.JoinMaps;
|
||||||
using PepperDash_Essentials_Core.DeviceTypeInterfaces;
|
|
||||||
using Feedback = PepperDash.Essentials.Core.Feedback;
|
using Feedback = PepperDash.Essentials.Core.Feedback;
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||||
|
|
|
||||||
|
|
@ -17,13 +17,12 @@ using PepperDash.Essentials.Devices.Common.Cameras;
|
||||||
using PepperDash.Essentials.Devices.Common.Codec;
|
using PepperDash.Essentials.Devices.Common.Codec;
|
||||||
using PepperDash.Essentials.Devices.Common.VideoCodec.Cisco;
|
using PepperDash.Essentials.Devices.Common.VideoCodec.Cisco;
|
||||||
using PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces;
|
using PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces;
|
||||||
using PepperDash_Essentials_Core.DeviceTypeInterfaces;
|
|
||||||
|
|
||||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||||
{
|
{
|
||||||
public class ZoomRoom : VideoCodecBase, IHasCodecSelfView, IHasDirectoryHistoryStack, ICommunicationMonitor,
|
public class ZoomRoom : VideoCodecBase, IHasCodecSelfView, IHasDirectoryHistoryStack, ICommunicationMonitor,
|
||||||
IRouting,
|
IRouting,
|
||||||
IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraAutoMode,
|
IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraMute, IHasCameraAutoMode,
|
||||||
IHasFarEndContentStatus, IHasSelfviewPosition, IHasPhoneDialing
|
IHasFarEndContentStatus, IHasSelfviewPosition, IHasPhoneDialing
|
||||||
{
|
{
|
||||||
private const long MeetingRefreshTimer = 60000;
|
private const long MeetingRefreshTimer = 60000;
|
||||||
|
|
@ -98,6 +97,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||||
|
|
||||||
CameraIsOffFeedback = new BoolFeedback(CameraIsOffFeedbackFunc);
|
CameraIsOffFeedback = new BoolFeedback(CameraIsOffFeedbackFunc);
|
||||||
|
|
||||||
|
CameraIsMutedFeedback = CameraIsOffFeedback;
|
||||||
|
|
||||||
CameraAutoModeIsOnFeedback = new BoolFeedback(CameraAutoModeIsOnFeedbackFunc);
|
CameraAutoModeIsOnFeedback = new BoolFeedback(CameraAutoModeIsOnFeedbackFunc);
|
||||||
|
|
||||||
CodecSchedule = new CodecScheduleAwareness(MeetingRefreshTimer);
|
CodecSchedule = new CodecScheduleAwareness(MeetingRefreshTimer);
|
||||||
|
|
@ -1775,16 +1776,37 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||||
|
|
||||||
public void CameraOff()
|
public void CameraOff()
|
||||||
{
|
{
|
||||||
SendText("zConfiguration Call Camera Mute: On");
|
CameraMuteOn();
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
public BoolFeedback CameraIsMutedFeedback { get; private set; }
|
||||||
|
|
||||||
|
public void CameraMuteOn()
|
||||||
|
{
|
||||||
|
SendText("zConfiguration Call Camera Mute: On");
|
||||||
|
}
|
||||||
|
|
||||||
|
public void CameraMuteOff()
|
||||||
|
{
|
||||||
|
SendText("zConfiguration Call Camera Mute: Off");
|
||||||
|
}
|
||||||
|
|
||||||
|
public void CameraMuteToggle()
|
||||||
|
{
|
||||||
|
if (CameraIsMutedFeedback.BoolValue)
|
||||||
|
CameraMuteOff();
|
||||||
|
else
|
||||||
|
CameraMuteOn();
|
||||||
|
}
|
||||||
|
|
||||||
#region Implementation of IHasCameraAutoMode
|
#region Implementation of IHasCameraAutoMode
|
||||||
|
|
||||||
//Zoom doesn't support camera auto modes. Setting this to just unmute video
|
//Zoom doesn't support camera auto modes. Setting this to just unmute video
|
||||||
public void CameraAutoModeOn()
|
public void CameraAutoModeOn()
|
||||||
{
|
{
|
||||||
|
CameraMuteOff();
|
||||||
throw new NotImplementedException("Zoom Room Doesn't support camera auto mode");
|
throw new NotImplementedException("Zoom Room Doesn't support camera auto mode");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue