mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-01-30 21:04:48 +00:00
Compare commits
18 Commits
1.10.3-hot
...
2.0.0-beta
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c8ccbe1fcf | ||
|
|
ff068b98ac | ||
|
|
665101b4c8 | ||
|
|
8a3c7ce6d4 | ||
|
|
55cd3036c8 | ||
|
|
de3f2004de | ||
|
|
0cfc727b08 | ||
|
|
0f8251ea8a | ||
|
|
13cbeb7605 | ||
|
|
2fd2b6787f | ||
|
|
dd48147fdb | ||
|
|
33c3c1ad30 | ||
|
|
f154ce2385 | ||
|
|
9a0cf05360 | ||
|
|
d2e4be162d | ||
|
|
9dbfd9bcae | ||
|
|
8d1ec183df | ||
|
|
d52941d91d |
23
.github/scripts/GenerateVersionNumber-2.0.0.ps1
vendored
Normal file
23
.github/scripts/GenerateVersionNumber-2.0.0.ps1
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
$latestVersion = [version]"2.0.0"
|
||||
|
||||
$newVersion = [version]$latestVersion
|
||||
$phase = ""
|
||||
$newVersionString = ""
|
||||
|
||||
switch -regex ($Env:GITHUB_REF) {
|
||||
'^refs\/pull\/*.' {
|
||||
$phase = 'beta';
|
||||
$newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
|
||||
}
|
||||
'^refs\/heads\/feature-2.0.0\/*.' {
|
||||
$phase = 'alpha'
|
||||
$newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
|
||||
}
|
||||
'development-2.0.0' {
|
||||
$phase = 'beta'
|
||||
$newVersionString = "{0}-{1}-{2}" -f $newVersion, $phase, $Env:GITHUB_RUN_NUMBER
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Write-Output $newVersionString
|
||||
307
.github/workflows/Build Essentials.yml
vendored
Normal file
307
.github/workflows/Build Essentials.yml
vendored
Normal file
@@ -0,0 +1,307 @@
|
||||
name: Build Essentials 2.0.0
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- feature-2.0.0/*
|
||||
pull_request:
|
||||
types:
|
||||
- closed
|
||||
branches:
|
||||
- development-2.0.0
|
||||
|
||||
env:
|
||||
# solution path doesn't need slashes unless there it is multiple folders deep
|
||||
# solution name does not include extension. .sln is assumed
|
||||
SOLUTION_PATH: PepperDashEssentials
|
||||
SOLUTION_FILE: PepperDashEssentials
|
||||
# Do not edit this, we're just creating it here
|
||||
VERSION: 0.0.0-buildtype-buildnumber
|
||||
# Defaults to debug for build type
|
||||
BUILD_TYPE: Debug
|
||||
# Defaults to main as the release branch. Change as necessary
|
||||
RELEASE_BRANCH: main
|
||||
jobs:
|
||||
Build_Project:
|
||||
runs-on: windows-2019
|
||||
steps:
|
||||
# First we checkout the source repo
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
# Fetch all tags
|
||||
- name: Fetch tags
|
||||
run: git fetch --tags
|
||||
# Generate the appropriate version number
|
||||
- name: Set Version Number
|
||||
shell: powershell
|
||||
run: |
|
||||
$version = ./.github/scripts/GenerateVersionNumber-2.0.0.ps1
|
||||
echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
||||
# Use the version number to set the version of the assemblies
|
||||
- name: Update AssemblyInfo.cs
|
||||
shell: powershell
|
||||
run: |
|
||||
./.github/scripts/UpdateAssemblyVersion.ps1 ${{ env.VERSION }}
|
||||
- name: restore Nuget Packages
|
||||
run: nuget install .\packages.config -OutputDirectory .\packages -ExcludeVersion
|
||||
# Login to Docker
|
||||
- name: Login to Docker
|
||||
uses: azure/docker-login@v1
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_TOKEN }}
|
||||
# Build the solutions in the docker image
|
||||
- name: Build Solution
|
||||
shell: powershell
|
||||
run: |
|
||||
Invoke-Expression "docker run --rm --mount type=bind,source=""$($Env:GITHUB_WORKSPACE)"",target=""c:/project"" pepperdash/sspbuilder c:\cihelpers\vsidebuild.exe -Solution ""c:\project\$($Env:SOLUTION_FILE).sln"" -BuildSolutionConfiguration $($ENV:BUILD_TYPE)"
|
||||
# Zip up the output files as needed
|
||||
- name: Zip Build Output
|
||||
shell: powershell
|
||||
run: ./.github/scripts/ZipBuildOutput.ps1
|
||||
# Write the version to a file to be consumed by the push jobs
|
||||
- name: Write Version
|
||||
run: Write-Output "$($Env:VERSION)" | Out-File -FilePath "$($Env:GITHUB_HOME)\output\version.txt"
|
||||
# Upload the build output as an artifact
|
||||
- name: Upload Build Output
|
||||
uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: Build
|
||||
path: ./${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
|
||||
# Upload the Version file as an artifact
|
||||
- name: Upload version.txt
|
||||
uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: Version
|
||||
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
|
||||
id: create_release
|
||||
# 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
|
||||
with:
|
||||
tag_name: ${{ env.VERSION }}
|
||||
release_name: ${{ env.VERSION }}
|
||||
prerelease: ${{contains('debug', env.BUILD_TYPE)}}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
# Upload the build package to the release
|
||||
- name: Upload Release Package
|
||||
if: contains(env.VERSION,'-rc-') || contains(env.VERSION,'-hotfix-')
|
||||
id: upload_release
|
||||
uses: actions/upload-release-asset@v1
|
||||
with:
|
||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||||
asset_path: ./${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
|
||||
asset_name: ${{ env.SOLUTION_FILE}}-${{ env.VERSION}}.zip
|
||||
asset_content_type: application/zip
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
Push_Nuget_Package:
|
||||
needs: Build_Project
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- name: Download Build Version Info
|
||||
uses: actions/download-artifact@v1
|
||||
with:
|
||||
name: Version
|
||||
- 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
|
||||
- name: Download Build output
|
||||
uses: actions/download-artifact@v1
|
||||
with:
|
||||
name: Build
|
||||
path: ./
|
||||
- name: Unzip Build file
|
||||
run: |
|
||||
Get-ChildItem .\*.zip | Expand-Archive -DestinationPath .\
|
||||
Remove-Item -Path .\*.zip
|
||||
- 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
|
||||
- name: Add nuget.exe
|
||||
uses: nuget/setup-nuget@v1
|
||||
- name: Add Github Packages source
|
||||
run: nuget sources add -name github -source https://nuget.pkg.github.com/pepperdash/index.json -username Pepperdash -password ${{ secrets.GITHUB_TOKEN }}
|
||||
- name: Add nuget.org API Key
|
||||
run: nuget setApiKey ${{ secrets.NUGET_API_KEY }}
|
||||
- name: Create nuget package
|
||||
run: nuget pack "./PepperDash_Essentials_Core.nuspec" -version ${{ env.VERSION }}
|
||||
- name: Publish nuget package to Github registry
|
||||
run: nuget push **/*.nupkg -source github
|
||||
- name: Publish nuget package to nuget.org
|
||||
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 ./
|
||||
2
.github/workflows/docker.yml
vendored
2
.github/workflows/docker.yml
vendored
@@ -98,7 +98,7 @@ jobs:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
Push_Nuget_Package:
|
||||
needs: Build_Project
|
||||
runs-on: windows-2019
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- name: Download Build Version Info
|
||||
uses: actions/download-artifact@v1
|
||||
|
||||
2
.github/workflows/main.yml
vendored
2
.github/workflows/main.yml
vendored
@@ -82,7 +82,7 @@ jobs:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
Push_Nuget_Package:
|
||||
needs: Build_Project
|
||||
runs-on: windows-2019
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- name: Download Build Version Info
|
||||
uses: actions/download-artifact@v1
|
||||
|
||||
@@ -9,6 +9,9 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PepperDashEssentials", "Pep
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PepperDash_Essentials_Core", "essentials-framework\Essentials Core\PepperDashEssentialsBase\PepperDash_Essentials_Core.csproj", "{A49AD6C8-FC0A-4CC0-9089-DFB4CF92D2B5}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{E51D7C84-4906-486C-B2BA-EEB3B4E9731B} = {E51D7C84-4906-486C-B2BA-EEB3B4E9731B}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Essentials Devices Common", "essentials-framework\Essentials Devices Common\Essentials Devices Common\Essentials Devices Common.csproj", "{892B761C-E479-44CE-BD74-243E9214AF13}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
@@ -20,6 +23,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PepperDash_Essentials_DM",
|
||||
{A49AD6C8-FC0A-4CC0-9089-DFB4CF92D2B5} = {A49AD6C8-FC0A-4CC0-9089-DFB4CF92D2B5}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PepperDash_Essentials_Interfaces", "essentials-framework\Essentials Interfaces\PepperDash_Essentials_Interfaces\PepperDash_Essentials_Interfaces.csproj", "{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
@@ -42,6 +47,10 @@ Global
|
||||
{9199CE8A-0C9F-4952-8672-3EED798B284F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{9199CE8A-0C9F-4952-8672-3EED798B284F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{9199CE8A-0C9F-4952-8672-3EED798B284F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<ProjectGuid>{1BED5BA9-88C4-4365-9362-6F4B128071D3}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>PepperDashEssentials</RootNamespace>
|
||||
<RootNamespace>PepperDash.Essentials</RootNamespace>
|
||||
<AssemblyName>PepperDashEssentials</AssemblyName>
|
||||
<ProjectTypeGuids>{0B4745B0-194B-4BB6-8E21-E9057CA92230};{4D628B5B-2FBC-4AA6-8C16-197242AEB884};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||
<PlatformFamilyName>WindowsCE</PlatformFamilyName>
|
||||
@@ -221,6 +221,10 @@
|
||||
<Project>{9199CE8A-0C9F-4952-8672-3EED798B284F}</Project>
|
||||
<Name>PepperDash_Essentials_DM</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\essentials-framework\Essentials Interfaces\PepperDash_Essentials_Interfaces\PepperDash_Essentials_Interfaces.csproj">
|
||||
<Project>{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}</Project>
|
||||
<Name>PepperDash_Essentials_Interfaces</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
|
||||
<ProjectExtensions>
|
||||
|
||||
@@ -56,9 +56,6 @@ namespace PepperDash.Essentials.Room.Config
|
||||
[JsonProperty("mirroredTuners")]
|
||||
public Dictionary<uint, string> MirroredTuners { get; set; }
|
||||
|
||||
[JsonProperty("helpMessage")]
|
||||
public string HelpMessage { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Indicates the room
|
||||
/// </summary>
|
||||
|
||||
@@ -89,7 +89,7 @@ namespace PepperDash.Essentials
|
||||
}
|
||||
}
|
||||
|
||||
public EssentialsHuddleVtc1PropertiesConfig PropertiesConfig { get; private set; }
|
||||
public EssentialsConferenceRoomPropertiesConfig PropertiesConfig { get; private set; }
|
||||
|
||||
private List<IRoutingSinkWithSwitching> Displays;
|
||||
|
||||
@@ -199,7 +199,7 @@ namespace PepperDash.Essentials
|
||||
{
|
||||
try
|
||||
{
|
||||
PropertiesConfig = JsonConvert.DeserializeObject<EssentialsHuddleVtc1PropertiesConfig>
|
||||
PropertiesConfig = JsonConvert.DeserializeObject<EssentialsConferenceRoomPropertiesConfig>
|
||||
(config.Properties.ToString());
|
||||
|
||||
VideoCodec = DeviceManager.GetDeviceForKey(PropertiesConfig.VideoCodecKey) as
|
||||
@@ -361,7 +361,7 @@ namespace PepperDash.Essentials
|
||||
|
||||
protected override void CustomSetConfig(DeviceConfig config)
|
||||
{
|
||||
var newPropertiesConfig = JsonConvert.DeserializeObject<EssentialsHuddleVtc1PropertiesConfig>(config.Properties.ToString());
|
||||
var newPropertiesConfig = JsonConvert.DeserializeObject<EssentialsConferenceRoomPropertiesConfig>(config.Properties.ToString());
|
||||
|
||||
if (newPropertiesConfig != null)
|
||||
PropertiesConfig = newPropertiesConfig;
|
||||
|
||||
@@ -101,7 +101,7 @@ namespace PepperDash.Essentials
|
||||
}
|
||||
}
|
||||
|
||||
public EssentialsHuddleVtc1PropertiesConfig PropertiesConfig { get; private set; }
|
||||
public EssentialsConferenceRoomPropertiesConfig PropertiesConfig { get; private set; }
|
||||
|
||||
public IRoutingSinkWithSwitching DefaultDisplay { get; private set; }
|
||||
public IBasicVolumeControls DefaultAudioDevice { get; private set; }
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace PepperDash.Essentials
|
||||
{
|
||||
public class EssentialsTechRoom : EssentialsRoomBase, ITvPresetsProvider, IBridgeAdvanced, IRunDirectRouteAction
|
||||
{
|
||||
public EssentialsTechRoomConfig PropertiesConfig { get; private set; }
|
||||
private readonly EssentialsTechRoomConfig _config;
|
||||
private readonly Dictionary<string, TwoWayDisplayBase> _displays;
|
||||
|
||||
private readonly DevicePresetsModel _tunerPresets;
|
||||
@@ -57,16 +57,16 @@ namespace PepperDash.Essentials
|
||||
|
||||
public EssentialsTechRoom(DeviceConfig config) : base(config)
|
||||
{
|
||||
PropertiesConfig = config.Properties.ToObject<EssentialsTechRoomConfig>();
|
||||
_config = config.Properties.ToObject<EssentialsTechRoomConfig>();
|
||||
|
||||
_tunerPresets = new DevicePresetsModel(String.Format("{0}-presets", config.Key), PropertiesConfig.PresetsFileName);
|
||||
_tunerPresets = new DevicePresetsModel(String.Format("{0}-presets", config.Key), _config.PresetsFileName);
|
||||
|
||||
_tunerPresets.SetFileName(PropertiesConfig.PresetsFileName);
|
||||
_tunerPresets.SetFileName(_config.PresetsFileName);
|
||||
|
||||
_tunerPresets.PresetRecalled += TunerPresetsOnPresetRecalled;
|
||||
|
||||
_tuners = GetDevices<IRSetTopBoxBase>(PropertiesConfig.Tuners);
|
||||
_displays = GetDevices<TwoWayDisplayBase>(PropertiesConfig.Displays);
|
||||
_tuners = GetDevices<IRSetTopBoxBase>(_config.Tuners);
|
||||
_displays = GetDevices<TwoWayDisplayBase>(_config.Displays);
|
||||
|
||||
RoomPowerIsOnFeedback = new BoolFeedback(() => RoomPowerIsOn);
|
||||
|
||||
@@ -153,7 +153,7 @@ namespace PepperDash.Essentials
|
||||
|
||||
private void CreateOrUpdateScheduledEvents()
|
||||
{
|
||||
var eventsConfig = PropertiesConfig.ScheduledEvents;
|
||||
var eventsConfig = _config.ScheduledEvents;
|
||||
|
||||
GetOrCreateScheduleGroup();
|
||||
|
||||
@@ -207,21 +207,21 @@ namespace PepperDash.Essentials
|
||||
{
|
||||
//update config based on key of scheduleEvent
|
||||
GetOrCreateScheduleGroup();
|
||||
var existingEventIndex = PropertiesConfig.ScheduledEvents.FindIndex((e) => e.Key == scheduledEvent.Key);
|
||||
var existingEventIndex = _config.ScheduledEvents.FindIndex((e) => e.Key == scheduledEvent.Key);
|
||||
|
||||
if (existingEventIndex < 0)
|
||||
{
|
||||
PropertiesConfig.ScheduledEvents.Add(scheduledEvent);
|
||||
_config.ScheduledEvents.Add(scheduledEvent);
|
||||
}
|
||||
else
|
||||
{
|
||||
PropertiesConfig.ScheduledEvents[existingEventIndex] = scheduledEvent;
|
||||
_config.ScheduledEvents[existingEventIndex] = scheduledEvent;
|
||||
}
|
||||
|
||||
//create or update event based on config
|
||||
CreateOrUpdateSingleEvent(scheduledEvent);
|
||||
//save config
|
||||
Config.Properties = JToken.FromObject(PropertiesConfig);
|
||||
Config.Properties = JToken.FromObject(_config);
|
||||
|
||||
CustomSetConfig(Config);
|
||||
//Fire Event
|
||||
@@ -230,7 +230,7 @@ namespace PepperDash.Essentials
|
||||
|
||||
public List<ScheduledEventConfig> GetScheduledEvents()
|
||||
{
|
||||
return PropertiesConfig.ScheduledEvents ?? new List<ScheduledEventConfig>();
|
||||
return _config.ScheduledEvents ?? new List<ScheduledEventConfig>();
|
||||
}
|
||||
|
||||
private void OnScheduledEventUpdate()
|
||||
@@ -242,14 +242,14 @@ namespace PepperDash.Essentials
|
||||
return;
|
||||
}
|
||||
|
||||
handler(this, new ScheduledEventEventArgs {ScheduledEvents = PropertiesConfig.ScheduledEvents});
|
||||
handler(this, new ScheduledEventEventArgs {ScheduledEvents = _config.ScheduledEvents});
|
||||
}
|
||||
|
||||
public event EventHandler<ScheduledEventEventArgs> ScheduledEventsChanged;
|
||||
|
||||
private void HandleScheduledEvent(ScheduledEvent schevent, ScheduledEventCommon.eCallbackReason type)
|
||||
{
|
||||
var eventConfig = PropertiesConfig.ScheduledEvents.FirstOrDefault(e => e.Key == schevent.Name);
|
||||
var eventConfig = _config.ScheduledEvents.FirstOrDefault(e => e.Key == schevent.Name);
|
||||
|
||||
if (eventConfig == null)
|
||||
{
|
||||
@@ -286,11 +286,11 @@ Params: {2}"
|
||||
{
|
||||
Debug.Console(2, this, "Room Powering On");
|
||||
|
||||
var dummySource = DeviceManager.GetDeviceForKey(PropertiesConfig.DummySourceKey) as IRoutingOutputs;
|
||||
var dummySource = DeviceManager.GetDeviceForKey(_config.DummySourceKey) as IRoutingOutputs;
|
||||
|
||||
if (dummySource == null)
|
||||
{
|
||||
Debug.Console(1, this, "Unable to get source with key: {0}", PropertiesConfig.DummySourceKey);
|
||||
Debug.Console(1, this, "Unable to get source with key: {0}", _config.DummySourceKey);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -376,12 +376,12 @@ Params: {2}"
|
||||
bridge.AddJoinMap(Key, joinMap);
|
||||
}
|
||||
|
||||
if (PropertiesConfig.IsPrimary)
|
||||
if (_config.IsPrimary)
|
||||
{
|
||||
Debug.Console(1, this, "Linking Primary system Tuner Preset Mirroring");
|
||||
if (PropertiesConfig.MirroredTuners != null && PropertiesConfig.MirroredTuners.Count > 0)
|
||||
if (_config.MirroredTuners != null && _config.MirroredTuners.Count > 0)
|
||||
{
|
||||
foreach (var tuner in PropertiesConfig.MirroredTuners)
|
||||
foreach (var tuner in _config.MirroredTuners)
|
||||
{
|
||||
var f = CurrentPresetsFeedbacks[tuner.Value];
|
||||
|
||||
@@ -423,9 +423,9 @@ Params: {2}"
|
||||
{
|
||||
Debug.Console(1, this, "Linking Secondary system Tuner Preset Mirroring");
|
||||
|
||||
if (PropertiesConfig.MirroredTuners != null && PropertiesConfig.MirroredTuners.Count > 0)
|
||||
if (_config.MirroredTuners != null && _config.MirroredTuners.Count > 0)
|
||||
{
|
||||
foreach (var tuner in PropertiesConfig.MirroredTuners)
|
||||
foreach (var tuner in _config.MirroredTuners)
|
||||
{
|
||||
var t = _tuners[tuner.Value];
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ namespace PepperDash.Essentials
|
||||
public interface IEssentialsHuddleVtc1Room : IEssentialsRoom, IHasCurrentSourceInfoChange,
|
||||
IPrivacy, IHasCurrentVolumeControls, IRunRouteAction, IRunDefaultCallRoute, IHasVideoCodec, IHasAudioCodec, IHasDefaultDisplay, IHasInCallFeedback
|
||||
{
|
||||
EssentialsHuddleVtc1PropertiesConfig PropertiesConfig { get; }
|
||||
EssentialsConferenceRoomPropertiesConfig PropertiesConfig { get; }
|
||||
|
||||
bool ExcludeFromGlobalFunctions { get; }
|
||||
|
||||
|
||||
@@ -493,10 +493,10 @@ namespace PepperDash.Essentials
|
||||
// and the LastMeetingDismissed != this meeting
|
||||
|
||||
var lastMeetingDismissed = meetings.FirstOrDefault(m => m.Id == LastMeetingDismissedId);
|
||||
//Debug.Console(0, "*#* Room on: {0}, lastMeetingDismissedId: {1} {2} *#*",
|
||||
// CurrentRoom.OnFeedback.BoolValue,
|
||||
// LastMeetingDismissedId,
|
||||
// lastMeetingDismissed != null ? lastMeetingDismissed.StartTime.ToString("t", Global.Culture) : "");
|
||||
Debug.Console(0, "*#* Room on: {0}, lastMeetingDismissedId: {1} {2} *#*",
|
||||
CurrentRoom.OnFeedback.BoolValue,
|
||||
LastMeetingDismissedId,
|
||||
lastMeetingDismissed != null ? lastMeetingDismissed.StartTime.ToString("t", Global.Culture) : "");
|
||||
|
||||
var meeting = meetings.LastOrDefault(m => m.Joinable);
|
||||
if (CurrentRoom.OnFeedback.BoolValue
|
||||
|
||||
@@ -52,7 +52,7 @@ namespace PepperDash.Essentials
|
||||
{
|
||||
var prevJoin = CurrentJoin;
|
||||
var wasShown = _IsShown;
|
||||
//Debug.Console(2, "Trilist {0:X2}, interlock swapping {1} for {2}", TriList.ID, CurrentJoin, join);
|
||||
Debug.Console(2, "Trilist {0:X2}, interlock swapping {1} for {2}", TriList.ID, CurrentJoin, join);
|
||||
if (CurrentJoin == join && TriList.BooleanInput[join].BoolValue)
|
||||
return;
|
||||
SetButDontShow(join);
|
||||
@@ -71,7 +71,7 @@ namespace PepperDash.Essentials
|
||||
var prevJoin = CurrentJoin;
|
||||
var wasShown = IsShown;
|
||||
|
||||
//Debug.Console(2, "Trilist {0:X2}, interlock swapping {1} for {2}", TriList.ID, CurrentJoin, join);
|
||||
Debug.Console(2, "Trilist {0:X2}, interlock swapping {1} for {2}", TriList.ID, CurrentJoin, join);
|
||||
if (CurrentJoin == join)
|
||||
HideAndClear();
|
||||
else
|
||||
@@ -92,7 +92,7 @@ namespace PepperDash.Essentials
|
||||
{
|
||||
var prevJoin = CurrentJoin;
|
||||
var wasShown = IsShown;
|
||||
//Debug.Console(2, "Trilist {0:X2}, interlock hiding {1}", TriList.ID, CurrentJoin);
|
||||
Debug.Console(2, "Trilist {0:X2}, interlock hiding {1}", TriList.ID, CurrentJoin);
|
||||
Hide();
|
||||
CurrentJoin = 0;
|
||||
|
||||
@@ -108,7 +108,7 @@ namespace PepperDash.Essentials
|
||||
var prevJoin = CurrentJoin;
|
||||
var wasShown = IsShown;
|
||||
|
||||
//Debug.Console(2, "Trilist {0:X2}, interlock hiding {1}", TriList.ID, CurrentJoin);
|
||||
Debug.Console(2, "Trilist {0:X2}, interlock hiding {1}", TriList.ID, CurrentJoin);
|
||||
if (CurrentJoin > 0)
|
||||
{
|
||||
TriList.BooleanInput[CurrentJoin].BoolValue = false;
|
||||
@@ -125,7 +125,7 @@ namespace PepperDash.Essentials
|
||||
var prevJoin = CurrentJoin;
|
||||
var wasShown = IsShown;
|
||||
|
||||
//Debug.Console(2, "Trilist {0:X2}, interlock showing {1}", TriList.ID, CurrentJoin);
|
||||
Debug.Console(2, "Trilist {0:X2}, interlock showing {1}", TriList.ID, CurrentJoin);
|
||||
if (CurrentJoin > 0)
|
||||
{
|
||||
TriList.BooleanInput[CurrentJoin].BoolValue = true;
|
||||
|
||||
@@ -51,7 +51,7 @@ namespace PepperDash.Essentials
|
||||
|
||||
public override void Show()
|
||||
{
|
||||
//Debug.Console(2, "Showing ScreenSaverController: {0:X2}", TriList.ID);
|
||||
Debug.Console(2, "Showing ScreenSaverController: {0:X2}", TriList.ID);
|
||||
|
||||
if (_parent.AvDriver != null)
|
||||
{
|
||||
@@ -67,11 +67,11 @@ namespace PepperDash.Essentials
|
||||
|
||||
public override void Hide()
|
||||
{
|
||||
//Debug.Console(2, "Hiding ScreenSaverController: {0:X2}", TriList.ID);
|
||||
Debug.Console(2, "Hiding ScreenSaverController: {0:X2}", TriList.ID);
|
||||
|
||||
if (PositionTimer != null)
|
||||
{
|
||||
//Debug.Console(2, "Stopping PositionTimer: {0:X2}", TriList.ID);
|
||||
Debug.Console(2, "Stopping PositionTimer: {0:X2}", TriList.ID);
|
||||
PositionTimer.Stop();
|
||||
PositionTimer.Dispose();
|
||||
PositionTimer = null;
|
||||
@@ -89,7 +89,7 @@ namespace PepperDash.Essentials
|
||||
|
||||
void StartPositionTimer()
|
||||
{
|
||||
//Debug.Console(2, "Starting Position Timer: {0:X2}", TriList.ID);
|
||||
Debug.Console(2, "Starting Position Timer: {0:X2}", TriList.ID);
|
||||
|
||||
if (PositionTimer == null)
|
||||
{
|
||||
@@ -122,7 +122,7 @@ namespace PepperDash.Essentials
|
||||
CurrentPositionIndex = 0;
|
||||
}
|
||||
|
||||
//Debug.Console(2, "ScreenSaver Position Timer Expired: Setting new position: {0} ID: {1:X2}", CurrentPositionIndex, TriList.ID);
|
||||
Debug.Console(2, "ScreenSaver Position Timer Expired: Setting new position: {0} ID: {1:X2}", CurrentPositionIndex, TriList.ID);
|
||||
}
|
||||
|
||||
//
|
||||
@@ -134,7 +134,7 @@ namespace PepperDash.Essentials
|
||||
|
||||
void ClearAllPositions()
|
||||
{
|
||||
//Debug.Console(2, "Hiding all screensaver positions: {0:X2}", TriList.ID);
|
||||
Debug.Console(2, "Hiding all screensaver positions: {0:X2}", TriList.ID);
|
||||
|
||||
PositionInterlock.HideAndClear();
|
||||
}
|
||||
|
||||
@@ -1,60 +0,0 @@
|
||||
using System;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Bridges
|
||||
{
|
||||
public class PduJoinMapBase : JoinMapBaseAdvanced
|
||||
{
|
||||
[JoinName("Name")]
|
||||
public JoinDataComplete Name = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "PDU Name", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
||||
|
||||
[JoinName("Online")]
|
||||
public JoinDataComplete Online = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "PDU Name", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||
|
||||
[JoinName("OutletCount")]
|
||||
public JoinDataComplete OutletCount = new JoinDataComplete(new JoinData { JoinNumber = 1, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "Number of COntrolled Outlets", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Analog });
|
||||
|
||||
[JoinName("OutletName")]
|
||||
public JoinDataComplete OutletName = new JoinDataComplete(new JoinData { JoinNumber = 11, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "Outlet Name", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Serial });
|
||||
|
||||
[JoinName("OutletEnabled")]
|
||||
public JoinDataComplete OutletEnabled = new JoinDataComplete(new JoinData { JoinNumber = 11, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "Outlet Enabled", JoinCapabilities = eJoinCapabilities.ToSIMPL, JoinType = eJoinType.Digital });
|
||||
|
||||
[JoinName("OutletPowerCycle")]
|
||||
public JoinDataComplete OutletPowerCycle = new JoinDataComplete(new JoinData { JoinNumber = 12, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "Outlet Power Cycle", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Digital });
|
||||
|
||||
[JoinName("OutletPowerOn")]
|
||||
public JoinDataComplete OutletPowerOn = new JoinDataComplete(new JoinData { JoinNumber = 13, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "Outlet Power On", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Digital });
|
||||
|
||||
[JoinName("OutletPowerOff")]
|
||||
public JoinDataComplete OutletPowerOff = new JoinDataComplete(new JoinData { JoinNumber = 14, JoinSpan = 1 },
|
||||
new JoinMetadata { Description = "Outlet Power Off", JoinCapabilities = eJoinCapabilities.ToFromSIMPL, JoinType = eJoinType.Digital });
|
||||
|
||||
|
||||
|
||||
/// <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 PduJoinMapBase(uint joinStart)
|
||||
:base(joinStart, typeof(PduJoinMapBase))
|
||||
{
|
||||
}
|
||||
|
||||
/// <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>
|
||||
public PduJoinMapBase(uint joinStart, Type type)
|
||||
: base(joinStart, type)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using PepperDash.Essentials.Core;
|
||||
namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
{
|
||||
@@ -20,21 +20,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("SendDtmfToSpecificCallIndex")]
|
||||
public JoinDataComplete SendDtmfToSpecificCallIndex = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 10,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "If High, will send DTMF tones to the call set by SelectCall analog. If low sends DTMF tones to last connected call.",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf1")]
|
||||
[JoinName("1")]
|
||||
public JoinDataComplete Dtmf1 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -48,7 +34,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf2")]
|
||||
[JoinName("2")]
|
||||
public JoinDataComplete Dtmf2 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -62,7 +48,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf3")]
|
||||
[JoinName("3")]
|
||||
public JoinDataComplete Dtmf3 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -76,7 +62,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf4")]
|
||||
[JoinName("4")]
|
||||
public JoinDataComplete Dtmf4 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -90,7 +76,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf5")]
|
||||
[JoinName("5")]
|
||||
public JoinDataComplete Dtmf5 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -104,7 +90,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf6")]
|
||||
[JoinName("6")]
|
||||
public JoinDataComplete Dtmf6 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -118,7 +104,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf7")]
|
||||
[JoinName("7")]
|
||||
public JoinDataComplete Dtmf7 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -132,7 +118,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf8")]
|
||||
[JoinName("8")]
|
||||
public JoinDataComplete Dtmf8 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -146,7 +132,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf9")]
|
||||
[JoinName("9")]
|
||||
public JoinDataComplete Dtmf9 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -160,7 +146,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("Dtmf0")]
|
||||
[JoinName("0")]
|
||||
public JoinDataComplete Dtmf0 = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -174,7 +160,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DtmfStar")]
|
||||
[JoinName("*")]
|
||||
public JoinDataComplete DtmfStar = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -188,7 +174,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DtmfPound")]
|
||||
[JoinName("#")]
|
||||
public JoinDataComplete DtmfPound = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -202,8 +188,8 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("EndAllCalls")]
|
||||
public JoinDataComplete EndAllCalls = new JoinDataComplete(
|
||||
[JoinName("EndCall")]
|
||||
public JoinDataComplete EndCall = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 24,
|
||||
@@ -211,7 +197,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "End All Calls",
|
||||
Description = "Hang Up",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
@@ -240,7 +226,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Speed Dial",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
@@ -295,12 +281,12 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Dial manual string specified by CurrentDialString serial join",
|
||||
Description = "Dial manual string",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DialPhone")]
|
||||
[JoinName("DialPhoneCall")]
|
||||
public JoinDataComplete DialPhone = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -328,7 +314,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("HangUpPhone")]
|
||||
[JoinName("EndPhoneCall")]
|
||||
public JoinDataComplete HangUpPhone = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -337,53 +323,11 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Hang Up Phone",
|
||||
Description = "Hang Up PHone",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("EndCallStart")]
|
||||
public JoinDataComplete EndCallStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 81,
|
||||
JoinSpan = 8
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "End a specific call by call index. ",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("JoinAllCalls")]
|
||||
public JoinDataComplete JoinAllCalls = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 90,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Join all calls",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("JoinCallStart")]
|
||||
public JoinDataComplete JoinCallStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 91,
|
||||
JoinSpan = 8
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Join a specific call by call index. ",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DirectorySearchBusy")]
|
||||
public JoinDataComplete DirectorySearchBusy = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -464,7 +408,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Go to Directory Root",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
@@ -496,33 +440,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DirectoryDisableAutoDialSelectedLine")]
|
||||
public JoinDataComplete DirectoryDisableAutoDialSelectedLine = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 107,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Set high to disable automatic dialing of a contact when selected",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DirectoryDialSelectedContactMethod")]
|
||||
public JoinDataComplete DirectoryDialSelectedContactMethod = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 108,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to dial the selected contact method",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("CameraTiltUp")]
|
||||
public JoinDataComplete CameraTiltUp = new JoinDataComplete(
|
||||
@@ -608,48 +525,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("CameraFocusNear")]
|
||||
public JoinDataComplete CameraFocusNear = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 117,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Focus Near",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("CameraFocusFar")]
|
||||
public JoinDataComplete CameraFocusFar = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 118,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Focus Far",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("CameraFocusAuto")]
|
||||
public JoinDataComplete CameraFocusAuto = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 119,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Auto Focus Trigger",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("CameraPresetSave")]
|
||||
public JoinDataComplete CameraPresetSave = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -659,7 +534,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to save selected preset spcified by CameraPresetSelect analog join. FB will pulse for 3s when preset saved.",
|
||||
Description = "Save Selected Preset",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
@@ -673,7 +548,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Mode Auto. Enables camera auto tracking mode, with feedback",
|
||||
Description = "Camera Mode Auto",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
@@ -687,7 +562,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Mode Manual. Disables camera auto tracking mode, with feedback",
|
||||
Description = "Camera Mode Manual",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
@@ -701,7 +576,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Mode Off. Disables camera video, with feedback. Works like video mute.",
|
||||
Description = "Camera Mode Off",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
@@ -930,34 +805,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("RemoveSelectedRecentCallItem")]
|
||||
public JoinDataComplete RemoveSelectedRecentCallItem = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 181,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to remove the selected recent call item specified by the SelectRecentCallItem analog join",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("DialSelectedRecentCallItem")]
|
||||
public JoinDataComplete DialSelectedRecentCallItem = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 182,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to dial the selected recent call item specified by the SelectRecentCallItem analog join",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("SourceShareStart")]
|
||||
public JoinDataComplete SourceShareStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1023,81 +870,11 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Toggles selfview position",
|
||||
Description = "advance selfview position",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("HoldAllCalls")]
|
||||
public JoinDataComplete HoldAllCalls = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 220,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Holds all calls",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("HoldCallsStart")]
|
||||
public JoinDataComplete HoldCallsStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 221,
|
||||
JoinSpan = 8
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Holds Call at specified index. FB reported on Call Status XSIG",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("ResumeCallsStart")]
|
||||
public JoinDataComplete ResumeCallsStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 231,
|
||||
JoinSpan = 8
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Resume Call at specified index",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("MultiSiteOptionIsEnabled")]
|
||||
public JoinDataComplete MultiSiteOptionIsEnabled = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 301,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Multi site option is enabled FB",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("AutoAnswerEnabled")]
|
||||
public JoinDataComplete AutoAnswerEnabled = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 302,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Auto Answer is enabled FB",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("ParticipantAudioMuteToggleStart")]
|
||||
public JoinDataComplete ParticipantAudioMuteToggleStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1162,35 +939,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("SelectCall")]
|
||||
public JoinDataComplete SelectCall = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 24,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Sets the selected Call for DTMF commands. Valid values 1-8",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
|
||||
[JoinName("ConnectedCallCount")]
|
||||
public JoinDataComplete ConnectedCallCount = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 25,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Reports the number of currently connected calls",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("MinutesBeforeMeetingStart")]
|
||||
public JoinDataComplete MinutesBeforeMeetingStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1214,25 +962,11 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Number Select/FB. 1 based index. Valid range is 1 to the value reported by CameraCount.",
|
||||
Description = "Camera Number Select/FB",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("CameraCount")]
|
||||
public JoinDataComplete CameraCount = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 61,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Reports the number of cameras",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("DirectoryRowCount")]
|
||||
public JoinDataComplete DirectoryRowCount = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1261,34 +995,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("SelectedContactMethodCount")]
|
||||
public JoinDataComplete SelectedContactMethodCount = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 102,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Reports the number of contact methods for the selected contact",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("SelectContactMethod")]
|
||||
public JoinDataComplete SelectContactMethod = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 103,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Selects a contact method by index",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("CameraPresetSelect")]
|
||||
public JoinDataComplete CameraPresetSelect = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1299,24 +1005,10 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Preset Select",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("FarEndPresetSelect")]
|
||||
public JoinDataComplete FarEndPresetSelect = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 122,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Far End Preset Preset Select",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("ParticipantCount")]
|
||||
public JoinDataComplete ParticipantCount = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1359,48 +1051,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("SelectRecentCallItem")]
|
||||
public JoinDataComplete SelectRecentCallItem = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 180,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Select/FB for Recent Call Item. Valid values 1 - 10",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("RecentCallOccurrenceType")]
|
||||
public JoinDataComplete RecentCallOccurrenceType = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 181,
|
||||
JoinSpan = 10
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Recent Call Occurrence Type. [0-3] 0 = Unknown, 1 = Placed, 2 = Received, 3 = NoAnswer",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("RecentCallCount")]
|
||||
public JoinDataComplete RecentCallCount = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 191,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Recent Call Count",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
@@ -1416,12 +1066,12 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Value to dial when ManualDial digital join is pulsed",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
Description = "Current Dial String",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("PhoneDialString")]
|
||||
[JoinName("PhoneString")]
|
||||
public JoinDataComplete PhoneDialString = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -1435,7 +1085,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("CurrentCallData")]
|
||||
[JoinName("CurrentCallName")]
|
||||
public JoinDataComplete CurrentCallData = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
@@ -1534,20 +1184,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("ContactMethods")]
|
||||
public JoinDataComplete ContactMethods = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 103,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Contact Methods - XSig, 10 entries",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("CameraPresetNames")]
|
||||
public JoinDataComplete CameraPresetNames = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1562,8 +1198,8 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("CurrentLayoutStringFb")]
|
||||
public JoinDataComplete CurrentLayoutStringFb = new JoinDataComplete(
|
||||
[JoinName("CameraLayoutStringFb")]
|
||||
public JoinDataComplete CameraLayoutStringFb = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 141,
|
||||
@@ -1590,76 +1226,6 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("CameraNamesFb")]
|
||||
public JoinDataComplete CameraNamesFb = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 161,
|
||||
JoinSpan = 10
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Camera Name Fb",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("SelectedRecentCallName")]
|
||||
public JoinDataComplete SelectedRecentCallName = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 171,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Selected Recent Call Name",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("SelectedRecentCallNumber")]
|
||||
public JoinDataComplete SelectedRecentCallNumber = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 172,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Selected Recent Call Number",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("RecentCallNamesStart")]
|
||||
public JoinDataComplete RecentCallNamesStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 181,
|
||||
JoinSpan = 10
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Recent Call Names",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("RecentCallTimesStart")]
|
||||
public JoinDataComplete RecentCallTimesStart = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 191,
|
||||
JoinSpan = 10
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Recent Calls Times",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("CurrentSource")]
|
||||
public JoinDataComplete CurrentSource = new JoinDataComplete(
|
||||
new JoinData
|
||||
@@ -1686,77 +1252,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
||||
Description = "advance selfview position",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("DeviceIpAddresss")]
|
||||
public JoinDataComplete DeviceIpAddresss = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 301,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "IP Address of device",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("SipPhoneNumber")]
|
||||
public JoinDataComplete SipPhoneNumber = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 302,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "SIP phone number of device",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("E164Alias")]
|
||||
public JoinDataComplete E164Alias = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 303,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "E164 alias of device",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("H323Id")]
|
||||
public JoinDataComplete H323Id = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 304,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "H323 ID of device",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
[JoinName("SipUri")]
|
||||
public JoinDataComplete SipUri = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 305,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "SIP URI of device",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
});
|
||||
|
||||
[JoinName("DirectoryEntrySelectedName")]
|
||||
public JoinDataComplete DirectoryEntrySelectedName = new JoinDataComplete(
|
||||
@@ -3111,4 +2607,4 @@ namespace PepperDash_Essentials_Core.Bridges.JoinMaps
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,35 +1,35 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Crestron.SimplSharp;
|
||||
using Crestron.SimplSharp.CrestronIO;
|
||||
using Crestron.SimplSharpPro;
|
||||
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using PepperDash.Core;
|
||||
using PepperDash.Essentials.Core;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Config
|
||||
{
|
||||
public class DeviceConfig
|
||||
{
|
||||
[JsonProperty("key")]
|
||||
public string Key { get; set; }
|
||||
|
||||
[JsonProperty("uid")]
|
||||
public int Uid { get; set; }
|
||||
|
||||
[JsonProperty("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonProperty("group")]
|
||||
public string Group { get; set; }
|
||||
|
||||
[JsonProperty("type")]
|
||||
public string Type { get; set; }
|
||||
|
||||
[JsonProperty("properties")]
|
||||
[JsonConverter(typeof(DevicePropertiesConverter))]
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Crestron.SimplSharp;
|
||||
using Crestron.SimplSharp.CrestronIO;
|
||||
using Crestron.SimplSharpPro;
|
||||
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using PepperDash.Core;
|
||||
using PepperDash.Essentials.Core;
|
||||
|
||||
namespace PepperDash.Essentials.Core.Config
|
||||
{
|
||||
public class DeviceConfig
|
||||
{
|
||||
[JsonProperty("key")]
|
||||
public string Key { get; set; }
|
||||
|
||||
[JsonProperty("uid")]
|
||||
public int Uid { get; set; }
|
||||
|
||||
[JsonProperty("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonProperty("group")]
|
||||
public string Group { get; set; }
|
||||
|
||||
[JsonProperty("type")]
|
||||
public string Type { get; set; }
|
||||
|
||||
[JsonProperty("properties")]
|
||||
[JsonConverter(typeof(DevicePropertiesConverter))]
|
||||
public JToken Properties { get; set; }
|
||||
|
||||
public DeviceConfig(DeviceConfig dc)
|
||||
@@ -39,42 +39,39 @@ namespace PepperDash.Essentials.Core.Config
|
||||
Name = dc.Name;
|
||||
Group = dc.Group;
|
||||
Type = dc.Type;
|
||||
|
||||
Properties = JToken.Parse(dc.Properties.ToString());
|
||||
|
||||
//Properties = JToken.FromObject(dc.Properties);
|
||||
Properties = JToken.FromObject(dc.Properties);
|
||||
}
|
||||
|
||||
public DeviceConfig() {}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public class DevicePropertiesConverter : JsonConverter
|
||||
{
|
||||
|
||||
public override bool CanConvert(Type objectType)
|
||||
{
|
||||
return objectType == typeof(JToken);
|
||||
}
|
||||
|
||||
public override object ReadJson(JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer)
|
||||
{
|
||||
return JToken.ReadFrom(reader);
|
||||
}
|
||||
|
||||
public override bool CanWrite
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public override void WriteJson(JsonWriter writer, object value, JsonSerializer serializer)
|
||||
{
|
||||
throw new NotImplementedException("SOD OFF HOSER");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public class DevicePropertiesConverter : JsonConverter
|
||||
{
|
||||
|
||||
public override bool CanConvert(Type objectType)
|
||||
{
|
||||
return objectType == typeof(JToken);
|
||||
}
|
||||
|
||||
public override object ReadJson(JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer)
|
||||
{
|
||||
return JToken.ReadFrom(reader);
|
||||
}
|
||||
|
||||
public override bool CanWrite
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public override void WriteJson(JsonWriter writer, object value, JsonSerializer serializer)
|
||||
{
|
||||
throw new NotImplementedException("SOD OFF HOSER");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -66,7 +66,7 @@ namespace PepperDash.Essentials.Core.CrestronIO
|
||||
#endregion
|
||||
}
|
||||
|
||||
public class C2NIoControllerFactory : EssentialsDeviceFactory<C2NIoController>
|
||||
public class C2NIoControllerFactory : EssentialsDeviceFactory<C2nRthsController>
|
||||
{
|
||||
public C2NIoControllerFactory()
|
||||
{
|
||||
|
||||
@@ -9,11 +9,8 @@ namespace PepperDash.Essentials.Core
|
||||
/// <summary>
|
||||
/// Defines minimal volume and mute control methods
|
||||
/// </summary>
|
||||
public interface IBasicVolumeControls
|
||||
public interface IBasicVolumeControls : IHasVolumeControl, IHasMuteControl
|
||||
{
|
||||
void VolumeUp(bool pressRelease);
|
||||
void VolumeDown(bool pressRelease);
|
||||
void MuteToggle();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -55,13 +52,8 @@ namespace PepperDash.Essentials.Core
|
||||
/// <summary>
|
||||
/// Adds feedback and direct volume level set to IBasicVolumeControls
|
||||
/// </summary>
|
||||
public interface IBasicVolumeWithFeedback : IBasicVolumeControls
|
||||
public interface IBasicVolumeWithFeedback : IBasicVolumeControls, IHasVolumeControlWithFeedback, IHasMuteControlWithFeedback
|
||||
{
|
||||
BoolFeedback MuteFeedback { get; }
|
||||
void MuteOn();
|
||||
void MuteOff();
|
||||
void SetVolume(ushort level);
|
||||
IntFeedback VolumeLevelFeedback { get; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,35 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
using Crestron.SimplSharp;
|
||||
using PepperDash.Core;
|
||||
using PepperDash.Essentials.Core;
|
||||
|
||||
namespace PepperDash_Essentials_Core.Devices
|
||||
{
|
||||
/// <summary>
|
||||
/// Interface for any device that is able to control it'spower and has a configurable reboot time
|
||||
/// </summary>
|
||||
public interface IHasPowerCycle : IKeyName, IHasPowerControlWithFeedback
|
||||
{
|
||||
/// <summary>
|
||||
/// Delay between power off and power on for reboot
|
||||
/// </summary>
|
||||
int PowerCycleTimeMs { get;}
|
||||
|
||||
/// <summary>
|
||||
/// Reboot outlet
|
||||
/// </summary>
|
||||
void PowerCycle();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Interface for any device that contains a collection of IHasPowerReboot Devices
|
||||
/// </summary>
|
||||
public interface IHasControlledPowerOutlets : IKeyName
|
||||
{
|
||||
/// <summary>
|
||||
/// Collection of IPduOutlets
|
||||
/// </summary>
|
||||
ReadOnlyDictionary<int, IHasPowerCycle> PduOutlets { get; }
|
||||
|
||||
}
|
||||
}
|
||||
@@ -59,7 +59,7 @@ namespace PepperDash.Essentials.Core.Devices
|
||||
/// <summary>
|
||||
/// Used by the extending class to allow for any custom actions to be taken (tell the ConfigWriter to write config, etc)
|
||||
/// </summary>
|
||||
/// <param name="config"></param>
|
||||
/// <param name="Config"></param>
|
||||
protected virtual void CustomSetConfig(DeviceConfig config)
|
||||
{
|
||||
ConfigWriter.UpdateDeviceConfig(config);
|
||||
|
||||
@@ -111,12 +111,7 @@ namespace PepperDash.Essentials.Core
|
||||
|
||||
public override void ExecuteSwitch(object selector)
|
||||
{
|
||||
Debug.Console(2, this, "ExecuteSwitch: {0}", selector);
|
||||
|
||||
if (!_PowerIsOn)
|
||||
{
|
||||
PowerOn();
|
||||
}
|
||||
Debug.Console(2, this, "ExecuteSwitch: {0}", selector);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -16,28 +16,11 @@ namespace PepperDash.Essentials.Core
|
||||
/// <summary>
|
||||
/// Used for monitoring comms that are IBasicCommunication. Will send a poll string and provide an event when
|
||||
/// statuses change.
|
||||
/// Default monitoring uses TextReceived event on Client.
|
||||
/// </summary>
|
||||
public class GenericCommunicationMonitor : StatusMonitorBase
|
||||
{
|
||||
public IBasicCommunication Client { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Will monitor Client.BytesReceived if set to true. Otherwise the default is to monitor Client.TextReceived
|
||||
/// </summary>
|
||||
public bool MonitorBytesReceived { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Return true if the Client is ISocketStatus
|
||||
/// </summary>
|
||||
public bool IsSocket
|
||||
{
|
||||
get
|
||||
{
|
||||
return Client is ISocketStatus;
|
||||
}
|
||||
}
|
||||
|
||||
long PollTime;
|
||||
CTimer PollTimer;
|
||||
string PollString;
|
||||
@@ -63,20 +46,8 @@ namespace PepperDash.Essentials.Core
|
||||
Client = client;
|
||||
PollTime = pollTime;
|
||||
PollString = pollString;
|
||||
|
||||
if (IsSocket)
|
||||
{
|
||||
(Client as ISocketStatus).ConnectionChange += new EventHandler<GenericSocketStatusChageEventArgs>(socket_ConnectionChange);
|
||||
}
|
||||
}
|
||||
|
||||
public GenericCommunicationMonitor(IKeyed parent, IBasicCommunication client, long pollTime,
|
||||
long warningTime, long errorTime, string pollString, bool monitorBytesReceived) :
|
||||
this(parent, client, pollTime, warningTime, errorTime, pollString)
|
||||
{
|
||||
SetMonitorBytesReceived(monitorBytesReceived);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Poll is a provided action instead of string
|
||||
/// </summary>
|
||||
@@ -98,19 +69,6 @@ namespace PepperDash.Essentials.Core
|
||||
Client = client;
|
||||
PollTime = pollTime;
|
||||
PollAction = pollAction;
|
||||
|
||||
if (IsSocket)
|
||||
{
|
||||
(Client as ISocketStatus).ConnectionChange += new EventHandler<GenericSocketStatusChageEventArgs>(socket_ConnectionChange);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public GenericCommunicationMonitor(IKeyed parent, IBasicCommunication client, long pollTime,
|
||||
long warningTime, long errorTime, Action pollAction, bool monitorBytesReceived) :
|
||||
this(parent, client, pollTime, warningTime, errorTime, pollAction)
|
||||
{
|
||||
SetMonitorBytesReceived(monitorBytesReceived);
|
||||
}
|
||||
|
||||
|
||||
@@ -121,96 +79,23 @@ namespace PepperDash.Essentials.Core
|
||||
CommunicationMonitorConfig props) :
|
||||
this(parent, client, props.PollInterval, props.TimeToWarning, props.TimeToError, props.PollString)
|
||||
{
|
||||
if (IsSocket)
|
||||
{
|
||||
(Client as ISocketStatus).ConnectionChange += new EventHandler<GenericSocketStatusChageEventArgs>(socket_ConnectionChange);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Builds the monitor from a config object and takes a bool to specify whether to monitor BytesReceived
|
||||
/// Default is to monitor TextReceived
|
||||
/// </summary>
|
||||
/// <param name="parent"></param>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="props"></param>
|
||||
/// <param name="monitorBytesReceived"></param>
|
||||
public GenericCommunicationMonitor(IKeyed parent, IBasicCommunication client, CommunicationMonitorConfig props, bool monitorBytesReceived) :
|
||||
this(parent, client, props.PollInterval, props.TimeToWarning, props.TimeToError, props.PollString)
|
||||
{
|
||||
SetMonitorBytesReceived(monitorBytesReceived);
|
||||
}
|
||||
|
||||
void SetMonitorBytesReceived(bool monitorBytesReceived)
|
||||
{
|
||||
MonitorBytesReceived = monitorBytesReceived;
|
||||
}
|
||||
|
||||
public override void Start()
|
||||
{
|
||||
if (MonitorBytesReceived)
|
||||
{
|
||||
Client.BytesReceived += Client_BytesReceived;
|
||||
}
|
||||
else
|
||||
{
|
||||
Client.TextReceived += Client_TextReceived;
|
||||
}
|
||||
|
||||
if (!IsSocket)
|
||||
{
|
||||
BeginPolling();
|
||||
}
|
||||
Client.BytesReceived += Client_BytesReceived;
|
||||
Poll();
|
||||
PollTimer = new CTimer(o => Poll(), null, PollTime, PollTime);
|
||||
}
|
||||
|
||||
void socket_ConnectionChange(object sender, GenericSocketStatusChageEventArgs e)
|
||||
{
|
||||
if (!e.Client.IsConnected)
|
||||
{
|
||||
// Immediately stop polling and notify that device is offline
|
||||
Stop();
|
||||
Status = MonitorStatus.InError;
|
||||
ResetErrorTimers();
|
||||
}
|
||||
else
|
||||
{
|
||||
// Start polling and set status to unknow and let poll result update the status to IsOk when a response is received
|
||||
Status = MonitorStatus.StatusUnknown;
|
||||
Start();
|
||||
BeginPolling();
|
||||
}
|
||||
}
|
||||
|
||||
void BeginPolling()
|
||||
{
|
||||
Poll();
|
||||
PollTimer = new CTimer(o => Poll(), null, PollTime, PollTime);
|
||||
}
|
||||
|
||||
public override void Stop()
|
||||
{
|
||||
if(MonitorBytesReceived)
|
||||
{
|
||||
Client.BytesReceived -= this.Client_BytesReceived;
|
||||
}
|
||||
else
|
||||
{
|
||||
Client.TextReceived -= Client_TextReceived;
|
||||
}
|
||||
|
||||
if (PollTimer != null)
|
||||
{
|
||||
PollTimer.Stop();
|
||||
PollTimer = null;
|
||||
StopErrorTimers();
|
||||
}
|
||||
Client.BytesReceived -= this.Client_BytesReceived;
|
||||
PollTimer.Stop();
|
||||
PollTimer = null;
|
||||
StopErrorTimers();
|
||||
}
|
||||
|
||||
void Client_TextReceived(object sender, GenericCommMethodReceiveTextArgs e)
|
||||
{
|
||||
DataReceived();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Upon any receipt of data, set everything to ok!
|
||||
/// </summary>
|
||||
@@ -218,14 +103,10 @@ namespace PepperDash.Essentials.Core
|
||||
/// <param name="e"></param>
|
||||
void Client_BytesReceived(object sender, GenericCommMethodReceiveBytesArgs e)
|
||||
{
|
||||
DataReceived();
|
||||
}
|
||||
|
||||
void DataReceived()
|
||||
{
|
||||
Status = MonitorStatus.IsOk;
|
||||
ResetErrorTimers();
|
||||
}
|
||||
Status = MonitorStatus.IsOk;
|
||||
ResetErrorTimers();
|
||||
//
|
||||
}
|
||||
|
||||
void Poll()
|
||||
{
|
||||
@@ -243,6 +124,19 @@ namespace PepperDash.Essentials.Core
|
||||
Debug.Console(2, this, "Comm not connected");
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// When the client connects, and we're waiting for it, respond and disconect from event
|
||||
/// </summary>
|
||||
void OneTimeConnectHandler(object o, EventArgs a)
|
||||
{
|
||||
if (Client.IsConnected)
|
||||
{
|
||||
//Client.IsConnected -= OneTimeConnectHandler;
|
||||
Debug.Console(2, this, "Comm connected");
|
||||
Poll();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<ProjectGuid>{A49AD6C8-FC0A-4CC0-9089-DFB4CF92D2B5}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>PepperDash_Essentials_Core</RootNamespace>
|
||||
<RootNamespace>PepperDash.Essentials.Core</RootNamespace>
|
||||
<AssemblyName>PepperDash_Essentials_Core</AssemblyName>
|
||||
<ProjectTypeGuids>{0B4745B0-194B-4BB6-8E21-E9057CA92300};{4D628B5B-2FBC-4AA6-8C16-197242AEB884};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||
<PlatformFamilyName>WindowsCE</PlatformFamilyName>
|
||||
@@ -123,7 +123,6 @@
|
||||
<Compile Include="Bridges\IBridge.cs" />
|
||||
<Compile Include="Bridges\JoinMaps\AirMediaControllerJoinMap.cs" />
|
||||
<Compile Include="Bridges\JoinMaps\AppleTvJoinMap.cs" />
|
||||
<Compile Include="Bridges\JoinMaps\PduJoinMapBase.cs" />
|
||||
<Compile Include="Bridges\JoinMaps\C2nRthsControllerJoinMap.cs" />
|
||||
<Compile Include="Bridges\JoinMaps\CameraControllerJoinMap.cs" />
|
||||
<Compile Include="Bridges\JoinMaps\CenOdtOccupancySensorBaseJoinMap.cs" />
|
||||
@@ -204,7 +203,6 @@
|
||||
<Compile Include="Devices\IReconfigurableDevice.cs" />
|
||||
<Compile Include="Devices\PC\InRoomPc.cs" />
|
||||
<Compile Include="Devices\PC\Laptop.cs" />
|
||||
<Compile Include="Devices\PduInterfaces.cs" />
|
||||
<Compile Include="Devices\ReconfigurableDevice.cs" />
|
||||
<Compile Include="Devices\VolumeDeviceChangeEventArgs.cs" />
|
||||
<Compile Include="DeviceTypeInterfaces\IPasswordPrompt.cs" />
|
||||
@@ -383,6 +381,12 @@
|
||||
<None Include="app.config" />
|
||||
<None Include="Properties\ControlSystem.cfg" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\Essentials Interfaces\PepperDash_Essentials_Interfaces\PepperDash_Essentials_Interfaces.csproj">
|
||||
<Project>{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}</Project>
|
||||
<Name>PepperDash_Essentials_Interfaces</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
|
||||
<ProjectExtensions>
|
||||
<VisualStudio>
|
||||
|
||||
@@ -118,7 +118,7 @@ namespace PepperDash.Essentials.Core.Queues
|
||||
/// <param name="capacity"></param>
|
||||
public GenericQueue(string key, int pacing, Thread.eThreadPriority priority, int capacity)
|
||||
: this(key, priority, capacity, pacing)
|
||||
{
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -139,8 +139,7 @@ namespace PepperDash.Essentials.Core.Queues
|
||||
_queue = new CrestronQueue<IQueueMessage>(cap);
|
||||
_worker = new Thread(ProcessQueue, null, Thread.eThreadStartOptions.Running)
|
||||
{
|
||||
Priority = priority,
|
||||
Name = _key
|
||||
Priority = priority
|
||||
};
|
||||
|
||||
SetDelayValues(pacing);
|
||||
|
||||
@@ -36,22 +36,21 @@ namespace PepperDash.Essentials.Core
|
||||
public bool SetSecret(string key, object value)
|
||||
{
|
||||
var secret = value as string;
|
||||
CrestronDataStore.CDS_ERROR returnCode;
|
||||
|
||||
if (String.IsNullOrEmpty(secret))
|
||||
{
|
||||
returnCode = CrestronDataStoreStatic.clearLocal(key);
|
||||
if (returnCode == CrestronDataStore.CDS_ERROR.CDS_SUCCESS) return true;
|
||||
Debug.Console(2, this, "Unable to set secret for {0}:{1} - value is empty.", Key, key);
|
||||
return false;
|
||||
}
|
||||
|
||||
else
|
||||
var setErrorCode = CrestronDataStoreStatic.SetLocalStringValue(key, secret);
|
||||
switch (setErrorCode)
|
||||
{
|
||||
returnCode = CrestronDataStoreStatic.SetLocalStringValue(key, secret);
|
||||
if (returnCode == CrestronDataStore.CDS_ERROR.CDS_SUCCESS) return true;
|
||||
case CrestronDataStore.CDS_ERROR.CDS_SUCCESS:
|
||||
Debug.Console(1, this,"Secret Successfully Set for {0}:{1}", Key, key);
|
||||
return true;
|
||||
default:
|
||||
Debug.Console(2, this, Debug.ErrorLogLevel.Notice, "Unable to set secret for {0}:{1} - {2}", Key, key, setErrorCode.ToString());
|
||||
return false;
|
||||
}
|
||||
|
||||
Debug.Console(0, this, Debug.ErrorLogLevel.Notice, "Unable to set secret for {0}:{1} - {2}", Key, key, returnCode.ToString());
|
||||
return false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -144,7 +144,7 @@ namespace PepperDash.Essentials.Core
|
||||
public UShortOutputSig GetUShortOutputSig(uint index, uint sigNum)
|
||||
{
|
||||
if (sigNum > UShortIncrement) return null;
|
||||
return SRL.UShortOutput.FirstOrDefault(s => s.Name.Equals(GetUShortOutputSigName(index, sigNum)));
|
||||
return SRL.UShortOutput.FirstOrDefault(s => s.Name.Equals(GetBoolFeedbackSigName(index, sigNum)));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -159,7 +159,7 @@ namespace PepperDash.Essentials.Core
|
||||
public StringOutputSig GetStringOutputSig(uint index, uint sigNum)
|
||||
{
|
||||
if (sigNum > StringIncrement) return null;
|
||||
return SRL.StringOutput.FirstOrDefault(s => s.Name.Equals(GetStringOutputSigName(index, sigNum)));
|
||||
return SRL.StringOutput.FirstOrDefault(s => s.Name.Equals(GetBoolFeedbackSigName(index, sigNum)));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -156,6 +156,10 @@
|
||||
<Project>{A49AD6C8-FC0A-4CC0-9089-DFB4CF92D2B5}</Project>
|
||||
<Name>PepperDash_Essentials_Core</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\Essentials Interfaces\PepperDash_Essentials_Interfaces\PepperDash_Essentials_Interfaces.csproj">
|
||||
<Project>{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}</Project>
|
||||
<Name>PepperDash_Essentials_Interfaces</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
|
||||
<ProjectExtensions>
|
||||
|
||||
@@ -29,7 +29,6 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||
|
||||
public abstract class CameraBase : ReconfigurableDevice, IRoutingOutputs
|
||||
{
|
||||
[JsonProperty("controlMode", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public eCameraControlMode ControlMode { get; protected set; }
|
||||
|
||||
#region IRoutingOutputs Members
|
||||
@@ -38,7 +37,6 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||
|
||||
#endregion
|
||||
|
||||
[JsonProperty("canPan", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public bool CanPan
|
||||
{
|
||||
get
|
||||
@@ -46,7 +44,7 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||
return (Capabilities & eCameraCapabilities.Pan) == eCameraCapabilities.Pan;
|
||||
}
|
||||
}
|
||||
[JsonProperty("canTilt", NullValueHandling = NullValueHandling.Ignore)]
|
||||
|
||||
public bool CanTilt
|
||||
{
|
||||
get
|
||||
@@ -54,7 +52,7 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||
return (Capabilities & eCameraCapabilities.Tilt) == eCameraCapabilities.Tilt;
|
||||
}
|
||||
}
|
||||
[JsonProperty("canZoom", NullValueHandling = NullValueHandling.Ignore)]
|
||||
|
||||
public bool CanZoom
|
||||
{
|
||||
get
|
||||
@@ -62,7 +60,7 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||
return (Capabilities & eCameraCapabilities.Zoom) == eCameraCapabilities.Zoom;
|
||||
}
|
||||
}
|
||||
[JsonProperty("canFocus", NullValueHandling = NullValueHandling.Ignore)]
|
||||
|
||||
public bool CanFocus
|
||||
{
|
||||
get
|
||||
|
||||
@@ -57,11 +57,6 @@ namespace PepperDash.Essentials.Devices.Common.Cameras
|
||||
void CameraMuteToggle();
|
||||
}
|
||||
|
||||
public interface IHasCameraMuteWithUnmuteReqeust : IHasCameraMute
|
||||
{
|
||||
event EventHandler VideoUnmuteRequested;
|
||||
}
|
||||
|
||||
public class CameraSelectedEventArgs : EventArgs
|
||||
{
|
||||
public CameraBase SelectedCamera { get; private set; }
|
||||
|
||||
@@ -12,40 +12,34 @@ namespace PepperDash.Essentials.Devices.Common.Codec
|
||||
{
|
||||
public class CodecActiveCallItem
|
||||
{
|
||||
[JsonProperty("name", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[JsonProperty("number", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("number")]
|
||||
public string Number { get; set; }
|
||||
|
||||
[JsonProperty("type", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("type")]
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public eCodecCallType Type { get; set; }
|
||||
|
||||
[JsonProperty("status", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("status")]
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public eCodecCallStatus Status { get; set; }
|
||||
|
||||
[JsonProperty("direction", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("direction")]
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public eCodecCallDirection Direction { get; set; }
|
||||
|
||||
[JsonProperty("id", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("id")]
|
||||
public string Id { get; set; }
|
||||
|
||||
[JsonProperty("isOnHold", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public bool IsOnHold { get; set; }
|
||||
|
||||
[JsonProperty("duration", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public TimeSpan Duration { get; set; }
|
||||
|
||||
//public object CallMetaData { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Returns true when this call is any status other than
|
||||
/// Unknown, Disconnected, Disconnecting
|
||||
/// </summary>
|
||||
[JsonProperty("isActiveCall", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonProperty("isActiveCall")]
|
||||
public bool IsActiveCall
|
||||
{
|
||||
get
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Crestron.SimplSharp;
|
||||
|
||||
namespace PepperDash.Essentials.Devices.Common.Codec
|
||||
{
|
||||
public interface IHasCallHold
|
||||
{
|
||||
/// <summary>
|
||||
/// Put the specified call on hold
|
||||
/// </summary>
|
||||
/// <param name="activeCall"></param>
|
||||
void HoldCall(CodecActiveCallItem activeCall);
|
||||
|
||||
/// <summary>
|
||||
/// Resume the specified call
|
||||
/// </summary>
|
||||
/// <param name="activeCall"></param>
|
||||
void ResumeCall(CodecActiveCallItem activeCall);
|
||||
}
|
||||
}
|
||||
@@ -23,9 +23,9 @@ namespace PepperDash.Essentials.Devices.Common.Codec
|
||||
public enum eCodecOccurrenceType
|
||||
{
|
||||
Unknown = 0,
|
||||
Placed = 1,
|
||||
Received = 2,
|
||||
NoAnswer = 3,
|
||||
Placed,
|
||||
Received,
|
||||
NoAnswer
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -65,9 +65,8 @@ namespace PepperDash.Essentials.Devices.Common.Codec
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the contents of the directory
|
||||
/// We don't want to serialize this for messages to MobileControl. MC can combine Contacts and Folders to get the same data
|
||||
/// </summary>
|
||||
[JsonIgnore]
|
||||
[JsonProperty("directoryResults")]
|
||||
public List<DirectoryItem> CurrentDirectoryResults { get; private set; }
|
||||
|
||||
[JsonProperty("contacts")]
|
||||
|
||||
@@ -99,7 +99,7 @@ namespace PepperDash.Essentials.Devices.Displays
|
||||
WarmupTime = 10000;
|
||||
CooldownTime = 8000;
|
||||
|
||||
CommunicationMonitor = new GenericCommunicationMonitor(this, Communication, 2000, 120000, 300000, StatusGet, true);
|
||||
CommunicationMonitor = new GenericCommunicationMonitor(this, Communication, 2000, 120000, 300000, StatusGet);
|
||||
DeviceManager.AddDevice(CommunicationMonitor);
|
||||
|
||||
VolumeIncrementer = new ActionIncrementer(655, 0, 65535, 800, 80,
|
||||
|
||||
@@ -108,7 +108,6 @@
|
||||
<Compile Include="Codec\eCodecCallStatus.cs" />
|
||||
<Compile Include="Codec\eMeetingPrivacy.cs" />
|
||||
<Compile Include="Codec\iCodecAudio.cs" />
|
||||
<Compile Include="Codec\IHasCallHold.cs" />
|
||||
<Compile Include="Codec\IHasDoNotDisturb.cs" />
|
||||
<Compile Include="Codec\IHasExternalSourceSwitching.cs" />
|
||||
<Compile Include="ImageProcessors\TVOneCorio.cs" />
|
||||
@@ -132,7 +131,6 @@
|
||||
<Compile Include="VideoCodec\Interfaces\IHasSelfviewSize.cs" />
|
||||
<Compile Include="VideoCodec\Interfaces\IHasStandbyMode.cs" />
|
||||
<Compile Include="VideoCodec\Interfaces\IHasStartMeeting.cs" />
|
||||
<Compile Include="VideoCodec\Interfaces\IJoinCalls.cs" />
|
||||
<Compile Include="VideoCodec\Interfaces\iVideoCodecInfo.cs" />
|
||||
<Compile Include="Codec\iHasCallFavorites.cs" />
|
||||
<Compile Include="Codec\iHasCallHistory.cs" />
|
||||
@@ -196,6 +194,10 @@
|
||||
<Project>{A49AD6C8-FC0A-4CC0-9089-DFB4CF92D2B5}</Project>
|
||||
<Name>PepperDash_Essentials_Core</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\Essentials Interfaces\PepperDash_Essentials_Interfaces\PepperDash_Essentials_Interfaces.csproj">
|
||||
<Project>{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}</Project>
|
||||
<Name>PepperDash_Essentials_Interfaces</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
|
||||
<ProjectExtensions>
|
||||
|
||||
@@ -41,12 +41,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
|
||||
public void PanLeft()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Move Value: Left CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Move Value: Left CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void PanRight()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Move Value: Right CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Move Value: Right CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void PanStop()
|
||||
@@ -60,12 +60,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
|
||||
public void TiltDown()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Move Value: Down CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Move Value: Down CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void TiltUp()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Move Value: Up CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Move Value: Up CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void TiltStop()
|
||||
@@ -79,12 +79,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
|
||||
public void ZoomIn()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Move Value: ZoomIn CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Move Value: ZoomIn CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void ZoomOut()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Move Value: ZoomOut CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Move Value: ZoomOut CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void ZoomStop()
|
||||
@@ -97,7 +97,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
|
||||
void Stop()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Call FarEndControl Camera Stop CallId: {0}", CallId));
|
||||
ParentCodec.SendText(string.Format("xCommand Call FarEndControl Camera Stop CallId: {0}", CallId));
|
||||
}
|
||||
|
||||
public void LinkToApi(BasicTriList trilist, uint joinStart, string joinMapKey, EiscApiAdvanced bridge)
|
||||
@@ -116,7 +116,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
/// <summary>
|
||||
/// The ID of the camera on the codec
|
||||
/// </summary>
|
||||
public uint CameraId { get; private set; }
|
||||
protected uint CameraId { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// Valid range 1-15
|
||||
@@ -202,7 +202,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Pan: Left PanSpeed: {1}", CameraId, PanSpeed));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Pan: Left PanSpeed: {1}", CameraId, PanSpeed));
|
||||
isPanning = true;
|
||||
}
|
||||
}
|
||||
@@ -211,14 +211,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Pan: Right PanSpeed: {1}", CameraId, PanSpeed));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Pan: Right PanSpeed: {1}", CameraId, PanSpeed));
|
||||
isPanning = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void PanStop()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Pan: Stop", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Pan: Stop", CameraId));
|
||||
isPanning = false;
|
||||
}
|
||||
|
||||
@@ -232,7 +232,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Tilt: Down TiltSpeed: {1}", CameraId, TiltSpeed));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Tilt: Down TiltSpeed: {1}", CameraId, TiltSpeed));
|
||||
isTilting = true;
|
||||
}
|
||||
}
|
||||
@@ -241,14 +241,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Tilt: Up TiltSpeed: {1}", CameraId, TiltSpeed));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Tilt: Up TiltSpeed: {1}", CameraId, TiltSpeed));
|
||||
isTilting = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void TiltStop()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Tilt: Stop", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Tilt: Stop", CameraId));
|
||||
isTilting = false;
|
||||
}
|
||||
|
||||
@@ -260,7 +260,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Zoom: In ZoomSpeed: {1}", CameraId, ZoomSpeed));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Zoom: In ZoomSpeed: {1}", CameraId, ZoomSpeed));
|
||||
isZooming = true;
|
||||
}
|
||||
}
|
||||
@@ -269,14 +269,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Zoom: Out ZoomSpeed: {1}", CameraId, ZoomSpeed));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Zoom: Out ZoomSpeed: {1}", CameraId, ZoomSpeed));
|
||||
isZooming = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void ZoomStop()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Zoom: Stop", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Zoom: Stop", CameraId));
|
||||
isZooming = false;
|
||||
}
|
||||
|
||||
@@ -288,7 +288,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Focus: Near", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Focus: Near", CameraId));
|
||||
isFocusing = true;
|
||||
}
|
||||
}
|
||||
@@ -297,20 +297,20 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
if (!isMoving)
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Focus: Far", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Focus: Far", CameraId));
|
||||
isFocusing = true;
|
||||
}
|
||||
}
|
||||
|
||||
public void FocusStop()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera Ramp CameraId: {0} Focus: Stop", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera Ramp CameraId: {0} Focus: Stop", CameraId));
|
||||
isFocusing = false;
|
||||
}
|
||||
|
||||
public void TriggerAutoFocus()
|
||||
{
|
||||
ParentCodec.EnqueueCommand(string.Format("xCommand Camera TriggerAutofocus CameraId: {0}", CameraId));
|
||||
ParentCodec.SendText(string.Format("xCommand Camera TriggerAutofocus CameraId: {0}", CameraId));
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -9,39 +9,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
#region Digital
|
||||
|
||||
[JoinName("PresentationLocalOnly")]
|
||||
public JoinDataComplete PresentationLocalOnly = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 205,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Presentation Local Only Feedback",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("PresentationLocalRemote")]
|
||||
public JoinDataComplete PresentationLocalRemote = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 206,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Presentation Local and Remote Feedback",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("ActivateDoNotDisturbMode")]
|
||||
public JoinDataComplete ActivateDoNotDisturbMode = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 241,
|
||||
JoinNumber = 221,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -55,7 +27,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public JoinDataComplete DeactivateDoNotDisturbMode = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 242,
|
||||
JoinNumber = 222,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -69,7 +41,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public JoinDataComplete ToggleDoNotDisturbMode = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 243,
|
||||
JoinNumber = 223,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -83,7 +55,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public JoinDataComplete ActivateStandby = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 246,
|
||||
JoinNumber = 226,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -97,7 +69,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public JoinDataComplete DeactivateStandby = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 247,
|
||||
JoinNumber = 227,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -111,7 +83,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public JoinDataComplete ActivateHalfWakeMode = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 248,
|
||||
JoinNumber = 228,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -125,7 +97,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public JoinDataComplete EnteringStandbyMode = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 249,
|
||||
JoinNumber = 229,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
@@ -140,55 +112,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
|
||||
#region Analog
|
||||
|
||||
[JoinName("RingtoneVolume")]
|
||||
public JoinDataComplete RingtoneVolume = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 21,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Ringtone volume set/FB. Valid values are 0 - 100 in increments of 5 (5, 10, 15, 20, etc.)",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
[JoinName("PresentationSource")]
|
||||
public JoinDataComplete PresentationSource = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 201,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Presentation set/FB. Valid values are 0 - 6 depending on the codec model.",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Analog
|
||||
});
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
#region Serials
|
||||
|
||||
[JoinName("CommandToDevice")]
|
||||
public JoinDataComplete CommandToDevice = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 5,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Sends a serial command to the device. Do not include the delimiter, it will be added automatically.",
|
||||
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||
JoinType = eJoinType.Serial
|
||||
});
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -50,16 +50,8 @@ namespace PepperDash.Essentials.Devices.Common.Codec
|
||||
public uint PhonebookResultsLimit { get; set; }
|
||||
|
||||
[JsonProperty("UiBranding")]
|
||||
public BrandingLogoProperties UiBranding { get; set; }
|
||||
public BrandingLogoProperties UiBranding { get; set; }
|
||||
|
||||
[JsonProperty("cameraInfo")]
|
||||
public List<CameraInfo> CameraInfo { get; set; }
|
||||
|
||||
|
||||
public CiscoSparkCodecPropertiesConfig()
|
||||
{
|
||||
CameraInfo = new List<CameraInfo>();
|
||||
}
|
||||
}
|
||||
|
||||
public class SharingProperties
|
||||
@@ -76,14 +68,4 @@ namespace PepperDash.Essentials.Devices.Common.Codec
|
||||
[JsonProperty("brandingUrl")]
|
||||
public string BrandingUrl { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Describes configuration information for the near end cameras
|
||||
/// </summary>
|
||||
public class CameraInfo
|
||||
{
|
||||
public int CameraNumber { get; set; }
|
||||
public string Name { get; set; }
|
||||
public int SourceId { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -26,8 +26,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
void CodecRoomPresetSelect(int preset);
|
||||
|
||||
void CodecRoomPresetStore(int preset, string description);
|
||||
|
||||
void SelectFarEndPreset(int preset);
|
||||
}
|
||||
|
||||
public static class RoomPresets
|
||||
|
||||
@@ -112,46 +112,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class RingVolume : ValueProperty
|
||||
public class RingVolume
|
||||
{
|
||||
public string valueSpaceRef { get; set; }
|
||||
|
||||
string _Value;
|
||||
|
||||
/// <summary>
|
||||
/// Sets Value and triggers the action when set
|
||||
/// </summary>
|
||||
public string Value
|
||||
{
|
||||
get
|
||||
{
|
||||
return _Value;
|
||||
}
|
||||
set
|
||||
{
|
||||
_Value = value;
|
||||
OnValueChanged();
|
||||
}
|
||||
}
|
||||
|
||||
public int Volume
|
||||
{
|
||||
get
|
||||
{
|
||||
return Int32.Parse(_Value);
|
||||
}
|
||||
}
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class SoundsAndAlerts
|
||||
{
|
||||
public RingTone RingTone { get; set; }
|
||||
public RingVolume RingVolume { get; set; }
|
||||
|
||||
public SoundsAndAlerts()
|
||||
{
|
||||
RingVolume = new RingVolume();
|
||||
}
|
||||
}
|
||||
|
||||
public class Audio
|
||||
@@ -161,12 +131,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public Microphones Microphones { get; set; }
|
||||
public Output Output { get; set; }
|
||||
public SoundsAndAlerts SoundsAndAlerts { get; set; }
|
||||
|
||||
|
||||
public Audio()
|
||||
{
|
||||
SoundsAndAlerts = new SoundsAndAlerts();
|
||||
}
|
||||
}
|
||||
|
||||
public class DefaultMode
|
||||
@@ -376,13 +340,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public Delay Delay { get; set; }
|
||||
public Mode9 Mode { get; set; }
|
||||
public Mute2 Mute { get; set; }
|
||||
|
||||
public AutoAnswer()
|
||||
{
|
||||
Mode = new Mode9();
|
||||
Delay = new Delay();
|
||||
Mute = new Mute2();
|
||||
}
|
||||
}
|
||||
|
||||
public class Protocol
|
||||
@@ -483,11 +440,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public MaxTotalTransmitCallRate MaxTotalTransmitCallRate { get; set; }
|
||||
public MaxTransmitCallRate MaxTransmitCallRate { get; set; }
|
||||
public MultiStream MultiStream { get; set; }
|
||||
|
||||
public Conference()
|
||||
{
|
||||
AutoAnswer = new AutoAnswer();
|
||||
}
|
||||
}
|
||||
|
||||
public class LoginName
|
||||
@@ -738,11 +690,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public Assignment Assignment { get; set; }
|
||||
public Gateway Gateway { get; set; }
|
||||
public SubnetMask SubnetMask { get; set; }
|
||||
|
||||
public IPv4()
|
||||
{
|
||||
Address = new Address4();
|
||||
}
|
||||
}
|
||||
|
||||
public class Address5
|
||||
@@ -894,11 +841,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public RemoteAccess RemoteAccess { get; set; }
|
||||
public Speed Speed { get; set; }
|
||||
public VLAN VLAN { get; set; }
|
||||
|
||||
public Network()
|
||||
{
|
||||
IPv4 = new IPv4();
|
||||
}
|
||||
}
|
||||
|
||||
public class Mode19
|
||||
@@ -1855,23 +1797,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public UserInterface UserInterface { get; set; }
|
||||
public UserManagement UserManagement { get; set; }
|
||||
public Video2 Video { get; set; }
|
||||
|
||||
public Configuration()
|
||||
{
|
||||
Audio = new Audio();
|
||||
Conference = new Conference();
|
||||
Network = new List<Network>();
|
||||
}
|
||||
}
|
||||
|
||||
public class RootObject
|
||||
{
|
||||
public Configuration Configuration { get; set; }
|
||||
|
||||
public RootObject()
|
||||
{
|
||||
Configuration = new Configuration();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -12,28 +12,28 @@ using PepperDash.Essentials.Devices.Common.VideoCodec.CiscoCodec;
|
||||
|
||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
{
|
||||
// Helper Classes for Proerties
|
||||
public abstract class ValueProperty
|
||||
{
|
||||
/// <summary>
|
||||
/// Triggered when Value is set
|
||||
/// </summary>
|
||||
public Action ValueChangedAction { get; set; }
|
||||
|
||||
protected void OnValueChanged()
|
||||
{
|
||||
var a = ValueChangedAction;
|
||||
if (a != null)
|
||||
a();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// This class exists to capture serialized data sent back by a Cisco codec in JSON output mode
|
||||
/// </summary>
|
||||
public class CiscoCodecStatus
|
||||
{
|
||||
// Helper Classes for Proerties
|
||||
public abstract class ValueProperty
|
||||
{
|
||||
/// <summary>
|
||||
/// Triggered when Value is set
|
||||
/// </summary>
|
||||
public Action ValueChangedAction { get; set; }
|
||||
|
||||
protected void OnValueChanged()
|
||||
{
|
||||
var a = ValueChangedAction;
|
||||
if (a != null)
|
||||
a();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
public class ConnectionStatus
|
||||
{
|
||||
@@ -262,30 +262,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class DectectedConnector
|
||||
{
|
||||
public string Value { get; set; }
|
||||
|
||||
public int ConnectorId
|
||||
{
|
||||
get
|
||||
{
|
||||
if(!string.IsNullOrEmpty(Value))
|
||||
{
|
||||
return Convert.ToUInt16(Value);
|
||||
}
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public class Camera
|
||||
{
|
||||
public string id { get; set; }
|
||||
public Capabilities Capabilities { get; set; }
|
||||
public Connected Connected { get; set; }
|
||||
public DectectedConnector DetectedConnector { get; set; }
|
||||
public Flip Flip { get; set; }
|
||||
public HardwareID HardwareID { get; set; }
|
||||
public MacAddress MacAddress { get; set; }
|
||||
@@ -294,13 +275,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public Position Position { get; set; }
|
||||
public SerialNumber SerialNumber { get; set; }
|
||||
public SoftwareID SoftwareID { get; set; }
|
||||
|
||||
public Camera()
|
||||
{
|
||||
Manufacturer = new Manufacturer();
|
||||
Model = new Model();
|
||||
DetectedConnector = new DectectedConnector();
|
||||
}
|
||||
}
|
||||
|
||||
public class Availability : ValueProperty
|
||||
@@ -324,34 +298,11 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
}
|
||||
}
|
||||
|
||||
public class CallStatus : ValueProperty
|
||||
{
|
||||
string _Value;
|
||||
public bool BoolValue { get; private set; }
|
||||
|
||||
|
||||
public string Value
|
||||
{
|
||||
get
|
||||
{
|
||||
return _Value;
|
||||
}
|
||||
set
|
||||
{
|
||||
// If the incoming value is "Active" it sets the BoolValue true, otherwise sets it false
|
||||
_Value = value;
|
||||
BoolValue = value == "Connected";
|
||||
OnValueChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public class Status2 : ValueProperty
|
||||
{
|
||||
string _Value;
|
||||
public bool BoolValue { get; private set; }
|
||||
|
||||
|
||||
public string Value
|
||||
{
|
||||
get
|
||||
@@ -607,47 +558,9 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
}
|
||||
}
|
||||
|
||||
public class SendingMode : ValueProperty
|
||||
public class SendingMode
|
||||
{
|
||||
string _Value;
|
||||
|
||||
/// <summary>
|
||||
/// Sets Value and triggers the action when set
|
||||
/// </summary>
|
||||
public string Value
|
||||
{
|
||||
get
|
||||
{
|
||||
return _Value;
|
||||
}
|
||||
set
|
||||
{
|
||||
_Value = value;
|
||||
OnValueChanged();
|
||||
}
|
||||
}
|
||||
|
||||
public bool LocalOnly
|
||||
{
|
||||
get
|
||||
{
|
||||
if(string.IsNullOrEmpty(_Value))
|
||||
return false;
|
||||
|
||||
return _Value.ToLower() == "localonly";
|
||||
}
|
||||
}
|
||||
|
||||
public bool LocalRemote
|
||||
{
|
||||
get
|
||||
{
|
||||
if(string.IsNullOrEmpty(_Value))
|
||||
return false;
|
||||
|
||||
return _Value.ToLower() == "localremote";
|
||||
}
|
||||
}
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class LocalInstance
|
||||
@@ -660,7 +573,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public LocalInstance()
|
||||
{
|
||||
Source = new Source2();
|
||||
SendingMode = new SendingMode();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -969,11 +881,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public Address4 Address { get; set; }
|
||||
public Gateway Gateway { get; set; }
|
||||
public SubnetMask SubnetMask { get; set; }
|
||||
|
||||
public IPv4()
|
||||
{
|
||||
Address = new Address4();
|
||||
}
|
||||
}
|
||||
|
||||
public class Address5
|
||||
@@ -1016,11 +923,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public IPv4 IPv4 { get; set; }
|
||||
public IPv6 IPv6 { get; set; }
|
||||
public VLAN VLAN { get; set; }
|
||||
|
||||
public Network()
|
||||
{
|
||||
IPv4 = new IPv4();
|
||||
}
|
||||
}
|
||||
|
||||
public class CurrentAddress
|
||||
@@ -2047,30 +1949,9 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class Duration : ValueProperty
|
||||
public class Duration
|
||||
{
|
||||
private string _Value;
|
||||
|
||||
public string Value
|
||||
{
|
||||
get
|
||||
{
|
||||
return _Value;
|
||||
}
|
||||
set
|
||||
{
|
||||
_Value = value;
|
||||
OnValueChanged();
|
||||
}
|
||||
}
|
||||
|
||||
public TimeSpan DurationValue
|
||||
{
|
||||
get
|
||||
{
|
||||
return new TimeSpan(0, 0, Int32.Parse(_Value));
|
||||
}
|
||||
}
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class FacilityServiceId
|
||||
@@ -2083,19 +1964,9 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class PlacedOnHold : ValueProperty
|
||||
public class PlacedOnHold
|
||||
{
|
||||
public bool BoolValue { get; private set; }
|
||||
|
||||
public string Value
|
||||
{
|
||||
set
|
||||
{
|
||||
// If the incoming value is "True" it sets the BoolValue true, otherwise sets it false
|
||||
BoolValue = value == "True";
|
||||
OnValueChanged();
|
||||
}
|
||||
}
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
public class Protocol
|
||||
@@ -2136,14 +2007,13 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
public Protocol Protocol { get; set; }
|
||||
public ReceiveCallRate ReceiveCallRate { get; set; }
|
||||
public RemoteNumber RemoteNumber { get; set; }
|
||||
public CallStatus Status { get; set; }
|
||||
public Status2 Status { get; set; }
|
||||
public TransmitCallRate TransmitCallRate { get; set; }
|
||||
|
||||
public Call()
|
||||
{
|
||||
CallType = new CallType();
|
||||
Status = new CallStatus();
|
||||
Duration = new Duration();
|
||||
Status = new Status2();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2244,7 +2114,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
|
||||
SystemUnit = new SystemUnit();
|
||||
Video = new Video();
|
||||
Conference = new Conference2();
|
||||
Network = new List<Network>();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -42,11 +42,9 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces
|
||||
public Boolean WaitingForHost { get; private set; }
|
||||
[JsonProperty("isLocked", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public Boolean IsLocked { get; private set; }
|
||||
[JsonProperty("isRecording", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public Boolean IsRecording { get; private set; }
|
||||
|
||||
|
||||
public MeetingInfo(string id, string name, string host, string password, string shareStatus, bool isHost, bool isSharingMeeting, bool waitingForHost, bool isLocked, bool isRecording)
|
||||
public MeetingInfo(string id, string name, string host, string password, string shareStatus, bool isHost, bool isSharingMeeting, bool waitingForHost, bool isLocked)
|
||||
{
|
||||
Id = id;
|
||||
Name = name;
|
||||
@@ -57,7 +55,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces
|
||||
IsSharingMeeting = isSharingMeeting;
|
||||
WaitingForHost = waitingForHost;
|
||||
IsLocked = isLocked;
|
||||
IsRecording = isRecording;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -15,15 +15,4 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces
|
||||
void StopRecording();
|
||||
void ToggleRecording();
|
||||
}
|
||||
|
||||
public interface IHasMeetingRecordingWithPrompt : IHasMeetingRecording
|
||||
{
|
||||
BoolFeedback RecordConsentPromptIsVisible { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Used to agree or disagree to the meeting being recorded when prompted
|
||||
/// </summary>
|
||||
/// <param name="agree"></param>
|
||||
void RecordingPromptAcknowledgement(bool agree);
|
||||
}
|
||||
}
|
||||
@@ -24,12 +24,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Interfaces
|
||||
/// </summary>
|
||||
/// <param name="participant"></param>
|
||||
void SetParticipantAsHost(int userId);
|
||||
|
||||
/// <summary>
|
||||
/// Admits a participant from the waiting room
|
||||
/// </summary>
|
||||
/// <param name="userId"></param>
|
||||
void AdmitParticipantFromWaitingRoom(int userId);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Crestron.SimplSharp;
|
||||
|
||||
using PepperDash.Essentials.Devices.Common.Codec;
|
||||
|
||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
{
|
||||
public interface IJoinCalls
|
||||
{
|
||||
void JoinCall(CodecActiveCallItem activeCall);
|
||||
void JoinAllCalls();
|
||||
}
|
||||
}
|
||||
@@ -764,11 +764,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
SetConfig(Config);
|
||||
}
|
||||
|
||||
public void SelectFarEndPreset(int i)
|
||||
{
|
||||
Debug.Console(1, this, "Selecting Far End Preset: {0}", i);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
protected override void CustomSetConfig(DeviceConfig config)
|
||||
|
||||
@@ -152,7 +152,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
public abstract void AcceptCall(CodecActiveCallItem call);
|
||||
public abstract void RejectCall(CodecActiveCallItem call);
|
||||
public abstract void SendDtmf(string s);
|
||||
public virtual void SendDtmf(string s, CodecActiveCallItem call) { }
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -260,12 +259,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
/// </summary>
|
||||
public virtual void ListCalls()
|
||||
{
|
||||
Debug.Console(1, this, "Active Calls:");
|
||||
|
||||
var sb = new StringBuilder();
|
||||
foreach (var c in ActiveCalls)
|
||||
{
|
||||
sb.AppendFormat("id: {0} number: {1} -- name: {2} status: {3} onHold: {4}\r\n", c.Id, c.Number, c.Name, c.Status, c.IsOnHold);
|
||||
sb.AppendFormat("{0} {1} -- {2} {3}\n", c.Id, c.Number, c.Name, c.Status);
|
||||
}
|
||||
Debug.Console(1, this, "\n{0}\n", sb.ToString());
|
||||
}
|
||||
@@ -331,22 +328,15 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
|
||||
LinkVideoCodecVolumeToApi(trilist, joinMap);
|
||||
|
||||
LinkVideoCodecInfoToApi(trilist, joinMap);
|
||||
|
||||
// Register for this event to link any functions that require the codec to be ready first
|
||||
codec.IsReadyChange += (o, a) =>
|
||||
{
|
||||
if (codec is IHasCodecCameras)
|
||||
{
|
||||
LinkVideoCodecCameraToApi(codec as IHasCodecCameras, trilist, joinMap);
|
||||
}
|
||||
};
|
||||
|
||||
if (codec is ICommunicationMonitor)
|
||||
{
|
||||
LinkVideoCodecCommMonitorToApi(codec as ICommunicationMonitor, trilist, joinMap);
|
||||
}
|
||||
|
||||
if (codec is IHasCodecCameras)
|
||||
{
|
||||
LinkVideoCodecCameraToApi(codec as IHasCodecCameras, trilist, joinMap);
|
||||
}
|
||||
|
||||
if (codec is IHasCodecSelfView)
|
||||
{
|
||||
@@ -400,11 +390,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
LinkVideoCodecPhoneToApi(codec as IHasPhoneDialing, trilist, joinMap);
|
||||
}
|
||||
|
||||
if (codec is IHasCallHistory)
|
||||
{
|
||||
LinkVideoCodecCallHistoryToApi(codec as IHasCallHistory, trilist, joinMap);
|
||||
}
|
||||
|
||||
trilist.OnlineStatusChange += (device, args) =>
|
||||
{
|
||||
if (!args.DeviceOnLine) return;
|
||||
@@ -426,7 +411,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
|
||||
if (codec is IHasCameraAutoMode)
|
||||
{
|
||||
trilist.SetBool(joinMap.CameraSupportsAutoMode.JoinNumber, SupportsCameraAutoMode);
|
||||
trilist.SetBool(joinMap.CameraSupportsAutoMode.JoinNumber, true);
|
||||
|
||||
(codec as IHasCameraAutoMode).CameraAutoModeIsOnFeedback.FireUpdate();
|
||||
}
|
||||
@@ -451,11 +436,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
(codec as IHasPhoneDialing).PhoneOffHookFeedback.FireUpdate();
|
||||
}
|
||||
|
||||
if (codec is IHasCallHistory)
|
||||
{
|
||||
UpdateCallHistory((codec as IHasCallHistory), trilist, joinMap);
|
||||
}
|
||||
|
||||
SharingContentIsOnFeedback.FireUpdate();
|
||||
|
||||
trilist.SetBool(joinMap.HookState.JoinNumber, IsInCall);
|
||||
@@ -464,31 +444,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
};
|
||||
}
|
||||
|
||||
private void LinkVideoCodecInfoToApi(BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
trilist.SetBool(joinMap.MultiSiteOptionIsEnabled.JoinNumber, this.CodecInfo.MultiSiteOptionIsEnabled);
|
||||
trilist.SetBool(joinMap.AutoAnswerEnabled.JoinNumber, this.CodecInfo.AutoAnswerEnabled);
|
||||
trilist.SetString(joinMap.DeviceIpAddresss.JoinNumber, this.CodecInfo.IpAddress);
|
||||
trilist.SetString(joinMap.SipPhoneNumber.JoinNumber, this.CodecInfo.SipPhoneNumber);
|
||||
trilist.SetString(joinMap.E164Alias.JoinNumber, this.CodecInfo.E164Alias);
|
||||
trilist.SetString(joinMap.H323Id.JoinNumber, this.CodecInfo.H323Id);
|
||||
trilist.SetString(joinMap.SipUri.JoinNumber, this.CodecInfo.SipUri);
|
||||
|
||||
trilist.OnlineStatusChange += (o, a) =>
|
||||
{
|
||||
if (a.DeviceOnLine)
|
||||
{
|
||||
trilist.SetBool(joinMap.MultiSiteOptionIsEnabled.JoinNumber, this.CodecInfo.MultiSiteOptionIsEnabled);
|
||||
trilist.SetBool(joinMap.AutoAnswerEnabled.JoinNumber, this.CodecInfo.AutoAnswerEnabled);
|
||||
trilist.SetString(joinMap.DeviceIpAddresss.JoinNumber, this.CodecInfo.IpAddress);
|
||||
trilist.SetString(joinMap.SipPhoneNumber.JoinNumber, this.CodecInfo.SipPhoneNumber);
|
||||
trilist.SetString(joinMap.E164Alias.JoinNumber, this.CodecInfo.E164Alias);
|
||||
trilist.SetString(joinMap.H323Id.JoinNumber, this.CodecInfo.H323Id);
|
||||
trilist.SetString(joinMap.SipUri.JoinNumber, this.CodecInfo.SipUri);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private void LinkVideoCodecPhoneToApi(IHasPhoneDialing codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
codec.PhoneOffHookFeedback.LinkInputSig(trilist.BooleanInput[joinMap.PhoneHookState.JoinNumber]);
|
||||
@@ -690,37 +645,37 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
{
|
||||
if (meetingIndex >= maxParticipants * offset) break;
|
||||
|
||||
// Debug.Console(2, this,
|
||||
//@"Updating Participant on xsig:
|
||||
//Name: {0} (s{9})
|
||||
//AudioMute: {1} (d{10})
|
||||
//VideoMute: {2} (d{11})
|
||||
//CanMuteVideo: {3} (d{12})
|
||||
//CanUMuteVideo: {4} (d{13})
|
||||
//IsHost: {5} (d{14})
|
||||
//HandIsRaised: {6} (d{15})
|
||||
//IsPinned: {7} (d{16})
|
||||
//ScreenIndexIsPinnedTo: {8} (a{17})
|
||||
//",
|
||||
// participant.Name,
|
||||
// participant.AudioMuteFb,
|
||||
// participant.VideoMuteFb,
|
||||
// participant.CanMuteVideo,
|
||||
// participant.CanUnmuteVideo,
|
||||
// participant.IsHost,
|
||||
// participant.HandIsRaisedFb,
|
||||
// participant.IsPinnedFb,
|
||||
// participant.ScreenIndexIsPinnedToFb,
|
||||
// stringIndex + 1,
|
||||
// digitalIndex + 1,
|
||||
// digitalIndex + 2,
|
||||
// digitalIndex + 3,
|
||||
// digitalIndex + 4,
|
||||
// digitalIndex + 5,
|
||||
// digitalIndex + 6,
|
||||
// digitalIndex + 7,
|
||||
// analogIndex + 1
|
||||
// );
|
||||
Debug.Console(2, this,
|
||||
@"Updating Participant on xsig:
|
||||
Name: {0} (s{9})
|
||||
AudioMute: {1} (d{10})
|
||||
VideoMute: {2} (d{11})
|
||||
CanMuteVideo: {3} (d{12})
|
||||
CanUMuteVideo: {4} (d{13})
|
||||
IsHost: {5} (d{14})
|
||||
HandIsRaised: {6} (d{15})
|
||||
IsPinned: {7} (d{16})
|
||||
ScreenIndexIsPinnedTo: {8} (a{17})
|
||||
",
|
||||
participant.Name,
|
||||
participant.AudioMuteFb,
|
||||
participant.VideoMuteFb,
|
||||
participant.CanMuteVideo,
|
||||
participant.CanUnmuteVideo,
|
||||
participant.IsHost,
|
||||
participant.HandIsRaisedFb,
|
||||
participant.IsPinnedFb,
|
||||
participant.ScreenIndexIsPinnedToFb,
|
||||
stringIndex + 1,
|
||||
digitalIndex + 1,
|
||||
digitalIndex + 2,
|
||||
digitalIndex + 3,
|
||||
digitalIndex + 4,
|
||||
digitalIndex + 5,
|
||||
digitalIndex + 6,
|
||||
digitalIndex + 7,
|
||||
analogIndex + 1
|
||||
);
|
||||
|
||||
|
||||
//digitals
|
||||
@@ -990,33 +945,18 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
private void LinkVideoCodecDirectoryToApi(IHasDirectory codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
codec.CurrentDirectoryResultIsNotDirectoryRoot.LinkComplementInputSig(
|
||||
trilist.BooleanInput[joinMap.DirectoryIsRoot.JoinNumber]);
|
||||
trilist.BooleanInput[joinMap.DirectoryIsRoot.JoinNumber]);
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.DirectoryRoot.JoinNumber, codec.SetCurrentDirectoryToRoot);
|
||||
|
||||
trilist.SetStringSigAction(joinMap.DirectorySearchString.JoinNumber, codec.SearchDirectory);
|
||||
|
||||
trilist.SetUShortSigAction(joinMap.DirectorySelectRow.JoinNumber, (i) => SelectDirectoryEntry(codec, i, trilist, joinMap));
|
||||
|
||||
// Report feedback for number of contact methods for selected contact
|
||||
trilist.SetUShortSigAction(joinMap.DirectorySelectRow.JoinNumber, (i) => SelectDirectoryEntry(codec, i));
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.DirectoryRoot.JoinNumber, codec.SetCurrentDirectoryToRoot);
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.DirectoryFolderBack.JoinNumber, codec.GetDirectoryParentFolderContents);
|
||||
|
||||
if (codec.DirectoryRoot != null)
|
||||
{
|
||||
trilist.SetUshort(joinMap.DirectoryRowCount.JoinNumber, (ushort)codec.DirectoryRoot.CurrentDirectoryResults.Count);
|
||||
|
||||
var clearBytes = XSigHelpers.ClearOutputs();
|
||||
|
||||
trilist.SetString(joinMap.DirectoryEntries.JoinNumber,
|
||||
Encoding.GetEncoding(XSigEncoding).GetString(clearBytes, 0, clearBytes.Length));
|
||||
var directoryXSig = UpdateDirectoryXSig(codec.DirectoryRoot, !codec.CurrentDirectoryResultIsNotDirectoryRoot.BoolValue);
|
||||
|
||||
Debug.Console(2, this, "Directory XSig Length: {0}", directoryXSig.Length);
|
||||
|
||||
trilist.SetString(joinMap.DirectoryEntries.JoinNumber, directoryXSig);
|
||||
}
|
||||
|
||||
codec.DirectoryResultReturned += (sender, args) =>
|
||||
{
|
||||
trilist.SetUshort(joinMap.DirectoryRowCount.JoinNumber, (ushort)args.Directory.CurrentDirectoryResults.Count);
|
||||
@@ -1027,8 +967,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
Encoding.GetEncoding(XSigEncoding).GetString(clearBytes, 0, clearBytes.Length));
|
||||
var directoryXSig = UpdateDirectoryXSig(args.Directory, !codec.CurrentDirectoryResultIsNotDirectoryRoot.BoolValue);
|
||||
|
||||
Debug.Console(2, this, "Directory XSig Length: {0}", directoryXSig.Length);
|
||||
|
||||
trilist.SetString(joinMap.DirectoryEntries.JoinNumber, directoryXSig);
|
||||
};
|
||||
|
||||
@@ -1043,154 +981,40 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void SelectDirectoryEntry(IHasDirectory codec, ushort i, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
private void SelectDirectoryEntry(IHasDirectory codec, ushort i)
|
||||
{
|
||||
if (i < 1 || i > codec.CurrentDirectoryResult.CurrentDirectoryResults.Count) return;
|
||||
var entry = codec.CurrentDirectoryResult.CurrentDirectoryResults[i - 1];
|
||||
|
||||
_selectedDirectoryItem = codec.CurrentDirectoryResult.CurrentDirectoryResults[i - 1];
|
||||
|
||||
|
||||
if (_selectedDirectoryItem is DirectoryFolder)
|
||||
if (entry is DirectoryFolder)
|
||||
{
|
||||
codec.GetDirectoryFolderContents(_selectedDirectoryItem.FolderId);
|
||||
trilist.SetUshort(joinMap.SelectedContactMethodCount.JoinNumber, 0);
|
||||
trilist.SetString(joinMap.DirectorySelectedFolderName.JoinNumber, _selectedDirectoryItem.Name);
|
||||
trilist.SetString(joinMap.DirectoryEntrySelectedName.JoinNumber, string.Empty);
|
||||
trilist.ClearUShortSigAction(joinMap.SelectContactMethod.JoinNumber);
|
||||
trilist.ClearBoolSigAction(joinMap.DirectoryDialSelectedLine.JoinNumber);
|
||||
trilist.ClearBoolSigAction(joinMap.DirectoryDialSelectedContactMethod.JoinNumber);
|
||||
return;
|
||||
codec.GetDirectoryFolderContents(entry.FolderId);
|
||||
return;
|
||||
}
|
||||
|
||||
// not a folder. Clear this value
|
||||
trilist.SetString(joinMap.DirectorySelectedFolderName.JoinNumber, string.Empty);
|
||||
var dialableEntry = entry as IInvitableContact;
|
||||
|
||||
var selectedContact = _selectedDirectoryItem as DirectoryContact;
|
||||
if (selectedContact != null)
|
||||
{
|
||||
trilist.SetString(joinMap.DirectoryEntrySelectedName.JoinNumber, selectedContact.Name);
|
||||
|
||||
}
|
||||
if (dialableEntry != null)
|
||||
{
|
||||
Dial(dialableEntry);
|
||||
return;
|
||||
}
|
||||
|
||||
// Allow auto dial of selected line. Always dials first contact method
|
||||
if (!trilist.GetBool(joinMap.DirectoryDisableAutoDialSelectedLine.JoinNumber))
|
||||
{
|
||||
var invitableEntry = _selectedDirectoryItem as IInvitableContact;
|
||||
var entryToDial = entry as DirectoryContact;
|
||||
|
||||
if (invitableEntry != null)
|
||||
{
|
||||
Dial(invitableEntry);
|
||||
return;
|
||||
}
|
||||
if (entryToDial == null) return;
|
||||
|
||||
var entryToDial = _selectedDirectoryItem as DirectoryContact;
|
||||
|
||||
trilist.SetString(joinMap.DirectoryEntrySelectedNumber.JoinNumber, selectedContact.ContactMethods[0].Number);
|
||||
|
||||
if (entryToDial == null) return;
|
||||
|
||||
Dial(entryToDial.ContactMethods[0].Number);
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
// If auto dial is disabled...
|
||||
var entryToDial = _selectedDirectoryItem as DirectoryContact;
|
||||
|
||||
if (entryToDial == null)
|
||||
{
|
||||
// Clear out values and actions from last selected item
|
||||
trilist.SetUshort(joinMap.SelectedContactMethodCount.JoinNumber, 0);
|
||||
trilist.SetString(joinMap.DirectoryEntrySelectedName.JoinNumber, string.Empty);
|
||||
trilist.ClearUShortSigAction(joinMap.SelectContactMethod.JoinNumber);
|
||||
trilist.ClearBoolSigAction(joinMap.DirectoryDialSelectedLine.JoinNumber);
|
||||
trilist.ClearBoolSigAction(joinMap.DirectoryDialSelectedContactMethod.JoinNumber);
|
||||
return;
|
||||
}
|
||||
|
||||
trilist.SetUshort(joinMap.SelectedContactMethodCount.JoinNumber, (ushort)entryToDial.ContactMethods.Count);
|
||||
|
||||
// Update the action to dial the selected contact method
|
||||
trilist.SetUShortSigAction(joinMap.SelectContactMethod.JoinNumber, (u) =>
|
||||
{
|
||||
if (u < 1 || u > entryToDial.ContactMethods.Count) return;
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.DirectoryDialSelectedContactMethod.JoinNumber, () => Dial(entryToDial.ContactMethods[u - 1].Number));
|
||||
});
|
||||
|
||||
// Sets DirectoryDialSelectedLine join action to dial first contact method
|
||||
trilist.SetSigFalseAction(joinMap.DirectoryDialSelectedLine.JoinNumber, () => Dial(entryToDial.ContactMethods[0].Number));
|
||||
|
||||
var clearBytes = XSigHelpers.ClearOutputs();
|
||||
|
||||
trilist.SetString(joinMap.ContactMethods.JoinNumber,
|
||||
Encoding.GetEncoding(XSigEncoding).GetString(clearBytes, 0, clearBytes.Length));
|
||||
var contactMethodsXSig = UpdateContactMethodsXSig(entryToDial);
|
||||
|
||||
trilist.SetString(joinMap.ContactMethods.JoinNumber, contactMethodsXSig);
|
||||
}
|
||||
Dial(entryToDial.ContactMethods[0].Number);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Generates the XSig data representing the available contact methods for the selected DirectoryContact
|
||||
/// </summary>
|
||||
/// <param name="contact"></param>
|
||||
/// <returns></returns>
|
||||
private string UpdateContactMethodsXSig(DirectoryContact contact)
|
||||
{
|
||||
const int maxMethods = 10;
|
||||
const int maxStrings = 3;
|
||||
const int offset = maxStrings;
|
||||
var stringIndex = 0;
|
||||
var arrayIndex = 0;
|
||||
// Create a new token array and set the size to the number of methods times the total number of signals
|
||||
var tokenArray = new XSigToken[maxMethods * offset];
|
||||
|
||||
Debug.Console(2, this, "Creating XSIG token array with size {0}", maxMethods * offset);
|
||||
|
||||
// TODO: Add code to generate XSig data
|
||||
foreach (var method in contact.ContactMethods)
|
||||
{
|
||||
if (arrayIndex >= maxMethods * offset)
|
||||
break;
|
||||
|
||||
//serials
|
||||
tokenArray[arrayIndex + 1] = new XSigSerialToken(stringIndex + 1, method.Number);
|
||||
tokenArray[arrayIndex + 2] = new XSigSerialToken(stringIndex + 2, method.ContactMethodId.ToString());
|
||||
tokenArray[arrayIndex + 3] = new XSigSerialToken(stringIndex + 3, method.Device.ToString());
|
||||
|
||||
arrayIndex += offset;
|
||||
stringIndex += maxStrings;
|
||||
}
|
||||
|
||||
while (arrayIndex < maxMethods)
|
||||
{
|
||||
tokenArray[arrayIndex + 1] = new XSigSerialToken(stringIndex + 1, String.Empty);
|
||||
tokenArray[arrayIndex + 2] = new XSigSerialToken(stringIndex + 2, String.Empty);
|
||||
tokenArray[arrayIndex + 3] = new XSigSerialToken(stringIndex + 3, String.Empty);
|
||||
|
||||
arrayIndex += offset;
|
||||
stringIndex += maxStrings;
|
||||
}
|
||||
|
||||
return GetXSigString(tokenArray);
|
||||
}
|
||||
|
||||
private string UpdateDirectoryXSig(CodecDirectory directory, bool isRoot)
|
||||
{
|
||||
var contactIndex = 1;
|
||||
var tokenArray = new XSigToken[directory.CurrentDirectoryResults.Count];
|
||||
|
||||
Debug.Console(2, this, "Is root {0} Directory Count: {1}", isRoot, directory.CurrentDirectoryResults.Count);
|
||||
|
||||
foreach (var entry in directory.CurrentDirectoryResults)
|
||||
{
|
||||
var arrayIndex = contactIndex - 1;
|
||||
|
||||
Debug.Console(2, this, "Entry Name: {0}, Folder ID: {1}", entry.Name, entry.FolderId);
|
||||
|
||||
if (entry is DirectoryFolder && entry.ParentFolderId == "root")
|
||||
{
|
||||
tokenArray[arrayIndex] = new XSigSerialToken(contactIndex, String.Format("[+] {0}", entry.Name));
|
||||
@@ -1200,6 +1024,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
continue;
|
||||
}
|
||||
|
||||
if (isRoot && String.IsNullOrEmpty(entry.FolderId)) continue;
|
||||
|
||||
tokenArray[arrayIndex] = new XSigSerialToken(contactIndex, entry.Name);
|
||||
|
||||
contactIndex++;
|
||||
@@ -1213,34 +1039,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
trilist.SetSigFalseAction(joinMap.ManualDial.JoinNumber,
|
||||
() => Dial(trilist.StringOutput[joinMap.CurrentDialString.JoinNumber].StringValue));
|
||||
|
||||
//End All calls
|
||||
trilist.SetSigFalseAction(joinMap.EndAllCalls.JoinNumber, EndAllCalls);
|
||||
|
||||
//End a specific call, specified by index. Maximum 8 calls supported
|
||||
for (int i = 0; i < joinMap.EndCallStart.JoinSpan; i++)
|
||||
{
|
||||
var callIndex = i;
|
||||
|
||||
trilist.SetSigFalseAction((uint)(joinMap.EndCallStart.JoinNumber + i), () =>
|
||||
{
|
||||
|
||||
if (callIndex < 0 || callIndex >= ActiveCalls.Count)
|
||||
{
|
||||
Debug.Console(2, this, "Cannot end call. No call found at index: {0}", callIndex);
|
||||
return;
|
||||
}
|
||||
|
||||
var call = ActiveCalls[callIndex];
|
||||
if (call != null)
|
||||
{
|
||||
EndCall(call);
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "[End Call] Unable to find call at index '{0}'", i);
|
||||
}
|
||||
});
|
||||
}
|
||||
//End All calls for now
|
||||
trilist.SetSigFalseAction(joinMap.EndCall.JoinNumber, EndAllCalls);
|
||||
|
||||
trilist.SetBool(joinMap.HookState.JoinNumber, IsInCall);
|
||||
|
||||
@@ -1252,112 +1052,30 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
Debug.Console(1, this, "Call is incoming: {0}", args.CallItem.Direction == eCodecCallDirection.Incoming);
|
||||
trilist.SetBool(joinMap.IncomingCall.JoinNumber, args.CallItem.Direction == eCodecCallDirection.Incoming && args.CallItem.Status == eCodecCallStatus.Ringing);
|
||||
|
||||
if (args.CallItem.Direction == eCodecCallDirection.Incoming)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.IncomingAnswer.JoinNumber, () => AcceptCall(args.CallItem));
|
||||
trilist.SetSigFalseAction(joinMap.IncomingReject.JoinNumber, () => RejectCall(args.CallItem));
|
||||
trilist.SetString(joinMap.IncomingCallName.JoinNumber, args.CallItem.Name);
|
||||
trilist.SetString(joinMap.IncomingCallNumber.JoinNumber, args.CallItem.Number);
|
||||
}
|
||||
else
|
||||
{
|
||||
trilist.SetString(joinMap.IncomingCallName.JoinNumber, string.Empty);
|
||||
trilist.SetString(joinMap.IncomingCallNumber.JoinNumber, string.Empty);
|
||||
}
|
||||
|
||||
if (args.CallItem.Direction == eCodecCallDirection.Incoming)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.IncomingAnswer.JoinNumber, () => AcceptCall(args.CallItem));
|
||||
trilist.SetSigFalseAction(joinMap.IncomingReject.JoinNumber, () => RejectCall(args.CallItem));
|
||||
}
|
||||
|
||||
trilist.SetString(joinMap.CurrentCallData.JoinNumber, UpdateCallStatusXSig());
|
||||
|
||||
trilist.SetUshort(joinMap.ConnectedCallCount.JoinNumber, (ushort)ActiveCalls.Count);
|
||||
};
|
||||
|
||||
var joinCodec = this as IJoinCalls;
|
||||
if (joinCodec != null)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.JoinAllCalls.JoinNumber, () => joinCodec.JoinAllCalls());
|
||||
trilist.OnlineStatusChange += (device, args) =>
|
||||
{
|
||||
if (!args.DeviceOnLine) return;
|
||||
|
||||
for (int i = 0; i < joinMap.JoinCallStart.JoinSpan; i++)
|
||||
{
|
||||
trilist.SetSigFalseAction((uint)(joinMap.JoinCallStart.JoinNumber + i), () =>
|
||||
{
|
||||
var call = ActiveCalls[i];
|
||||
if (call != null)
|
||||
{
|
||||
joinCodec.JoinCall(call);
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "[Join Call] Unable to find call at index '{0}'", i);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
var holdCodec = this as IHasCallHold;
|
||||
if (holdCodec != null)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.HoldAllCalls.JoinNumber, () =>
|
||||
{
|
||||
foreach (var call in ActiveCalls)
|
||||
{
|
||||
holdCodec.HoldCall(call);
|
||||
}
|
||||
});
|
||||
|
||||
for (int i = 0; i < joinMap.HoldCallsStart.JoinSpan; i++)
|
||||
{
|
||||
var index = i;
|
||||
|
||||
trilist.SetSigFalseAction((uint)(joinMap.HoldCallsStart.JoinNumber + index), () =>
|
||||
{
|
||||
if (index < 0 || index >= ActiveCalls.Count) return;
|
||||
|
||||
var call = ActiveCalls[index];
|
||||
if (call != null)
|
||||
{
|
||||
holdCodec.HoldCall(call);
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "[Hold Call] Unable to find call at index '{0}'", i);
|
||||
}
|
||||
});
|
||||
|
||||
trilist.SetSigFalseAction((uint)(joinMap.ResumeCallsStart.JoinNumber + index), () =>
|
||||
{
|
||||
if (index < 0 || index >= ActiveCalls.Count) return;
|
||||
|
||||
var call = ActiveCalls[index];
|
||||
if (call != null)
|
||||
{
|
||||
holdCodec.ResumeCall(call);
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "[Resume Call] Unable to find call at index '{0}'", i);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
trilist.OnlineStatusChange += (device, args) =>
|
||||
{
|
||||
if (!args.DeviceOnLine) return;
|
||||
|
||||
// TODO [ ] Issue #868
|
||||
trilist.SetString(joinMap.CurrentCallData.JoinNumber, "\xFC");
|
||||
UpdateCallStatusXSig();
|
||||
};
|
||||
// TODO [ ] Issue #868
|
||||
trilist.SetString(joinMap.CurrentCallData.JoinNumber, "\xFC");
|
||||
UpdateCallStatusXSig();
|
||||
};
|
||||
}
|
||||
|
||||
private string UpdateCallStatusXSig()
|
||||
{
|
||||
const int maxCalls = 8;
|
||||
const int maxStrings = 6;
|
||||
const int maxDigitals = 2;
|
||||
const int offset = maxStrings + maxDigitals;
|
||||
const int maxStrings = 5;
|
||||
const int offset = 6;
|
||||
var stringIndex = 0;
|
||||
var digitalIndex = maxStrings * maxCalls;
|
||||
var arrayIndex = 0;
|
||||
@@ -1369,8 +1087,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
if (arrayIndex >= maxCalls * offset)
|
||||
break;
|
||||
//digitals
|
||||
tokenArray[digitalIndex] = new XSigDigitalToken(digitalIndex + 1, call.IsActiveCall);
|
||||
tokenArray[digitalIndex + 1] = new XSigDigitalToken(digitalIndex + 2, call.IsOnHold);
|
||||
tokenArray[arrayIndex] = new XSigDigitalToken(digitalIndex + 1, call.IsActiveCall);
|
||||
|
||||
//serials
|
||||
tokenArray[arrayIndex + 1] = new XSigSerialToken(stringIndex + 1, call.Name ?? String.Empty);
|
||||
@@ -1378,12 +1095,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
tokenArray[arrayIndex + 3] = new XSigSerialToken(stringIndex + 3, call.Direction.ToString());
|
||||
tokenArray[arrayIndex + 4] = new XSigSerialToken(stringIndex + 4, call.Type.ToString());
|
||||
tokenArray[arrayIndex + 5] = new XSigSerialToken(stringIndex + 5, call.Status.ToString());
|
||||
if(call.Duration != null)
|
||||
{
|
||||
// May need to verify correct string format here
|
||||
var dur = string.Format("{0:c}", call.Duration);
|
||||
tokenArray[arrayIndex + 6] = new XSigSerialToken(stringIndex + 6, dur);
|
||||
}
|
||||
|
||||
arrayIndex += offset;
|
||||
stringIndex += maxStrings;
|
||||
@@ -1392,17 +1103,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
while (digitalIndex < maxCalls)
|
||||
{
|
||||
//digitals
|
||||
tokenArray[digitalIndex] = new XSigDigitalToken(digitalIndex + 1, false);
|
||||
tokenArray[digitalIndex + 1] = new XSigDigitalToken(digitalIndex + 2, false);
|
||||
tokenArray[arrayIndex] = new XSigDigitalToken(digitalIndex + 1, false);
|
||||
|
||||
|
||||
//serials
|
||||
//serials
|
||||
tokenArray[arrayIndex + 1] = new XSigSerialToken(stringIndex + 1, String.Empty);
|
||||
tokenArray[arrayIndex + 2] = new XSigSerialToken(stringIndex + 2, String.Empty);
|
||||
tokenArray[arrayIndex + 3] = new XSigSerialToken(stringIndex + 3, String.Empty);
|
||||
tokenArray[arrayIndex + 4] = new XSigSerialToken(stringIndex + 4, String.Empty);
|
||||
tokenArray[arrayIndex + 5] = new XSigSerialToken(stringIndex + 5, String.Empty);
|
||||
tokenArray[arrayIndex + 6] = new XSigSerialToken(stringIndex + 6, String.Empty);
|
||||
|
||||
arrayIndex += offset;
|
||||
stringIndex += maxStrings;
|
||||
@@ -1414,61 +1122,25 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
|
||||
private void LinkVideoCodecDtmfToApi(BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf0.JoinNumber, () => SendDtmfAction("0", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf1.JoinNumber, () => SendDtmfAction("1", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf2.JoinNumber, () => SendDtmfAction("2", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf3.JoinNumber, () => SendDtmfAction("3", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf4.JoinNumber, () => SendDtmfAction("4", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf5.JoinNumber, () => SendDtmfAction("5", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf6.JoinNumber, () => SendDtmfAction("6", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf7.JoinNumber, () => SendDtmfAction("7", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf8.JoinNumber, () => SendDtmfAction("8", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf9.JoinNumber, () => SendDtmfAction("9", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.DtmfStar.JoinNumber, () => SendDtmfAction("*", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.DtmfPound.JoinNumber, () => SendDtmfAction("#", trilist, joinMap));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf0.JoinNumber, () => SendDtmf("0"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf1.JoinNumber, () => SendDtmf("1"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf2.JoinNumber, () => SendDtmf("2"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf3.JoinNumber, () => SendDtmf("3"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf4.JoinNumber, () => SendDtmf("4"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf5.JoinNumber, () => SendDtmf("5"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf6.JoinNumber, () => SendDtmf("6"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf7.JoinNumber, () => SendDtmf("7"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf8.JoinNumber, () => SendDtmf("8"));
|
||||
trilist.SetSigFalseAction(joinMap.Dtmf9.JoinNumber, () => SendDtmf("9"));
|
||||
trilist.SetSigFalseAction(joinMap.DtmfStar.JoinNumber, () => SendDtmf("*"));
|
||||
trilist.SetSigFalseAction(joinMap.DtmfPound.JoinNumber, () => SendDtmf("#"));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sends the specified string as a DTMF command.
|
||||
/// Reads the value of the SendDtmfToSpecificCallInstance digital join and SelectCall analog join to determine
|
||||
/// Whther to send to a specific call index or to the last connected call
|
||||
/// </summary>
|
||||
/// <param name="s"></param>
|
||||
/// <param name="trilist"></param>
|
||||
/// <param name="joinMap"></param>
|
||||
private void SendDtmfAction(string s, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
if (!trilist.GetBool(joinMap.SendDtmfToSpecificCallIndex.JoinNumber))
|
||||
{
|
||||
SendDtmf(s);
|
||||
}
|
||||
else
|
||||
{
|
||||
var callIndex = trilist.GetUshort(joinMap.SelectCall.JoinNumber);
|
||||
if (callIndex > 0 && callIndex <= 8)
|
||||
{
|
||||
var call = ActiveCalls[callIndex - 1];
|
||||
if (call != null && call.IsActiveCall)
|
||||
{
|
||||
SendDtmf(s, call);
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "Warning: No call found at index {0} or call is not active.", callIndex);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "Warning: Invalid call index specified. Please use a value of 1-8.");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void LinkVideoCodecCameraLayoutsToApi(IHasCodecLayouts codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.CameraLayout.JoinNumber, codec.LocalLayoutToggle);
|
||||
|
||||
codec.LocalLayoutFeedback.LinkInputSig(trilist.StringInput[joinMap.CurrentLayoutStringFb.JoinNumber]);
|
||||
codec.LocalLayoutFeedback.LinkInputSig(trilist.StringInput[joinMap.CameraLayoutStringFb.JoinNumber]);
|
||||
}
|
||||
|
||||
private void LinkVideoCodecCameraModeToApi(IHasCameraAutoMode codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
@@ -1599,81 +1271,18 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
else camera.ZoomStop();
|
||||
});
|
||||
|
||||
|
||||
trilist.SetBoolSigAction(joinMap.CameraFocusNear.JoinNumber, (b) =>
|
||||
{
|
||||
if (codec.SelectedCamera == null) return;
|
||||
var camera = codec.SelectedCamera as IHasCameraFocusControl;
|
||||
|
||||
if (camera == null) return;
|
||||
|
||||
if (b) camera.FocusNear();
|
||||
else camera.FocusStop();
|
||||
});
|
||||
|
||||
trilist.SetBoolSigAction(joinMap.CameraFocusFar.JoinNumber, (b) =>
|
||||
{
|
||||
if (codec.SelectedCamera == null) return;
|
||||
var camera = codec.SelectedCamera as IHasCameraFocusControl;
|
||||
|
||||
if (camera == null) return;
|
||||
|
||||
if (b) camera.FocusFar();
|
||||
else camera.FocusStop();
|
||||
});
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.CameraFocusAuto.JoinNumber, () =>
|
||||
{
|
||||
if (codec.SelectedCamera == null) return;
|
||||
var camera = codec.SelectedCamera as IHasCameraFocusControl;
|
||||
|
||||
if (camera == null) return;
|
||||
|
||||
camera.TriggerAutoFocus();
|
||||
});
|
||||
|
||||
// Camera count
|
||||
trilist.SetUshort(joinMap.CameraCount.JoinNumber, (ushort)codec.Cameras.Count);
|
||||
|
||||
// Camera names
|
||||
for (uint i = 0; i < joinMap.CameraNamesFb.JoinSpan; i++)
|
||||
{
|
||||
//Check the count first
|
||||
if (i < codec.Cameras.Count && codec.Cameras[(int)i] != null)
|
||||
{
|
||||
trilist.SetString(joinMap.CameraNamesFb.JoinNumber + i, codec.Cameras[(int)i].Name);
|
||||
}
|
||||
else
|
||||
{
|
||||
trilist.SetString(joinMap.CameraNamesFb.JoinNumber + i, "");
|
||||
}
|
||||
}
|
||||
|
||||
//Camera Select
|
||||
trilist.SetUShortSigAction(joinMap.CameraNumberSelect.JoinNumber, (i) =>
|
||||
{
|
||||
if (i > 0 && i <= codec.Cameras.Count)
|
||||
{
|
||||
codec.SelectCamera(codec.Cameras[i - 1].Key);
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(0, this, "Unable to select. No camera found at index {0}", i);
|
||||
}
|
||||
});
|
||||
if (codec.SelectedCamera == null) return;
|
||||
|
||||
// Set initial selected camera feedback
|
||||
if (codec.SelectedCamera != null)
|
||||
{
|
||||
trilist.SetUshort(joinMap.CameraNumberSelect.JoinNumber, (ushort)codec.Cameras.FindIndex((c) => c.Key == codec.SelectedCamera.Key));
|
||||
}
|
||||
codec.SelectCamera(codec.Cameras[i].Key);
|
||||
});
|
||||
|
||||
codec.CameraSelected += (sender, args) =>
|
||||
{
|
||||
var i = (ushort)codec.Cameras.FindIndex((c) => c.Key == args.SelectedCamera.Key);
|
||||
|
||||
trilist.SetUshort(joinMap.CameraNumberSelect.JoinNumber, (ushort)(i + 1));
|
||||
|
||||
if (codec is IHasCodecRoomPresets)
|
||||
{
|
||||
return;
|
||||
@@ -1716,16 +1325,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
trilist.SetUShortSigAction(joinMap.CameraPresetSelect.JoinNumber, (i) =>
|
||||
{
|
||||
presetCodec.CodecRoomPresetSelect(i);
|
||||
|
||||
trilist.SetUshort(joinMap.CameraPresetSelect.JoinNumber, i);
|
||||
});
|
||||
|
||||
|
||||
// Far End Presets
|
||||
trilist.SetUShortSigAction(joinMap.FarEndPresetSelect.JoinNumber, (i) =>
|
||||
{
|
||||
presetCodec.SelectFarEndPreset(i);
|
||||
});
|
||||
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.CameraPresetSave.JoinNumber,
|
||||
() =>
|
||||
{
|
||||
@@ -1744,96 +1347,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec
|
||||
};
|
||||
}
|
||||
|
||||
// Following fields only used for Bridging
|
||||
private int _selectedRecentCallItemIndex;
|
||||
private CodecCallHistory.CallHistoryEntry _selectedRecentCallItem;
|
||||
private DirectoryItem _selectedDirectoryItem;
|
||||
|
||||
private void LinkVideoCodecCallHistoryToApi(IHasCallHistory codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
codec.CallHistory.RecentCallsListHasChanged += (o, a) =>
|
||||
{
|
||||
UpdateCallHistory(codec, trilist, joinMap);
|
||||
};
|
||||
|
||||
// Selected item action and feedback
|
||||
trilist.SetUShortSigAction(joinMap.SelectRecentCallItem.JoinNumber, (u) =>
|
||||
{
|
||||
if (u == 0 || u > codec.CallHistory.RecentCalls.Count)
|
||||
{
|
||||
Debug.Console(2, this, "Recent Call History index out of range");
|
||||
return;
|
||||
}
|
||||
|
||||
_selectedRecentCallItemIndex = (int)(u - 1);
|
||||
trilist.SetUshort(joinMap.SelectRecentCallItem.JoinNumber, u);
|
||||
|
||||
var _selectedRecentCallItem = codec.CallHistory.RecentCalls[_selectedRecentCallItemIndex];
|
||||
|
||||
if (_selectedRecentCallItem != null)
|
||||
{
|
||||
trilist.SetString(joinMap.SelectedRecentCallName.JoinNumber, _selectedRecentCallItem.Name);
|
||||
trilist.SetString(joinMap.SelectedRecentCallNumber.JoinNumber, _selectedRecentCallItem.Number);
|
||||
trilist.SetSigFalseAction(joinMap.RemoveSelectedRecentCallItem.JoinNumber, () => codec.RemoveCallHistoryEntry(_selectedRecentCallItem));
|
||||
trilist.SetSigFalseAction(joinMap.DialSelectedRecentCallItem.JoinNumber, () => this.Dial(_selectedRecentCallItem.Number));
|
||||
}
|
||||
else
|
||||
{
|
||||
trilist.SetString(joinMap.SelectedRecentCallName.JoinNumber, string.Empty);
|
||||
trilist.SetString(joinMap.SelectedRecentCallNumber.JoinNumber, string.Empty);
|
||||
trilist.ClearBoolSigAction(joinMap.RemoveSelectedRecentCallItem.JoinNumber);
|
||||
trilist.ClearBoolSigAction(joinMap.DialSelectedRecentCallItem.JoinNumber);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void UpdateCallHistory(IHasCallHistory codec, BasicTriList trilist, VideoCodecControllerJoinMap joinMap)
|
||||
{
|
||||
// Clear out selected item
|
||||
_selectedRecentCallItemIndex = 0;
|
||||
_selectedRecentCallItem = null;
|
||||
trilist.SetUshort(joinMap.SelectRecentCallItem.JoinNumber, 0);
|
||||
trilist.SetString(joinMap.SelectedRecentCallName.JoinNumber, string.Empty);
|
||||
trilist.SetString(joinMap.SelectedRecentCallNumber.JoinNumber, string.Empty);
|
||||
trilist.ClearBoolSigAction(joinMap.RemoveSelectedRecentCallItem.JoinNumber);
|
||||
//
|
||||
|
||||
trilist.SetUshort(joinMap.RecentCallCount.JoinNumber, (ushort)codec.CallHistory.RecentCalls.Count);
|
||||
|
||||
// Update the call history joins
|
||||
var maxItems = joinMap.RecentCallNamesStart.JoinSpan;
|
||||
|
||||
// Create history
|
||||
uint index = 0;
|
||||
for (uint i = 0; i < maxItems && i < codec.CallHistory.RecentCalls.Count; i++)
|
||||
{
|
||||
trilist.SetString(joinMap.RecentCallNamesStart.JoinNumber + i, codec.CallHistory.RecentCalls[(int)i].Name);
|
||||
trilist.SetString(joinMap.RecentCallTimesStart.JoinNumber + i, codec.CallHistory.RecentCalls[(int)i].StartTime.ToShortTimeString());
|
||||
trilist.SetUshort(joinMap.RecentCallOccurrenceType.JoinNumber + i, (ushort)codec.CallHistory.RecentCalls[(int)i].OccurrenceType);
|
||||
//i++;
|
||||
index = i;
|
||||
}
|
||||
|
||||
//foreach(var item in codec.CallHistory.RecentCalls)
|
||||
//{
|
||||
// trilist.SetString(joinMap.RecentCallNamesStart.JoinNumber + i, item.Name);
|
||||
// trilist.SetString(joinMap.RecentCallTimesStart.JoinNumber + i, item.StartTime.ToShortTimeString());
|
||||
// trilist.SetUshort(joinMap.RecentCallOccurrenceType.JoinNumber + i, (ushort)item.OccurrenceType);
|
||||
// i++;
|
||||
//}
|
||||
|
||||
// Clears existing items
|
||||
for (uint j = index; j < maxItems; j++)
|
||||
{
|
||||
trilist.SetString(joinMap.RecentCallNamesStart.JoinNumber + j, string.Empty);
|
||||
trilist.SetString(joinMap.RecentCallTimesStart.JoinNumber + j, string.Empty);
|
||||
trilist.SetUshort(joinMap.RecentCallOccurrenceType.JoinNumber + j, 0);
|
||||
}
|
||||
}
|
||||
|
||||
private string SetCameraPresetNames(IEnumerable<CodecRoomPreset> presets)
|
||||
private string SetCameraPresetNames(IEnumerable<CodecRoomPreset> presets)
|
||||
{
|
||||
return SetCameraPresetNames(presets.Select(p => p.Description).ToList());
|
||||
}
|
||||
|
||||
@@ -31,15 +31,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
protected void NotifyPropertyChanged(string propertyName)
|
||||
{
|
||||
var handler = PropertyChanged;
|
||||
if (handler != null)
|
||||
{
|
||||
handler(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
else
|
||||
{
|
||||
Debug.Console(2, "PropertyChanged event is NULL");
|
||||
}
|
||||
if (PropertyChanged != null)
|
||||
{
|
||||
PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
@@ -783,20 +778,13 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
}
|
||||
set
|
||||
{
|
||||
//Debug.Console(2, "************************************setting value of meetingIsBeingRecorded to: {0}", value);
|
||||
if (value != _meetingIsBeingRecorded)
|
||||
{
|
||||
_meetingIsBeingRecorded = value;
|
||||
//Debug.Console(2, "********************************set value of meetingIsBeingRecorded to: {0}", _meetingIsBeingRecorded);
|
||||
NotifyPropertyChanged("meetingIsBeingRecorded");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public CallRecordInfo()
|
||||
{
|
||||
Debug.Console(2, Debug.ErrorLogLevel.Notice, "********************************************* CallRecordInfo() ******************************************");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -24,30 +24,16 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
public class ZoomRoom : VideoCodecBase, IHasCodecSelfView, IHasDirectoryHistoryStack, ICommunicationMonitor,
|
||||
IRouting,
|
||||
IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraMuteWithUnmuteReqeust, IHasCameraAutoMode,
|
||||
IHasScheduleAwareness, IHasCodecCameras, IHasParticipants, IHasCameraOff, IHasCameraMute, IHasCameraAutoMode,
|
||||
IHasFarEndContentStatus, IHasSelfviewPosition, IHasPhoneDialing, IHasZoomRoomLayouts, IHasParticipantPinUnpin,
|
||||
IHasParticipantAudioMute, IHasSelfviewSize, IPasswordPrompt, IHasStartMeeting, IHasMeetingInfo, IHasPresentationOnlyMeeting,
|
||||
IHasMeetingLock, IHasMeetingRecordingWithPrompt
|
||||
IHasMeetingLock, IHasMeetingRecording
|
||||
{
|
||||
public event EventHandler VideoUnmuteRequested;
|
||||
|
||||
private const long MeetingRefreshTimer = 60000;
|
||||
public uint DefaultMeetingDurationMin { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// CR LF CR LF Delimits an echoed response to a command
|
||||
/// </summary>
|
||||
private const string EchoDelimiter = "\x0D\x0A\x0D\x0A";
|
||||
private const string Delimiter = "\x0D\x0A";
|
||||
|
||||
private const string SendDelimiter = "\x0D";
|
||||
|
||||
/// <summary>
|
||||
/// CR LF } CR LF Delimits a JSON response
|
||||
/// </summary>
|
||||
private const string JsonDelimiter = "\x0D\x0A\x7D\x0D\x0A";
|
||||
|
||||
private string[] Delimiters = new string[] { EchoDelimiter, JsonDelimiter, "OK\x0D\x0A", "end\x0D\x0A" };
|
||||
//"echo off\x0D\x0A\x0A\x0D\x0A"
|
||||
private readonly GenericQueue _receiveQueue;
|
||||
//private readonly CrestronQueue<string> _receiveQueue;
|
||||
|
||||
@@ -73,7 +59,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
_props = JsonConvert.DeserializeObject<ZoomRoomPropertiesConfig>(config.Properties.ToString());
|
||||
|
||||
_receiveQueue = new GenericQueue(Key + "-rxQueue", Thread.eThreadPriority.MediumPriority, 2048);
|
||||
_receiveQueue = new GenericQueue(Key + "-rxQueue", Thread.eThreadPriority.MediumPriority, 512);
|
||||
|
||||
Communication = comm;
|
||||
|
||||
@@ -85,7 +71,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
else
|
||||
{
|
||||
CommunicationMonitor = new GenericCommunicationMonitor(this, Communication, 30000, 120000, 300000,
|
||||
"zStatus SystemUnit" + SendDelimiter);
|
||||
"zStatus SystemUnit\r");
|
||||
}
|
||||
|
||||
DeviceManager.AddDevice(CommunicationMonitor);
|
||||
@@ -100,31 +86,23 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
_syncState.InitialSyncCompleted += SyncState_InitialSyncCompleted;
|
||||
|
||||
_syncState.FirstJsonResponseReceived += (o, a) => SetUpSyncQueries();
|
||||
|
||||
PhonebookSyncState = new CodecPhonebookSyncState(Key + "--PhonebookSync");
|
||||
|
||||
PhonebookSyncState.InitialSyncCompleted += (o, a) => ResubscribeForAddedContacts();
|
||||
|
||||
PortGather = new CommunicationGather(Communication, Delimiters) {IncludeDelimiter = true};
|
||||
PortGather = new CommunicationGather(Communication, "\x0A") {IncludeDelimiter = true};
|
||||
PortGather.LineReceived += Port_LineReceived;
|
||||
|
||||
CodecOsdIn = new RoutingInputPort(RoutingPortNames.CodecOsd,
|
||||
eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||
eRoutingPortConnectionType.Hdmi, new Action(StopSharing), this);
|
||||
|
||||
Output1 = new RoutingOutputPort(RoutingPortNames.HdmiOut1,
|
||||
Output1 = new RoutingOutputPort(RoutingPortNames.AnyVideoOut,
|
||||
eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||
eRoutingPortConnectionType.Hdmi, null, this);
|
||||
|
||||
Output2 = new RoutingOutputPort(RoutingPortNames.HdmiOut2,
|
||||
Output2 = new RoutingOutputPort(RoutingPortNames.AnyVideoOut,
|
||||
eRoutingSignalType.Video,
|
||||
eRoutingPortConnectionType.DisplayPort, null, this);
|
||||
|
||||
Output3 = new RoutingOutputPort(RoutingPortNames.HdmiOut3,
|
||||
eRoutingSignalType.Audio | eRoutingSignalType.Video,
|
||||
eRoutingPortConnectionType.Hdmi, null, this);
|
||||
|
||||
SelfviewIsOnFeedback = new BoolFeedback(SelfViewIsOnFeedbackFunc);
|
||||
|
||||
CameraIsOffFeedback = new BoolFeedback(CameraIsOffFeedbackFunc);
|
||||
@@ -174,10 +152,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
MeetingIsLockedFeedback = new BoolFeedback(() => Configuration.Call.Lock.Enable );
|
||||
|
||||
MeetingIsRecordingFeedback = new BoolFeedback(() => Status.Call.CallRecordInfo.meetingIsBeingRecorded );
|
||||
|
||||
RecordConsentPromptIsVisible = new BoolFeedback(() => _recordConsentPromptIsVisible);
|
||||
|
||||
SetUpRouting();
|
||||
}
|
||||
|
||||
public CommunicationGather PortGather { get; private set; }
|
||||
@@ -307,7 +281,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
public RoutingInputPort CodecOsdIn { get; private set; }
|
||||
public RoutingOutputPort Output1 { get; private set; }
|
||||
public RoutingOutputPort Output2 { get; private set; }
|
||||
public RoutingOutputPort Output3 { get; private set; }
|
||||
|
||||
#region ICommunicationMonitor Members
|
||||
|
||||
@@ -353,11 +326,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
Debug.Console(1, this, "Selected Camera with key: '{0}'", camera.Key);
|
||||
SelectedCamera = camera;
|
||||
|
||||
if (CameraIsMutedFeedback.BoolValue)
|
||||
{
|
||||
CameraMuteOff();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -416,8 +384,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
_currentDirectoryResult = value;
|
||||
|
||||
Debug.Console(2, this, "CurrentDirectoryResult Updated. ResultsFolderId: {0} Contact Count: {1}",
|
||||
_currentDirectoryResult.ResultsFolderId, _currentDirectoryResult.CurrentDirectoryResults.Count);
|
||||
Debug.Console(2, this, "CurrentDirectoryResult Updated. ResultsFolderId: {0}",
|
||||
_currentDirectoryResult.ResultsFolderId);
|
||||
|
||||
CurrentDirectoryResultIsNotDirectoryRoot.FireUpdate();
|
||||
|
||||
OnDirectoryResultReturned(_currentDirectoryResult);
|
||||
}
|
||||
@@ -498,63 +468,25 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
private void SyncState_InitialSyncCompleted(object sender, EventArgs e)
|
||||
{
|
||||
SetUpRouting();
|
||||
|
||||
SetIsReady();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Handles subscriptions to Status.Call and sub objects. Needs to be called whenever Status.Call is constructed
|
||||
/// </summary>
|
||||
private void SetUpCallFeedbackActions()
|
||||
{
|
||||
Status.Call.Sharing.PropertyChanged -= HandleSharingStateUpdate;
|
||||
Status.Call.Sharing.PropertyChanged += HandleSharingStateUpdate;
|
||||
Status.Call.Sharing.PropertyChanged += HandleSharingStateUpdate;
|
||||
|
||||
Status.Call.PropertyChanged -= HandleCallStateUpdate;
|
||||
Status.Call.PropertyChanged += HandleCallStateUpdate;
|
||||
|
||||
Status.Call.CallRecordInfo.PropertyChanged -= HandleCallRecordInfoStateUpdate;
|
||||
Status.Call.CallRecordInfo.PropertyChanged += HandleCallRecordInfoStateUpdate;
|
||||
Status.Call.PropertyChanged += (o, a) =>
|
||||
{
|
||||
if (a.PropertyName == "Info")
|
||||
{
|
||||
Debug.Console(1, this, "Updating Call Status");
|
||||
UpdateCallStatus();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private void HandleCallRecordInfoStateUpdate(object sender, PropertyChangedEventArgs a)
|
||||
{
|
||||
if (a.PropertyName == "meetingIsBeingRecorded")
|
||||
{
|
||||
MeetingIsRecordingFeedback.FireUpdate();
|
||||
|
||||
var meetingInfo = new MeetingInfo(MeetingInfo.Id,
|
||||
MeetingInfo.Name,
|
||||
MeetingInfo.Host,
|
||||
MeetingInfo.Password,
|
||||
GetSharingStatus(),
|
||||
GetIsHostMyself(),
|
||||
MeetingInfo.IsSharingMeeting,
|
||||
MeetingInfo.WaitingForHost,
|
||||
MeetingIsLockedFeedback.BoolValue,
|
||||
MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingInfo = meetingInfo;
|
||||
}
|
||||
}
|
||||
|
||||
private void HandleCallStateUpdate(object sender, PropertyChangedEventArgs a)
|
||||
{
|
||||
switch (a.PropertyName)
|
||||
{
|
||||
case "Info":
|
||||
{
|
||||
Debug.Console(1, this, "Updating Call Status");
|
||||
UpdateCallStatus();
|
||||
break;
|
||||
}
|
||||
|
||||
case "Status":
|
||||
{
|
||||
UpdateCallStatus();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void HandleSharingStateUpdate(object sender, PropertyChangedEventArgs a)
|
||||
{
|
||||
if (a.PropertyName != "State")
|
||||
@@ -572,19 +504,19 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
var sharingStatus = GetSharingStatus();
|
||||
|
||||
MeetingInfo = new MeetingInfo("", "", "", "", sharingStatus, GetIsHostMyself(), true, false, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingInfo = new MeetingInfo("", "", "", "", sharingStatus, GetIsHostMyself(), true, false, MeetingIsLockedFeedback.BoolValue);
|
||||
return;
|
||||
}
|
||||
|
||||
var meetingInfo = new MeetingInfo(MeetingInfo.Id, MeetingInfo.Name, Participants.Host != null ? Participants.Host.Name : "None",
|
||||
MeetingInfo.Password, GetSharingStatus(), GetIsHostMyself(), MeetingInfo.IsSharingMeeting, MeetingInfo.WaitingForHost, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingInfo.Password, GetSharingStatus(), GetIsHostMyself(), MeetingInfo.IsSharingMeeting, MeetingInfo.WaitingForHost, MeetingIsLockedFeedback.BoolValue);
|
||||
MeetingInfo = meetingInfo;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Debug.Console(1, this, "Error processing state property update. {0}", e.Message);
|
||||
Debug.Console(2, this, e.StackTrace);
|
||||
MeetingInfo = new MeetingInfo("", "", "", "", "None", false, false, false, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingInfo = new MeetingInfo("", "", "", "", "None", false, false, false, MeetingIsLockedFeedback.BoolValue);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -593,9 +525,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
/// </summary>
|
||||
private void SetUpFeedbackActions()
|
||||
{
|
||||
// Set these up initially.
|
||||
SetUpCallFeedbackActions();
|
||||
|
||||
Configuration.Audio.Output.PropertyChanged += (o, a) =>
|
||||
{
|
||||
if (a.PropertyName == "Volume")
|
||||
@@ -690,8 +619,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
MeetingInfo.IsHost,
|
||||
MeetingInfo.IsSharingMeeting,
|
||||
MeetingInfo.WaitingForHost,
|
||||
MeetingIsLockedFeedback.BoolValue,
|
||||
MeetingIsRecordingFeedback.BoolValue
|
||||
MeetingIsLockedFeedback.BoolValue
|
||||
);
|
||||
}
|
||||
};
|
||||
@@ -724,6 +652,41 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
}
|
||||
};
|
||||
|
||||
Status.Call.Sharing.PropertyChanged += (o, a) =>
|
||||
{
|
||||
if (a.PropertyName == "State")
|
||||
{
|
||||
SharingContentIsOnFeedback.FireUpdate();
|
||||
ReceivingContent.FireUpdate();
|
||||
}
|
||||
};
|
||||
|
||||
Status.Call.PropertyChanged += (o, a) =>
|
||||
{
|
||||
switch(a.PropertyName)
|
||||
{
|
||||
case "Info":
|
||||
{
|
||||
Debug.Console(1, this, "Updating Call Status");
|
||||
UpdateCallStatus();
|
||||
break;
|
||||
}
|
||||
|
||||
case "Status":
|
||||
{
|
||||
UpdateCallStatus();
|
||||
break;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Status.Call.CallRecordInfo.PropertyChanged += (o, a) =>
|
||||
{
|
||||
if (a.PropertyName == "meetingIsBeingRecorded")
|
||||
{
|
||||
MeetingIsRecordingFeedback.FireUpdate();
|
||||
}
|
||||
};
|
||||
|
||||
Status.Sharing.PropertyChanged += (o, a) =>
|
||||
{
|
||||
@@ -755,8 +718,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
GetIsHostMyself(),
|
||||
MeetingInfo.IsSharingMeeting,
|
||||
MeetingInfo.WaitingForHost,
|
||||
MeetingIsLockedFeedback.BoolValue,
|
||||
MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingIsLockedFeedback.BoolValue);
|
||||
MeetingInfo = meetingInfo;
|
||||
break;
|
||||
}
|
||||
@@ -942,7 +904,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
Debug.Console(1, this, "Sending: '{0}'", command);
|
||||
}
|
||||
|
||||
Communication.SendText(command + SendDelimiter);
|
||||
Communication.SendText(command + Delimiter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -952,28 +914,13 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
/// <param name="args"></param>
|
||||
private void Port_LineReceived(object dev, GenericCommMethodReceiveTextArgs args)
|
||||
{
|
||||
//Debug.Console(0, this, "Port_LineReceived");
|
||||
//if (CommDebuggingIsOn)
|
||||
// Debug.Console(1, this, "Gathered: '{0}'", args.Text);
|
||||
|
||||
if (args.Delimiter != JsonDelimiter)
|
||||
{
|
||||
// Debug.Console(0, this,
|
||||
//@"Non JSON response:
|
||||
//Delimiter: {0}
|
||||
//{1}", ComTextHelper.GetDebugText(args.Delimiter), args.Text);
|
||||
ProcessNonJsonResponse(args.Text);
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
// Debug.Console(0, this,
|
||||
//@"JSON response:
|
||||
//Delimiter: {0}
|
||||
//{1}", ComTextHelper.GetDebugText(args.Delimiter), args.Text);
|
||||
_receiveQueue.Enqueue(new ProcessStringMessage(args.Text, DeserializeResponse));
|
||||
//_receiveQueue.Enqueue(new ProcessStringMessage(args.Text, ProcessMessage));
|
||||
}
|
||||
_receiveQueue.Enqueue(new ProcessStringMessage(args.Text, ProcessMessage));
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Queues the initial queries to be sent upon connection
|
||||
/// </summary>
|
||||
@@ -1032,93 +979,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
_syncState.StartSync();
|
||||
}
|
||||
|
||||
private void SetupSession()
|
||||
{
|
||||
// disable echo of commands
|
||||
SendText("echo off");
|
||||
// switch to json format
|
||||
// set feedback exclusions
|
||||
// Currently the feedback exclusions don't work when using the API in JSON response mode
|
||||
// But leave these here in case the API gets updated in the future
|
||||
// These may work as of 5.9.4
|
||||
|
||||
// In 5.9.4 we're getting sent an AddedContact message for every contact in the phonebook on connect, which is redunant and way too much data
|
||||
// We want to exclude these messages right away until after we've retrieved the entire phonebook and then we can re-enable them
|
||||
SendText("zFeedback Register Op: ex Path: /Event/Phonebook/AddedContact");
|
||||
|
||||
SendText("zFeedback Register Op: ex Path: /Event/InfoResult/Info/callin_country_list");
|
||||
SendText("zFeedback Register Op: ex Path: /Event/InfoResult/Info/callout_country_list");
|
||||
SendText("zFeedback Register Op: ex Path: /Event/InfoResult/Info/toll_free_callinLlist");
|
||||
|
||||
SendText("zStatus SystemUnit");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Removes the feedback exclusion for added contacts
|
||||
/// </summary>
|
||||
private void ResubscribeForAddedContacts()
|
||||
{
|
||||
SendText("zFeedback Register Op: in Path: /Event/Phonebook/AddedContact");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Processes non-JSON responses as their are received
|
||||
/// </summary>
|
||||
/// <param name="response"></param>
|
||||
private void ProcessNonJsonResponse(string response)
|
||||
{
|
||||
if (response.Contains("client_loop: send disconnect: Broken pipe"))
|
||||
{
|
||||
Debug.Console(1, this, Debug.ErrorLogLevel.Error,
|
||||
"Zoom Room Controller or App connected. Essentials will NOT control the Zoom Room until it is disconnected.");
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (!_syncState.InitialSyncComplete)
|
||||
{
|
||||
if(response.ToLower().Contains("*r login successful"))
|
||||
{
|
||||
_syncState.LoginResponseReceived();
|
||||
|
||||
SendText("format json");
|
||||
|
||||
SetupSession();
|
||||
}
|
||||
|
||||
//switch (response.Trim().ToLower()) // remove the whitespace
|
||||
//{
|
||||
// case "*r login successful":
|
||||
// {
|
||||
// _syncState.LoginMessageReceived();
|
||||
|
||||
// //// Fire up a thread to send the intial commands.
|
||||
// //CrestronInvoke.BeginInvoke(o =>
|
||||
// //{
|
||||
// // disable echo of commands
|
||||
// SendText("echo off");
|
||||
// // switch to json format
|
||||
// SendText("format json");
|
||||
// // set feedback exclusions
|
||||
// // Currently the feedback exclusions don't work when using the API in JSON response mode
|
||||
// // But leave these here in case the API gets updated in the future
|
||||
// // These may work as of 5.9.4
|
||||
// if (_props.DisablePhonebookAutoDownload)
|
||||
// {
|
||||
// SendText("zFeedback Register Op: ex Path: /Event/Phonebook/AddedContact");
|
||||
// }
|
||||
// SendText("zFeedback Register Op: ex Path: /Event/InfoResult/Info/callin_country_list");
|
||||
// SendText("zFeedback Register Op: ex Path: /Event/InfoResult/Info/callout_country_list");
|
||||
// SendText("zFeedback Register Op: ex Path: /Event/InfoResult/Info/toll_free_callinLlist");
|
||||
|
||||
// //});
|
||||
|
||||
// break;
|
||||
// }
|
||||
//}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Processes messages as they are dequeued
|
||||
/// </summary>
|
||||
@@ -1146,7 +1006,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
//Debug.Console(2, this, "JSON Curly Brace Count: {0}", _jsonCurlyBraceCounter);
|
||||
|
||||
if (!_jsonFeedbackMessageIsIncoming && message.Trim('\x20') == "{" + EchoDelimiter)
|
||||
if (!_jsonFeedbackMessageIsIncoming && message.Trim('\x20') == "{" + Delimiter)
|
||||
// Check for the beginning of a new JSON message
|
||||
{
|
||||
_jsonFeedbackMessageIsIncoming = true;
|
||||
@@ -1163,7 +1023,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
return;
|
||||
}
|
||||
if (_jsonFeedbackMessageIsIncoming && message.Trim('\x20') == "}" + EchoDelimiter)
|
||||
if (_jsonFeedbackMessageIsIncoming && message.Trim('\x20') == "}" + Delimiter)
|
||||
// Check for the end of a JSON message
|
||||
{
|
||||
_jsonMessage.Append(message);
|
||||
@@ -1208,7 +1068,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
case "*r login successful":
|
||||
{
|
||||
_syncState.LoginResponseReceived();
|
||||
_syncState.LoginMessageReceived();
|
||||
|
||||
|
||||
// Fire up a thread to send the intial commands.
|
||||
@@ -1261,11 +1121,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
var message = JObject.Parse(trimmedResponse);
|
||||
|
||||
if (!_syncState.FirstJsonResponseWasReceived)
|
||||
{
|
||||
_syncState.ReceivedFirstJsonResponse();
|
||||
}
|
||||
|
||||
var eType =
|
||||
(eZoomRoomResponseType)
|
||||
Enum.Parse(typeof (eZoomRoomResponseType), message["type"].Value<string>(), true);
|
||||
@@ -1274,7 +1129,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
var responseObj = message[topKey];
|
||||
|
||||
Debug.Console(1, this, "{0} Response Received. topKey: '{1}'\n{2}", eType, topKey, responseObj.ToString().Replace("\n", CrestronEnvironment.NewLine));
|
||||
Debug.Console(1, "{0} Response Received. topKey: '{1}'\n{2}", eType, topKey, responseObj.ToString());
|
||||
|
||||
switch (eType)
|
||||
{
|
||||
@@ -1327,9 +1182,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
// This result will always be the complete contents of the directory and never
|
||||
// A subset of the results via a search
|
||||
|
||||
// Clear out any existing data
|
||||
Status.Phonebook = new zStatus.Phonebook();
|
||||
|
||||
JsonConvert.PopulateObject(responseObj.ToString(), Status.Phonebook);
|
||||
|
||||
var directoryResults =
|
||||
@@ -1343,7 +1195,10 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
PhonebookSyncState.SetNumberOfContacts(Status.Phonebook.Contacts.Count);
|
||||
}
|
||||
|
||||
directoryResults.ResultsFolderId = "root";
|
||||
if (directoryResults.ResultsFolderId != "root")
|
||||
{
|
||||
directoryResults.ResultsFolderId = "root";
|
||||
}
|
||||
|
||||
DirectoryRoot = directoryResults;
|
||||
|
||||
@@ -1453,8 +1308,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
GetIsHostMyself(),
|
||||
MeetingInfo.IsSharingMeeting,
|
||||
MeetingInfo.WaitingForHost,
|
||||
MeetingIsLockedFeedback.BoolValue,
|
||||
MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingIsLockedFeedback.BoolValue);
|
||||
MeetingInfo = meetingInfo;
|
||||
|
||||
PrintCurrentCallParticipants();
|
||||
@@ -1631,13 +1485,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
}
|
||||
case "videounmuterequest":
|
||||
{
|
||||
var handler = VideoUnmuteRequested;
|
||||
|
||||
if (handler != null)
|
||||
{
|
||||
handler(this, null);
|
||||
}
|
||||
|
||||
// TODO: notify room of a request to unmute video
|
||||
break;
|
||||
}
|
||||
case "meetingneedspassword":
|
||||
@@ -1669,14 +1517,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
if (MeetingInfo == null)
|
||||
{
|
||||
MeetingInfo = new MeetingInfo("Waiting For Host", "Waiting For Host", "Waiting For Host", "",
|
||||
GetSharingStatus(), false, false, true, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
GetSharingStatus(), false, false, true, MeetingIsLockedFeedback.BoolValue);
|
||||
|
||||
UpdateCallStatus();
|
||||
break;
|
||||
}
|
||||
|
||||
MeetingInfo = new MeetingInfo("Waiting For Host", "Waiting For Host", "Waiting For Host", "",
|
||||
GetSharingStatus(), false, false, true, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
GetSharingStatus(), false, false, true, MeetingIsLockedFeedback.BoolValue);
|
||||
|
||||
UpdateCallStatus();
|
||||
|
||||
@@ -1686,12 +1534,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
if (MeetingInfo == null)
|
||||
{
|
||||
MeetingInfo = new MeetingInfo("Waiting For Host", "Waiting For Host", "Waiting For Host", "",
|
||||
GetSharingStatus(), false, false, false, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
GetSharingStatus(), false, false, false, MeetingIsLockedFeedback.BoolValue);
|
||||
break;
|
||||
}
|
||||
|
||||
MeetingInfo = new MeetingInfo(MeetingInfo.Id, MeetingInfo.Name, MeetingInfo.Host, MeetingInfo.Password,
|
||||
GetSharingStatus(), GetIsHostMyself(), false, false, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
GetSharingStatus(), GetIsHostMyself(), false, false, MeetingIsLockedFeedback.BoolValue);
|
||||
|
||||
break;
|
||||
}
|
||||
@@ -1700,18 +1548,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
// TODO: notify user that host has disabled unmuting video
|
||||
break;
|
||||
}
|
||||
case "updatecallrecordinfo":
|
||||
case "updatedcallrecordinfo":
|
||||
{
|
||||
JsonConvert.PopulateObject(responseObj.ToString(), Status.Call.CallRecordInfo);
|
||||
|
||||
break;
|
||||
}
|
||||
case "recordingconsent":
|
||||
{
|
||||
_recordConsentPromptIsVisible = responseObj["isShow"].Value<bool>();
|
||||
RecordConsentPromptIsVisible.FireUpdate();
|
||||
break;
|
||||
}
|
||||
case "phonecallstatus":
|
||||
{
|
||||
JsonConvert.PopulateObject(responseObj.ToString(), Status.PhoneCall);
|
||||
@@ -1781,7 +1623,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
if (result.Success)
|
||||
{
|
||||
MeetingInfo = new MeetingInfo("", "", "", "", "", true, true, MeetingInfo.WaitingForHost, MeetingIsLockedFeedback.BoolValue, MeetingIsRecordingFeedback.BoolValue);
|
||||
MeetingInfo = new MeetingInfo("", "", "", "", "", true, true, MeetingInfo.WaitingForHost, MeetingIsLockedFeedback.BoolValue);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -1800,17 +1642,19 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
case "login":
|
||||
{
|
||||
_syncState.LoginResponseReceived();
|
||||
_syncState.LoginMessageReceived();
|
||||
|
||||
SetupSession();
|
||||
if (!_syncState.InitialQueryMessagesWereSent)
|
||||
{
|
||||
SetUpSyncQueries();
|
||||
}
|
||||
|
||||
JsonConvert.PopulateObject(responseObj.ToString(), Status.Login);
|
||||
|
||||
break;
|
||||
}
|
||||
case "systemunit":
|
||||
{
|
||||
|
||||
{
|
||||
JsonConvert.PopulateObject(responseObj.ToString(), Status.SystemUnit);
|
||||
|
||||
break;
|
||||
@@ -1876,8 +1720,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
}
|
||||
case "video camera line":
|
||||
{
|
||||
Status.Cameras.Clear();
|
||||
|
||||
JsonConvert.PopulateObject(responseObj.ToString(), Status.Cameras);
|
||||
|
||||
if (!_syncState.CamerasHaveBeenSetUp)
|
||||
@@ -1982,11 +1824,12 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
// If not crrently in a meeting, intialize the call object
|
||||
if (callStatus != zStatus.eCallStatus.IN_MEETING && callStatus != zStatus.eCallStatus.CONNECTING_MEETING)
|
||||
{
|
||||
//Debug.Console(1, this, "[UpdateCallStatus] Creating new Status.Call object");
|
||||
Status.Call = new zStatus.Call {Status = callStatus};
|
||||
// Resubscribe to all property change events after Status.Call is reconstructed
|
||||
SetUpCallFeedbackActions();
|
||||
|
||||
OnCallStatusChange(new CodecActiveCallItem() {Status = eCodecCallStatus.Disconnected});
|
||||
|
||||
SetUpCallFeedbackActions();
|
||||
}
|
||||
|
||||
if (ActiveCalls.Count == 0)
|
||||
@@ -2126,8 +1969,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
GetIsHostMyself(),
|
||||
!String.Equals(Status.Call.Info.meeting_type,"NORMAL"),
|
||||
false,
|
||||
MeetingIsLockedFeedback.BoolValue,
|
||||
MeetingIsRecordingFeedback.BoolValue
|
||||
MeetingIsLockedFeedback.BoolValue
|
||||
);
|
||||
}
|
||||
// TODO [ ] Issue #868
|
||||
@@ -2142,7 +1984,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
);
|
||||
}
|
||||
@@ -2368,21 +2209,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
/// <param name="joinMap"></param>
|
||||
public void LinkZoomRoomToApi(BasicTriList trilist, ZoomRoomJoinMap joinMap)
|
||||
{
|
||||
var recordingCodec = this as IHasMeetingRecordingWithPrompt;
|
||||
if (recordingCodec != null)
|
||||
{
|
||||
trilist.SetSigFalseAction(joinMap.StartRecording.JoinNumber, () => recordingCodec.StartRecording());
|
||||
trilist.SetSigFalseAction(joinMap.StopRecording.JoinNumber, () => recordingCodec.StopRecording());
|
||||
|
||||
recordingCodec.MeetingIsRecordingFeedback.LinkInputSig(trilist.BooleanInput[joinMap.StartRecording.JoinNumber]);
|
||||
recordingCodec.MeetingIsRecordingFeedback.LinkComplementInputSig(trilist.BooleanInput[joinMap.StopRecording.JoinNumber]);
|
||||
|
||||
trilist.SetSigFalseAction(joinMap.RecordingPromptAgree.JoinNumber, () => recordingCodec.RecordingPromptAcknowledgement(true));
|
||||
trilist.SetSigFalseAction(joinMap.RecordingPromptDisagree.JoinNumber, () => recordingCodec.RecordingPromptAcknowledgement(false));
|
||||
|
||||
recordingCodec.RecordConsentPromptIsVisible.LinkInputSig(trilist.BooleanInput[joinMap.RecordConsentPromptIsVisible.JoinNumber]);
|
||||
}
|
||||
|
||||
var layoutsCodec = this as IHasZoomRoomLayouts;
|
||||
if (layoutsCodec != null)
|
||||
{
|
||||
@@ -2469,7 +2295,29 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
});
|
||||
|
||||
layoutSizeCodec.SelfviewPipSizeFeedback.LinkInputSig(trilist.StringInput[joinMap.GetSetSelfviewPipSize.JoinNumber]);
|
||||
}
|
||||
}
|
||||
|
||||
PasswordRequired += (device, args) =>
|
||||
{
|
||||
if (args.LoginAttemptCancelled)
|
||||
{
|
||||
trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, false);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(args.Message))
|
||||
{
|
||||
trilist.SetString(joinMap.PasswordPromptMessage.JoinNumber, args.Message);
|
||||
}
|
||||
|
||||
if (args.LoginAttemptFailed)
|
||||
{
|
||||
trilist.SetBool(joinMap.PasswordLoginFailed.JoinNumber, true);
|
||||
return;
|
||||
}
|
||||
|
||||
trilist.SetBool(joinMap.ShowPasswordPrompt.JoinNumber, true);
|
||||
};
|
||||
|
||||
MeetingInfoChanged += (device, args) =>
|
||||
{
|
||||
@@ -2727,27 +2575,27 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
try
|
||||
{
|
||||
Debug.Console(2, this, "OnDirectoryResultReturned. Result has {0} contacts", result.Contacts.Count);
|
||||
Debug.Console(2, this, "OnDirectoryResultReturned");
|
||||
|
||||
var directoryResult = result;
|
||||
var directoryResult = new CodecDirectory();
|
||||
|
||||
// If result is Root, create a copy and filter out contacts whose parent folder is not root
|
||||
//if (!CurrentDirectoryResultIsNotDirectoryRoot.BoolValue)
|
||||
//{
|
||||
// Debug.Console(2, this, "Filtering DirectoryRoot to remove contacts for display");
|
||||
if (!CurrentDirectoryResultIsNotDirectoryRoot.BoolValue)
|
||||
{
|
||||
Debug.Console(2, this, "Filtering DirectoryRoot to remove contacts for display");
|
||||
|
||||
// directoryResult.ResultsFolderId = result.ResultsFolderId;
|
||||
// directoryResult.AddFoldersToDirectory(result.Folders);
|
||||
// directoryResult.AddContactsToDirectory(
|
||||
// result.Contacts.Where((c) => c.ParentFolderId == result.ResultsFolderId).ToList());
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// directoryResult = result;
|
||||
//}
|
||||
directoryResult.ResultsFolderId = result.ResultsFolderId;
|
||||
directoryResult.AddFoldersToDirectory(result.Folders);
|
||||
directoryResult.AddContactsToDirectory(
|
||||
result.Contacts.Where((c) => c.ParentFolderId == result.ResultsFolderId).ToList());
|
||||
}
|
||||
else
|
||||
{
|
||||
directoryResult = result;
|
||||
}
|
||||
|
||||
Debug.Console(2, this, "Updating directoryResult. IsOnRoot: {0} Contact Count: {1}",
|
||||
!CurrentDirectoryResultIsNotDirectoryRoot.BoolValue, directoryResult.Contacts.Count);
|
||||
Debug.Console(2, this, "Updating directoryResult. IsOnRoot: {0}",
|
||||
!CurrentDirectoryResultIsNotDirectoryRoot.BoolValue);
|
||||
|
||||
// This will return the latest results to all UIs. Multiple indendent UI Directory browsing will require a different methodology
|
||||
var handler = DirectoryResultReturned;
|
||||
@@ -2759,8 +2607,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
DirectoryIsOnRoot = !CurrentDirectoryResultIsNotDirectoryRoot.BoolValue
|
||||
});
|
||||
}
|
||||
|
||||
CurrentDirectoryResultIsNotDirectoryRoot.FireUpdate();
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
@@ -2791,19 +2637,14 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
continue;
|
||||
}
|
||||
|
||||
var existingCam = Cameras.FirstOrDefault((c) => c.Key.Equals(cam.id));
|
||||
var camera = new ZoomRoomCamera(cam.id, cam.Name, this);
|
||||
|
||||
if (existingCam == null)
|
||||
{
|
||||
var camera = new ZoomRoomCamera(cam.id, cam.Name, this);
|
||||
Cameras.Add(camera);
|
||||
|
||||
Cameras.Add(camera);
|
||||
|
||||
if (cam.Selected)
|
||||
{
|
||||
SelectedCamera = camera;
|
||||
}
|
||||
}
|
||||
if (cam.Selected)
|
||||
{
|
||||
SelectedCamera = camera;
|
||||
}
|
||||
}
|
||||
|
||||
if (IsInCall)
|
||||
@@ -2836,11 +2677,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
SendText(string.Format("zCommand Call HostChange Id: {0}", userId));
|
||||
}
|
||||
|
||||
public void AdmitParticipantFromWaitingRoom(int userId)
|
||||
{
|
||||
SendText(string.Format("zCommand Call Admit Participant Id: {0}", userId));
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region IHasParticipantAudioMute Members
|
||||
@@ -3224,7 +3060,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
handler(this, new LayoutInfoChangedEventArgs()
|
||||
{
|
||||
AvailableLayouts = AvailableLayouts,
|
||||
CurrentSelectedLayout = (zConfiguration.eLayoutStyle)Enum.Parse(typeof(zConfiguration.eLayoutStyle),string.IsNullOrEmpty(LocalLayoutFeedback.StringValue) ? "None" : LocalLayoutFeedback.StringValue , true),
|
||||
CurrentSelectedLayout = (zConfiguration.eLayoutStyle)Enum.Parse(typeof(zConfiguration.eLayoutStyle),LocalLayoutFeedback.StringValue, true),
|
||||
LayoutViewIsOnFirstPage = LayoutViewIsOnFirstPageFeedback.BoolValue,
|
||||
LayoutViewIsOnLastPage = LayoutViewIsOnLastPageFeedback.BoolValue,
|
||||
CanSwapContentWithThumbnail = CanSwapContentWithThumbnailFeedback.BoolValue,
|
||||
@@ -3451,29 +3287,18 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
#endregion
|
||||
|
||||
#region IHasMeetingRecordingWithPrompt Members
|
||||
#region IHasMeetingRecording Members
|
||||
|
||||
public BoolFeedback MeetingIsRecordingFeedback { get; private set; }
|
||||
|
||||
bool _recordConsentPromptIsVisible;
|
||||
|
||||
public BoolFeedback RecordConsentPromptIsVisible { get; private set; }
|
||||
|
||||
public void RecordingPromptAcknowledgement(bool agree)
|
||||
{
|
||||
var command = string.Format("zCommand Agree Recording: {0}", agree ? "on" : "off");
|
||||
//Debug.Console(2, this, "Sending agree: {0} {1}", agree, command);
|
||||
SendText(command);
|
||||
}
|
||||
|
||||
public void StartRecording()
|
||||
{
|
||||
SendText(string.Format("zCommand Call Record Enable: on"));
|
||||
SendText(string.Format("Command Call Record Enable: on"));
|
||||
}
|
||||
|
||||
public void StopRecording()
|
||||
{
|
||||
SendText(string.Format("zCommand Call Record Enable: off"));
|
||||
SendText(string.Format("Command Call Record Enable: off"));
|
||||
}
|
||||
|
||||
public void ToggleRecording()
|
||||
@@ -3612,9 +3437,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
}
|
||||
}
|
||||
|
||||
public bool LoginResponseWasReceived { get; private set; }
|
||||
|
||||
public bool FirstJsonResponseWasReceived { get; private set; }
|
||||
public bool LoginMessageWasReceived { get; private set; }
|
||||
|
||||
public bool InitialQueryMessagesWereSent { get; private set; }
|
||||
|
||||
@@ -3630,8 +3453,6 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
public event EventHandler<EventArgs> InitialSyncCompleted;
|
||||
|
||||
public event EventHandler FirstJsonResponseReceived;
|
||||
|
||||
public void StartSync()
|
||||
{
|
||||
DequeueQueries();
|
||||
@@ -3654,26 +3475,13 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
_syncQueries.Enqueue(query);
|
||||
}
|
||||
|
||||
public void LoginResponseReceived()
|
||||
public void LoginMessageReceived()
|
||||
{
|
||||
LoginResponseWasReceived = true;
|
||||
Debug.Console(1, this, "Login Rsponse Received.");
|
||||
LoginMessageWasReceived = true;
|
||||
Debug.Console(1, this, "Login Message Received.");
|
||||
CheckSyncStatus();
|
||||
}
|
||||
|
||||
public void ReceivedFirstJsonResponse()
|
||||
{
|
||||
FirstJsonResponseWasReceived = true;
|
||||
Debug.Console(1, this, "First JSON Response Received.");
|
||||
|
||||
var handler = FirstJsonResponseReceived;
|
||||
if (handler != null)
|
||||
{
|
||||
handler(this, null);
|
||||
}
|
||||
CheckSyncStatus();
|
||||
}
|
||||
|
||||
public void InitialQueryMessagesSent()
|
||||
{
|
||||
InitialQueryMessagesWereSent = true;
|
||||
@@ -3698,8 +3506,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
public void CodecDisconnected()
|
||||
{
|
||||
_syncQueries.Clear();
|
||||
LoginResponseWasReceived = false;
|
||||
FirstJsonResponseWasReceived = false;
|
||||
LoginMessageWasReceived = false;
|
||||
InitialQueryMessagesWereSent = false;
|
||||
LastQueryResponseWasReceived = false;
|
||||
CamerasHaveBeenSetUp = false;
|
||||
@@ -3708,7 +3515,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
|
||||
private void CheckSyncStatus()
|
||||
{
|
||||
if (LoginResponseWasReceived && FirstJsonResponseWasReceived && InitialQueryMessagesWereSent && LastQueryResponseWasReceived &&
|
||||
if (LoginMessageWasReceived && InitialQueryMessagesWereSent && LastQueryResponseWasReceived &&
|
||||
CamerasHaveBeenSetUp)
|
||||
{
|
||||
InitialSyncComplete = true;
|
||||
|
||||
@@ -7,8 +7,6 @@ using Crestron.SimplSharpPro.DeviceSupport;
|
||||
using PepperDash.Essentials.Core.Bridges;
|
||||
using PepperDash.Essentials.Devices.Common.Cameras;
|
||||
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
public enum eZoomRoomCameraState
|
||||
@@ -36,8 +34,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
protected ZoomRoom ParentCodec { get; private set; }
|
||||
|
||||
[JsonProperty("id", NullValueHandling = NullValueHandling.Ignore)]
|
||||
public int? Id = 0; // ID of near end selected camara is always 0
|
||||
public int Id = 0; // ID of near end selected camara is always 0
|
||||
|
||||
private int ContinueTime = 10; // number of milliseconds between issuing continue commands
|
||||
|
||||
|
||||
@@ -295,77 +295,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
Description = "Toggles the selfview pip size, (aka layout size)",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("StartRecording")]
|
||||
public JoinDataComplete StartRecording = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 241,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to start the Meeting Recording. FB high if meeting is currently recording",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("StopRecording")]
|
||||
public JoinDataComplete StopRecording = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 242,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to stop the Meeting Recording. FB high if meeting is currently NOT recording",
|
||||
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("RecordConsentPromptIsVisible")]
|
||||
public JoinDataComplete RecordConsentPromptIsVisible = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 243,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "When high, indicates that the recording consent prompt is visible on the ZoomRoom UI",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("RecordingPromptAgree")]
|
||||
public JoinDataComplete RecordingPromptAgree = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 244,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to agree to consent for meeting recording",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
|
||||
[JoinName("RecordingPromptDisagree")]
|
||||
public JoinDataComplete RecordingPromptDisagree = new JoinDataComplete(
|
||||
new JoinData
|
||||
{
|
||||
JoinNumber = 245,
|
||||
JoinSpan = 1
|
||||
},
|
||||
new JoinMetadata
|
||||
{
|
||||
Description = "Pulse to disagree to consent for meeting recording",
|
||||
JoinCapabilities = eJoinCapabilities.ToSIMPL,
|
||||
JoinType = eJoinType.Digital
|
||||
});
|
||||
});
|
||||
|
||||
//[JoinName("ParticipantAudioMuteToggleStart")]
|
||||
//public JoinDataComplete ParticipantAudioMuteToggleStart = new JoinDataComplete(
|
||||
|
||||
@@ -2,40 +2,30 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using Crestron.SimplSharp;
|
||||
using Newtonsoft.Json;
|
||||
using Crestron.SimplSharp;
|
||||
|
||||
using PepperDash.Core;
|
||||
using PepperDash.Essentials.Core;
|
||||
|
||||
namespace PepperDash.Essentials.Devices.Common.VideoCodec.ZoomRoom
|
||||
{
|
||||
public class ZoomRoomPropertiesConfig
|
||||
{
|
||||
[JsonProperty("communicationMonitorProperties")]
|
||||
public CommunicationMonitorConfig CommunicationMonitorProperties { get; set; }
|
||||
|
||||
[JsonProperty("disablePhonebookAutoDownload")]
|
||||
public bool DisablePhonebookAutoDownload { get; set; }
|
||||
|
||||
[JsonProperty("supportsCameraAutoMode")]
|
||||
public bool SupportsCameraAutoMode { get; set; }
|
||||
|
||||
[JsonProperty("supportsCameraOff")]
|
||||
{
|
||||
public CommunicationMonitorConfig CommunicationMonitorProperties { get; set; }
|
||||
|
||||
public bool DisablePhonebookAutoDownload { get; set; }
|
||||
public bool SupportsCameraAutoMode { get; set; }
|
||||
public bool SupportsCameraOff { get; set; }
|
||||
|
||||
//if true, the layouts will be set automatically when sharing starts/ends or a call is joined
|
||||
[JsonProperty("autoDefaultLayouts")]
|
||||
//if true, the layouts will be set automatically when sharing starts/ends or a call is joined
|
||||
public bool AutoDefaultLayouts { get; set; }
|
||||
|
||||
/* This layout will be selected when Sharing starts (either from Far end or locally)*/
|
||||
[JsonProperty("defaultSharingLayout")]
|
||||
/* This layout will be selected when Sharing starts (either from Far end or locally)*/
|
||||
public string DefaultSharingLayout { get; set; }
|
||||
|
||||
//This layout will be selected when a call is connected and no content is being shared
|
||||
[JsonProperty("defaultCallLayout")]
|
||||
public string DefaultCallLayout { get; set; }
|
||||
|
||||
[JsonProperty("minutesBeforeMeetingStart")]
|
||||
//This layout will be selected when a call is connected and no content is being shared
|
||||
public string DefaultCallLayout { get; set; }
|
||||
|
||||
public int MinutesBeforeMeetingStart { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,70 @@
|
||||
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>9.0.30729</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{E51D7C84-4906-486C-B2BA-EEB3B4E9731B}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>PepperDash.Essentials.Interfaces</RootNamespace>
|
||||
<AssemblyName>PepperDash_Essentials_Interfaces</AssemblyName>
|
||||
<ProjectTypeGuids>{0B4745B0-194B-4BB6-8E21-E9057CA92500};{4D628B5B-2FBC-4AA6-8C16-197242AEB884};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||
<PlatformFamilyName>WindowsCE</PlatformFamilyName>
|
||||
<PlatformID>E2BECB1F-8C8C-41ba-B736-9BE7D946A398</PlatformID>
|
||||
<OSVersion>5.0</OSVersion>
|
||||
<DeployDirSuffix>SmartDeviceProject1</DeployDirSuffix>
|
||||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
|
||||
<NativePlatformName>Windows CE</NativePlatformName>
|
||||
<FormFactorID>
|
||||
</FormFactorID>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<AllowedReferenceRelatedFileExtensions>.allowedReferenceRelatedFileExtensions</AllowedReferenceRelatedFileExtensions>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE;</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<NoStdLib>true</NoStdLib>
|
||||
<NoConfig>true</NoConfig>
|
||||
<GenerateSerializationAssemblies>off</GenerateSerializationAssemblies>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<AllowedReferenceRelatedFileExtensions>.allowedReferenceRelatedFileExtensions</AllowedReferenceRelatedFileExtensions>
|
||||
<DebugType>none</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<NoStdLib>true</NoStdLib>
|
||||
<NoConfig>true</NoConfig>
|
||||
<GenerateSerializationAssemblies>off</GenerateSerializationAssemblies>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="mscorlib" />
|
||||
<Reference Include="SimplSharpCustomAttributesInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpCustomAttributesInterface.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SimplSharpHelperInterface, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1099c178b3b54c3b, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\..\..\..\..\..\..\ProgramData\Crestron\SDK\SimplSharpHelperInterface.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Data" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<None Include="Properties\ControlSystem.cfg" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent>rem S# preparation will execute after these operations</PostBuildEvent>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,8 @@
|
||||
using System.Reflection;
|
||||
|
||||
[assembly: AssemblyTitle("PepperDash_Essentials_Interfaces")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("PepperDash_Essentials_Interfaces")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2020")]
|
||||
[assembly: AssemblyVersion("1.0.0.*")]
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
<packages>
|
||||
<package id="PepperDashCore" version="1.1.1" targetFramework="net35" allowedVersions="[1.0,2.0)"/>
|
||||
<package id="PepperDashCore" version="1.1.0" targetFramework="net35" allowedVersions="[1.0,2.0)"/>
|
||||
</packages>
|
||||
Reference in New Issue
Block a user