Compare commits

...

2 Commits

Author SHA1 Message Date
github-actions
fee2b6ccbd Update protobufs 2026-02-14 16:48:14 +00:00
Ben Meadors
d0ccb1a597 Update protobufs GH action 2026-02-14 10:47:14 -06:00
13 changed files with 859 additions and 130 deletions

206
.github/copilot-instructions.md vendored Normal file
View File

@@ -0,0 +1,206 @@
# Copilot Instructions for Meshtastic Python
## Project Overview
This is the Meshtastic Python library and CLI - a Python API for interacting with Meshtastic mesh radio devices. It supports communication via Serial, TCP, and BLE interfaces.
## Technology Stack
- **Language**: Python 3.9 - 3.14
- **Package Manager**: Poetry
- **Testing**: pytest with hypothesis for property-based testing
- **Linting**: pylint
- **Type Checking**: mypy (working toward strict mode)
- **Documentation**: pdoc3
- **License**: GPL-3.0
## Project Structure
```
meshtastic/ # Main library package
├── __init__.py # Core interface classes and pub/sub topics
├── __main__.py # CLI entry point
├── mesh_interface.py # Base interface class for all connection types
├── serial_interface.py
├── tcp_interface.py
├── ble_interface.py
├── node.py # Node representation and configuration
├── protobuf/ # Generated Protocol Buffer files (*_pb2.py, *_pb2.pyi)
├── tests/ # Unit and integration tests
├── powermon/ # Power monitoring tools
└── analysis/ # Data analysis tools
examples/ # Usage examples
protobufs/ # Protocol Buffer source definitions
```
## Coding Standards
### Style Guidelines
- Follow PEP 8 style conventions
- Use type hints for function parameters and return values
- Document public functions and classes with docstrings
- Prefer explicit imports over wildcard imports
- Use `logging` module instead of print statements for debug output
### Type Annotations
- Add type hints to all new code
- Use `Optional[T]` for nullable types
- Use `Dict`, `List`, `Tuple` from `typing` module for Python 3.9 compatibility
- Protobuf types are in `meshtastic.protobuf.*_pb2` modules
### Naming Conventions
- Classes: `PascalCase` (e.g., `MeshInterface`, `SerialInterface`)
- Functions/methods: `camelCase` for public API (e.g., `sendText`, `sendData`)
- Internal functions: `snake_case` with leading underscore (e.g., `_send_packet`)
- Constants: `UPPER_SNAKE_CASE` (e.g., `BROADCAST_ADDR`, `LOCAL_ADDR`)
### Error Handling
- Use custom exception classes when appropriate (e.g., `MeshInterface.MeshInterfaceError`)
- Provide meaningful error messages
- Use `our_exit()` from `meshtastic.util` for CLI exits with error codes
## Testing
### Test Organization
Tests are in `meshtastic/tests/` and use pytest markers:
- `@pytest.mark.unit` - Fast unit tests (default)
- `@pytest.mark.unitslow` - Slower unit tests
- `@pytest.mark.int` - Integration tests
- `@pytest.mark.smoke1` - Single device smoke tests
- `@pytest.mark.smoke2` - Two device smoke tests
- `@pytest.mark.smokevirt` - Virtual device smoke tests
- `@pytest.mark.examples` - Example validation tests
### Running Tests
```bash
# Run unit tests only (default)
make test
# or
pytest -m unit
# Run all tests
pytest
# Run with coverage
make cov
```
### Writing Tests
- Use `pytest` fixtures from `conftest.py`
- Use `hypothesis` for property-based testing where appropriate
- Mock external dependencies (serial ports, network connections)
- Test file naming: `test_<module_name>.py`
## Pub/Sub Events
The library uses pypubsub for event handling. Key topics:
- `meshtastic.connection.established` - Connection successful
- `meshtastic.connection.lost` - Connection lost
- `meshtastic.receive.text(packet)` - Text message received
- `meshtastic.receive.position(packet)` - Position update received
- `meshtastic.receive.data.portnum(packet)` - Data packet by port number
- `meshtastic.node.updated(node)` - Node database changed
- `meshtastic.log.line(line)` - Raw log line from device
## Protocol Buffers
- Protobuf definitions are in `protobufs/meshtastic/`
- Generated Python files are in `meshtastic/protobuf/`
- Never edit `*_pb2.py` or `*_pb2.pyi` files directly
- Regenerate with: `make protobufs` or `./bin/regen-protobufs.sh`
## Common Patterns
### Creating an Interface
```python
import meshtastic.serial_interface
# Auto-detect device
iface = meshtastic.serial_interface.SerialInterface()
# Specific device
iface = meshtastic.serial_interface.SerialInterface(devPath="/dev/ttyUSB0")
# Always close when done
iface.close()
# Or use context manager
with meshtastic.serial_interface.SerialInterface() as iface:
iface.sendText("Hello mesh")
```
### Sending Messages
```python
# Text message (broadcast)
iface.sendText("Hello")
# Text message to specific node
iface.sendText("Hello", destinationId="!abcd1234")
# Binary data
iface.sendData(data, portNum=portnums_pb2.PRIVATE_APP)
```
### Subscribing to Events
```python
from pubsub import pub
def on_receive(packet, interface):
print(f"Received: {packet}")
pub.subscribe(on_receive, "meshtastic.receive")
```
## Development Workflow
1. Install dependencies: `poetry install --all-extras --with dev`
2. Make changes
3. Run linting: `poetry run pylint meshtastic examples/`
4. Run type checking: `poetry run mypy meshtastic/`
5. Run tests: `poetry run pytest -m unit`
6. Update documentation if needed
## CLI Development
The CLI is in `meshtastic/__main__.py`. When adding new CLI commands:
- Use argparse for argument parsing
- Support `--dest` for specifying target node
- Provide `--help` documentation
- Handle errors gracefully with meaningful messages
## Dependencies
### Required
- `pyserial` - Serial port communication
- `protobuf` - Protocol Buffers
- `pypubsub` - Pub/sub messaging
- `bleak` - BLE communication
- `tabulate` - Table formatting
- `pyyaml` - YAML config support
- `requests` - HTTP requests
### Optional (extras)
- `cli` extra: `pyqrcode`, `print-color`, `dotmap`, `argcomplete`
- `tunnel` extra: `pytap2`
- `analysis` extra: `dash`, `pandas`
## Important Notes
- Always test with actual Meshtastic hardware when possible
- Be mindful of radio regulations in your region
- The nodedb (`interface.nodes`) is read-only
- Packet IDs are random 32-bit integers
- Default timeout is 300 seconds for operations

View File

@@ -1,6 +1,9 @@
name: "Update protobufs" name: "Update protobufs"
on: workflow_dispatch on: workflow_dispatch
permissions:
contents: write
jobs: jobs:
update-protobufs: update-protobufs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@@ -9,23 +12,34 @@ jobs:
- name: Checkout code - name: Checkout code
uses: actions/checkout@v4 uses: actions/checkout@v4
with: with:
fetch-depth: 0
submodules: true submodules: true
- name: Update Submodule - name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install Poetry
run: | run: |
git pull --recurse-submodules python -m pip install --upgrade pip
python -m pip install poetry
- name: Update protobuf submodule
run: |
git submodule sync --recursive
git submodule update --init --recursive
git submodule update --remote --recursive git submodule update --remote --recursive
- name: Download nanopb - name: Download nanopb
run: | run: |
wget https://jpa.kapsi.fi/nanopb/download/nanopb-0.4.8-linux-x86.tar.gz curl -L -o nanopb-0.4.8-linux-x86.tar.gz https://jpa.kapsi.fi/nanopb/download/nanopb-0.4.8-linux-x86.tar.gz
tar xvzf nanopb-0.4.8-linux-x86.tar.gz tar xvzf nanopb-0.4.8-linux-x86.tar.gz
mv nanopb-0.4.8-linux-x86 nanopb-0.4.8 mv nanopb-0.4.8-linux-x86 nanopb-0.4.8
- name: Install poetry (needed by regen-protobufs.sh) - name: Install Python dependencies
run: | run: |
python -m pip install --upgrade pip poetry install --with dev
pip3 install poetry
- name: Re-generate protocol buffers - name: Re-generate protocol buffers
run: | run: |
@@ -38,4 +52,9 @@ jobs:
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }} git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
git add protobufs git add protobufs
git add meshtastic/protobuf git add meshtastic/protobuf
git commit -m "Update protobuf submodule" && git push || echo "No changes to commit" if [[ -n "$(git status --porcelain)" ]]; then
git commit -m "Update protobufs"
git push
else
echo "No changes to commit"
fi

View File

File diff suppressed because one or more lines are too long

View File

@@ -228,6 +228,10 @@ class AdminMessage(google.protobuf.message.Message):
""" """
TODO: REPLACE TODO: REPLACE
""" """
TRAFFICMANAGEMENT_CONFIG: AdminMessage._ModuleConfigType.ValueType # 14
"""
Traffic management module config
"""
class ModuleConfigType(_ModuleConfigType, metaclass=_ModuleConfigTypeEnumTypeWrapper): class ModuleConfigType(_ModuleConfigType, metaclass=_ModuleConfigTypeEnumTypeWrapper):
""" """
@@ -290,6 +294,10 @@ class AdminMessage(google.protobuf.message.Message):
""" """
TODO: REPLACE TODO: REPLACE
""" """
TRAFFICMANAGEMENT_CONFIG: AdminMessage.ModuleConfigType.ValueType # 14
"""
Traffic management module config
"""
class _BackupLocation: class _BackupLocation:
ValueType = typing.NewType("ValueType", builtins.int) ValueType = typing.NewType("ValueType", builtins.int)
@@ -439,6 +447,7 @@ class AdminMessage(google.protobuf.message.Message):
FACTORY_RESET_CONFIG_FIELD_NUMBER: builtins.int FACTORY_RESET_CONFIG_FIELD_NUMBER: builtins.int
NODEDB_RESET_FIELD_NUMBER: builtins.int NODEDB_RESET_FIELD_NUMBER: builtins.int
OTA_REQUEST_FIELD_NUMBER: builtins.int OTA_REQUEST_FIELD_NUMBER: builtins.int
SENSOR_CONFIG_FIELD_NUMBER: builtins.int
session_passkey: builtins.bytes session_passkey: builtins.bytes
""" """
The node generates this key and sends it with any get_x_response packets. The node generates this key and sends it with any get_x_response packets.
@@ -720,6 +729,12 @@ class AdminMessage(google.protobuf.message.Message):
Tell the node to reset into the OTA Loader Tell the node to reset into the OTA Loader
""" """
@property
def sensor_config(self) -> global___SensorConfig:
"""
Parameters and sensor configuration
"""
def __init__( def __init__(
self, self,
*, *,
@@ -780,10 +795,11 @@ class AdminMessage(google.protobuf.message.Message):
factory_reset_config: builtins.int = ..., factory_reset_config: builtins.int = ...,
nodedb_reset: builtins.bool = ..., nodedb_reset: builtins.bool = ...,
ota_request: global___AdminMessage.OTAEvent | None = ..., ota_request: global___AdminMessage.OTAEvent | None = ...,
sensor_config: global___SensorConfig | None = ...,
) -> None: ... ) -> None: ...
def HasField(self, field_name: typing.Literal["add_contact", b"add_contact", "backup_preferences", b"backup_preferences", "begin_edit_settings", b"begin_edit_settings", "commit_edit_settings", b"commit_edit_settings", "delete_file_request", b"delete_file_request", "enter_dfu_mode_request", b"enter_dfu_mode_request", "exit_simulator", b"exit_simulator", "factory_reset_config", b"factory_reset_config", "factory_reset_device", b"factory_reset_device", "get_canned_message_module_messages_request", b"get_canned_message_module_messages_request", "get_canned_message_module_messages_response", b"get_canned_message_module_messages_response", "get_channel_request", b"get_channel_request", "get_channel_response", b"get_channel_response", "get_config_request", b"get_config_request", "get_config_response", b"get_config_response", "get_device_connection_status_request", b"get_device_connection_status_request", "get_device_connection_status_response", b"get_device_connection_status_response", "get_device_metadata_request", b"get_device_metadata_request", "get_device_metadata_response", b"get_device_metadata_response", "get_module_config_request", b"get_module_config_request", "get_module_config_response", b"get_module_config_response", "get_node_remote_hardware_pins_request", b"get_node_remote_hardware_pins_request", "get_node_remote_hardware_pins_response", b"get_node_remote_hardware_pins_response", "get_owner_request", b"get_owner_request", "get_owner_response", b"get_owner_response", "get_ringtone_request", b"get_ringtone_request", "get_ringtone_response", b"get_ringtone_response", "get_ui_config_request", b"get_ui_config_request", "get_ui_config_response", b"get_ui_config_response", "key_verification", b"key_verification", "nodedb_reset", b"nodedb_reset", "ota_request", b"ota_request", "payload_variant", b"payload_variant", "reboot_ota_seconds", b"reboot_ota_seconds", "reboot_seconds", b"reboot_seconds", "remove_backup_preferences", b"remove_backup_preferences", "remove_by_nodenum", b"remove_by_nodenum", "remove_favorite_node", b"remove_favorite_node", "remove_fixed_position", b"remove_fixed_position", "remove_ignored_node", b"remove_ignored_node", "restore_preferences", b"restore_preferences", "send_input_event", b"send_input_event", "set_canned_message_module_messages", b"set_canned_message_module_messages", "set_channel", b"set_channel", "set_config", b"set_config", "set_favorite_node", b"set_favorite_node", "set_fixed_position", b"set_fixed_position", "set_ham_mode", b"set_ham_mode", "set_ignored_node", b"set_ignored_node", "set_module_config", b"set_module_config", "set_owner", b"set_owner", "set_ringtone_message", b"set_ringtone_message", "set_scale", b"set_scale", "set_time_only", b"set_time_only", "shutdown_seconds", b"shutdown_seconds", "store_ui_config", b"store_ui_config", "toggle_muted_node", b"toggle_muted_node"]) -> builtins.bool: ... def HasField(self, field_name: typing.Literal["add_contact", b"add_contact", "backup_preferences", b"backup_preferences", "begin_edit_settings", b"begin_edit_settings", "commit_edit_settings", b"commit_edit_settings", "delete_file_request", b"delete_file_request", "enter_dfu_mode_request", b"enter_dfu_mode_request", "exit_simulator", b"exit_simulator", "factory_reset_config", b"factory_reset_config", "factory_reset_device", b"factory_reset_device", "get_canned_message_module_messages_request", b"get_canned_message_module_messages_request", "get_canned_message_module_messages_response", b"get_canned_message_module_messages_response", "get_channel_request", b"get_channel_request", "get_channel_response", b"get_channel_response", "get_config_request", b"get_config_request", "get_config_response", b"get_config_response", "get_device_connection_status_request", b"get_device_connection_status_request", "get_device_connection_status_response", b"get_device_connection_status_response", "get_device_metadata_request", b"get_device_metadata_request", "get_device_metadata_response", b"get_device_metadata_response", "get_module_config_request", b"get_module_config_request", "get_module_config_response", b"get_module_config_response", "get_node_remote_hardware_pins_request", b"get_node_remote_hardware_pins_request", "get_node_remote_hardware_pins_response", b"get_node_remote_hardware_pins_response", "get_owner_request", b"get_owner_request", "get_owner_response", b"get_owner_response", "get_ringtone_request", b"get_ringtone_request", "get_ringtone_response", b"get_ringtone_response", "get_ui_config_request", b"get_ui_config_request", "get_ui_config_response", b"get_ui_config_response", "key_verification", b"key_verification", "nodedb_reset", b"nodedb_reset", "ota_request", b"ota_request", "payload_variant", b"payload_variant", "reboot_ota_seconds", b"reboot_ota_seconds", "reboot_seconds", b"reboot_seconds", "remove_backup_preferences", b"remove_backup_preferences", "remove_by_nodenum", b"remove_by_nodenum", "remove_favorite_node", b"remove_favorite_node", "remove_fixed_position", b"remove_fixed_position", "remove_ignored_node", b"remove_ignored_node", "restore_preferences", b"restore_preferences", "send_input_event", b"send_input_event", "sensor_config", b"sensor_config", "set_canned_message_module_messages", b"set_canned_message_module_messages", "set_channel", b"set_channel", "set_config", b"set_config", "set_favorite_node", b"set_favorite_node", "set_fixed_position", b"set_fixed_position", "set_ham_mode", b"set_ham_mode", "set_ignored_node", b"set_ignored_node", "set_module_config", b"set_module_config", "set_owner", b"set_owner", "set_ringtone_message", b"set_ringtone_message", "set_scale", b"set_scale", "set_time_only", b"set_time_only", "shutdown_seconds", b"shutdown_seconds", "store_ui_config", b"store_ui_config", "toggle_muted_node", b"toggle_muted_node"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["add_contact", b"add_contact", "backup_preferences", b"backup_preferences", "begin_edit_settings", b"begin_edit_settings", "commit_edit_settings", b"commit_edit_settings", "delete_file_request", b"delete_file_request", "enter_dfu_mode_request", b"enter_dfu_mode_request", "exit_simulator", b"exit_simulator", "factory_reset_config", b"factory_reset_config", "factory_reset_device", b"factory_reset_device", "get_canned_message_module_messages_request", b"get_canned_message_module_messages_request", "get_canned_message_module_messages_response", b"get_canned_message_module_messages_response", "get_channel_request", b"get_channel_request", "get_channel_response", b"get_channel_response", "get_config_request", b"get_config_request", "get_config_response", b"get_config_response", "get_device_connection_status_request", b"get_device_connection_status_request", "get_device_connection_status_response", b"get_device_connection_status_response", "get_device_metadata_request", b"get_device_metadata_request", "get_device_metadata_response", b"get_device_metadata_response", "get_module_config_request", b"get_module_config_request", "get_module_config_response", b"get_module_config_response", "get_node_remote_hardware_pins_request", b"get_node_remote_hardware_pins_request", "get_node_remote_hardware_pins_response", b"get_node_remote_hardware_pins_response", "get_owner_request", b"get_owner_request", "get_owner_response", b"get_owner_response", "get_ringtone_request", b"get_ringtone_request", "get_ringtone_response", b"get_ringtone_response", "get_ui_config_request", b"get_ui_config_request", "get_ui_config_response", b"get_ui_config_response", "key_verification", b"key_verification", "nodedb_reset", b"nodedb_reset", "ota_request", b"ota_request", "payload_variant", b"payload_variant", "reboot_ota_seconds", b"reboot_ota_seconds", "reboot_seconds", b"reboot_seconds", "remove_backup_preferences", b"remove_backup_preferences", "remove_by_nodenum", b"remove_by_nodenum", "remove_favorite_node", b"remove_favorite_node", "remove_fixed_position", b"remove_fixed_position", "remove_ignored_node", b"remove_ignored_node", "restore_preferences", b"restore_preferences", "send_input_event", b"send_input_event", "session_passkey", b"session_passkey", "set_canned_message_module_messages", b"set_canned_message_module_messages", "set_channel", b"set_channel", "set_config", b"set_config", "set_favorite_node", b"set_favorite_node", "set_fixed_position", b"set_fixed_position", "set_ham_mode", b"set_ham_mode", "set_ignored_node", b"set_ignored_node", "set_module_config", b"set_module_config", "set_owner", b"set_owner", "set_ringtone_message", b"set_ringtone_message", "set_scale", b"set_scale", "set_time_only", b"set_time_only", "shutdown_seconds", b"shutdown_seconds", "store_ui_config", b"store_ui_config", "toggle_muted_node", b"toggle_muted_node"]) -> None: ... def ClearField(self, field_name: typing.Literal["add_contact", b"add_contact", "backup_preferences", b"backup_preferences", "begin_edit_settings", b"begin_edit_settings", "commit_edit_settings", b"commit_edit_settings", "delete_file_request", b"delete_file_request", "enter_dfu_mode_request", b"enter_dfu_mode_request", "exit_simulator", b"exit_simulator", "factory_reset_config", b"factory_reset_config", "factory_reset_device", b"factory_reset_device", "get_canned_message_module_messages_request", b"get_canned_message_module_messages_request", "get_canned_message_module_messages_response", b"get_canned_message_module_messages_response", "get_channel_request", b"get_channel_request", "get_channel_response", b"get_channel_response", "get_config_request", b"get_config_request", "get_config_response", b"get_config_response", "get_device_connection_status_request", b"get_device_connection_status_request", "get_device_connection_status_response", b"get_device_connection_status_response", "get_device_metadata_request", b"get_device_metadata_request", "get_device_metadata_response", b"get_device_metadata_response", "get_module_config_request", b"get_module_config_request", "get_module_config_response", b"get_module_config_response", "get_node_remote_hardware_pins_request", b"get_node_remote_hardware_pins_request", "get_node_remote_hardware_pins_response", b"get_node_remote_hardware_pins_response", "get_owner_request", b"get_owner_request", "get_owner_response", b"get_owner_response", "get_ringtone_request", b"get_ringtone_request", "get_ringtone_response", b"get_ringtone_response", "get_ui_config_request", b"get_ui_config_request", "get_ui_config_response", b"get_ui_config_response", "key_verification", b"key_verification", "nodedb_reset", b"nodedb_reset", "ota_request", b"ota_request", "payload_variant", b"payload_variant", "reboot_ota_seconds", b"reboot_ota_seconds", "reboot_seconds", b"reboot_seconds", "remove_backup_preferences", b"remove_backup_preferences", "remove_by_nodenum", b"remove_by_nodenum", "remove_favorite_node", b"remove_favorite_node", "remove_fixed_position", b"remove_fixed_position", "remove_ignored_node", b"remove_ignored_node", "restore_preferences", b"restore_preferences", "send_input_event", b"send_input_event", "sensor_config", b"sensor_config", "session_passkey", b"session_passkey", "set_canned_message_module_messages", b"set_canned_message_module_messages", "set_channel", b"set_channel", "set_config", b"set_config", "set_favorite_node", b"set_favorite_node", "set_fixed_position", b"set_fixed_position", "set_ham_mode", b"set_ham_mode", "set_ignored_node", b"set_ignored_node", "set_module_config", b"set_module_config", "set_owner", b"set_owner", "set_ringtone_message", b"set_ringtone_message", "set_scale", b"set_scale", "set_time_only", b"set_time_only", "shutdown_seconds", b"shutdown_seconds", "store_ui_config", b"store_ui_config", "toggle_muted_node", b"toggle_muted_node"]) -> None: ...
def WhichOneof(self, oneof_group: typing.Literal["payload_variant", b"payload_variant"]) -> typing.Literal["get_channel_request", "get_channel_response", "get_owner_request", "get_owner_response", "get_config_request", "get_config_response", "get_module_config_request", "get_module_config_response", "get_canned_message_module_messages_request", "get_canned_message_module_messages_response", "get_device_metadata_request", "get_device_metadata_response", "get_ringtone_request", "get_ringtone_response", "get_device_connection_status_request", "get_device_connection_status_response", "set_ham_mode", "get_node_remote_hardware_pins_request", "get_node_remote_hardware_pins_response", "enter_dfu_mode_request", "delete_file_request", "set_scale", "backup_preferences", "restore_preferences", "remove_backup_preferences", "send_input_event", "set_owner", "set_channel", "set_config", "set_module_config", "set_canned_message_module_messages", "set_ringtone_message", "remove_by_nodenum", "set_favorite_node", "remove_favorite_node", "set_fixed_position", "remove_fixed_position", "set_time_only", "get_ui_config_request", "get_ui_config_response", "store_ui_config", "set_ignored_node", "remove_ignored_node", "toggle_muted_node", "begin_edit_settings", "commit_edit_settings", "add_contact", "key_verification", "factory_reset_device", "reboot_ota_seconds", "exit_simulator", "reboot_seconds", "shutdown_seconds", "factory_reset_config", "nodedb_reset", "ota_request"] | None: ... def WhichOneof(self, oneof_group: typing.Literal["payload_variant", b"payload_variant"]) -> typing.Literal["get_channel_request", "get_channel_response", "get_owner_request", "get_owner_response", "get_config_request", "get_config_response", "get_module_config_request", "get_module_config_response", "get_canned_message_module_messages_request", "get_canned_message_module_messages_response", "get_device_metadata_request", "get_device_metadata_response", "get_ringtone_request", "get_ringtone_response", "get_device_connection_status_request", "get_device_connection_status_response", "set_ham_mode", "get_node_remote_hardware_pins_request", "get_node_remote_hardware_pins_response", "enter_dfu_mode_request", "delete_file_request", "set_scale", "backup_preferences", "restore_preferences", "remove_backup_preferences", "send_input_event", "set_owner", "set_channel", "set_config", "set_module_config", "set_canned_message_module_messages", "set_ringtone_message", "remove_by_nodenum", "set_favorite_node", "remove_favorite_node", "set_fixed_position", "remove_fixed_position", "set_time_only", "get_ui_config_request", "get_ui_config_response", "store_ui_config", "set_ignored_node", "remove_ignored_node", "toggle_muted_node", "begin_edit_settings", "commit_edit_settings", "add_contact", "key_verification", "factory_reset_device", "reboot_ota_seconds", "exit_simulator", "reboot_seconds", "shutdown_seconds", "factory_reset_config", "nodedb_reset", "ota_request", "sensor_config"] | None: ...
global___AdminMessage = AdminMessage global___AdminMessage = AdminMessage
@@ -977,3 +993,199 @@ class KeyVerificationAdmin(google.protobuf.message.Message):
def WhichOneof(self, oneof_group: typing.Literal["_security_number", b"_security_number"]) -> typing.Literal["security_number"] | None: ... def WhichOneof(self, oneof_group: typing.Literal["_security_number", b"_security_number"]) -> typing.Literal["security_number"] | None: ...
global___KeyVerificationAdmin = KeyVerificationAdmin global___KeyVerificationAdmin = KeyVerificationAdmin
@typing.final
class SensorConfig(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
SCD4X_CONFIG_FIELD_NUMBER: builtins.int
SEN5X_CONFIG_FIELD_NUMBER: builtins.int
SCD30_CONFIG_FIELD_NUMBER: builtins.int
@property
def scd4x_config(self) -> global___SCD4X_config:
"""
SCD4X CO2 Sensor configuration
"""
@property
def sen5x_config(self) -> global___SEN5X_config:
"""
SEN5X PM Sensor configuration
"""
@property
def scd30_config(self) -> global___SCD30_config:
"""
SCD30 CO2 Sensor configuration
"""
def __init__(
self,
*,
scd4x_config: global___SCD4X_config | None = ...,
sen5x_config: global___SEN5X_config | None = ...,
scd30_config: global___SCD30_config | None = ...,
) -> None: ...
def HasField(self, field_name: typing.Literal["scd30_config", b"scd30_config", "scd4x_config", b"scd4x_config", "sen5x_config", b"sen5x_config"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["scd30_config", b"scd30_config", "scd4x_config", b"scd4x_config", "sen5x_config", b"sen5x_config"]) -> None: ...
global___SensorConfig = SensorConfig
@typing.final
class SCD4X_config(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
SET_ASC_FIELD_NUMBER: builtins.int
SET_TARGET_CO2_CONC_FIELD_NUMBER: builtins.int
SET_TEMPERATURE_FIELD_NUMBER: builtins.int
SET_ALTITUDE_FIELD_NUMBER: builtins.int
SET_AMBIENT_PRESSURE_FIELD_NUMBER: builtins.int
FACTORY_RESET_FIELD_NUMBER: builtins.int
SET_POWER_MODE_FIELD_NUMBER: builtins.int
set_asc: builtins.bool
"""
Set Automatic self-calibration enabled
"""
set_target_co2_conc: builtins.int
"""
Recalibration target CO2 concentration in ppm (FRC or ASC)
"""
set_temperature: builtins.float
"""
Reference temperature in degC
"""
set_altitude: builtins.int
"""
Altitude of sensor in meters above sea level. 0 - 3000m (overrides ambient pressure)
"""
set_ambient_pressure: builtins.int
"""
Sensor ambient pressure in Pa. 70000 - 120000 Pa (overrides altitude)
"""
factory_reset: builtins.bool
"""
Perform a factory reset of the sensor
"""
set_power_mode: builtins.bool
"""
Power mode for sensor (true for low power, false for normal)
"""
def __init__(
self,
*,
set_asc: builtins.bool | None = ...,
set_target_co2_conc: builtins.int | None = ...,
set_temperature: builtins.float | None = ...,
set_altitude: builtins.int | None = ...,
set_ambient_pressure: builtins.int | None = ...,
factory_reset: builtins.bool | None = ...,
set_power_mode: builtins.bool | None = ...,
) -> None: ...
def HasField(self, field_name: typing.Literal["_factory_reset", b"_factory_reset", "_set_altitude", b"_set_altitude", "_set_ambient_pressure", b"_set_ambient_pressure", "_set_asc", b"_set_asc", "_set_power_mode", b"_set_power_mode", "_set_target_co2_conc", b"_set_target_co2_conc", "_set_temperature", b"_set_temperature", "factory_reset", b"factory_reset", "set_altitude", b"set_altitude", "set_ambient_pressure", b"set_ambient_pressure", "set_asc", b"set_asc", "set_power_mode", b"set_power_mode", "set_target_co2_conc", b"set_target_co2_conc", "set_temperature", b"set_temperature"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["_factory_reset", b"_factory_reset", "_set_altitude", b"_set_altitude", "_set_ambient_pressure", b"_set_ambient_pressure", "_set_asc", b"_set_asc", "_set_power_mode", b"_set_power_mode", "_set_target_co2_conc", b"_set_target_co2_conc", "_set_temperature", b"_set_temperature", "factory_reset", b"factory_reset", "set_altitude", b"set_altitude", "set_ambient_pressure", b"set_ambient_pressure", "set_asc", b"set_asc", "set_power_mode", b"set_power_mode", "set_target_co2_conc", b"set_target_co2_conc", "set_temperature", b"set_temperature"]) -> None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_factory_reset", b"_factory_reset"]) -> typing.Literal["factory_reset"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_altitude", b"_set_altitude"]) -> typing.Literal["set_altitude"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_ambient_pressure", b"_set_ambient_pressure"]) -> typing.Literal["set_ambient_pressure"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_asc", b"_set_asc"]) -> typing.Literal["set_asc"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_power_mode", b"_set_power_mode"]) -> typing.Literal["set_power_mode"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_target_co2_conc", b"_set_target_co2_conc"]) -> typing.Literal["set_target_co2_conc"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_temperature", b"_set_temperature"]) -> typing.Literal["set_temperature"] | None: ...
global___SCD4X_config = SCD4X_config
@typing.final
class SEN5X_config(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
SET_TEMPERATURE_FIELD_NUMBER: builtins.int
SET_ONE_SHOT_MODE_FIELD_NUMBER: builtins.int
set_temperature: builtins.float
"""
Reference temperature in degC
"""
set_one_shot_mode: builtins.bool
"""
One-shot mode (true for low power - one-shot mode, false for normal - continuous mode)
"""
def __init__(
self,
*,
set_temperature: builtins.float | None = ...,
set_one_shot_mode: builtins.bool | None = ...,
) -> None: ...
def HasField(self, field_name: typing.Literal["_set_one_shot_mode", b"_set_one_shot_mode", "_set_temperature", b"_set_temperature", "set_one_shot_mode", b"set_one_shot_mode", "set_temperature", b"set_temperature"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["_set_one_shot_mode", b"_set_one_shot_mode", "_set_temperature", b"_set_temperature", "set_one_shot_mode", b"set_one_shot_mode", "set_temperature", b"set_temperature"]) -> None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_one_shot_mode", b"_set_one_shot_mode"]) -> typing.Literal["set_one_shot_mode"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_temperature", b"_set_temperature"]) -> typing.Literal["set_temperature"] | None: ...
global___SEN5X_config = SEN5X_config
@typing.final
class SCD30_config(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
SET_ASC_FIELD_NUMBER: builtins.int
SET_TARGET_CO2_CONC_FIELD_NUMBER: builtins.int
SET_TEMPERATURE_FIELD_NUMBER: builtins.int
SET_ALTITUDE_FIELD_NUMBER: builtins.int
SET_MEASUREMENT_INTERVAL_FIELD_NUMBER: builtins.int
SOFT_RESET_FIELD_NUMBER: builtins.int
set_asc: builtins.bool
"""
Set Automatic self-calibration enabled
"""
set_target_co2_conc: builtins.int
"""
Recalibration target CO2 concentration in ppm (FRC or ASC)
"""
set_temperature: builtins.float
"""
Reference temperature in degC
"""
set_altitude: builtins.int
"""
Altitude of sensor in meters above sea level. 0 - 3000m (overrides ambient pressure)
"""
set_measurement_interval: builtins.int
"""
Power mode for sensor (true for low power, false for normal)
"""
soft_reset: builtins.bool
"""
Perform a factory reset of the sensor
"""
def __init__(
self,
*,
set_asc: builtins.bool | None = ...,
set_target_co2_conc: builtins.int | None = ...,
set_temperature: builtins.float | None = ...,
set_altitude: builtins.int | None = ...,
set_measurement_interval: builtins.int | None = ...,
soft_reset: builtins.bool | None = ...,
) -> None: ...
def HasField(self, field_name: typing.Literal["_set_altitude", b"_set_altitude", "_set_asc", b"_set_asc", "_set_measurement_interval", b"_set_measurement_interval", "_set_target_co2_conc", b"_set_target_co2_conc", "_set_temperature", b"_set_temperature", "_soft_reset", b"_soft_reset", "set_altitude", b"set_altitude", "set_asc", b"set_asc", "set_measurement_interval", b"set_measurement_interval", "set_target_co2_conc", b"set_target_co2_conc", "set_temperature", b"set_temperature", "soft_reset", b"soft_reset"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["_set_altitude", b"_set_altitude", "_set_asc", b"_set_asc", "_set_measurement_interval", b"_set_measurement_interval", "_set_target_co2_conc", b"_set_target_co2_conc", "_set_temperature", b"_set_temperature", "_soft_reset", b"_soft_reset", "set_altitude", b"set_altitude", "set_asc", b"set_asc", "set_measurement_interval", b"set_measurement_interval", "set_target_co2_conc", b"set_target_co2_conc", "set_temperature", b"set_temperature", "soft_reset", b"soft_reset"]) -> None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_altitude", b"_set_altitude"]) -> typing.Literal["set_altitude"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_asc", b"_set_asc"]) -> typing.Literal["set_asc"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_measurement_interval", b"_set_measurement_interval"]) -> typing.Literal["set_measurement_interval"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_target_co2_conc", b"_set_target_co2_conc"]) -> typing.Literal["set_target_co2_conc"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_set_temperature", b"_set_temperature"]) -> typing.Literal["set_temperature"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_soft_reset", b"_soft_reset"]) -> typing.Literal["soft_reset"] | None: ...
global___SCD30_config = SCD30_config

View File

File diff suppressed because one or more lines are too long

View File

@@ -1164,6 +1164,7 @@ class Config(google.protobuf.message.Message):
COMPASS_ORIENTATION_FIELD_NUMBER: builtins.int COMPASS_ORIENTATION_FIELD_NUMBER: builtins.int
USE_12H_CLOCK_FIELD_NUMBER: builtins.int USE_12H_CLOCK_FIELD_NUMBER: builtins.int
USE_LONG_NODE_NAME_FIELD_NUMBER: builtins.int USE_LONG_NODE_NAME_FIELD_NUMBER: builtins.int
ENABLE_MESSAGE_BUBBLES_FIELD_NUMBER: builtins.int
screen_on_secs: builtins.int screen_on_secs: builtins.int
""" """
Number of seconds the screen stays on after pressing the user button or receiving a message Number of seconds the screen stays on after pressing the user button or receiving a message
@@ -1222,6 +1223,10 @@ class Config(google.protobuf.message.Message):
If false (default), the device will use short names for various display screens. If false (default), the device will use short names for various display screens.
If true, node names will show in long format If true, node names will show in long format
""" """
enable_message_bubbles: builtins.bool
"""
If true, the device will display message bubbles on screen.
"""
def __init__( def __init__(
self, self,
*, *,
@@ -1238,8 +1243,9 @@ class Config(google.protobuf.message.Message):
compass_orientation: global___Config.DisplayConfig.CompassOrientation.ValueType = ..., compass_orientation: global___Config.DisplayConfig.CompassOrientation.ValueType = ...,
use_12h_clock: builtins.bool = ..., use_12h_clock: builtins.bool = ...,
use_long_node_name: builtins.bool = ..., use_long_node_name: builtins.bool = ...,
enable_message_bubbles: builtins.bool = ...,
) -> None: ... ) -> None: ...
def ClearField(self, field_name: typing.Literal["auto_screen_carousel_secs", b"auto_screen_carousel_secs", "compass_north_top", b"compass_north_top", "compass_orientation", b"compass_orientation", "displaymode", b"displaymode", "flip_screen", b"flip_screen", "gps_format", b"gps_format", "heading_bold", b"heading_bold", "oled", b"oled", "screen_on_secs", b"screen_on_secs", "units", b"units", "use_12h_clock", b"use_12h_clock", "use_long_node_name", b"use_long_node_name", "wake_on_tap_or_motion", b"wake_on_tap_or_motion"]) -> None: ... def ClearField(self, field_name: typing.Literal["auto_screen_carousel_secs", b"auto_screen_carousel_secs", "compass_north_top", b"compass_north_top", "compass_orientation", b"compass_orientation", "displaymode", b"displaymode", "enable_message_bubbles", b"enable_message_bubbles", "flip_screen", b"flip_screen", "gps_format", b"gps_format", "heading_bold", b"heading_bold", "oled", b"oled", "screen_on_secs", b"screen_on_secs", "units", b"units", "use_12h_clock", b"use_12h_clock", "use_long_node_name", b"use_long_node_name", "wake_on_tap_or_motion", b"wake_on_tap_or_motion"]) -> None: ...
@typing.final @typing.final
class LoRaConfig(google.protobuf.message.Message): class LoRaConfig(google.protobuf.message.Message):

View File

@@ -15,7 +15,7 @@ from meshtastic.protobuf import config_pb2 as meshtastic_dot_protobuf_dot_config
from meshtastic.protobuf import module_config_pb2 as meshtastic_dot_protobuf_dot_module__config__pb2 from meshtastic.protobuf import module_config_pb2 as meshtastic_dot_protobuf_dot_module__config__pb2
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n#meshtastic/protobuf/localonly.proto\x12\x13meshtastic.protobuf\x1a meshtastic/protobuf/config.proto\x1a\'meshtastic/protobuf/module_config.proto\"\xfa\x03\n\x0bLocalConfig\x12\x38\n\x06\x64\x65vice\x18\x01 \x01(\x0b\x32(.meshtastic.protobuf.Config.DeviceConfig\x12<\n\x08position\x18\x02 \x01(\x0b\x32*.meshtastic.protobuf.Config.PositionConfig\x12\x36\n\x05power\x18\x03 \x01(\x0b\x32\'.meshtastic.protobuf.Config.PowerConfig\x12:\n\x07network\x18\x04 \x01(\x0b\x32).meshtastic.protobuf.Config.NetworkConfig\x12:\n\x07\x64isplay\x18\x05 \x01(\x0b\x32).meshtastic.protobuf.Config.DisplayConfig\x12\x34\n\x04lora\x18\x06 \x01(\x0b\x32&.meshtastic.protobuf.Config.LoRaConfig\x12>\n\tbluetooth\x18\x07 \x01(\x0b\x32+.meshtastic.protobuf.Config.BluetoothConfig\x12\x0f\n\x07version\x18\x08 \x01(\r\x12<\n\x08security\x18\t \x01(\x0b\x32*.meshtastic.protobuf.Config.SecurityConfig\"\xbe\x08\n\x11LocalModuleConfig\x12:\n\x04mqtt\x18\x01 \x01(\x0b\x32,.meshtastic.protobuf.ModuleConfig.MQTTConfig\x12>\n\x06serial\x18\x02 \x01(\x0b\x32..meshtastic.protobuf.ModuleConfig.SerialConfig\x12[\n\x15\x65xternal_notification\x18\x03 \x01(\x0b\x32<.meshtastic.protobuf.ModuleConfig.ExternalNotificationConfig\x12K\n\rstore_forward\x18\x04 \x01(\x0b\x32\x34.meshtastic.protobuf.ModuleConfig.StoreForwardConfig\x12\x45\n\nrange_test\x18\x05 \x01(\x0b\x32\x31.meshtastic.protobuf.ModuleConfig.RangeTestConfig\x12\x44\n\ttelemetry\x18\x06 \x01(\x0b\x32\x31.meshtastic.protobuf.ModuleConfig.TelemetryConfig\x12M\n\x0e\x63\x61nned_message\x18\x07 \x01(\x0b\x32\x35.meshtastic.protobuf.ModuleConfig.CannedMessageConfig\x12<\n\x05\x61udio\x18\t \x01(\x0b\x32-.meshtastic.protobuf.ModuleConfig.AudioConfig\x12O\n\x0fremote_hardware\x18\n \x01(\x0b\x32\x36.meshtastic.protobuf.ModuleConfig.RemoteHardwareConfig\x12K\n\rneighbor_info\x18\x0b \x01(\x0b\x32\x34.meshtastic.protobuf.ModuleConfig.NeighborInfoConfig\x12Q\n\x10\x61mbient_lighting\x18\x0c \x01(\x0b\x32\x37.meshtastic.protobuf.ModuleConfig.AmbientLightingConfig\x12Q\n\x10\x64\x65tection_sensor\x18\r \x01(\x0b\x32\x37.meshtastic.protobuf.ModuleConfig.DetectionSensorConfig\x12\x46\n\npaxcounter\x18\x0e \x01(\x0b\x32\x32.meshtastic.protobuf.ModuleConfig.PaxcounterConfig\x12L\n\rstatusmessage\x18\x0f \x01(\x0b\x32\x35.meshtastic.protobuf.ModuleConfig.StatusMessageConfig\x12\x0f\n\x07version\x18\x08 \x01(\rBe\n\x14org.meshtastic.protoB\x0fLocalOnlyProtosZ\"github.com/meshtastic/go/generated\xaa\x02\x14Meshtastic.Protobufs\xba\x02\x00\x62\x06proto3') DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n#meshtastic/protobuf/localonly.proto\x12\x13meshtastic.protobuf\x1a meshtastic/protobuf/config.proto\x1a\'meshtastic/protobuf/module_config.proto\"\xfa\x03\n\x0bLocalConfig\x12\x38\n\x06\x64\x65vice\x18\x01 \x01(\x0b\x32(.meshtastic.protobuf.Config.DeviceConfig\x12<\n\x08position\x18\x02 \x01(\x0b\x32*.meshtastic.protobuf.Config.PositionConfig\x12\x36\n\x05power\x18\x03 \x01(\x0b\x32\'.meshtastic.protobuf.Config.PowerConfig\x12:\n\x07network\x18\x04 \x01(\x0b\x32).meshtastic.protobuf.Config.NetworkConfig\x12:\n\x07\x64isplay\x18\x05 \x01(\x0b\x32).meshtastic.protobuf.Config.DisplayConfig\x12\x34\n\x04lora\x18\x06 \x01(\x0b\x32&.meshtastic.protobuf.Config.LoRaConfig\x12>\n\tbluetooth\x18\x07 \x01(\x0b\x32+.meshtastic.protobuf.Config.BluetoothConfig\x12\x0f\n\x07version\x18\x08 \x01(\r\x12<\n\x08security\x18\t \x01(\x0b\x32*.meshtastic.protobuf.Config.SecurityConfig\"\x95\t\n\x11LocalModuleConfig\x12:\n\x04mqtt\x18\x01 \x01(\x0b\x32,.meshtastic.protobuf.ModuleConfig.MQTTConfig\x12>\n\x06serial\x18\x02 \x01(\x0b\x32..meshtastic.protobuf.ModuleConfig.SerialConfig\x12[\n\x15\x65xternal_notification\x18\x03 \x01(\x0b\x32<.meshtastic.protobuf.ModuleConfig.ExternalNotificationConfig\x12K\n\rstore_forward\x18\x04 \x01(\x0b\x32\x34.meshtastic.protobuf.ModuleConfig.StoreForwardConfig\x12\x45\n\nrange_test\x18\x05 \x01(\x0b\x32\x31.meshtastic.protobuf.ModuleConfig.RangeTestConfig\x12\x44\n\ttelemetry\x18\x06 \x01(\x0b\x32\x31.meshtastic.protobuf.ModuleConfig.TelemetryConfig\x12M\n\x0e\x63\x61nned_message\x18\x07 \x01(\x0b\x32\x35.meshtastic.protobuf.ModuleConfig.CannedMessageConfig\x12<\n\x05\x61udio\x18\t \x01(\x0b\x32-.meshtastic.protobuf.ModuleConfig.AudioConfig\x12O\n\x0fremote_hardware\x18\n \x01(\x0b\x32\x36.meshtastic.protobuf.ModuleConfig.RemoteHardwareConfig\x12K\n\rneighbor_info\x18\x0b \x01(\x0b\x32\x34.meshtastic.protobuf.ModuleConfig.NeighborInfoConfig\x12Q\n\x10\x61mbient_lighting\x18\x0c \x01(\x0b\x32\x37.meshtastic.protobuf.ModuleConfig.AmbientLightingConfig\x12Q\n\x10\x64\x65tection_sensor\x18\r \x01(\x0b\x32\x37.meshtastic.protobuf.ModuleConfig.DetectionSensorConfig\x12\x46\n\npaxcounter\x18\x0e \x01(\x0b\x32\x32.meshtastic.protobuf.ModuleConfig.PaxcounterConfig\x12L\n\rstatusmessage\x18\x0f \x01(\x0b\x32\x35.meshtastic.protobuf.ModuleConfig.StatusMessageConfig\x12U\n\x12traffic_management\x18\x10 \x01(\x0b\x32\x39.meshtastic.protobuf.ModuleConfig.TrafficManagementConfig\x12\x0f\n\x07version\x18\x08 \x01(\rBe\n\x14org.meshtastic.protoB\x0fLocalOnlyProtosZ\"github.com/meshtastic/go/generated\xaa\x02\x14Meshtastic.Protobufs\xba\x02\x00\x62\x06proto3')
_globals = globals() _globals = globals()
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
@@ -26,5 +26,5 @@ if _descriptor._USE_C_DESCRIPTORS == False:
_globals['_LOCALCONFIG']._serialized_start=136 _globals['_LOCALCONFIG']._serialized_start=136
_globals['_LOCALCONFIG']._serialized_end=642 _globals['_LOCALCONFIG']._serialized_end=642
_globals['_LOCALMODULECONFIG']._serialized_start=645 _globals['_LOCALMODULECONFIG']._serialized_start=645
_globals['_LOCALMODULECONFIG']._serialized_end=1731 _globals['_LOCALMODULECONFIG']._serialized_end=1818
# @@protoc_insertion_point(module_scope) # @@protoc_insertion_point(module_scope)

View File

@@ -120,6 +120,7 @@ class LocalModuleConfig(google.protobuf.message.Message):
DETECTION_SENSOR_FIELD_NUMBER: builtins.int DETECTION_SENSOR_FIELD_NUMBER: builtins.int
PAXCOUNTER_FIELD_NUMBER: builtins.int PAXCOUNTER_FIELD_NUMBER: builtins.int
STATUSMESSAGE_FIELD_NUMBER: builtins.int STATUSMESSAGE_FIELD_NUMBER: builtins.int
TRAFFIC_MANAGEMENT_FIELD_NUMBER: builtins.int
VERSION_FIELD_NUMBER: builtins.int VERSION_FIELD_NUMBER: builtins.int
version: builtins.int version: builtins.int
""" """
@@ -211,6 +212,12 @@ class LocalModuleConfig(google.protobuf.message.Message):
StatusMessage Config StatusMessage Config
""" """
@property
def traffic_management(self) -> meshtastic.protobuf.module_config_pb2.ModuleConfig.TrafficManagementConfig:
"""
The part of the config that is specific to the Traffic Management module
"""
def __init__( def __init__(
self, self,
*, *,
@@ -228,9 +235,10 @@ class LocalModuleConfig(google.protobuf.message.Message):
detection_sensor: meshtastic.protobuf.module_config_pb2.ModuleConfig.DetectionSensorConfig | None = ..., detection_sensor: meshtastic.protobuf.module_config_pb2.ModuleConfig.DetectionSensorConfig | None = ...,
paxcounter: meshtastic.protobuf.module_config_pb2.ModuleConfig.PaxcounterConfig | None = ..., paxcounter: meshtastic.protobuf.module_config_pb2.ModuleConfig.PaxcounterConfig | None = ...,
statusmessage: meshtastic.protobuf.module_config_pb2.ModuleConfig.StatusMessageConfig | None = ..., statusmessage: meshtastic.protobuf.module_config_pb2.ModuleConfig.StatusMessageConfig | None = ...,
traffic_management: meshtastic.protobuf.module_config_pb2.ModuleConfig.TrafficManagementConfig | None = ...,
version: builtins.int = ..., version: builtins.int = ...,
) -> None: ... ) -> None: ...
def HasField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry"]) -> builtins.bool: ... def HasField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry", "traffic_management", b"traffic_management"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry", "version", b"version"]) -> None: ... def ClearField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry", "traffic_management", b"traffic_management", "version", b"version"]) -> None: ...
global___LocalModuleConfig = LocalModuleConfig global___LocalModuleConfig = LocalModuleConfig

View File

File diff suppressed because one or more lines are too long

View File

@@ -492,6 +492,105 @@ class ModuleConfig(google.protobuf.message.Message):
) -> None: ... ) -> None: ...
def ClearField(self, field_name: typing.Literal["ble_threshold", b"ble_threshold", "enabled", b"enabled", "paxcounter_update_interval", b"paxcounter_update_interval", "wifi_threshold", b"wifi_threshold"]) -> None: ... def ClearField(self, field_name: typing.Literal["ble_threshold", b"ble_threshold", "enabled", b"enabled", "paxcounter_update_interval", b"paxcounter_update_interval", "wifi_threshold", b"wifi_threshold"]) -> None: ...
@typing.final
class TrafficManagementConfig(google.protobuf.message.Message):
"""
Config for the Traffic Management module.
Provides packet inspection and traffic shaping to help reduce channel utilization
"""
DESCRIPTOR: google.protobuf.descriptor.Descriptor
ENABLED_FIELD_NUMBER: builtins.int
POSITION_DEDUP_ENABLED_FIELD_NUMBER: builtins.int
POSITION_PRECISION_BITS_FIELD_NUMBER: builtins.int
POSITION_MIN_INTERVAL_SECS_FIELD_NUMBER: builtins.int
NODEINFO_DIRECT_RESPONSE_FIELD_NUMBER: builtins.int
NODEINFO_DIRECT_RESPONSE_MAX_HOPS_FIELD_NUMBER: builtins.int
RATE_LIMIT_ENABLED_FIELD_NUMBER: builtins.int
RATE_LIMIT_WINDOW_SECS_FIELD_NUMBER: builtins.int
RATE_LIMIT_MAX_PACKETS_FIELD_NUMBER: builtins.int
DROP_UNKNOWN_ENABLED_FIELD_NUMBER: builtins.int
UNKNOWN_PACKET_THRESHOLD_FIELD_NUMBER: builtins.int
EXHAUST_HOP_TELEMETRY_FIELD_NUMBER: builtins.int
EXHAUST_HOP_POSITION_FIELD_NUMBER: builtins.int
ROUTER_PRESERVE_HOPS_FIELD_NUMBER: builtins.int
enabled: builtins.bool
"""
Master enable for traffic management module
"""
position_dedup_enabled: builtins.bool
"""
Enable position deduplication to drop redundant position broadcasts
"""
position_precision_bits: builtins.int
"""
Number of bits of precision for position deduplication (0-32)
"""
position_min_interval_secs: builtins.int
"""
Minimum interval in seconds between position updates from the same node
"""
nodeinfo_direct_response: builtins.bool
"""
Enable direct response to NodeInfo requests from local cache
"""
nodeinfo_direct_response_max_hops: builtins.int
"""
Minimum hop distance from requestor before responding to NodeInfo requests
"""
rate_limit_enabled: builtins.bool
"""
Enable per-node rate limiting to throttle chatty nodes
"""
rate_limit_window_secs: builtins.int
"""
Time window in seconds for rate limiting calculations
"""
rate_limit_max_packets: builtins.int
"""
Maximum packets allowed per node within the rate limit window
"""
drop_unknown_enabled: builtins.bool
"""
Enable dropping of unknown/undecryptable packets per rate_limit_window_secs
"""
unknown_packet_threshold: builtins.int
"""
Number of unknown packets before dropping from a node
"""
exhaust_hop_telemetry: builtins.bool
"""
Set hop_limit to 0 for relayed telemetry broadcasts (own packets unaffected)
"""
exhaust_hop_position: builtins.bool
"""
Set hop_limit to 0 for relayed position broadcasts (own packets unaffected)
"""
router_preserve_hops: builtins.bool
"""
Preserve hop_limit for router-to-router traffic
"""
def __init__(
self,
*,
enabled: builtins.bool = ...,
position_dedup_enabled: builtins.bool = ...,
position_precision_bits: builtins.int = ...,
position_min_interval_secs: builtins.int = ...,
nodeinfo_direct_response: builtins.bool = ...,
nodeinfo_direct_response_max_hops: builtins.int = ...,
rate_limit_enabled: builtins.bool = ...,
rate_limit_window_secs: builtins.int = ...,
rate_limit_max_packets: builtins.int = ...,
drop_unknown_enabled: builtins.bool = ...,
unknown_packet_threshold: builtins.int = ...,
exhaust_hop_telemetry: builtins.bool = ...,
exhaust_hop_position: builtins.bool = ...,
router_preserve_hops: builtins.bool = ...,
) -> None: ...
def ClearField(self, field_name: typing.Literal["drop_unknown_enabled", b"drop_unknown_enabled", "enabled", b"enabled", "exhaust_hop_position", b"exhaust_hop_position", "exhaust_hop_telemetry", b"exhaust_hop_telemetry", "nodeinfo_direct_response", b"nodeinfo_direct_response", "nodeinfo_direct_response_max_hops", b"nodeinfo_direct_response_max_hops", "position_dedup_enabled", b"position_dedup_enabled", "position_min_interval_secs", b"position_min_interval_secs", "position_precision_bits", b"position_precision_bits", "rate_limit_enabled", b"rate_limit_enabled", "rate_limit_max_packets", b"rate_limit_max_packets", "rate_limit_window_secs", b"rate_limit_window_secs", "router_preserve_hops", b"router_preserve_hops", "unknown_packet_threshold", b"unknown_packet_threshold"]) -> None: ...
@typing.final @typing.final
class SerialConfig(google.protobuf.message.Message): class SerialConfig(google.protobuf.message.Message):
""" """
@@ -1216,6 +1315,7 @@ class ModuleConfig(google.protobuf.message.Message):
DETECTION_SENSOR_FIELD_NUMBER: builtins.int DETECTION_SENSOR_FIELD_NUMBER: builtins.int
PAXCOUNTER_FIELD_NUMBER: builtins.int PAXCOUNTER_FIELD_NUMBER: builtins.int
STATUSMESSAGE_FIELD_NUMBER: builtins.int STATUSMESSAGE_FIELD_NUMBER: builtins.int
TRAFFIC_MANAGEMENT_FIELD_NUMBER: builtins.int
@property @property
def mqtt(self) -> global___ModuleConfig.MQTTConfig: def mqtt(self) -> global___ModuleConfig.MQTTConfig:
""" """
@@ -1300,6 +1400,12 @@ class ModuleConfig(google.protobuf.message.Message):
TODO: REPLACE TODO: REPLACE
""" """
@property
def traffic_management(self) -> global___ModuleConfig.TrafficManagementConfig:
"""
Traffic management module config for mesh network optimization
"""
def __init__( def __init__(
self, self,
*, *,
@@ -1317,10 +1423,11 @@ class ModuleConfig(google.protobuf.message.Message):
detection_sensor: global___ModuleConfig.DetectionSensorConfig | None = ..., detection_sensor: global___ModuleConfig.DetectionSensorConfig | None = ...,
paxcounter: global___ModuleConfig.PaxcounterConfig | None = ..., paxcounter: global___ModuleConfig.PaxcounterConfig | None = ...,
statusmessage: global___ModuleConfig.StatusMessageConfig | None = ..., statusmessage: global___ModuleConfig.StatusMessageConfig | None = ...,
traffic_management: global___ModuleConfig.TrafficManagementConfig | None = ...,
) -> None: ... ) -> None: ...
def HasField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "payload_variant", b"payload_variant", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry"]) -> builtins.bool: ... def HasField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "payload_variant", b"payload_variant", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry", "traffic_management", b"traffic_management"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "payload_variant", b"payload_variant", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry"]) -> None: ... def ClearField(self, field_name: typing.Literal["ambient_lighting", b"ambient_lighting", "audio", b"audio", "canned_message", b"canned_message", "detection_sensor", b"detection_sensor", "external_notification", b"external_notification", "mqtt", b"mqtt", "neighbor_info", b"neighbor_info", "paxcounter", b"paxcounter", "payload_variant", b"payload_variant", "range_test", b"range_test", "remote_hardware", b"remote_hardware", "serial", b"serial", "statusmessage", b"statusmessage", "store_forward", b"store_forward", "telemetry", b"telemetry", "traffic_management", b"traffic_management"]) -> None: ...
def WhichOneof(self, oneof_group: typing.Literal["payload_variant", b"payload_variant"]) -> typing.Literal["mqtt", "serial", "external_notification", "store_forward", "range_test", "telemetry", "canned_message", "audio", "remote_hardware", "neighbor_info", "ambient_lighting", "detection_sensor", "paxcounter", "statusmessage"] | None: ... def WhichOneof(self, oneof_group: typing.Literal["payload_variant", b"payload_variant"]) -> typing.Literal["mqtt", "serial", "external_notification", "store_forward", "range_test", "telemetry", "canned_message", "audio", "remote_hardware", "neighbor_info", "ambient_lighting", "detection_sensor", "paxcounter", "statusmessage", "traffic_management"] | None: ...
global___ModuleConfig = ModuleConfig global___ModuleConfig = ModuleConfig

View File

File diff suppressed because one or more lines are too long

View File

@@ -207,6 +207,22 @@ class _TelemetrySensorTypeEnumTypeWrapper(google.protobuf.internal.enum_type_wra
""" """
BH1750 light sensor BH1750 light sensor
""" """
HDC1080: _TelemetrySensorType.ValueType # 46
"""
HDC1080 Temperature and Humidity Sensor
"""
SHT21: _TelemetrySensorType.ValueType # 47
"""
STH21 Temperature and R. Humidity sensor
"""
STC31: _TelemetrySensorType.ValueType # 48
"""
Sensirion STC31 CO2 sensor
"""
SCD30: _TelemetrySensorType.ValueType # 49
"""
SCD30 CO2, humidity, temperature sensor
"""
class TelemetrySensorType(_TelemetrySensorType, metaclass=_TelemetrySensorTypeEnumTypeWrapper): class TelemetrySensorType(_TelemetrySensorType, metaclass=_TelemetrySensorTypeEnumTypeWrapper):
""" """
@@ -397,6 +413,22 @@ BH1750: TelemetrySensorType.ValueType # 45
""" """
BH1750 light sensor BH1750 light sensor
""" """
HDC1080: TelemetrySensorType.ValueType # 46
"""
HDC1080 Temperature and Humidity Sensor
"""
SHT21: TelemetrySensorType.ValueType # 47
"""
STH21 Temperature and R. Humidity sensor
"""
STC31: TelemetrySensorType.ValueType # 48
"""
Sensirion STC31 CO2 sensor
"""
SCD30: TelemetrySensorType.ValueType # 49
"""
SCD30 CO2, humidity, temperature sensor
"""
global___TelemetrySensorType = TelemetrySensorType global___TelemetrySensorType = TelemetrySensorType
@typing.final @typing.final
@@ -1121,6 +1153,64 @@ class LocalStats(google.protobuf.message.Message):
global___LocalStats = LocalStats global___LocalStats = LocalStats
@typing.final
class TrafficManagementStats(google.protobuf.message.Message):
"""
Traffic management statistics for mesh network optimization
"""
DESCRIPTOR: google.protobuf.descriptor.Descriptor
PACKETS_INSPECTED_FIELD_NUMBER: builtins.int
POSITION_DEDUP_DROPS_FIELD_NUMBER: builtins.int
NODEINFO_CACHE_HITS_FIELD_NUMBER: builtins.int
RATE_LIMIT_DROPS_FIELD_NUMBER: builtins.int
UNKNOWN_PACKET_DROPS_FIELD_NUMBER: builtins.int
HOP_EXHAUSTED_PACKETS_FIELD_NUMBER: builtins.int
ROUTER_HOPS_PRESERVED_FIELD_NUMBER: builtins.int
packets_inspected: builtins.int
"""
Total number of packets inspected by traffic management
"""
position_dedup_drops: builtins.int
"""
Number of position packets dropped due to deduplication
"""
nodeinfo_cache_hits: builtins.int
"""
Number of NodeInfo requests answered from cache
"""
rate_limit_drops: builtins.int
"""
Number of packets dropped due to rate limiting
"""
unknown_packet_drops: builtins.int
"""
Number of unknown/undecryptable packets dropped
"""
hop_exhausted_packets: builtins.int
"""
Number of packets with hop_limit exhausted for local-only broadcast
"""
router_hops_preserved: builtins.int
"""
Number of times router hop preservation was applied
"""
def __init__(
self,
*,
packets_inspected: builtins.int = ...,
position_dedup_drops: builtins.int = ...,
nodeinfo_cache_hits: builtins.int = ...,
rate_limit_drops: builtins.int = ...,
unknown_packet_drops: builtins.int = ...,
hop_exhausted_packets: builtins.int = ...,
router_hops_preserved: builtins.int = ...,
) -> None: ...
def ClearField(self, field_name: typing.Literal["hop_exhausted_packets", b"hop_exhausted_packets", "nodeinfo_cache_hits", b"nodeinfo_cache_hits", "packets_inspected", b"packets_inspected", "position_dedup_drops", b"position_dedup_drops", "rate_limit_drops", b"rate_limit_drops", "router_hops_preserved", b"router_hops_preserved", "unknown_packet_drops", b"unknown_packet_drops"]) -> None: ...
global___TrafficManagementStats = TrafficManagementStats
@typing.final @typing.final
class HealthMetrics(google.protobuf.message.Message): class HealthMetrics(google.protobuf.message.Message):
""" """
@@ -1256,6 +1346,7 @@ class Telemetry(google.protobuf.message.Message):
LOCAL_STATS_FIELD_NUMBER: builtins.int LOCAL_STATS_FIELD_NUMBER: builtins.int
HEALTH_METRICS_FIELD_NUMBER: builtins.int HEALTH_METRICS_FIELD_NUMBER: builtins.int
HOST_METRICS_FIELD_NUMBER: builtins.int HOST_METRICS_FIELD_NUMBER: builtins.int
TRAFFIC_MANAGEMENT_STATS_FIELD_NUMBER: builtins.int
time: builtins.int time: builtins.int
""" """
Seconds since 1970 - or 0 for unknown/unset Seconds since 1970 - or 0 for unknown/unset
@@ -1302,6 +1393,12 @@ class Telemetry(google.protobuf.message.Message):
Linux host metrics Linux host metrics
""" """
@property
def traffic_management_stats(self) -> global___TrafficManagementStats:
"""
Traffic management statistics
"""
def __init__( def __init__(
self, self,
*, *,
@@ -1313,10 +1410,11 @@ class Telemetry(google.protobuf.message.Message):
local_stats: global___LocalStats | None = ..., local_stats: global___LocalStats | None = ...,
health_metrics: global___HealthMetrics | None = ..., health_metrics: global___HealthMetrics | None = ...,
host_metrics: global___HostMetrics | None = ..., host_metrics: global___HostMetrics | None = ...,
traffic_management_stats: global___TrafficManagementStats | None = ...,
) -> None: ... ) -> None: ...
def HasField(self, field_name: typing.Literal["air_quality_metrics", b"air_quality_metrics", "device_metrics", b"device_metrics", "environment_metrics", b"environment_metrics", "health_metrics", b"health_metrics", "host_metrics", b"host_metrics", "local_stats", b"local_stats", "power_metrics", b"power_metrics", "variant", b"variant"]) -> builtins.bool: ... def HasField(self, field_name: typing.Literal["air_quality_metrics", b"air_quality_metrics", "device_metrics", b"device_metrics", "environment_metrics", b"environment_metrics", "health_metrics", b"health_metrics", "host_metrics", b"host_metrics", "local_stats", b"local_stats", "power_metrics", b"power_metrics", "traffic_management_stats", b"traffic_management_stats", "variant", b"variant"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["air_quality_metrics", b"air_quality_metrics", "device_metrics", b"device_metrics", "environment_metrics", b"environment_metrics", "health_metrics", b"health_metrics", "host_metrics", b"host_metrics", "local_stats", b"local_stats", "power_metrics", b"power_metrics", "time", b"time", "variant", b"variant"]) -> None: ... def ClearField(self, field_name: typing.Literal["air_quality_metrics", b"air_quality_metrics", "device_metrics", b"device_metrics", "environment_metrics", b"environment_metrics", "health_metrics", b"health_metrics", "host_metrics", b"host_metrics", "local_stats", b"local_stats", "power_metrics", b"power_metrics", "time", b"time", "traffic_management_stats", b"traffic_management_stats", "variant", b"variant"]) -> None: ...
def WhichOneof(self, oneof_group: typing.Literal["variant", b"variant"]) -> typing.Literal["device_metrics", "environment_metrics", "air_quality_metrics", "power_metrics", "local_stats", "health_metrics", "host_metrics"] | None: ... def WhichOneof(self, oneof_group: typing.Literal["variant", b"variant"]) -> typing.Literal["device_metrics", "environment_metrics", "air_quality_metrics", "power_metrics", "local_stats", "health_metrics", "host_metrics", "traffic_management_stats"] | None: ...
global___Telemetry = Telemetry global___Telemetry = Telemetry
@@ -1347,3 +1445,62 @@ class Nau7802Config(google.protobuf.message.Message):
def ClearField(self, field_name: typing.Literal["calibrationFactor", b"calibrationFactor", "zeroOffset", b"zeroOffset"]) -> None: ... def ClearField(self, field_name: typing.Literal["calibrationFactor", b"calibrationFactor", "zeroOffset", b"zeroOffset"]) -> None: ...
global___Nau7802Config = Nau7802Config global___Nau7802Config = Nau7802Config
@typing.final
class SEN5XState(google.protobuf.message.Message):
"""
SEN5X State, for saving to flash
"""
DESCRIPTOR: google.protobuf.descriptor.Descriptor
LAST_CLEANING_TIME_FIELD_NUMBER: builtins.int
LAST_CLEANING_VALID_FIELD_NUMBER: builtins.int
ONE_SHOT_MODE_FIELD_NUMBER: builtins.int
VOC_STATE_TIME_FIELD_NUMBER: builtins.int
VOC_STATE_VALID_FIELD_NUMBER: builtins.int
VOC_STATE_ARRAY_FIELD_NUMBER: builtins.int
last_cleaning_time: builtins.int
"""
Last cleaning time for SEN5X
"""
last_cleaning_valid: builtins.bool
"""
Last cleaning time for SEN5X - valid flag
"""
one_shot_mode: builtins.bool
"""
Config flag for one-shot mode (see admin.proto)
"""
voc_state_time: builtins.int
"""
Last VOC state time for SEN55
"""
voc_state_valid: builtins.bool
"""
Last VOC state validity flag for SEN55
"""
voc_state_array: builtins.int
"""
VOC state array (8x uint8t) for SEN55
"""
def __init__(
self,
*,
last_cleaning_time: builtins.int = ...,
last_cleaning_valid: builtins.bool = ...,
one_shot_mode: builtins.bool = ...,
voc_state_time: builtins.int | None = ...,
voc_state_valid: builtins.bool | None = ...,
voc_state_array: builtins.int | None = ...,
) -> None: ...
def HasField(self, field_name: typing.Literal["_voc_state_array", b"_voc_state_array", "_voc_state_time", b"_voc_state_time", "_voc_state_valid", b"_voc_state_valid", "voc_state_array", b"voc_state_array", "voc_state_time", b"voc_state_time", "voc_state_valid", b"voc_state_valid"]) -> builtins.bool: ...
def ClearField(self, field_name: typing.Literal["_voc_state_array", b"_voc_state_array", "_voc_state_time", b"_voc_state_time", "_voc_state_valid", b"_voc_state_valid", "last_cleaning_time", b"last_cleaning_time", "last_cleaning_valid", b"last_cleaning_valid", "one_shot_mode", b"one_shot_mode", "voc_state_array", b"voc_state_array", "voc_state_time", b"voc_state_time", "voc_state_valid", b"voc_state_valid"]) -> None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_voc_state_array", b"_voc_state_array"]) -> typing.Literal["voc_state_array"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_voc_state_time", b"_voc_state_time"]) -> typing.Literal["voc_state_time"] | None: ...
@typing.overload
def WhichOneof(self, oneof_group: typing.Literal["_voc_state_valid", b"_voc_state_valid"]) -> typing.Literal["voc_state_valid"] | None: ...
global___SEN5XState = SEN5XState