Skip to content

Commit

Permalink
Temperature app measurement does not build anymore on the esp32 (#3907)
Browse files Browse the repository at this point in the history
  • Loading branch information
vivien-apple authored Nov 20, 2020
1 parent f408bf6 commit 0f45b74
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,14 @@
#include <stdlib.h>

#include "CHIPDeviceManager.h"
#include <app/util/basic-types.h>
#include <setup_payload/SetupPayload.h>
#include <support/CHIPMem.h>
#include <support/CodeUtils.h>
#include <support/ErrorStr.h>

using namespace ::chip;

namespace chip {

namespace DeviceManager {
Expand Down Expand Up @@ -92,16 +95,16 @@ CHIP_ERROR CHIPDeviceManager::Init(CHIPDeviceManagerCallbacks * cb)
exit:
return err;
}
} // namespace DeviceManager
} // namespace chip

void emberAfPostAttributeChangeCallback(EndpointId endpoint, ClusterId clusterId, AttributeId attributeId, uint8_t mask,
void emberAfPostAttributeChangeCallback(EndpointId endpointId, ClusterId clusterId, AttributeId attributeId, uint8_t mask,
uint16_t manufacturerCode, uint8_t type, uint8_t size, uint8_t * value)
{
CHIPDeviceManagerCallbacks * cb = CHIPDeviceManager::GetInstance().GetCHIPDeviceManagerCallbacks();
chip::DeviceManager::CHIPDeviceManagerCallbacks * cb =
chip::DeviceManager::CHIPDeviceManager::GetInstance().GetCHIPDeviceManagerCallbacks();
if (cb != nullptr)
{
cb->PostAttributeChangeCallback(endpoint, clusterId, attributeId, mask, manufacturerCode, type, size, value);
cb->PostAttributeChangeCallback(endpointId, clusterId, attributeId, mask, manufacturerCode, type, size, value);
}
}

} // namespace DeviceManager
} // namespace chip
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@

static const char * TAG = "echo-devicecallbacks";

using namespace ::chip;
using namespace ::chip::Inet;
using namespace ::chip::System;
using namespace ::chip::DeviceLayer;
Expand Down
2 changes: 2 additions & 0 deletions examples/temperature-measurement-app/esp32/main/component.mk
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,13 @@ COMPONENT_SRCDIRS :=
gen \
../third_party/connectedhomeip/examples/common/chip-app-server \
../third_party/connectedhomeip/src/app/util \
../third_party/connectedhomeip/src/app/reporting \
../third_party/connectedhomeip/src/app/clusters/basic \
../third_party/connectedhomeip/src/app/clusters/temperature-measurement-server \


COMPONENT_EXTRA_INCLUDES := $(PROJECT_PATH)/third_party/connectedhomeip/src/app/util \
$(PROJECT_PATH)/third_party/connectedhomeip/src/app/reporting \
$(PROJECT_PATH)/third_party/connectedhomeip/examples/common/chip-app-server/include \
$(PROJECT_PATH)/third_party/connectedhomeip/src

Expand Down
14 changes: 0 additions & 14 deletions examples/temperature-measurement-app/esp32/main/gen/callback.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@

//#include "hal/hal.h"

#ifdef __cplusplus
extern "C" {
#endif // #ifdef __cplusplus

/** @name Non-Cluster Related Callbacks */
// @{
/** @brief Add To Current App Tasks
Expand Down Expand Up @@ -109,13 +105,6 @@ bool emberAfAttributeReadAccessCallback(chip::EndpointId endpoint, chip::Cluster
*/
bool emberAfAttributeWriteAccessCallback(chip::EndpointId endpoint, chip::ClusterId clusterId, uint16_t manufacturerCode,
chip::AttributeId attributeId);
/** @brief Clear Report Table
*
* This function is called by the framework when the application should clear
* the report table.
*
*/
EmberStatus emberAfClearReportTableCallback(void);
/** @brief Cluster Init
*
* This function is called when a specific cluster is initialized. It gives the
Expand Down Expand Up @@ -23446,8 +23435,5 @@ void halSleepCallback(bool enter, SleepModes sleepMode);
/** @} END HAL Library Plugin Callbacks */

/** @} END addtogroup */
#ifdef __cplusplus
}
#endif // #ifdef __cplusplus

#endif // SILABS_EMBER_AF_CALLBACK_PROTOTYPES
2 changes: 1 addition & 1 deletion examples/temperature-measurement-app/esp32/main/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ using namespace ::chip::DeviceLayer;
// Used to indicate that an IP address has been added to the QRCode
#define EXAMPLE_VENDOR_TAG_IP 1

extern void PairingComplete(SecurePairingSession * pairing);
extern void PairingComplete(NodeId assignedNodeId, NodeId peerNodeId, SecurePairingSession * pairing);

const char * TAG = "temperature-measurement-app";

Expand Down

0 comments on commit 0f45b74

Please sign in to comment.