Skip to content

Conversation

@bhmanda-silabs
Copy link
Contributor

Summary

Related issues

Testing

Readability checklist

The checklist below will help the reviewer finish PR review in time and keep the
code readable:

  • PR title is
    descriptive
  • Apply the
    “When in Rome…”
    rule (coding style)
  • PR size is short
  • Try to avoid "squashing" and "force-update" in commit history
  • CI time didn't increase

See: Pull Request Guidelines

@silabs-matter-ci-bot silabs-matter-ci-bot bot added the sl-only This TAG indicates that this commit is a silabs-specific commit that cannot be upstreamed to CSA. label Oct 29, 2025
@@ -0,0 +1,29 @@
# Copyright (c) 2025 Project CHIP Authors
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file should be deleted.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

static void ActionInitiated(RangeHoodManager::Action_t aAction, int32_t aActor, uint8_t * value);
static void ActionCompleted(RangeHoodManager::Action_t aAction);

static void LightActionEventHandler(AppEvent * aEvent);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like this is not being used.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Button event handler added for Fancontrol so this is not required so removed, thanks for the comment @chirag-silabs

* @param aEvent button event being processed
*/
static void ButtonHandler(AppEvent * aEvent);
// Work item executed on CHIP stack thread to toggle fan mode safely
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add comments for the API

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comments and renamed it to FanControlButtonHandler as BTN1 is used for Fan control ON/OFF.

uint8_t percentCurrent;
uint8_t speedCurrent;

// Fan Mode Limits
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these being used anywhere?

: FanControl::Delegate(aEndpoint), mEndpoint(aEndpoint) {}

protected:
EndpointId mEndpoint = 0;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by default endpoint should be invalid endpoint

*/
Status HandleStep(StepDirectionEnum aDirection, bool aWrap, bool aLowestOff) override;

FanDelegate(EndpointId aEndpoint)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ideally constructor should be before other functions

CHIP_ERROR LightEndpoint::Init()
{
bool state = false;
OnOffServer::Instance().getOnOffValue(mEndpointId, &state);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should call with the ChipTask lock

bool LightEndpoint::GetOnOffState()
{
bool state = false;
OnOffServer::Instance().getOnOffValue(mEndpointId, &state);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should call with the ChipTask lock

void LightEndpoint::SetOnOffState(bool state)
{
CommandId commandId = state ? OnOff::Commands::On::Id : OnOff::Commands::Off::Id;
auto status = OnOffServer::Instance().setOnOffValue(mEndpointId, commandId, false);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should call with the ChipTask lock

@@ -0,0 +1,29 @@
# Copyright (c) 2025 Project CHIP Authors
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicate file to be removed

import("${chip_root}/src/platform/silabs/wifi/args.gni")

sl_enable_test_event_trigger = false
chip_enable_ota_requestor = false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be true


#define APP_TASK_NAME "RangeHood"

#define BLE_DEV_NAME "SiLabs-RangeHood"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can use Silabs-$APP_TASK_NAME

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done as per suggestion

#endif // SL_LCDCTRL_MUX
}

void RangeHoodUI::DrawFont(GLIB_Context_t * glibContext, uint8_t initial_x, uint8_t initial_y, uint8_t width, uint8_t * data,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can use the font avialable in GLIB directly, these are written for thermostat for a specific purpose.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be removed as did not use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

sl-only This TAG indicates that this commit is a silabs-specific commit that cannot be upstreamed to CSA.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants