Skip to content

Commit bd60354

Browse files
Merge branch 'YAML-Updates-2-23-2024' of https://github.com/raul-marquez-csa/connectedhomeip into YAML-Updates-2-23-2024
2 parents ce8de21 + c2e4b56 commit bd60354

File tree

18 files changed

+588
-177
lines changed

18 files changed

+588
-177
lines changed

build/chip/chip_codegen.gni

+3-52
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ template("_chip_build_time_zapgen") {
152152
_output_subdir = "zap-generated"
153153
}
154154

155-
pw_python_action("${_name}_zap_pregen") {
155+
pw_python_action("${_name}_zap") {
156156
script = "${chip_root}/scripts/tools/zap/generate.py"
157157

158158
# TODO: this seems to touch internals. Is this ok? speeds up builds!
@@ -165,7 +165,7 @@ template("_chip_build_time_zapgen") {
165165
"--templates",
166166
_template_path,
167167
"--output-dir",
168-
rebase_path(target_gen_dir) + "/zap_pregen/" + _output_subdir,
168+
rebase_path(target_gen_dir) + "/zapgen/" + _output_subdir,
169169

170170
# TODO: lock file support should be removed as this serializes zap
171171
# (slower), however this is currently done because on Darwin zap startup
@@ -188,54 +188,10 @@ template("_chip_build_time_zapgen") {
188188

189189
sources = [ _idl_file ]
190190

191-
outputs = []
192-
foreach(name, invoker.outputs) {
193-
outputs += [ "${target_gen_dir}/zap_pregen/${name}" ]
194-
}
195-
196-
forward_variables_from(invoker, [ "prune_outputs" ])
197-
if (defined(prune_outputs)) {
198-
foreach(name, prune_outputs) {
199-
outputs += [ "${target_gen_dir}/zap_pregen/${name}" ]
200-
}
201-
}
202-
}
203-
204-
# This action ensures that any "extra" files generated by zap codegen
205-
# are actually deleted.
206-
#
207-
# This is to avoid double-codegen of configurations like endpoint config
208-
# or access credentials being generated for both "controller client" and
209-
# application-specific
210-
pw_python_action("${_name}_files") {
211-
# TODO: this seems to touch internals. Is this ok? speeds up builds!
212-
_pw_internal_run_in_venv = false
213-
214-
script = "${chip_root}/scripts/tools/zap/prune_outputs.py"
215-
216-
_keep_file = rebase_path("${target_gen_dir}/${_name}.keep.outputs")
217-
write_file(_keep_file, invoker.outputs, "list lines")
218-
219-
args = [
220-
"--keep",
221-
_keep_file,
222-
"--input-dir",
223-
rebase_path("${target_gen_dir}/zap_pregen/"),
224-
"--output-dir",
225-
rebase_path("${target_gen_dir}/zapgen/"),
226-
]
227-
228-
inputs = []
229-
foreach(name, invoker.outputs) {
230-
inputs += [ "${target_gen_dir}/zap_pregen/${name}" ]
231-
}
232-
233191
outputs = []
234192
foreach(name, invoker.outputs) {
235193
outputs += [ "${target_gen_dir}/zapgen/${name}" ]
236194
}
237-
238-
deps = [ ":${_name}_zap_pregen" ]
239195
}
240196

241197
source_set(_name) {
@@ -255,10 +211,7 @@ template("_chip_build_time_zapgen") {
255211
if (!defined(public_deps)) {
256212
public_deps = []
257213
}
258-
public_deps += [
259-
":${_name}_files",
260-
":${_name}_zap_pregen",
261-
]
214+
public_deps += [ ":${_name}_zap" ]
262215
}
263216
}
264217

@@ -420,7 +373,6 @@ template("chip_zapgen") {
420373
"input",
421374
"outputs",
422375
"public_configs",
423-
"prune_outputs",
424376
])
425377
}
426378
} else {
@@ -482,7 +434,6 @@ template("chip_zapgen") {
482434
[
483435
"deps",
484436
"public_configs",
485-
"prune_outputs",
486437
])
487438
if (!defined(public_configs)) {
488439
public_configs = []

examples/air-quality-sensor-app/linux/README.md

+18
Original file line numberDiff line numberDiff line change
@@ -165,3 +165,21 @@ value.
165165
```
166166
$ echo '{"Name":"NitrogenDioxideConcentrationMeasurement","NewValue":1}' > /tmp/chip_air_quality_fifo_<PID>
167167
```
168+
169+
Generate event `Pm1ConcentrationMeasurement`, to change the PM1 value.
170+
171+
```
172+
echo '{"Name":"Pm1ConcentrationMeasurement","NewValue":1}' > /tmp/chip_air_quality_fifo_<PID>
173+
```
174+
175+
Generate event `Pm25ConcentrationMeasurement`, to change the PM2.5 value.
176+
177+
```
178+
echo '{"Name":"Pm25ConcentrationMeasurement","NewValue":2.5}' > /tmp/chip_air_quality_fifo_<PID>
179+
```
180+
181+
Generate event `Pm10ConcentrationMeasurement`, to change the PM10 value.
182+
183+
```
184+
echo '{"Name":"Pm10ConcentrationMeasurement","NewValue":10}' > /tmp/chip_air_quality_fifo_<PID>
185+
```
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
37 : [NXP] Update Docker image for RW61X SDK
1+
38 : [NXP] Update Docker image for K32W1 SDK

integrations/docker/images/stage-2/chip-build-k32w/Dockerfile

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ RUN set -x \
2424

2525
RUN set -x \
2626
&& mkdir -p k32w1 \
27-
&& wget https://cache.nxp.com/lgfiles/bsps/SDK_2_12_6_K32W148-EVK.zip \
28-
&& unzip SDK_2_12_6_K32W148-EVK.zip -d k32w1 \
29-
&& rm -rf SDK_2_12_6_K32W148-EVK.zip
27+
&& wget https://cache.nxp.com/lgfiles/bsps/SDK_2_12_7_K32W148-EVK.zip \
28+
&& unzip SDK_2_12_7_K32W148-EVK.zip -d k32w1 \
29+
&& rm -rf SDK_2_12_7_K32W148-EVK.zip
3030

3131
FROM ghcr.io/project-chip/chip-build:${VERSION}
3232

scripts/py_matter_yamltests/matter_yamltests/hooks.py

+11
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515

16+
from typing import Optional
17+
1618
from .parser import TestStep
1719

1820

@@ -213,6 +215,15 @@ async def step_manual(self):
213215
"""
214216
pass
215217

218+
def show_prompt(self,
219+
msg: str,
220+
placeholder: Optional[str] = None,
221+
default_value: Optional[str] = None) -> None:
222+
"""
223+
This method is called when the step needs to ask the user to perform some action or provide some value.
224+
"""
225+
pass
226+
216227

217228
class WebSocketRunnerHooks():
218229
def connecting(self, url: str):

scripts/tools/zap/prune_outputs.py

-42
This file was deleted.

scripts/tools/zap/tests/outputs/all-clusters-app/app-templates/endpoint_config.h

+17-17
Original file line numberDiff line numberDiff line change
@@ -302,15 +302,15 @@
302302
{ (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x7 }, /* ControlMode */ \
303303
\
304304
/* Endpoint: 1, Cluster: Thermostat (server) */ \
305-
{ (uint16_t) 0xA28, (uint16_t) - 0x6AB3, (uint16_t) 0x7FFF }, /* OccupiedCoolingSetpoint */ \
306-
{ (uint16_t) 0x7D0, (uint16_t) - 0x6AB3, (uint16_t) 0x7FFF }, /* OccupiedHeatingSetpoint */ \
307-
{ (uint16_t) 0x2BC, (uint16_t) - 0x6AB3, (uint16_t) 0x7FFF }, /* MinHeatSetpointLimit */ \
308-
{ (uint16_t) 0xBB8, (uint16_t) - 0x6AB3, (uint16_t) 0x7FFF }, /* MaxHeatSetpointLimit */ \
309-
{ (uint16_t) 0x640, (uint16_t) - 0x6AB3, (uint16_t) 0x7FFF }, /* MinCoolSetpointLimit */ \
310-
{ (uint16_t) 0xC80, (uint16_t) - 0x6AB3, (uint16_t) 0x7FFF }, /* MaxCoolSetpointLimit */ \
311-
{ (uint16_t) 0x19, (uint16_t) 0x0, (uint16_t) 0x19 }, /* MinSetpointDeadBand */ \
312-
{ (uint16_t) 0x4, (uint16_t) 0x0, (uint16_t) 0x5 }, /* ControlSequenceOfOperation */ \
313-
{ (uint16_t) 0x1, (uint16_t) 0x0, (uint16_t) 0x9 }, /* SystemMode */ \
305+
{ (uint16_t) 0xA28, (uint16_t) -0x6AB3, (uint16_t) 0x7FFF }, /* OccupiedCoolingSetpoint */ \
306+
{ (uint16_t) 0x7D0, (uint16_t) -0x6AB3, (uint16_t) 0x7FFF }, /* OccupiedHeatingSetpoint */ \
307+
{ (uint16_t) 0x2BC, (uint16_t) -0x6AB3, (uint16_t) 0x7FFF }, /* MinHeatSetpointLimit */ \
308+
{ (uint16_t) 0xBB8, (uint16_t) -0x6AB3, (uint16_t) 0x7FFF }, /* MaxHeatSetpointLimit */ \
309+
{ (uint16_t) 0x640, (uint16_t) -0x6AB3, (uint16_t) 0x7FFF }, /* MinCoolSetpointLimit */ \
310+
{ (uint16_t) 0xC80, (uint16_t) -0x6AB3, (uint16_t) 0x7FFF }, /* MaxCoolSetpointLimit */ \
311+
{ (uint16_t) 0x19, (uint16_t) 0x0, (uint16_t) 0x19 }, /* MinSetpointDeadBand */ \
312+
{ (uint16_t) 0x4, (uint16_t) 0x0, (uint16_t) 0x5 }, /* ControlSequenceOfOperation */ \
313+
{ (uint16_t) 0x1, (uint16_t) 0x0, (uint16_t) 0x9 }, /* SystemMode */ \
314314
\
315315
/* Endpoint: 1, Cluster: Fan Control (server) */ \
316316
{ (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0x6 }, /* FanMode */ \
@@ -334,14 +334,14 @@
334334
{ (uint16_t) 0x0, (uint16_t) 0x0, (uint16_t) 0xFEFF }, /* StartUpColorTemperatureMireds */ \
335335
\
336336
/* Endpoint: 1, Cluster: Unit Testing (server) */ \
337-
{ (uint16_t) 0x46, (uint16_t) 0x14, (uint16_t) 0x64 }, /* range_restricted_int8u */ \
338-
{ (uint16_t) - 0x14, (uint16_t) - 0x28, (uint16_t) 0x32 }, /* range_restricted_int8s */ \
339-
{ (uint16_t) 0xC8, (uint16_t) 0x64, (uint16_t) 0x3E8 }, /* range_restricted_int16u */ \
340-
{ (uint16_t) - 0x64, (uint16_t) - 0x96, (uint16_t) 0xC8 }, /* range_restricted_int16s */ \
341-
{ (uint16_t) 0x46, (uint16_t) 0x14, (uint16_t) 0x64 }, /* nullable_range_restricted_int8u */ \
342-
{ (uint16_t) - 0x14, (uint16_t) - 0x28, (uint16_t) 0x32 }, /* nullable_range_restricted_int8s */ \
343-
{ (uint16_t) 0xC8, (uint16_t) 0x64, (uint16_t) 0x3E8 }, /* nullable_range_restricted_int16u */ \
344-
{ (uint16_t) - 0x64, (uint16_t) - 0x96, (uint16_t) 0xC8 }, /* nullable_range_restricted_int16s */ \
337+
{ (uint16_t) 0x46, (uint16_t) 0x14, (uint16_t) 0x64 }, /* range_restricted_int8u */ \
338+
{ (uint16_t) -0x14, (uint16_t) -0x28, (uint16_t) 0x32 }, /* range_restricted_int8s */ \
339+
{ (uint16_t) 0xC8, (uint16_t) 0x64, (uint16_t) 0x3E8 }, /* range_restricted_int16u */ \
340+
{ (uint16_t) -0x64, (uint16_t) -0x96, (uint16_t) 0xC8 }, /* range_restricted_int16s */ \
341+
{ (uint16_t) 0x46, (uint16_t) 0x14, (uint16_t) 0x64 }, /* nullable_range_restricted_int8u */ \
342+
{ (uint16_t) -0x14, (uint16_t) -0x28, (uint16_t) 0x32 }, /* nullable_range_restricted_int8s */ \
343+
{ (uint16_t) 0xC8, (uint16_t) 0x64, (uint16_t) 0x3E8 }, /* nullable_range_restricted_int16u */ \
344+
{ (uint16_t) -0x64, (uint16_t) -0x96, (uint16_t) 0xC8 }, /* nullable_range_restricted_int16s */ \
345345
\
346346
/* Endpoint: 2, Cluster: On/Off (server) */ \
347347
{ \

src/app/chip_data_model.gni

-12
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,8 @@ template("chip_data_model") {
5656
"zap-generated/endpoint_config.h",
5757
]
5858

59-
# NOTE: these are ALSO auto-generated but handled below:
60-
# "zap-generated/IMClusterCommandHandler.cpp"
61-
# -> contains one large DispatchSingleClusterCommand and DispatchServerCommand
62-
63-
if (chip_code_pre_generated_directory == "") {
64-
prune_outputs = []
65-
}
66-
6759
if (!chip_build_controller_dynamic_server) {
6860
outputs += [ "zap-generated/IMClusterCommandHandler.cpp" ]
69-
} else {
70-
if (defined(prune_outputs)) {
71-
prune_outputs += [ "zap-generated/IMClusterCommandHandler.cpp" ]
72-
}
7361
}
7462

7563
if (!defined(deps)) {

0 commit comments

Comments
 (0)