Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QPG] QPG SDK feature updates. #30094

Merged
merged 1 commit into from
Oct 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions examples/lighting-app/qpg/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ chip_stack_lock_tracking = "none"

matter_device_vid = "0xFFF1"
matter_device_pid = "0x8005"
matter_device_software_version = "0x0001"
matter_device_software_version_string = "1.0"

pw_log_BACKEND = "${chip_root}/src/lib/support/pw_log_chip"
pw_assert_BACKEND = "$dir_pw_assert_log:check_backend"
20 changes: 13 additions & 7 deletions examples/lighting-app/qpg/src/AppTask.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,15 +257,23 @@ void AppTask::InitServer(intptr_t arg)
// Open commissioning after boot if no fabric was available
if (chip::Server::GetInstance().GetFabricTable().FabricCount() == 0)
{
PlatformMgr().ScheduleWork(OpenCommissioning, 0);
ChipLogProgress(NotSpecified, "No fabrics, starting commissioning.");
AppTask::OpenCommissioning((intptr_t) 0);
}
}

void AppTask::OpenCommissioning(intptr_t arg)
{
// Enable BLE advertisements
chip::Server::GetInstance().GetCommissioningWindowManager().OpenBasicCommissioningWindow();
ChipLogProgress(NotSpecified, "BLE advertising started. Waiting for Pairing.");

SystemLayer().ScheduleLambda([] {
CHIP_ERROR err;
err = chip::Server::GetInstance().GetCommissioningWindowManager().OpenBasicCommissioningWindow();
if (err == CHIP_NO_ERROR)
{
ChipLogProgress(NotSpecified, "BLE advertising started. Waiting for Pairing.");
}
});
}

CHIP_ERROR AppTask::Init()
Expand Down Expand Up @@ -486,10 +494,8 @@ void AppTask::FunctionHandler(AppEvent * aEvent)
else
{
// Enable BLE advertisements and pairing window
if (chip::Server::GetInstance().GetCommissioningWindowManager().OpenBasicCommissioningWindow() == CHIP_NO_ERROR)
{
ChipLogProgress(NotSpecified, "BLE advertising started. Waiting for Pairing.");
}
AppTask::OpenCommissioning((intptr_t) 0);
ChipLogProgress(NotSpecified, "BLE advertising started. Waiting for Pairing.");
}
}
else if (sAppTask.mFunctionTimerActive && sAppTask.mFunction == kFunction_SoftwareUpdate)
Expand Down
26 changes: 0 additions & 26 deletions examples/lighting-app/qpg/zap/light.matter
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,6 @@ server cluster LevelControl = 8 {
readonly attribute int16u remainingTime = 1;
readonly attribute int8u minLevel = 2;
readonly attribute int8u maxLevel = 3;
readonly attribute int16u currentFrequency = 4;
readonly attribute int16u minFrequency = 5;
readonly attribute int16u maxFrequency = 6;
attribute LevelControlOptions options = 15;
attribute nullable int8u onLevel = 17;
attribute access(write: manage) nullable int8u startUpCurrentLevel = 16384;
Expand Down Expand Up @@ -957,7 +954,6 @@ server cluster GeneralDiagnostics = 51 {
readonly attribute NetworkInterface networkInterfaces[] = 0;
readonly attribute int16u rebootCount = 1;
readonly attribute int64u upTime = 2;
readonly attribute int32u totalOperationalHours = 3;
readonly attribute BootReasonEnum bootReason = 4;
readonly attribute HardwareFaultEnum activeHardwareFaults[] = 5;
readonly attribute RadioFaultEnum activeRadioFaults[] = 6;
Expand Down Expand Up @@ -1867,7 +1863,6 @@ endpoint 0 {
callback attribute networkInterfaces;
callback attribute rebootCount default = 0x0000;
callback attribute upTime default = 0x0000000000000000;
callback attribute totalOperationalHours default = 0x00000000;
callback attribute bootReason;
callback attribute activeHardwareFaults;
callback attribute activeRadioFaults;
Expand Down Expand Up @@ -2107,9 +2102,6 @@ endpoint 1 {
ram attribute remainingTime default = 0x0000;
ram attribute minLevel default = 0x01;
ram attribute maxLevel default = 0xFE;
ram attribute currentFrequency default = 0x0000;
ram attribute minFrequency default = 0x0000;
ram attribute maxFrequency default = 0x0000;
ram attribute options default = 0x00;
ram attribute onLevel default = 0xFF;
persist attribute startUpCurrentLevel default = 255;
Expand Down Expand Up @@ -2141,24 +2133,6 @@ endpoint 1 {
callback attribute clusterRevision default = 1;
}

server cluster FixedLabel {
callback attribute labelList;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute attributeList;
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 1;
}

server cluster UserLabel {
callback attribute labelList;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute attributeList;
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 1;
}

server cluster ColorControl {
ram attribute currentHue default = 0x00;
ram attribute currentSaturation default = 0x00;
Expand Down
Loading
Loading