• Home
Name Date Size #Lines LOC

..--

bindings/04-Jul-2025-2621

docgen/04-Jul-2025-182131

OWNERSD04-Jul-202531 21

README.mdD04-Jul-202545.9 KiB1,7291,127

brand_config.starD04-Jul-20252.5 KiB7264

build_metadata.starD04-Jul-20253.5 KiB10286

component.starD04-Jul-202511.4 KiB380347

config_bundle.starD04-Jul-20251,015 3732

design.starD04-Jul-202520.2 KiB519470

device_brand.starD04-Jul-2025933 3832

dut.starD04-Jul-20251 KiB4034

flat_config.starD04-Jul-20252.9 KiB9278

generate.starD04-Jul-2025985 3323

hw_features.starD04-Jul-202510.5 KiB357318

hw_topology.starD04-Jul-202587 KiB2,3651,990

partner.starD04-Jul-20257.3 KiB221212

portage.starD04-Jul-2025682 2923

program.starD04-Jul-202511.6 KiB328300

public_replication.starD04-Jul-2025930 3023

sw_config.starD04-Jul-202568.2 KiB1,8011,655

system_image.starD04-Jul-20251.7 KiB5748

test_plan.starD04-Jul-20254.9 KiB187159

test_plan_v2.starD04-Jul-20254.1 KiB140118

README.md

1# Config API Reference
2
3[TOC]
4
5
6## Updating this Reference
7
8This reference is automatically generated based on Starlark docstrings. If you
9change a Starlark util function, run `util/docgen/generate.sh` to regenerate. A
10few tips:
11
12- Templating is based on Go's [`text/template`](https://golang.org/pkg/text/template/)
13package. Usually, the contents this template file won't need to be changed in
14order to regenerate.
15
16- Generation is based on docstrings, not the actual Starlark signatures. Thus,
17an "Args" section needs to be specified in the docstring in order for args to
18be picked up. Similarly, a "Returns" section needs to be specified in the
19docstring for returns to get picked up.
20
21- Specify "Required." after an argument to make it a required argument in the
22generated documentation.
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38## //config/util/brand_config.star
39
40### brand_config.create {#brand_config.create}
41Builds a BrandConfig proto.
42
43```python
44brand_config.create(
45    # Required arguments.
46    device_brand_id,
47
48    # Optional arguments.
49    wallpaper = None,
50    regulatory_label = None,
51    whitelabel_tag = None,
52    help_content_id = None,
53)
54```
55
56#### Arguments {#brand_config.create-args}
57
58* **device_brand_id**: A DeviceBrandId proto that is used to select a BrandConfig at runtime. Required.
59* **wallpaper**: Base filename of the default wallpaper to show.
60* **regulatory_label**: See chromeos-config readme
61* **whitelabel_tag**: "whitelabel_tag" value set in the VPD, used to select a BrandConfig at runtime. See https://chromeos.google.com/partner/dlm/docs/factory/vpd.html#field-whitelabel_tag.
62* **help_content_id**: help content identifier
63
64#### Returns  {#brand_config.create-returns}
65A BrandConfig proto.
66
67
68
69
70## //config/util/component.star
71
72### comp.create_soc_family {#comp.create_soc_family}
73Builds a Component.Soc.Family proto.
74
75```python
76comp.create_soc_family()
77```
78
79
80
81### comp.create_soc_model {#comp.create_soc_model}
82Builds a Component proto for an Soc.
83
84```python
85comp.create_soc_model()
86```
87
88
89
90### comp.create_bt {#comp.create_bt}
91Builds a Component proto for Bluetooth.
92
93```python
94comp.create_bt()
95```
96
97
98
99### comp.create_cellular {#comp.create_cellular}
100Builds a Component proto for Cellular device.
101
102```python
103comp.create_cellular()
104```
105
106
107
108### comp.create_display_panel {#comp.create_display_panel}
109Builds a Component.DisplayPanel proto for touchscreen.
110
111```python
112comp.create_display_panel()
113```
114
115
116
117### comp.create_touchscreen {#comp.create_touchscreen}
118Builds a Component.Touch proto for touchscreen.
119
120```python
121comp.create_touchscreen()
122```
123
124
125
126### comp.create_touchpad {#comp.create_touchpad}
127Builds a Component.Touch proto for touchpad.
128
129```python
130comp.create_touchpad()
131```
132
133
134
135### comp.create_wifi {#comp.create_wifi}
136Builds a Component proto for Wifi.
137
138```python
139comp.create_wifi()
140```
141
142
143
144### comp.create_qual {#comp.create_qual}
145Builds a Component.Qualification proto.
146
147```python
148comp.create_qual()
149```
150
151
152
153### comp.create_quals {#comp.create_quals}
154Builds a Component.Qualification proto for each of component_ids.
155
156```python
157comp.create_quals()
158```
159
160
161
162### comp.create_amplifier {#comp.create_amplifier}
163Builds a Component.Amplifier proto.
164
165```python
166comp.create_amplifier()
167```
168
169
170
171### comp.create_audio_codec {#comp.create_audio_codec}
172Builds a Component.AudioCodec proto.
173
174```python
175comp.create_audio_codec()
176```
177
178
179
180### comp.create_battery {#comp.create_battery}
181
182
183```python
184comp.create_battery()
185```
186
187
188
189### comp.create_ec_flash_chip {#comp.create_ec_flash_chip}
190Build a Component.FlashChip proto.
191
192```python
193comp.create_ec_flash_chip()
194```
195
196
197
198### comp.create_flash_chip {#comp.create_flash_chip}
199Build a Component.FlashChip proto.
200
201```python
202comp.create_flash_chip()
203```
204
205
206
207### comp.create_embedded_controller {#comp.create_embedded_controller}
208Build a Component.EmbeddedController proto.
209
210```python
211comp.create_embedded_controller()
212```
213
214
215
216### comp.create_storage_mmc {#comp.create_storage_mmc}
217Build a Component.Storage proto for an MMC device.
218
219```python
220comp.create_storage_mmc()
221```
222
223
224
225### comp.create_tpm {#comp.create_tpm}
226Build a Component.Tpm proto.
227
228```python
229comp.create_tpm()
230```
231
232
233
234### comp.create_usb {#comp.create_usb}
235Builds a Interface.Usb proto.
236
237```python
238comp.create_usb()
239```
240
241
242
243### comp.create_pci {#comp.create_pci}
244Builds a Interface.Pci proto.
245
246```python
247comp.create_pci()
248```
249
250
251
252### comp.append_battery {#comp.append_battery}
253
254
255```python
256comp.append_battery()
257```
258
259
260
261### comp.append_display_panel {#comp.append_display_panel}
262
263
264```python
265comp.append_display_panel()
266```
267
268
269
270### comp.append_touchpad {#comp.append_touchpad}
271
272
273```python
274comp.append_touchpad()
275```
276
277
278
279### comp.append_touchscreen {#comp.append_touchscreen}
280
281
282```python
283comp.append_touchscreen()
284```
285
286
287
288
289
290## //config/util/config_bundle.star
291
292### config_bundle.create {#config_bundle.create}
293Builds a ConfigBundle proto.
294
295```python
296config_bundle.create()
297```
298
299
300
301### config_bundle.generate {#config_bundle.generate}
302Serializes a ConfigBundle to a file.
303
304A json proto is written. Note that there is some post processing done
305by the gen_config script to convert this json output into a json
306output that uses ints for encoding enums.
307
308```python
309config_bundle.generate()
310```
311
312
313
314
315
316## //config/util/design.star
317
318### design.append_configs {#design.append_configs}
319Creates and appends new SW and HW configs.
320
321Create new Software and Hardware Design Configuration with the
322specified properties and then append them to the sw_configs and hw_configs
323arrays respectively. This ensures that all IDs are consistent.
324
325```python
326design.append_configs(
327    # Required arguments.
328    sw_configs,
329    hw_configs,
330    design_id,
331    config_id,
332
333    # Optional arguments.
334    extra_hw_config_public_fields = None,
335    extra_sw_config_public_fields = None,
336    hardware_topology = None,
337    firmware = None,
338    firmware_build_config = None,
339    firmware_info = None,
340    bluetooth = None,
341    power = None,
342    audio = None,
343    wifi = None,
344    camera = None,
345    health = None,
346    ui = None,
347    device_tree_compatible_match = None,
348    smbios_name_match_override = None,
349    frid = None,
350)
351```
352
353#### Arguments {#design.append_configs-args}
354
355* **sw_configs**: An array to append the new SoftwareConfig to. Required.
356* **hw_configs**: An array to append the new Design.Config to. Required.
357* **design_id**: A DesignId to use for the Design.Config and SoftwareConfig. Required.
358* **config_id**: A str or int used to construct the DesignConfigId for the Design.Config and SoftwareConfig. Required.
359* **extra_hw_config_public_fields**: A list of str specifying fields on Design.Config that will be made public in addition to the default _DEFAULT_PUBLIC_HW_CONFIG_FIELDS. See PublicReplication proto for details.
360* **extra_sw_config_public_fields**: A list of str specifying fields on SoftwareConfig that will be made public in addition to the default _DEFAULT_PUBLIC_SW_CONFIG_FIELDS. See PublicReplication proto for details.
361* **hardware_topology**: A HardwareTopology to be used in the Design.Config.
362* **firmware**: A FirmwareConfig to be used in the SoftwareConfig.
363* **firmware_build_config**: A FirmwareBuildConfig to be used in the SoftwareConfig.
364* **firmware_info**: Information related to runtime firmware.
365* **bluetooth**: A BluetoothConfig to be used in the SoftwareConfig.
366* **power**: A PowerConfig to be used in the SoftwareConfig.
367* **audio**: An AudioConfig to be used in the SoftwareConfig. Can be either a single AudioConfig or a list of AudioConfigs.
368* **wifi**: A WifiConfig to be used in the SoftwareConfig.
369* **camera**: A CameraConfig to be used in the SoftwareConfig.
370* **health**: A HealthConfig to be used in the SoftwareConfig.
371* **ui**: A UiConfig to be used in the SoftwareConfig.
372* **device_tree_compatible_match**: For ARM platform, a str used for device_tree_compatible_match in IdentityScanConfig.
373* **smbios_name_match_override**: For x86 platform, a str used for smbios_name_match in IdentityScanConfig. If not specified, the string in DesignId is used. Note only one of device_tree_compatible_match and smbios_name_match_override can be specified.
374* **frid**: A str used for frid matching.  Note: This will override device_tree_compatible_match and smbios_name_match_override.
375
376
377### design.create_constraint {#design.create_constraint}
378Builds a Design.Config.Constraint proto.
379
380```python
381design.create_constraint()
382```
383
384
385
386### design.create_constraints {#design.create_constraints}
387Builds a Design.Config.Constrain proto for each of hw_features.
388
389```python
390design.create_constraints()
391```
392
393
394
395### design.create_design_id {#design.create_design_id}
396Builds a DesignId proto.
397
398```python
399design.create_design_id()
400```
401
402
403
404### design.create_design {#design.create_design}
405Builds a Design proto.
406
407```python
408design.create_design()
409```
410
411
412
413### design.generate {#design.generate}
414Serializes a ConfigBundle to a file.
415
416A json proto is written. Note that there is some post processing done
417by the gen_config script to convert this json output into a json
418output that uses ints for encoding enums.
419
420```python
421design.generate()
422```
423
424
425
426
427
428## //config/util/device_brand.star
429
430### device_brand.create {#device_brand.create}
431Builds a DeviceBrand proto.
432
433```python
434device_brand.create()
435```
436
437
438
439
440
441## //config/util/hw_topology.star
442
443### hw_topo.create_design_features {#hw_topo.create_design_features}
444Builds a HardwareFeatures proto with form_factor.
445
446```python
447hw_topo.create_design_features()
448```
449
450
451
452### hw_topo.create_features {#hw_topo.create_features}
453Builds a HardwareFeatures proto for each of form_factors.
454
455```python
456hw_topo.create_features()
457```
458
459
460
461### hw_topo.create_screen {#hw_topo.create_screen}
462Builds a Topology proto for a screen.
463
464```python
465hw_topo.create_screen()
466```
467
468
469
470### hw_topo.create_als_step {#hw_topo.create_als_step}
471Builds a Component.AlsStep.
472lux_decrease_threshold: An int containing the sensor value below which the
473    previous step should be considered. A value of None indicates negative
474    infinity.
475lux_increase_threshold: An int containing the sensor value above which the
476    next step should be considered. A value of None indicates infinity.
477ac_backlight_percent: A double containing the backlight brightness
478    percentage to use at this step while on AC power.
479battery_backlight_percent: A double containing the backlight brightness
480    percentage to use at this step while on battery power. If unset,
481    defaults to the ac_backlight_percent value.
482
483```python
484hw_topo.create_als_step()
485```
486
487
488
489### hw_topo.create_form_factor {#hw_topo.create_form_factor}
490Builds a Topology proto for a form factor.
491
492```python
493hw_topo.create_form_factor(
494    # Required arguments.
495    form_factor,
496
497    # Optional arguments.
498    fw_configs = None,
499    id = None,
500    description = None,
501)
502```
503
504#### Arguments {#hw_topo.create_form_factor-args}
505
506* **form_factor**: A FormFactorType enum. Required.
507* **fw_configs**: A list of FirmwareConfiguration protos for the form factor.
508* **id**: A string identifier for the Topology. If not passed, a default is provided based on form_factor.
509* **description**: An English description for the Topology. If not passed, a default is provided based on form_factor.
510
511
512### hw_topo.create_audio {#hw_topo.create_audio}
513Builds a Topology proto for audio.
514
515```python
516hw_topo.create_audio(
517    # Optional arguments.
518    id = None,
519    description = None,
520    codec = None,
521    speaker_amp = None,
522    headphone_codec = None,
523    fw_configs = None,
524    card_configs = None,
525    cras_config = None,
526)
527```
528
529#### Arguments {#hw_topo.create_audio-args}
530
531* **id**: A string identifier for the Topology.
532* **description**: An English description for the Topology.
533* **codec**: Deprecated.
534* **speaker_amp**: An Amplifier enum value specifying the speaker amplifier.
535* **headphone_codec**: An AudioCodec enum value specifying the jack codec.
536* **fw_configs**: A list of FirmwareConfiguration protos for this audio topology.
537* **card_configs**: A list of CardConfig protos specifying card configs to be installed and used for this audio topology.
538* **cras_config**: An AudioConfigStructure enum specifying how card-agnostic cras config files are structured. If unset, defaults to DESIGN if any card_configs are passed, otherwise NONE.
539
540
541### hw_topo.create_audio_card_config {#hw_topo.create_audio_card_config}
542Builds a CardConfig proto for an audio card config.
543
544```python
545hw_topo.create_audio_card_config(
546    # Optional arguments.
547    card_name = None,
548    ucm_suffix = None,
549    cras_config = None,
550    ucm_config = None,
551    sound_card_init_config = None,
552)
553```
554
555#### Arguments {#hw_topo.create_audio_card_config-args}
556
557* **card_name**: A string. This should match the card used by ALSA, with an optional suffix starting with a dot, if a suffix representing hardware details, such as the speaker amplifier or jack codec is required. For example, "sof-rt5682.max98373".
558* **ucm_suffix**: An optional format string used to generate the remainder of the UCM suffix not referring to audio components. If unset, the program-wide default suffix is used. The following placeholders may be used:     {design}: The design name.     {camera_count}: The number of cameras (usually 0, 1 or 2).     {headset_codec}: The headset codec name (in lowercase)         specified in the topology containing this card config.     {speaker_amp}: The speaker amp name (in lowercase) specified in         the topology containing this card config.     {mic_description}: A description of the microphone topology, of         the form {user_facing_mic_count}uf{world_facing_mic_count}wf, with         components elided if their count is 0.     {total_mic_count}: The total number of internal microphones.     {user_facing_mic_count}: The number of internal user-facing microphones.     {world_facing_mic_count}: The number of internal world-facing microphones. It is strongly recommended that any details of the speaker amplifier or jack codec not be included in this suffix - they should instead be included as part of card_name.
559* **cras_config**: An AudioConfigStructure enum specifying how cras config files are structured for this card. If unset, defaults to DESIGN.
560* **ucm_config**: An AudioConfigStructure enum specifying how ALSA UCM config files are structured for this card. If unset, defaults to DESIGN.
561* **sound_card_init_config**: An AudioConfigStructure enum specifying how sound card init config files are structured for this card. If unset, defaults to NONE.
562
563
564### hw_topo.override_audio {#hw_topo.override_audio}
565
566
567```python
568hw_topo.override_audio()
569```
570
571
572
573### hw_topo.create_stylus {#hw_topo.create_stylus}
574Builds a Topology proto for a stylus.
575
576```python
577hw_topo.create_stylus()
578```
579
580
581
582### hw_topo.create_keyboard {#hw_topo.create_keyboard}
583Builds a Topology proto for a keyboard.
584
585```python
586hw_topo.create_keyboard(
587    # Required arguments.
588    backlight,
589    pwr_btn_present,
590    kb_type,
591
592    # Optional arguments.
593    numpad_present = None,
594    fw_configs = None,
595    id = None,
596    description = None,
597    backlight_user_steps = None,
598)
599```
600
601#### Arguments {#hw_topo.create_keyboard-args}
602
603* **backlight**: True if a backlight is present. Required.
604* **pwr_btn_present**: True if a power button is present. Required.
605* **kb_type**: A KeyboardType enum. Required.
606* **numpad_present**: True if numeric pad is present.
607* **fw_configs**: A list of FirmwareConfiguration protos for the form factor.
608* **id**: A string identifier for the Topology. If not passed, a default is provided.
609* **description**: An English description for the Topology. If not passed, a default is provided.
610* **backlight_user_steps**: A list of doubles specifying the user-selectable backlight steps in increasing order, starting from 0. This controls the keyboard_backlight_user_steps powerd pref.
611* **mcu_type**: A KeyboardMcuType enum. Optional.
612
613
614### hw_topo.create_thermal {#hw_topo.create_thermal}
615Builds a Topology proto for thermal.
616
617```python
618hw_topo.create_thermal()
619```
620
621
622
623### hw_topo.create_camera {#hw_topo.create_camera}
624Builds a Topology proto for cameras.
625
626```python
627hw_topo.create_camera(
628    # Optional arguments.
629    id = None,
630    description = None,
631    fw_configs = None,
632    camera_devices = None,
633)
634```
635
636#### Arguments {#hw_topo.create_camera-args}
637
638* **id**: A string identifier for the Topology.
639* **description**: An English description for the Topology.
640* **fw_configs**: A list of FirmwareConfiguration protos for the form factor.
641* **camera_devices**: A list of HardwareFeatures.Camera.Device protos.
642
643
644### hw_topo.create_sensor {#hw_topo.create_sensor}
645Builds a Topology proto for accelerometer/gyroscrope/magnometer sensors.
646
647```python
648hw_topo.create_sensor()
649```
650
651
652
653### hw_topo.create_fingerprint {#hw_topo.create_fingerprint}
654Builds a Topology proto for a fingerprint reader.
655
656```python
657hw_topo.create_fingerprint()
658```
659
660
661
662### hw_topo.create_proximity_sensor {#hw_topo.create_proximity_sensor}
663Builds a Topology proto for proximity sensors.
664
665```python
666hw_topo.create_proximity_sensor()
667```
668
669
670
671### hw_topo.create_daughter_board {#hw_topo.create_daughter_board}
672Builds a Topology proto for a daughter board.
673
674```python
675hw_topo.create_daughter_board()
676```
677
678
679
680### hw_topo.create_non_volatile_storage {#hw_topo.create_non_volatile_storage}
681Builds a Topology proto for non-volatile storage.
682
683```python
684hw_topo.create_non_volatile_storage()
685```
686
687
688
689### hw_topo.create_wifi {#hw_topo.create_wifi}
690Builds a Topology proto for a WiFi chip.
691
692```python
693hw_topo.create_wifi()
694```
695
696
697
698### hw_topo.create_cellular_board {#hw_topo.create_cellular_board}
699Builds a Topology proto for a Cellular board.
700
701```python
702hw_topo.create_cellular_board()
703```
704
705
706
707### hw_topo.create_sd_reader {#hw_topo.create_sd_reader}
708Builds a Topology proto for a SD reader.
709
710```python
711hw_topo.create_sd_reader()
712```
713
714
715
716### hw_topo.create_motherboard_usb {#hw_topo.create_motherboard_usb}
717Builds a Topology proto for a motherboard.
718
719```python
720hw_topo.create_motherboard_usb()
721```
722
723
724
725### hw_topo.create_usbc_port {#hw_topo.create_usbc_port}
726Builds a UsbC Port.
727
728```python
729hw_topo.create_usbc_port(position = None, index_override = None)
730```
731
732#### Arguments {#hw_topo.create_usbc_port-args}
733
734* **position**: An optional topo_pb.HardwareFeatures.PortPosition indicating the position of this port on the side of the chassis it occupies. Required if more than one USB-C port is present on the same side of the chassis.
735* **index_override**: An optional int specifying the 0-indexed index of this port. For ports with this unset, the motherboard ports will be ordered before the daughter board ports, in the order they are specified, leaving gaps as needed for ports with an override set. If set, this value must be in the range [0, number_of_usb_c_ports).
736
737
738### hw_topo.create_bluetooth {#hw_topo.create_bluetooth}
739Builds a Topology proto for bluetooth.
740
741```python
742hw_topo.create_bluetooth()
743```
744
745
746
747### hw_topo.create_barreljack {#hw_topo.create_barreljack}
748Builds a Topology proto for barreljack.
749
750```python
751hw_topo.create_barreljack()
752```
753
754
755
756### hw_topo.create_power_supply {#hw_topo.create_power_supply}
757Builds a Topology proto for power supply.
758
759```python
760hw_topo.create_power_supply(
761    # Optional arguments.
762    id = None,
763    description = None,
764    bj_present = None,
765    usb_min_ac_watts = None,
766    fw_configs = None,
767)
768```
769
770#### Arguments {#hw_topo.create_power_supply-args}
771
772* **id**: A string identifier for the Topology.
773* **description**: An English description for the Topology.
774* **bj_present**: A bool containing whether a barreljack power port is present
775* **usb_min_ac_watts**: The input power below which a warning should be shown to use a higher-power USB adapter.
776* **fw_configs**: A list of firmware configs implied by the Topology.
777
778
779### hw_topo.create_hardware_topology {#hw_topo.create_hardware_topology}
780Builds a HardwareTopology proto from Topology protos.
781
782```python
783hw_topo.create_hardware_topology()
784```
785
786
787
788### hw_topo.create_power_button {#hw_topo.create_power_button}
789Builds a Topology proto for a power button.
790
791```python
792hw_topo.create_power_button(
793    # Required arguments.
794    region,
795    edge,
796    position,
797
798    # Optional arguments.
799    id = None,
800    description = None,
801)
802```
803
804#### Arguments {#hw_topo.create_power_button-args}
805
806* **region**: A HardwareFeatures.Button.Region enum. Required.
807* **edge**: A HardwareFeatures.Button.Edge enum. Required.
808* **position**: The percentage for button center position to the display's width/height in primary landscape screen orientation. If edge is LEFT or RIGHT, specifies the button's center position as a fraction of region's height relative to the top of region. For TOP and BOTTOM, specifies the position as a fraction of region width relative to the left side of region. Must be in the range [0.0, 1.0]. Required.
809* **id**: A string identifier for the Topology. If not passed, a default is provided.
810* **description**: An English description for the Topology. If not passed, a default is provided.
811
812
813### hw_topo.create_volume_button {#hw_topo.create_volume_button}
814Builds a Topology proto for a volume button.
815
816```python
817hw_topo.create_volume_button(
818    # Required arguments.
819    region,
820    edge,
821    position,
822
823    # Optional arguments.
824    id = None,
825    description = None,
826)
827```
828
829#### Arguments {#hw_topo.create_volume_button-args}
830
831* **region**: A HardwareFeatures.Button.Region enum. Required.
832* **edge**: A HardwareFeatures.Button.Edge enum. Required.
833* **position**: The percentage for button center position to the display's width/height in primary landscape screen orientation. If edge is LEFT or RIGHT, specifies the button's center position as a fraction of region's height relative to the top of region. For TOP and BOTTOM, specifies the position as a fraction of region width relative to the left side of region. Must be in the range [0.0, 1.0]. Required.
834* **id**: A string identifier for the Topology. If not passed, a default is provided.
835* **description**: An English description for the Topology. If not passed, a default is provided.
836
837
838### hw_topo.create_touch {#hw_topo.create_touch}
839Builds a Topology proto for touch.
840
841```python
842hw_topo.create_touch()
843```
844
845
846
847### hw_topo.create_microphone_mute_switch {#hw_topo.create_microphone_mute_switch}
848Builds a Topology proto for an microphone mute switch.
849
850```python
851hw_topo.create_microphone_mute_switch(present = None)
852```
853
854#### Arguments {#hw_topo.create_microphone_mute_switch-args}
855
856* **present**: flag indicating whether the device has an microphone mute switch
857
858
859### hw_topo.create_hdmi {#hw_topo.create_hdmi}
860Builds a Topology proto for HDMI.
861
862```python
863hw_topo.create_hdmi()
864```
865
866
867
868### hw_topo.create_hps {#hw_topo.create_hps}
869Builds a Topology proto for HPS.
870
871```python
872hw_topo.create_hps()
873```
874
875
876
877### hw_topo.create_dp_converter {#hw_topo.create_dp_converter}
878Builds a Topology proto for DisplayPort converters.
879
880```python
881hw_topo.create_dp_converter()
882```
883
884
885
886### hw_topo.create_poe {#hw_topo.create_poe}
887Builds a Topology proto for PoE.
888
889```python
890hw_topo.create_poe()
891```
892
893
894
895### hw_topo.convert_to_hw_features {#hw_topo.convert_to_hw_features}
896Converts a HardwareTopology proto to a HardwareFeatures proto.
897
898```python
899hw_topo.convert_to_hw_features()
900```
901
902
903
904### hw_topo.make_camera_device {#hw_topo.make_camera_device}
905Builds a HardwareFeatures.Camera.Device proto.
906
907```python
908hw_topo.make_camera_device()
909```
910
911
912
913### hw_topo.make_fw_config {#hw_topo.make_fw_config}
914Builds a HardwareFeatures.FirmwareConfiguration proto.
915
916Takes a 32-bit mask for the field and an id. Shifts the id
917into the mask region and checks that the value fits within the bit mask.
918
919```python
920hw_topo.make_fw_config()
921```
922
923
924
925### hw_topo.create_ec {#hw_topo.create_ec}
926Builds a Topology proto for an embedded controller.
927
928```python
929hw_topo.create_ec(present = None, ec_type = None, id = None)
930```
931
932#### Arguments {#hw_topo.create_ec-args}
933
934* **present**: flag indicating whether the device has an EC at all
935* **ec_type**: An EmbeddedControllerType enum
936* **id**: A string identifier for the Topology. If not passed, a default is provided.
937
938
939### hw_topo.create_tpm {#hw_topo.create_tpm}
940Builds a Topology proto for a trusted platform module.
941
942```python
943hw_topo.create_tpm(tpm_type = None, id = None, fw_configs = None)
944```
945
946#### Arguments {#hw_topo.create_tpm-args}
947
948* **tpm_type**: A TrustedPlatformModuleType enum
949* **id**: A string identifier for the Topology. If not passed, a default is provided.
950* **fw_configs**: A list of FirmwareConfiguration protos for the tpm.
951
952
953
954
955## //config/util/partner.star
956
957### partner.create {#partner.create}
958Builds a Partner proto.
959
960```python
961partner.create()
962```
963
964
965
966
967
968## //config/util/program.star
969
970### program.create {#program.create}
971Builds a Program proto.
972
973```python
974program.create()
975```
976
977
978
979### program.create_audio_config {#program.create_audio_config}
980Builds an AudioConfig proto.
981
982```python
983program.create_audio_config()
984```
985
986
987
988### program.create_platform {#program.create_platform}
989
990
991```python
992program.create_platform()
993```
994
995
996
997### program.create_firmware_configuration_segment {#program.create_firmware_configuration_segment}
998Builds a FirmwareConfigurationSegment proto.
999
1000```python
1001program.create_firmware_configuration_segment()
1002```
1003
1004
1005
1006### program.create_design_config_id_segment {#program.create_design_config_id_segment}
1007Builds a DesignConfigIdSegment proto.
1008
1009```python
1010program.create_design_config_id_segment()
1011```
1012
1013
1014
1015### program.create_signer_config {#program.create_signer_config}
1016Builds a DeviceSignerConfig proto.
1017
1018```python
1019program.create_signer_config()
1020```
1021
1022
1023
1024### program.create_signer_config_by_brand {#program.create_signer_config_by_brand}
1025
1026
1027```python
1028program.create_signer_config_by_brand()
1029```
1030
1031
1032
1033### program.create_signer_configs_by_brand {#program.create_signer_configs_by_brand}
1034
1035
1036```python
1037program.create_signer_configs_by_brand()
1038```
1039
1040
1041
1042### program.create_signer_config_by_design {#program.create_signer_config_by_design}
1043
1044
1045```python
1046program.create_signer_config_by_design()
1047```
1048
1049
1050
1051### program.create_signer_configs_by_design {#program.create_signer_configs_by_design}
1052
1053
1054```python
1055program.create_signer_configs_by_design()
1056```
1057
1058
1059
1060### program.generate {#program.generate}
1061Serializes a ConfigBundle to a file.
1062
1063A json proto is written. Note that there is some post processing done
1064by the gen_config script to convert this json output into a json
1065output that uses ints for encoding enums.
1066
1067```python
1068program.generate()
1069```
1070
1071
1072
1073
1074
1075## //config/util/public_replication.star
1076
1077### public_replication.create {#public_replication.create}
1078Creates a PublicReplication proto.
1079
1080```python
1081public_replication.create(public_fields)
1082```
1083
1084#### Arguments {#public_replication.create-args}
1085
1086* **public_fields**: A list of strings specifying fields that should be made public. See comment on the PublicReplication proto for semantics and example of how the proto works. Required.
1087
1088#### Returns  {#public_replication.create-returns}
1089A PublicReplication proto, None if public_fields evaluates to False.
1090
1091
1092
1093
1094## //config/util/sw_config.star
1095
1096### sw_config.create_ath10k {#sw_config.create_ath10k}
1097Builds a WifiConfig proto for use with ath10k drivers.
1098
1099```python
1100sw_config.create_ath10k(non_tablet_mode_transmit_power_chain, tablet_mode_transmit_power_chain)
1101```
1102
1103#### Arguments {#sw_config.create_ath10k-args}
1104
1105* **non_tablet_mode_transmit_power_chain**: non-tablet mode power chain. Required.
1106* **tablet_mode_transmit_power_chain**: tablet mode power chain. Required.
1107
1108
1109### sw_config.create_ath10k_power_chain {#sw_config.create_ath10k_power_chain}
1110Builds a TransmitPowerChain for ath10k drivers.
1111
1112```python
1113sw_config.create_ath10k_power_chain(limit_2g, limit_5g)
1114```
1115
1116#### Arguments {#sw_config.create_ath10k_power_chain-args}
1117
1118* **limit_2g**: 2G band power limit (dBm). Required.
1119* **limit_5g**: 5G band power limit (dBm). Required.
1120
1121
1122### sw_config.create_audio {#sw_config.create_audio}
1123Builds an AudioConfig proto.
1124
1125```python
1126sw_config.create_audio()
1127```
1128
1129
1130
1131### sw_config.create_bluetooth {#sw_config.create_bluetooth}
1132Builds a BluetoothConfig proto.
1133
1134```python
1135sw_config.create_bluetooth()
1136```
1137
1138
1139
1140### sw_config.create_camera {#sw_config.create_camera}
1141Builds a CameraConfig proto.
1142
1143```python
1144sw_config.create_camera()
1145```
1146
1147
1148
1149### sw_config.create_fw_version {#sw_config.create_fw_version}
1150Builds a firmware Version proto.
1151
1152If major_version is not specified, None is returned.
1153
1154```python
1155sw_config.create_fw_version()
1156```
1157
1158
1159
1160### sw_config.create_fw_payload {#sw_config.create_fw_payload}
1161Builds a FirmwarePayload proto.
1162
1163```python
1164sw_config.create_fw_payload()
1165```
1166
1167
1168
1169### sw_config.create_fw_config {#sw_config.create_fw_config}
1170Builds a FirmwareConfig proto.
1171
1172```python
1173sw_config.create_fw_config()
1174```
1175
1176
1177
1178### sw_config.create_fw_payloads_by_names {#sw_config.create_fw_payloads_by_names}
1179Builds a FirmwareConfig proto using common naming patterns.
1180
1181```python
1182sw_config.create_fw_payloads_by_names()
1183```
1184
1185
1186
1187### sw_config.create_fw_build_config {#sw_config.create_fw_build_config}
1188Builds a FirmwareBuildConfig proto.
1189
1190```python
1191sw_config.create_fw_build_config()
1192```
1193
1194
1195
1196### sw_config.create_fw_build_config_by_names {#sw_config.create_fw_build_config_by_names}
1197Builds a FirmwareBuildConfig proto using common naming patterns.
1198
1199Build targets are set to be coreboot_name unless they are otherwise
1200specified, e.g. depthcharge is set to coreboot_name unless
1201depthcharge_name is specified. This function is provided as a convenience,
1202as different firmware build targets often share the same name.
1203
1204```python
1205sw_config.create_fw_build_config_by_names()
1206```
1207
1208
1209
1210### sw_config.create_fw_build_targets {#sw_config.create_fw_build_targets}
1211Builds a Firmware.BuildTargets proto.
1212
1213```python
1214sw_config.create_fw_build_targets()
1215```
1216
1217
1218
1219### sw_config.create_health {#sw_config.create_health}
1220Builds a HealthConfig proto.
1221
1222```python
1223sw_config.create_health()
1224```
1225
1226
1227
1228### sw_config.create_power {#sw_config.create_power}
1229Builds a PowerConfig proto.
1230
1231```python
1232sw_config.create_power()
1233```
1234
1235
1236
1237### sw_config.create_intel_antenna_gain {#sw_config.create_intel_antenna_gain}
1238Builds AntennaGain for intel drivers.
1239
1240```python
1241sw_config.create_intel_antenna_gain(
1242    # Required arguments.
1243    ant_gain_5g_1,
1244    ant_gain_5g_2,
1245    ant_gain_5g_3,
1246    ant_gain_5g_4,
1247
1248    # Optional arguments.
1249    ant_gain_2g = None,
1250    ant_gain_5g_5 = None,
1251    ant_gain_6g_1 = None,
1252    ant_gain_6g_2 = None,
1253    ant_gain_6g_3 = None,
1254    ant_gain_6g_4 = None,
1255    ant_gain_6g_5 = None,
1256)
1257```
1258
1259#### Arguments {#sw_config.create_intel_antenna_gain-args}
1260
1261* **ant_gain_2g**: Antenna gain used for 2400MHz frequency.
1262* **ant_gain_5g_1**: Antenna gain used for 5150–5350MHz frequency. Required.
1263* **ant_gain_5g_2**: Antenna gain used for 5350–5470MHz frequency. Required.
1264* **ant_gain_5g_3**: Antenna gain used for 5470–5725MHz frequency. Required.
1265* **ant_gain_5g_4**: Antenna gain used for 5725–5950MHz frequency. Required.
1266* **ant_gain_5g_5**: Antenna gain used for 5945–6165MHz frequency. Rev 1 & 2.
1267* **ant_gain_6g_1**: Antenna gain used for 6165–6405MHz frequency. Rev 1 & 2.
1268* **ant_gain_6g_2**: Antenna gain used for 6405–6525MHz frequency. Rev 1 & 2.
1269* **ant_gain_6g_3**: Antenna gain used for 6525–6705MHz frequency. Rev 1 & 2.
1270* **ant_gain_6g_4**: Antenna gain used for 6705–6865MHz frequency. Rev 1 & 2.
1271* **ant_gain_6g_5**: Antenna gain used for 6865–7105MHz frequency. Rev 1 & 2.
1272
1273
1274### sw_config.create_intel_antgain_table {#sw_config.create_intel_antgain_table}
1275Builds a antenna Gains for intel drivers.
1276
1277```python
1278sw_config.create_intel_antgain_table(
1279    # Optional arguments.
1280    ant_table_revision = None,
1281    ant_ppag_mode = None,
1282    ant_gain_chain_a = None,
1283    ant_gain_chain_b = None,
1284)
1285```
1286
1287#### Arguments {#sw_config.create_intel_antgain_table-args}
1288
1289* **ant_table_revision**: Antenna gains table revision
1290* **ant_ppag_mode**: Defines the mode of the ANT_gain control to be used.
1291* **ant_gain_chain_a**: Defines the ANT_gain in dBi for chain A to be used.
1292* **ant_gain_chain_b**: Defines the ANT_gain in dBi for chain B to be used.
1293
1294
1295### sw_config.create_intel_dsm {#sw_config.create_intel_dsm}
1296Builds a DSM for intel drivers.
1297
1298```python
1299sw_config.create_intel_dsm(
1300    # Optional arguments.
1301    disable_active_sdr_channels = None,
1302    support_indonesia_5g_band = None,
1303    support_ultra_high_band = None,
1304    regulatory_configurations = None,
1305    uart_configurations = None,
1306    enablement_11ax = None,
1307    unii_4 = None,
1308)
1309```
1310
1311#### Arguments {#sw_config.create_intel_dsm-args}
1312
1313* **disable_active_sdr_channels**: Allow OEMs to set ETSI 5.8GHz SRD Channels to Passive/Disabled.
1314* **support_indonesia_5g_band**: Enable/Disable 5.15-5.35GHz band support in Indonesia.
1315* **support_ultra_high_band**: Control the enablement of 6 GHz band.
1316* **regulatory_configurations**: Regulatory special configurations enablements value.
1317* **uart_configurations**: M.2 UART interface configuration.
1318* **enablement_11ax**: Control enablement of 11ax on certificated modules.
1319* **unii_4**: Control enablement of UNII-4 over certificate modules.
1320
1321
1322### sw_config.create_intel_geo_offsets {#sw_config.create_intel_geo_offsets}
1323Builds a GeoOffsets for intel drivers.
1324
1325```python
1326sw_config.create_intel_geo_offsets(
1327    # Required arguments.
1328    max_2g,
1329    offset_2g_a,
1330    offset_2g_b,
1331    max_5g,
1332    offset_5g_a,
1333    offset_5g_b,
1334
1335    # Optional arguments.
1336    max_6g = None,
1337    offset_6g_a = None,
1338    offset_6g_b = None,
1339)
1340```
1341
1342#### Arguments {#sw_config.create_intel_geo_offsets-args}
1343
1344* **max_2g**: Defines the 2.4 GHz upper value for the allowed power to not be crossed by applying the Geo offset. Required.
1345* **offset_2g_a**: Value to be added to the 2.4GHz WiFi band for chain a. (0.125 dBm) Required.
1346* **offset_2g_b**: Value to be added to the 2.4GHz WiFi band for chain b. (0.125 dBm) Required.
1347* **max_5g**: Defines the 5 GHz upper value for the allowed power to not be crossed by applying the Geo offset. Required.
1348* **offset_5g_a**: Value to be added to 5GHz WiFi bands for chain a. (0.125 dBm) Required.
1349* **offset_5g_b**: Value to be added to 5GHz WiFi bands for chain b. (0.125 dBm) Required.
1350* **max_6g**: Defines the 6 GHz upper value for the allowed power to not be crossed by applying the Geo offset. Rev 1 & 2.
1351* **offset_6g_a**: Value to be added to 6GHz WiFi bands for chain a. (0.125 dBm) Rev 1 & 2.
1352* **offset_6g_b**: Value to be added to 6GHz WiFi bands for chain b. (0.125 dBm) Rev 1 & 2.
1353
1354
1355### sw_config.create_intel_offsets_table {#sw_config.create_intel_offsets_table}
1356Builds a Geo Offsets proto for use with intel drivers.
1357
1358```python
1359sw_config.create_intel_offsets_table(
1360    # Optional arguments.
1361    wgds_revision = None,
1362    fcc_offsets = None,
1363    eu_offsets = None,
1364    other_offsets = None,
1365)
1366```
1367
1368#### Arguments {#sw_config.create_intel_offsets_table-args}
1369
1370* **wgds_revision**: Geo delta table revision,
1371* **fcc_offsets**: Offsets used for regulatory domains that follow FCC guidelines.
1372* **eu_offsets**: Offsets used for regulatory domains that follow ESTI guidelines.
1373* **other_offsets**: Offsets for regulatory domains that don't follow FCC or ETSI guidelines.
1374
1375
1376### sw_config.create_intel_power_chain {#sw_config.create_intel_power_chain}
1377Builds a TransmitPowerChain for intel drivers.
1378
1379```python
1380sw_config.create_intel_power_chain(
1381    # Required arguments.
1382    limit_2g,
1383    limit_5g_1,
1384    limit_5g_2,
1385    limit_5g_3,
1386    limit_5g_4,
1387
1388    # Optional arguments.
1389    limit_5g_5 = None,
1390    limit_6g_1 = None,
1391    limit_6g_2 = None,
1392    limit_6g_3 = None,
1393    limit_6g_4 = None,
1394    limit_6g_5 = None,
1395)
1396```
1397
1398#### Arguments {#sw_config.create_intel_power_chain-args}
1399
1400* **limit_2g**: 2G band power limit: All 2G band channels. (0.125 dBm). Required.
1401* **limit_5g_1**: 5G band 1 power limit: 5.15G-5.35G channels. (0.125 dBm). Required.
1402* **limit_5g_2**: 5G band 2 power limit: 5.35G-5.47G channels. (0.125 dBm). Required.
1403* **limit_5g_3**: 5G band 3 power limit: 5.47G-5.725G channels. (0.125 dBm). Required.
1404* **limit_5g_4**: 5G band 4 power limit: 5.725G-5.95G channels. (0.125 dBm). Required.
1405* **limit_5g_5**: 5G band 5 power limit: 5.95G-6.165G channels. (0.125 dBm). Rev 1 & 2.
1406* **limit_6g_1**: 6G band 1 power limit: 6.165G-6.405G channels. (0.125 dBm). Rev 1 & 2.
1407* **limit_6g_2**: 6G band 2 power limit: 6.405G-6.525G channels. (0.125 dBm). Rev 1 & 2.
1408* **limit_6g_3**: 6G band 3 power limit: 6.525G-6.705G channels. (0.125 dBm). Rev 1 & 2.
1409* **limit_6g_4**: 6G band 4 power limit: 6.705G-6.865G channels. (0.125 dBm). Rev 1 & 2.
1410* **limit_6g_5**: 6G band 5 power limit: 6.865G-7.105G channels. (0.125 dBm). Rev 1 & 2.
1411
1412
1413### sw_config.create_intel_sar_table {#sw_config.create_intel_sar_table}
1414Builds a SarTable proto for use with intel drivers.
1415
1416```python
1417sw_config.create_intel_sar_table(
1418    # Optional arguments.
1419    sar_table_revision = None,
1420    tablet_mode_transmit_power_chain_a = None,
1421    tablet_mode_transmit_power_chain_b = None,
1422    non_tablet_mode_transmit_power_chain_a = None,
1423    non_tablet_mode_transmit_power_chain_b = None,
1424    cdb_tablet_mode_transmit_power_chain_a = None,
1425    cdb_tablet_mode_transmit_power_chain_b = None,
1426    cdb_non_tablet_mode_transmit_power_chain_a = None,
1427    cdb_non_tablet_mode_transmit_power_chain_b = None,
1428)
1429```
1430
1431#### Arguments {#sw_config.create_intel_sar_table-args}
1432
1433* **sar_table_revision**: SAR table revision.
1434* **tablet_mode_transmit_power_chain_a**: Tablet mode power chain for chain a.
1435* **tablet_mode_transmit_power_chain_b**: Tablet mode power chain for chain b.
1436* **non_tablet_mode_transmit_power_chain_a**: Non-tablet mode power chain for chain a.
1437* **non_tablet_mode_transmit_power_chain_b**: Non-tablet mode power chain for chain b.
1438* **cdb_tablet_mode_transmit_power_chain_a**: Tablet mode concurrency dual band power chain for chain a.
1439* **cdb_tablet_mode_transmit_power_chain_b**: Tablet mode concurrency dual band power chain for chain b.
1440* **cdb_non_tablet_mode_transmit_power_chain_a**: Non-tablet mode concurrency dual band power chain for chain a.
1441* **cdb_non_tablet_mode_transmit_power_chain_b**: Non-tablet mode concurrency dual band power chain for chain b.
1442
1443
1444### sw_config.create_intel_sar_avg_table {#sw_config.create_intel_sar_avg_table}
1445Builds a wifi time average SAR proto for use with intel drivers.
1446
1447```python
1448sw_config.create_intel_sar_avg_table(
1449    # Optional arguments.
1450    wtas_revision = None,
1451    tas_selection = None,
1452    tas_list_size = None,
1453    deny_list_entry_1 = None,
1454    deny_list_entry_2 = None,
1455    deny_list_entry_3 = None,
1456    deny_list_entry_4 = None,
1457    deny_list_entry_5 = None,
1458    deny_list_entry_6 = None,
1459    deny_list_entry_7 = None,
1460    deny_list_entry_8 = None,
1461    deny_list_entry_9 = None,
1462    deny_list_entry_10 = None,
1463    deny_list_entry_11 = None,
1464    deny_list_entry_12 = None,
1465    deny_list_entry_13 = None,
1466    deny_list_entry_14 = None,
1467    deny_list_entry_15 = None,
1468    deny_list_entry_16 = None,
1469)
1470```
1471
1472#### Arguments {#sw_config.create_intel_sar_avg_table-args}
1473
1474* **wtas_revision**: Wifi time average SAR version.
1475* **tas_selection**: Enable/disable the TAS feature.
1476* **tas_list_size**: Represents the number of blocked countries that are not approved by the OEM to support this feature, even if that feature is enabled.
1477* **deny_list_entry_1**: ISO country code 1 to block.
1478* **deny_list_entry_2**: ISO country code 2 to block.
1479* **deny_list_entry_3**: ISO country code 3 to block.
1480* **deny_list_entry_4**: ISO country code 4 to block.
1481* **deny_list_entry_5**: ISO country code 5 to block.
1482* **deny_list_entry_6**: ISO country code 6 to block.
1483* **deny_list_entry_7**: ISO country code 7 to block.
1484* **deny_list_entry_8**: ISO country code 8 to block.
1485* **deny_list_entry_9**: ISO country code 9 to block.
1486* **deny_list_entry_10**: ISO country code 10 to block.
1487* **deny_list_entry_11**: ISO country code 11 to block.
1488* **deny_list_entry_12**: ISO country code 12 to block.
1489* **deny_list_entry_13**: ISO country code 13 to block.
1490* **deny_list_entry_14**: ISO country code 14 to block.
1491* **deny_list_entry_15**: ISO country code 15 to block.
1492* **deny_list_entry_16**: ISO country code 16 to block.
1493
1494
1495### sw_config.create_intel_wifi {#sw_config.create_intel_wifi}
1496Builds a IntelConfig proto for use with intel drivers.
1497
1498```python
1499sw_config.create_intel_wifi(
1500    # Optional arguments.
1501    sar_table = None,
1502    wgds_table = None,
1503    ant_table = None,
1504    wtas_table = None,
1505    dsm = None,
1506)
1507```
1508
1509#### Arguments {#sw_config.create_intel_wifi-args}
1510
1511* **sar_table**: SarTable proto for use with intel driver.
1512* **wgds_table**: Geo Offsets proto for use with intel driver.
1513* **ant_table**: Antenna Gains for use with intel driver.
1514* **wtas_table**: Time average SAR for use with intel driver.
1515* **dsm**: Device specific methods return values for intel driver.
1516
1517
1518### sw_config.create_mtk_geo_power_chain {#sw_config.create_mtk_geo_power_chain}
1519Builds a GeoTransmitPowerChain for mtk drivers.
1520
1521```python
1522sw_config.create_mtk_geo_power_chain(
1523    # Required arguments.
1524    limit_2g,
1525    limit_5g,
1526    offset_2g,
1527    offset_5g,
1528)
1529```
1530
1531#### Arguments {#sw_config.create_mtk_geo_power_chain-args}
1532
1533* **limit_2g**: 2G band geo power limit. (0.25 dBm). Required.
1534* **limit_5g**: 5G band geo power limit. (0.25 dBm). Required.
1535* **offset_2g**: Value to be added to the 2.4GHz WiFi band. (0.25 dBm). Required.
1536* **offset_5g**: Value to be added to all 5GHz WiFi bands. (0.25 dBm). Required.
1537
1538
1539### sw_config.create_mtk_power_chain {#sw_config.create_mtk_power_chain}
1540Builds a TransmitPowerChain for mtk drivers.
1541
1542```python
1543sw_config.create_mtk_power_chain(
1544    # Required arguments.
1545    limit_2g,
1546    limit_5g_1,
1547    limit_5g_2,
1548    limit_5g_3,
1549    limit_5g_4,
1550)
1551```
1552
1553#### Arguments {#sw_config.create_mtk_power_chain-args}
1554
1555* **limit_2g**: 2G band power limit. (0.25 dBm). Required.
1556* **limit_5g_1**: 5G band 1 power limit: 5.15G-5.35G frequency. (0.25 dBm). Required.
1557* **limit_5g_2**: 5G band 2 power limit: 5.35G-5.47G frequency. (0.25 dBm). Required.
1558* **limit_5g_3**: 5G band 3 power limit: 5.47G-5.725G frequency. (0.25 dBm). Required.
1559* **limit_5g_4**: 5G band 4 power limit: 5.725G-5.95G frequency. (0.25 dBm). Required.
1560
1561
1562### sw_config.create_mtk_wifi {#sw_config.create_mtk_wifi}
1563Builds a WifiConfig proto for use with mtk drivers.
1564
1565```python
1566sw_config.create_mtk_wifi(
1567    # Required arguments.
1568    non_tablet_mode_transmit_power_chain,
1569    tablet_mode_transmit_power_chain,
1570
1571    # Optional arguments.
1572    fcc_transmit_power_chain = None,
1573    eu_transmit_power_chain = None,
1574    other_transmit_power_chain = None,
1575)
1576```
1577
1578#### Arguments {#sw_config.create_mtk_wifi-args}
1579
1580* **non_tablet_mode_transmit_power_chain**: non-tablet mode power chain. Required.
1581* **tablet_mode_transmit_power_chain**: tablet mode power chain. Required.
1582* **fcc_transmit_power_chain**: power chain for regulatory domains that follow FCC guidelines.
1583* **eu_transmit_power_chain**: power chain for regulatory domains that follow ESTI guidelines.
1584* **other_transmit_power_chain**: power chain for regulatory domains that don't follow FCC or ETSI guidelines.
1585
1586
1587### sw_config.create_rtw88 {#sw_config.create_rtw88}
1588Builds a WifiConfig proto for use with rtw88 drivers.
1589
1590```python
1591sw_config.create_rtw88(
1592    # Required arguments.
1593    non_tablet_mode_transmit_power_chain,
1594    tablet_mode_transmit_power_chain,
1595
1596    # Optional arguments.
1597    fcc_offsets = None,
1598    eu_offsets = None,
1599    other_offsets = None,
1600)
1601```
1602
1603#### Arguments {#sw_config.create_rtw88-args}
1604
1605* **non_tablet_mode_transmit_power_chain**: non-tablet mode power chain. Required.
1606* **tablet_mode_transmit_power_chain**: tablet mode power chain. Required.
1607* **fcc_offsets**: Offsets used for regulatory domains that follow FCC guidelines
1608* **eu_offsets**: Offsets used for regulatory domains that follow ESTI guidelines
1609* **other_offsets**: Offsets for regulatory domains that don't follow FCC or ETSI guidelines
1610
1611
1612### sw_config.create_rtw88_geo_offsets {#sw_config.create_rtw88_geo_offsets}
1613Builds a GeoOffsets from rtw88 drivers.
1614
1615```python
1616sw_config.create_rtw88_geo_offsets(offset_2g, offset_5g)
1617```
1618
1619#### Arguments {#sw_config.create_rtw88_geo_offsets-args}
1620
1621* **offset_2g**: Value to be added to the 2.4GHz WiFi band. (0.125 dBm) Required.
1622* **offset_5g**: Value to be added to all 5GHz WiFi bands. (0.125 dBm) Required.
1623
1624
1625### sw_config.create_rtw88_power_chain {#sw_config.create_rtw88_power_chain}
1626Builds a TransmitPowerChain for rtw88 drivers.
1627
1628```python
1629sw_config.create_rtw88_power_chain(
1630    # Required arguments.
1631    limit_2g,
1632    limit_5g_1,
1633    limit_5g_3,
1634    limit_5g_4,
1635)
1636```
1637
1638#### Arguments {#sw_config.create_rtw88_power_chain-args}
1639
1640* **limit_2g**: 2G band power limit: All 2G band channels. (0.125 dBm). Required.
1641* **limit_5g_1**: 5G band 1 power limit: 5.15G-5.35G channels. (0.125 dBm). Required.
1642* **limit_5g_3**: 5G band 3 power limit: 5.47G-5.725G channels. (0.125 dBm). Required.
1643* **limit_5g_4**: 5G band 4 power limit: 5.725G-5.95G channels. (0.125 dBm). Required.
1644
1645
1646### sw_config.create_rtw89 {#sw_config.create_rtw89}
1647Builds a WifiConfig proto for use with rtw89 drivers.
1648
1649```python
1650sw_config.create_rtw89(
1651    # Required arguments.
1652    non_tablet_mode_transmit_power_chain,
1653    tablet_mode_transmit_power_chain,
1654
1655    # Optional arguments.
1656    fcc_offsets = None,
1657    eu_offsets = None,
1658    other_offsets = None,
1659)
1660```
1661
1662#### Arguments {#sw_config.create_rtw89-args}
1663
1664* **non_tablet_mode_transmit_power_chain**: non-tablet mode power chain. Required.
1665* **tablet_mode_transmit_power_chain**: tablet mode power chain. Required.
1666* **fcc_offsets**: Offsets used for regulatory domains that follow FCC guidelines
1667* **eu_offsets**: Offsets used for regulatory domains that follow ESTI guidelines
1668* **other_offsets**: Offsets for regulatory domains that don't follow FCC or ETSI guidelines
1669
1670
1671### sw_config.create_rtw89_geo_offsets {#sw_config.create_rtw89_geo_offsets}
1672Builds a GeoOffsets from rtw89 drivers.
1673
1674```python
1675sw_config.create_rtw89_geo_offsets(offset_2g, offset_5g)
1676```
1677
1678#### Arguments {#sw_config.create_rtw89_geo_offsets-args}
1679
1680* **offset_2g**: Value to be added to the 2.4GHz WiFi band. (0.25 dBm) Required.
1681* **offset_5g**: Value to be added to all 5GHz WiFi bands. (0.25 dBm) Required.
1682
1683
1684### sw_config.create_rtw89_power_chain {#sw_config.create_rtw89_power_chain}
1685Builds a TransmitPowerChain for rtw89 drivers.
1686
1687```python
1688sw_config.create_rtw89_power_chain(
1689    # Required arguments.
1690    limit_2g,
1691    limit_5g_1,
1692    limit_5g_3,
1693    limit_5g_4,
1694)
1695```
1696
1697#### Arguments {#sw_config.create_rtw89_power_chain-args}
1698
1699* **limit_2g**: 2G band power limit: All 2G band channels. (0.25 dBm). Required.
1700* **limit_5g_1**: 5G band 1 power limit: 5.15G-5.35G channels. (0.25 dBm). Required.
1701* **limit_5g_3**: 5G band 3 power limit: 5.47G-5.725G channels. (0.25 dBm). Required.
1702* **limit_5g_4**: 5G band 4 power limit: 5.725G-5.95G channels. (0.25 dBm). Required.
1703
1704
1705### sw_config.create_ui {#sw_config.create_ui}
1706
1707
1708```python
1709sw_config.create_ui()
1710```
1711
1712
1713
1714### sw_config.create_usb {#sw_config.create_usb}
1715
1716
1717```python
1718sw_config.create_usb()
1719```
1720
1721
1722
1723### sw_config.make_resolution {#sw_config.make_resolution}
1724
1725
1726```python
1727sw_config.make_resolution()
1728```
1729