Home
last modified time | relevance | path

Searched refs:self (Results 1 – 25 of 186) sorted by relevance

12345678

/scripts/west_commands/zspdx/
A Dcmakefileapi.py10 def __init__(self): argument
17 def __repr__(self): argument
23 def __init__(self): argument
26 self.name = ""
31 def __repr__(self): argument
40 def __init__(self): argument
44 self.build = ""
58 def __repr__(self): argument
67 self.name = ""
89 self.id = ""
[all …]
/scripts/pylib/pytest-twister-harness/src/twister_harness/device/
A Dfifo_handler.py36 self._timeout = timeout
47 self._make_fifo_file(self._fifo_out_path)
48 self._make_fifo_file(self._fifo_in_path)
50 self._open_fifo_thread = threading.Thread(target=self._open_fifo, daemon=True)
62 self._fifo_out_file = open(self._fifo_out_path, 'rb', buffering=0)
63 self._fifo_in_file = open(self._fifo_in_path, 'wb', buffering=0)
93 if self._open_fifo_thread and self._open_fifo_thread.is_alive():
96 if self._opening_monitor_thread and self._opening_monitor_thread.is_alive():
103 if self._fifo_in_file:
116 and self._fifo_in_file is not None and self._fifo_out_file is not None
[all …]
A Ddevice_adapter.py49 self._log_files: list[Path] = [self.handler_log_path]
65 self.close()
68 if not self.command:
71 self.command.extend(self.device_config.extra_test_args.split())
77 self.connect()
91 self.connect()
99 self.disconnect()
143 if self.is_device_connected() or not self._device_read_queue.empty():
154 self, argument
263 self._reader_thread.join(self.base_timeout)
[all …]
A Dbinary_adapter.py30 'env': self.env,
39 self._run_subprocess()
42 if not self.command:
48 self._process = subprocess.Popen(self.command, **self.process_kwargs)
84 terminate_process(self._process, self.base_timeout)
85 return_code = self._process.wait(self.base_timeout)
101 return self._device_run.is_set() and self._is_binary_running()
104 if self._process is None or self._process.poll() is not None:
110 return self.is_device_running() and self._device_connected.is_set()
130 self.command = [str(self.device_config.app_build_dir / 'testbinary')]
[all …]
A Dhardware_adapter.py39 self._log_files.append(self.device_log_path)
44 self.west,
62 self.command = command
102 if not self.command:
108 self._run_custom_script(self.device_config.pre_script, self.base_timeout)
133 self._run_custom_script(self.device_config.post_flash_script, self.base_timeout)
142 serial_name = self._open_serial_pty() or self.device_config.serial
197 self._serial_pty_proc.communicate(timeout=self.base_timeout)
203 self._run_custom_script(self.device_config.post_script, self.base_timeout)
237 if self._serial_connection is None or not self._serial_connection.is_open:
[all …]
/scripts/build/
A Dgen_isr_tables.py23 def debug(self, text): argument
28 if self.__debug:
68 self.__log = log
72 self.__vt_default_handler = self.__vt_irq_handler
74 self.__vt_default_handler = self.__vt_spurious_handler
102 self.__int_lvl_masks[0] = self.__bm(self.int_bits[0])
103 self.__int_lvl_masks[1] = self.__bm(self.int_bits[1]) << self.int_bits[0]
104self.__int_lvl_masks[2] = self.__bm(self.int_bits[2]) << (self.int_bits[0] + self.int_bits[1])
131 def args(self): argument
198 irq3 = (irq & self.int_lvl_masks[2]) >> (self.int_bits[0] + self.int_bits[1])
[all …]
A Dllext_prepare_exptab.py85 self.size = self.section['sh_size']
86 self.flags = self.section['sh_flags']
87 self.offset = self.section['sh_offset']
98 self.fd.seek(self.base_offset + index * self.lcs_struct.size)
108 return self.lcs_struct.unpack(self.fd.read(self.lcs_struct.size))
132 self.elf_fd = open(self.elf_path, 'rb+')
133 self.elf = ELFFile(self.elf_fd)
261 self.elf_fd.write(int.to_bytes(sh_flags, self.ptrsize, self.endianness))
279 self.ptrsize = self.elf.elfclass // 8
281 self.lcs_struct = _llext_const_symbol_struct(self.ptrsize, self.endianness)
[all …]
A Dgen_isr_tables_parser_local.py52 self.__config = config
53 self.__log = log
55 self.__vt, self.__swt, self.__nv, header = self.__parse_intlist(intlist)
171 if not(self.__config.args.sw_isr_table or self.__config.args.vector_table):
262 for i in range(self.__nv):
281 "{}[{}];\n".format(self.__config.shared_array_name, self.__nv))
309 def write_source(self, fp): argument
312 if self.__vt:
315 if not self.__swt:
367 if self.__vt:
[all …]
/scripts/dts/python-devicetree/src/devicetree/
A Dgrutils.py22 self.__roots = None
27 self.__nodes = set()
47 def roots(self): argument
63 def _tarjan(self): argument
76 self.__stack = []
78 self.__index = 0
107 self.__tarjan_index[v] = self.__tarjan_low_link[v] = self.__index
114self.__tarjan_low_link[v] = min(self.__tarjan_low_link[v], self.__tarjan_low_link[target])
116self.__tarjan_low_link[v] = min(self.__tarjan_low_link[v], self.__tarjan_low_link[target])
118 if self.__tarjan_low_link[v] == self.__tarjan_index[v]:
[all …]
A Ddtlib.py158 cur = self
199 self.parent.nodes.pop(self.name) # type: ignore
566 return self.type is Type.NUMS and not self.value
992 ret = DT(None, (), self._force, self._base_dir)
1093 self._tok_i = self._tok_end_i = 0
1158 name="/", parent=None, dt=self, filename=self.filename, lineno=self._lineno
1160 self._parse_node(self.root)
1622 self._saved_token = self._next_token()
1675 self._tok_i = self._tok_end_i
1759 _FileStackElt(self.filename, self._lineno,
[all …]
/scripts/west_commands/runners/
A Dnrf_common.py95 self.force = force
101 self.tool_opt = []
492 if self.erase or self.recover:
560 if self.suit_starter and self.family == 'nrf54h':
580 self.do_exec_op(self.ops.popleft(), force)
585 if self.softreset and self.pinreset:
589 if self.erase and self.erase_mode:
593 if self.erase and self.ext_erase_mode:
599 if self.family != 'nrf54l' and self.erase_mode:
610 self.hex_contents.loadfile(self.hex_, format='hex')
[all …]
A Dlinkserver.py41 self.core = core
44 self.erase = erase
45 self.probe = probe
51 self.override_cli = self._build_override_cli()
53 self.tool_opt = []
121 self.linkserver = self.require(self.linkserver)
195 if self.erase:
200 if self.supports_hex() and self.hex_name is not None and os.path.isfile(self.hex_name):
203 elif self.bin_name is not None and os.path.isfile(self.bin_name):
211 elif self.elf_name is not None and os.path.isfile(self.elf_name):
[all …]
A Djlink.py319 Path(self.require(self.commander)).resolve())
323 rtos = self.thread_info_enabled and self.supports_thread_info
332 detected_type = self._detect_dev_id_type(self.dev_id)
374 self.require(self.gdbserver)
391 self.run_telnet_client('localhost', self.rtt_port, sock)
419 self.require(self.gdbserver)
432 if self.erase:
486 raise ValueError(err.format(self.hex_name, self.bin_name))
495 sram_addr = self.sram_address_from_build_conf(self.build_conf)
517 if self.supports_loader and self.loader:
[all …]
A Dpyocd.py19 def __init__(self, cfg, target, argument
36 self.pyocd = pyocd
38 self.erase = erase
138 def port_args(self): argument
139 return ['-p', str(self.gdb_port), '-T', str(self.telnet_port)]
142 self.require(self.pyocd)
153 if self.hex_name is not None and os.path.isfile(self.hex_name):
156 elif self.bin_name is not None and os.path.isfile(self.bin_name):
158 elif self.elf_name is not None and os.path.isfile(self.elf_name):
181 self.check_call(cmd)
[all …]
A Dxsdb.py27 self.pdi = pdi
57 if self.bitstream and self.fsbl:
58 cmd = ['xsdb', self.xsdb_cfg_file, self.elf_file, self.bitstream, self.fsbl]
60 cmd = ['xsdb', self.xsdb_cfg_file, self.elf_file, self.bitstream]
62 cmd = ['xsdb', self.xsdb_cfg_file, self.elf_file, self.fsbl]
63 elif self.pdi and self.bl31 and self.dtb:
64 cmd = ['xsdb', self.xsdb_cfg_file, self.elf_file, self.pdi, self.bl31, self.dtb]
65 elif self.pdi and self.bl31:
66 cmd = ['xsdb', self.xsdb_cfg_file, self.elf_file, self.pdi, self.bl31]
68 cmd = ['xsdb', self.xsdb_cfg_file, self.elf_file, self.pdi]
[all …]
A Dezflashcli.py19 self.tool = tool
20 self.dev_id = dev_id
24 self.tool_opt = []
68 def get_options(self): argument
74 def program_bin(self): argument
77 if self.erase:
79 self.check_call([self.tool] + options + ["erase_flash"])
85 self.check_call([self.tool] + options + ["image_flash", self.bin_])
95 self.check_call([self.tool] + options + ["go"])
98 self.require(self.tool)
[all …]
A Dcanopen_program.py70 self.downloader = CANopenProgramDownloader(logger=self.logger,
171 self.downloader.wait_for_flash_status_ok(self.timeout)
172 self.downloader.download(self.bin_file)
181 self.downloader.wait_for_bootup(self.timeout)
202 self.node = self.network.add_node(self.node_id,
204 self.data_sdo = self.node.sdo[H1F50_PROGRAM_DATA][self.program_number]
205 self.ctrl_sdo = self.node.sdo[H1F51_PROGRAM_CTRL][self.program_number]
206 self.swid_sdo = self.node.sdo[H1F56_PROGRAM_SWID][self.program_number]
207 self.flash_sdo = self.node.sdo[H1F57_FLASH_STATUS][self.program_number]
218 self.network.connect(context=self.can_context)
[all …]
/scripts/pylib/twister/twisterlib/
A Dharness.py175 if self.fail_on_fault and line == self.FAULT:
203 tc = self.instance.get_case_or_create(self.id)
269 if self.regex is None or len(self.regex) == 0:
278 self.pattern = re.compile(self.regex[0])
319 if len(self.matches) == len(self.regex):
324 if self.fail_on_fault and self.FAULT in line:
342 self.next_pattern < self.patterns_expected:
388 self.instance.record(self.recording)
588 self.instance.status = self.status if self.status != TwisterStatus.NONE else \
1057 self.instance.record(self.recording)
[all …]
A Drunner.py152 selected_cases = self.cases - self.filtered_cases
153 selected_configs = self.done - self.filtered_static - self.filtered_runtime
186 if self.none_cases or self.started_cases:
753 os.path.join(self.build_dir, self.log),
831 if self.testsuite and self.testsuite.filter:
967 self.instance.setup_handler(self.env)
1838 self.jobs = self.options.jobs
1850 self.jobs = self.jobserver.jobs
1865 self.results.done = self.results.total - self.results.failed
1871 self.results.done = self.results.filtered_static + self.results.skipped
[all …]
/scripts/logging/dictionary/dictionary_parser/
A Ddata_types.py33 self.add_data_type(self.LONG, "q")
34 self.add_data_type(self.ULONG, "Q")
35 self.add_data_type(self.LONG_LONG, "q")
37 self.add_data_type(self.PTR, "Q")
39 self.add_data_type(self.LONG, "i")
40 self.add_data_type(self.ULONG, "I")
43 self.add_data_type(self.PTR, "I")
45 self.add_data_type(self.INT, "i")
46 self.add_data_type(self.UINT, "I")
47 self.add_data_type(self.DOUBLE, "d")
[all …]
A Dlog_database.py64 def __init__(self): argument
75 self.database = new_db
78 def get_version(self): argument
83 def get_build_id(self): argument
93 def get_arch(self): argument
98 def set_arch(self, arch): argument
103 def get_tgt_bits(self): argument
111 def set_tgt_bits(self, bits): argument
116 def is_tgt_64bit(self): argument
157 return self.database['target']['little_endianness'] == self.LITTLE_ENDIAN
[all …]
/scripts/west_commands/
A Dbindesc.py67 def __init__(self): argument
76 self.bindesc_gen_tag(self.TYPE_STR, 0x805): 'APP_BUILD_VERSION',
83 self.bindesc_gen_tag(self.TYPE_UINT, 0xa00): 'BUILD_TIME_YEAR',
85 self.bindesc_gen_tag(self.TYPE_UINT, 0xa02): 'BUILD_TIME_DAY',
86 self.bindesc_gen_tag(self.TYPE_UINT, 0xa03): 'BUILD_TIME_HOUR',
93 self.bindesc_gen_tag(self.TYPE_STR, 0xb00): 'HOST_NAME',
94 self.bindesc_gen_tag(self.TYPE_STR, 0xb01): 'C_COMPILER_NAME',
99 self.NAME_TO_TAG = {v: k for k, v in self.TAG_TO_NAME.items()}
164 self.inf(f'{tag}', self.bindesc_repr(value))
177 self.inf(self.bindesc_repr(value))
[all …]
A Dbuild.py70 def __init__(self): argument
102 self.name,
241 if (self.args.cmake or self.args.cmake_opts or
242 self.args.cmake_only or self.args.snippets or
249 self.source_dir = self._find_source_dir()
267 self._run_cmake(board, origin, self.args.cmake_opts)
273 self.domains = load_domains(self.build_dir)
500 self.die('build directory', self.build_dir,
508 if self.source_dir == self.build_dir:
577 or self.args.board or self.config_board or
[all …]
/scripts/kconfig/
A Dkconfiglib.py1007 self.n = self.const_syms["n"]
1008 self.m = self.const_syms["m"]
1009 self.y = self.const_syms["y"]
1047 self.top_node.kconfig = self
1053 self.top_node.dep = self.y
1098 self._finalize_node(self.top_node, self.y)
2172 self._filestack.append((self._include_path, self._readline))
2176 self._include_path += ((self.filename, self.linenr),)
2207 self.filename, self.linenr = self._include_path[-1]
2210 self._include_path, self._readline = self._filestack.pop()
[all …]
/scripts/pylib/power-twister-harness/stm32l562e_dk/
A DSerialHandler.py19 self.port = port
20 self.baudrate = baudrate
21 self.timeout = timeout
24 def open(self): argument
31 self.port, self.baudrate, timeout=self.timeout
41 def close(self): argument
43 if self.serial_connection and self.serial_connection.is_open:
53 if self.serial_connection and self.serial_connection.is_open:
71 if self.serial_connection and self.serial_connection.is_open:
78 def is_open(self) -> bool: argument
[all …]

Completed in 160 milliseconds

12345678