system.hardware.tici package

Submodules

system.hardware.tici.agnos module

class system.hardware.tici.agnos.StreamingDecompressor(url: str)[source]

Bases: object

read(length: int) bytes[source]
system.hardware.tici.agnos.clear_partition_hash(target_slot_number: int, partition: dict) None[source]
system.hardware.tici.agnos.extract_casync_image(target_slot_number: int, partition: dict, cloudlog)[source]
system.hardware.tici.agnos.extract_compressed_image(target_slot_number: int, partition: dict, cloudlog)[source]
system.hardware.tici.agnos.flash_agnos_update(manifest_path: str, target_slot_number: int, cloudlog, standalone=False) None[source]
system.hardware.tici.agnos.flash_partition(target_slot_number: int, partition: dict, cloudlog, standalone=False)[source]
system.hardware.tici.agnos.get_partition_path(target_slot_number: int, partition: dict) str[source]
system.hardware.tici.agnos.get_raw_hash(path: str, partition_size: int) str[source]
system.hardware.tici.agnos.get_target_slot_number() int[source]
system.hardware.tici.agnos.noop(f: StreamingDecompressor) Generator[bytes, None, None][source]
system.hardware.tici.agnos.slot_number_to_suffix(slot_number: int) str[source]
system.hardware.tici.agnos.swap(manifest_path: str, target_slot_number: int, cloudlog) None[source]
system.hardware.tici.agnos.unsparsify(f: StreamingDecompressor) Generator[bytes, None, None][source]
system.hardware.tici.agnos.verify_agnos_update(manifest_path: str, target_slot_number: int) bool[source]
system.hardware.tici.agnos.verify_partition(target_slot_number: int, partition: Dict[str, Union[str, int]], force_full_check: bool = False) bool[source]

system.hardware.tici.amplifier module

class system.hardware.tici.amplifier.AmpConfig(name, value, register, offset, mask)

Bases: tuple

mask

Alias for field number 4

name

Alias for field number 0

offset

Alias for field number 3

register

Alias for field number 2

value

Alias for field number 1

class system.hardware.tici.amplifier.Amplifier(debug=False)[source]

Bases: object

AMP_ADDRESS = 16
AMP_I2C_BUS = 0
initialize_configuration()[source]
set_config(config)[source]
set_global_shutdown(amp_disabled)[source]
class system.hardware.tici.amplifier.EQParams(K, k1, k2, c1, c2)

Bases: tuple

K

Alias for field number 0

c1

Alias for field number 3

c2

Alias for field number 4

k1

Alias for field number 1

k2

Alias for field number 2

system.hardware.tici.amplifier.configs_from_eq_params(base, eq_params)[source]

system.hardware.tici.casync module

class system.hardware.tici.casync.Chunk(sha, offset, length)

Bases: tuple

length

Alias for field number 2

offset

Alias for field number 1

sha

Alias for field number 0

class system.hardware.tici.casync.ChunkReader[source]

Bases: ABC

abstract read(chunk: Chunk) bytes[source]
class system.hardware.tici.casync.FileChunkReader(fn: str)[source]

Bases: ChunkReader

Reads chunks from a local file

read(chunk: Chunk) bytes[source]
class system.hardware.tici.casync.RemoteChunkReader(url: str)[source]

Bases: ChunkReader

Reads lzma compressed chunks from a remote store

read(chunk: Chunk) bytes[source]
system.hardware.tici.casync.build_chunk_dict(chunks: List[Chunk]) Dict[bytes, Chunk][source]

Turn a list of chunks into a dict for faster lookups based on hash. Keep first chunk since it’s more likely to be already downloaded.

system.hardware.tici.casync.extract(target: List[Chunk], sources: List[Tuple[str, ChunkReader, Dict[bytes, Chunk]]], out_path: str, progress: Optional[Callable[[int], None]] = None)[source]
system.hardware.tici.casync.extract_simple(caibx_path, out_path, store_path)[source]
system.hardware.tici.casync.parse_caibx(caibx_path: str) List[Chunk][source]

Parses the chunks from a caibx file. Can handle both local and remote files. Returns a list of chunks with hash, offset and length

system.hardware.tici.casync.print_stats(stats: Dict[str, int])[source]

system.hardware.tici.hardware module

class system.hardware.tici.hardware.MM_MODEM_STATE(value)[source]

Bases: IntEnum

An enumeration.

CONNECTED = 11
CONNECTING = 10
DISABLED = 3
DISABLING = 4
DISCONNECTING = 9
ENABLED = 6
ENABLING = 5
FAILED = -1
INITIALIZING = 1
LOCKED = 2
REGISTERED = 8
SEARCHING = 7
UNKNOWN = 0
class system.hardware.tici.hardware.NMMetered(value)[source]

Bases: IntEnum

An enumeration.

NM_METERED_GUESS_NO = 4
NM_METERED_GUESS_YES = 3
NM_METERED_NO = 2
NM_METERED_UNKNOWN = 0
NM_METERED_YES = 1
class system.hardware.tici.hardware.Tici[source]

Bases: HardwareBase

property amplifier
property bus
configure_modem()[source]
get_current_power_draw()[source]
get_device_type()[source]
get_gpu_usage_percent()[source]
get_imei(slot)[source]
get_modem()[source]
get_modem_data_usage()[source]
get_modem_nv()[source]
get_modem_temperatures()[source]
get_modem_version()[source]
get_network_info()[source]
get_network_metered(network_type) bool[source]
get_network_strength(network_type)[source]
get_network_type()[source]
get_networks()[source]
get_nvme_temperatures()[source]
get_os_version()[source]
get_screen_brightness()[source]
get_serial()[source]
get_sim_info()[source]
get_som_power_draw()[source]
get_sound_card_online()[source]
get_subscriber_info()[source]
get_thermal_config()[source]
get_usb_present()[source]
get_wlan()[source]
get_wwan()[source]
initialize_hardware()[source]
property mm
property nm
parse_strength(percentage)[source]
reboot(reason=None)[source]
recover_internal_panda()[source]
reset_internal_panda()[source]
static set_bandwidth_limit(upload_speed_kbps: int, download_speed_kbps: int) None[source]
set_power_save(powersave_enabled)[source]
set_screen_brightness(percentage)[source]
shutdown()[source]
uninstall()[source]
system.hardware.tici.hardware.affine_irq(val, irq)[source]
system.hardware.tici.hardware.sudo_write(val, path)[source]

system.hardware.tici.iwlist module

system.hardware.tici.iwlist.scan(interface='wlan0')[source]

system.hardware.tici.pins module

class system.hardware.tici.pins.GPIO[source]

Bases: object

BMX055_ACCEL_INT = 21
BMX055_GYRO_INT = 23
BMX055_MAGN_INT = 87
CAM0_AVDD_EN = 8
CAM0_RSTN = 9
CAM1_RSTN = 7
CAM2_RSTN = 12
HUB_RST_N = 30
LSM_INT = 84
LTE_BOOT = 52
LTE_PWRKEY = 116
LTE_RST_N = 50
STM_BOOT0 = 134
STM_RST_N = 124
UBLOX_PWR_EN = 34
UBLOX_RST_N = 32
UBLOX_SAFEBOOT_N = 33

system.hardware.tici.power_draw_test module

system.hardware.tici.power_draw_test.gpio_export(pin)[source]
system.hardware.tici.power_draw_test.read_power()[source]
system.hardware.tici.power_draw_test.read_power_avg()[source]

system.hardware.tici.power_monitor module

system.hardware.tici.power_monitor.get_power(seconds=5)[source]
system.hardware.tici.power_monitor.read_power()[source]
system.hardware.tici.power_monitor.sample_power(seconds=5) List[float][source]

system.hardware.tici.precise_power_measure module

system.hardware.tici.test_agnos_updater module

class system.hardware.tici.test_agnos_updater.TestAgnosUpdater(methodName='runTest')[source]

Bases: TestCase

test_manifest()[source]

system.hardware.tici.test_power_draw module

class system.hardware.tici.test_power_draw.Proc(name: str, power: float, rtol: float = 0.05, atol: float = 0.1, warmup: float = 6.0)[source]

Bases: object

atol: float = 0.1
name: str
power: float
rtol: float = 0.05
warmup: float = 6.0
class system.hardware.tici.test_power_draw.TestPowerDraw(methodName='runTest')[source]

Bases: TestCase

setUp()[source]

Hook method for setting up the test fixture before exercising it.

classmethod setUpClass()[source]

Hook method for setting up class fixture before running tests in the class.

tearDown()[source]

Hook method for deconstructing the test fixture after testing it.

test_camera_procs()[source]

Module contents