initial commit
This commit is contained in:
1 parent
a718708860
commit
3e139b01da
285 files changed
+45042
No files matched your search
Generated
+10
@@ -0,0 +1,10 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
||||
# Ignored default folder with query files
|
||||
/queries/
|
||||
# Datasource local storage ignored files
|
||||
/dataSources/
|
||||
/dataSources.local.xml
|
||||
# Editor-based HTTP Client requests
|
||||
/httpRequests/
|
||||
Generated
+56
@@ -0,0 +1,56 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="PublishConfigData" remoteFilesAllowedToDisappearOnAutoupload="false">
|
||||
<serverData>
|
||||
<paths name="dev-web03.servicecloud.info">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
<paths name="dew-web04.servicecloud.info">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
<paths name="ip.it-stories.ru">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
<paths name="rsgrinko.online">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
<paths name="tula.it-stories.ru">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
<paths name="vpn.it-stories.ru">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
<paths name="vpnservice.it-stories.ru">
|
||||
<serverdata>
|
||||
<mappings>
|
||||
<mapping local="$PROJECT_DIR$" web="/" />
|
||||
</mappings>
|
||||
</serverdata>
|
||||
</paths>
|
||||
</serverData>
|
||||
</component>
|
||||
</project>
|
||||
Generated
+8
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="WEB_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
Generated
+8
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/meshtastic-proto.iml" filepath="$PROJECT_DIR$/.idea/meshtastic-proto.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
||||
Generated
+19
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="MessDetectorOptionsConfiguration">
|
||||
<option name="transferred" value="true" />
|
||||
</component>
|
||||
<component name="PHPCSFixerOptionsConfiguration">
|
||||
<option name="transferred" value="true" />
|
||||
</component>
|
||||
<component name="PHPCodeSnifferOptionsConfiguration">
|
||||
<option name="highlightLevel" value="WARNING" />
|
||||
<option name="transferred" value="true" />
|
||||
</component>
|
||||
<component name="PhpStanOptionsConfiguration">
|
||||
<option name="transferred" value="true" />
|
||||
</component>
|
||||
<component name="PsalmOptionsConfiguration">
|
||||
<option name="transferred" value="true" />
|
||||
</component>
|
||||
</project>
|
||||
Generated
+6
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="VcsDirectoryMappings">
|
||||
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||
</component>
|
||||
</project>
|
||||
@@ -0,0 +1,31 @@
|
||||
{
|
||||
"name": "rsgrinko/meshtastic-protobufs",
|
||||
"type": "library",
|
||||
"description": "PHP Compiled Protobufs from the Official Meshtastic Protobufs repository",
|
||||
"keywords": ["meshtastic", "protobuf", "rsgrinko"],
|
||||
"license": "MIT",
|
||||
"authors": [
|
||||
{
|
||||
"name": "Roman Grinko",
|
||||
"email": "rsgrinko@gmail.com"
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"google/protobuf": "*",
|
||||
"protobuf-php/protobuf": "*"
|
||||
},
|
||||
"require-dev": {},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Meshtastic\\": "src/Meshtastic/",
|
||||
"GPBMetadata\\": "src/GPBMetadata/"
|
||||
}
|
||||
},
|
||||
"config": {
|
||||
"optimize-autoloader": true,
|
||||
"preferred-install": "dist",
|
||||
"sort-packages": true
|
||||
},
|
||||
"minimum-stability": "stable",
|
||||
"prefer-stable": true
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic\AdminMessage;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.AdminMessage.BackupLocation</code>
|
||||
*/
|
||||
class BackupLocation
|
||||
{
|
||||
/**
|
||||
* Backup to the internal flash
|
||||
*
|
||||
* Generated from protobuf enum <code>FLASH = 0;</code>
|
||||
*/
|
||||
const FLASH = 0;
|
||||
/**
|
||||
* Backup to the SD card
|
||||
*
|
||||
* Generated from protobuf enum <code>SD = 1;</code>
|
||||
*/
|
||||
const SD = 1;
|
||||
|
||||
private static $valueToName = [
|
||||
self::FLASH => 'FLASH',
|
||||
self::SD => 'SD',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(BackupLocation::class, \Meshtastic\AdminMessage_BackupLocation::class);
|
||||
|
||||
@@ -0,0 +1,113 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic\AdminMessage;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Protobuf type <code>meshtastic.AdminMessage.ConfigType</code>
|
||||
*/
|
||||
class ConfigType
|
||||
{
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>DEVICE_CONFIG = 0;</code>
|
||||
*/
|
||||
const DEVICE_CONFIG = 0;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>POSITION_CONFIG = 1;</code>
|
||||
*/
|
||||
const POSITION_CONFIG = 1;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>POWER_CONFIG = 2;</code>
|
||||
*/
|
||||
const POWER_CONFIG = 2;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>NETWORK_CONFIG = 3;</code>
|
||||
*/
|
||||
const NETWORK_CONFIG = 3;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>DISPLAY_CONFIG = 4;</code>
|
||||
*/
|
||||
const DISPLAY_CONFIG = 4;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>LORA_CONFIG = 5;</code>
|
||||
*/
|
||||
const LORA_CONFIG = 5;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>BLUETOOTH_CONFIG = 6;</code>
|
||||
*/
|
||||
const BLUETOOTH_CONFIG = 6;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>SECURITY_CONFIG = 7;</code>
|
||||
*/
|
||||
const SECURITY_CONFIG = 7;
|
||||
/**
|
||||
* Session key config
|
||||
*
|
||||
* Generated from protobuf enum <code>SESSIONKEY_CONFIG = 8;</code>
|
||||
*/
|
||||
const SESSIONKEY_CONFIG = 8;
|
||||
/**
|
||||
* device-ui config
|
||||
*
|
||||
* Generated from protobuf enum <code>DEVICEUI_CONFIG = 9;</code>
|
||||
*/
|
||||
const DEVICEUI_CONFIG = 9;
|
||||
|
||||
private static $valueToName = [
|
||||
self::DEVICE_CONFIG => 'DEVICE_CONFIG',
|
||||
self::POSITION_CONFIG => 'POSITION_CONFIG',
|
||||
self::POWER_CONFIG => 'POWER_CONFIG',
|
||||
self::NETWORK_CONFIG => 'NETWORK_CONFIG',
|
||||
self::DISPLAY_CONFIG => 'DISPLAY_CONFIG',
|
||||
self::LORA_CONFIG => 'LORA_CONFIG',
|
||||
self::BLUETOOTH_CONFIG => 'BLUETOOTH_CONFIG',
|
||||
self::SECURITY_CONFIG => 'SECURITY_CONFIG',
|
||||
self::SESSIONKEY_CONFIG => 'SESSIONKEY_CONFIG',
|
||||
self::DEVICEUI_CONFIG => 'DEVICEUI_CONFIG',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(ConfigType::class, \Meshtastic\AdminMessage_ConfigType::class);
|
||||
|
||||
@@ -0,0 +1,172 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic\AdminMessage;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Input event message to be sent to the node.
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.AdminMessage.InputEvent</code>
|
||||
*/
|
||||
class InputEvent extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The input event code
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 event_code = 1;</code>
|
||||
*/
|
||||
protected $event_code = 0;
|
||||
/**
|
||||
* Keyboard character code
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 kb_char = 2;</code>
|
||||
*/
|
||||
protected $kb_char = 0;
|
||||
/**
|
||||
* The touch X coordinate
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 touch_x = 3;</code>
|
||||
*/
|
||||
protected $touch_x = 0;
|
||||
/**
|
||||
* The touch Y coordinate
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 touch_y = 4;</code>
|
||||
*/
|
||||
protected $touch_y = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $event_code
|
||||
* The input event code
|
||||
* @type int $kb_char
|
||||
* Keyboard character code
|
||||
* @type int $touch_x
|
||||
* The touch X coordinate
|
||||
* @type int $touch_y
|
||||
* The touch Y coordinate
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Admin::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The input event code
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 event_code = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getEventCode()
|
||||
{
|
||||
return $this->event_code;
|
||||
}
|
||||
|
||||
/**
|
||||
* The input event code
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 event_code = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setEventCode($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->event_code = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Keyboard character code
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 kb_char = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getKbChar()
|
||||
{
|
||||
return $this->kb_char;
|
||||
}
|
||||
|
||||
/**
|
||||
* Keyboard character code
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 kb_char = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setKbChar($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->kb_char = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The touch X coordinate
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 touch_x = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getTouchX()
|
||||
{
|
||||
return $this->touch_x;
|
||||
}
|
||||
|
||||
/**
|
||||
* The touch X coordinate
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 touch_x = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTouchX($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->touch_x = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The touch Y coordinate
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 touch_y = 4;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getTouchY()
|
||||
{
|
||||
return $this->touch_y;
|
||||
}
|
||||
|
||||
/**
|
||||
* The touch Y coordinate
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 touch_y = 4;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTouchY($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->touch_y = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(InputEvent::class, \Meshtastic\AdminMessage_InputEvent::class);
|
||||
|
||||
@@ -0,0 +1,148 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic\AdminMessage;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Protobuf type <code>meshtastic.AdminMessage.ModuleConfigType</code>
|
||||
*/
|
||||
class ModuleConfigType
|
||||
{
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>MQTT_CONFIG = 0;</code>
|
||||
*/
|
||||
const MQTT_CONFIG = 0;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>SERIAL_CONFIG = 1;</code>
|
||||
*/
|
||||
const SERIAL_CONFIG = 1;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>EXTNOTIF_CONFIG = 2;</code>
|
||||
*/
|
||||
const EXTNOTIF_CONFIG = 2;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>STOREFORWARD_CONFIG = 3;</code>
|
||||
*/
|
||||
const STOREFORWARD_CONFIG = 3;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>RANGETEST_CONFIG = 4;</code>
|
||||
*/
|
||||
const RANGETEST_CONFIG = 4;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>TELEMETRY_CONFIG = 5;</code>
|
||||
*/
|
||||
const TELEMETRY_CONFIG = 5;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>CANNEDMSG_CONFIG = 6;</code>
|
||||
*/
|
||||
const CANNEDMSG_CONFIG = 6;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>AUDIO_CONFIG = 7;</code>
|
||||
*/
|
||||
const AUDIO_CONFIG = 7;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>REMOTEHARDWARE_CONFIG = 8;</code>
|
||||
*/
|
||||
const REMOTEHARDWARE_CONFIG = 8;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>NEIGHBORINFO_CONFIG = 9;</code>
|
||||
*/
|
||||
const NEIGHBORINFO_CONFIG = 9;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>AMBIENTLIGHTING_CONFIG = 10;</code>
|
||||
*/
|
||||
const AMBIENTLIGHTING_CONFIG = 10;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>DETECTIONSENSOR_CONFIG = 11;</code>
|
||||
*/
|
||||
const DETECTIONSENSOR_CONFIG = 11;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>PAXCOUNTER_CONFIG = 12;</code>
|
||||
*/
|
||||
const PAXCOUNTER_CONFIG = 12;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf enum <code>STATUSMESSAGE_CONFIG = 13;</code>
|
||||
*/
|
||||
const STATUSMESSAGE_CONFIG = 13;
|
||||
/**
|
||||
* Traffic management module config
|
||||
*
|
||||
* Generated from protobuf enum <code>TRAFFICMANAGEMENT_CONFIG = 14;</code>
|
||||
*/
|
||||
const TRAFFICMANAGEMENT_CONFIG = 14;
|
||||
|
||||
private static $valueToName = [
|
||||
self::MQTT_CONFIG => 'MQTT_CONFIG',
|
||||
self::SERIAL_CONFIG => 'SERIAL_CONFIG',
|
||||
self::EXTNOTIF_CONFIG => 'EXTNOTIF_CONFIG',
|
||||
self::STOREFORWARD_CONFIG => 'STOREFORWARD_CONFIG',
|
||||
self::RANGETEST_CONFIG => 'RANGETEST_CONFIG',
|
||||
self::TELEMETRY_CONFIG => 'TELEMETRY_CONFIG',
|
||||
self::CANNEDMSG_CONFIG => 'CANNEDMSG_CONFIG',
|
||||
self::AUDIO_CONFIG => 'AUDIO_CONFIG',
|
||||
self::REMOTEHARDWARE_CONFIG => 'REMOTEHARDWARE_CONFIG',
|
||||
self::NEIGHBORINFO_CONFIG => 'NEIGHBORINFO_CONFIG',
|
||||
self::AMBIENTLIGHTING_CONFIG => 'AMBIENTLIGHTING_CONFIG',
|
||||
self::DETECTIONSENSOR_CONFIG => 'DETECTIONSENSOR_CONFIG',
|
||||
self::PAXCOUNTER_CONFIG => 'PAXCOUNTER_CONFIG',
|
||||
self::STATUSMESSAGE_CONFIG => 'STATUSMESSAGE_CONFIG',
|
||||
self::TRAFFICMANAGEMENT_CONFIG => 'TRAFFICMANAGEMENT_CONFIG',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(ModuleConfigType::class, \Meshtastic\AdminMessage_ModuleConfigType::class);
|
||||
|
||||
@@ -0,0 +1,109 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic\AdminMessage;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* User is requesting an over the air update.
|
||||
* Node will reboot into the OTA loader
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.AdminMessage.OTAEvent</code>
|
||||
*/
|
||||
class OTAEvent extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Tell the node to reboot into OTA mode for firmware update via BLE or WiFi (ESP32 only for now)
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.OTAMode reboot_ota_mode = 1;</code>
|
||||
*/
|
||||
protected $reboot_ota_mode = 0;
|
||||
/**
|
||||
* A 32 byte hash of the OTA firmware.
|
||||
* Used to verify the integrity of the firmware before applying an update.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes ota_hash = 2;</code>
|
||||
*/
|
||||
protected $ota_hash = '';
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $reboot_ota_mode
|
||||
* Tell the node to reboot into OTA mode for firmware update via BLE or WiFi (ESP32 only for now)
|
||||
* @type string $ota_hash
|
||||
* A 32 byte hash of the OTA firmware.
|
||||
* Used to verify the integrity of the firmware before applying an update.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Admin::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tell the node to reboot into OTA mode for firmware update via BLE or WiFi (ESP32 only for now)
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.OTAMode reboot_ota_mode = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRebootOtaMode()
|
||||
{
|
||||
return $this->reboot_ota_mode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Tell the node to reboot into OTA mode for firmware update via BLE or WiFi (ESP32 only for now)
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.OTAMode reboot_ota_mode = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRebootOtaMode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\OTAMode::class);
|
||||
$this->reboot_ota_mode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* A 32 byte hash of the OTA firmware.
|
||||
* Used to verify the integrity of the firmware before applying an update.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes ota_hash = 2;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getOtaHash()
|
||||
{
|
||||
return $this->ota_hash;
|
||||
}
|
||||
|
||||
/**
|
||||
* A 32 byte hash of the OTA firmware.
|
||||
* Used to verify the integrity of the firmware before applying an update.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes ota_hash = 2;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setOtaHash($var)
|
||||
{
|
||||
GPBUtil::checkString($var, False);
|
||||
$this->ota_hash = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(OTAEvent::class, \Meshtastic\AdminMessage_OTAEvent::class);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\AdminMessage\BackupLocation instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class AdminMessage_BackupLocation {}
|
||||
}
|
||||
class_exists(AdminMessage\BackupLocation::class);
|
||||
@trigger_error('Meshtastic\AdminMessage_BackupLocation is deprecated and will be removed in the next major release. Use Meshtastic\AdminMessage\BackupLocation instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\AdminMessage\ConfigType instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class AdminMessage_ConfigType {}
|
||||
}
|
||||
class_exists(AdminMessage\ConfigType::class);
|
||||
@trigger_error('Meshtastic\AdminMessage_ConfigType is deprecated and will be removed in the next major release. Use Meshtastic\AdminMessage\ConfigType instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\AdminMessage\InputEvent instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class AdminMessage_InputEvent {}
|
||||
}
|
||||
class_exists(AdminMessage\InputEvent::class);
|
||||
@trigger_error('Meshtastic\AdminMessage_InputEvent is deprecated and will be removed in the next major release. Use Meshtastic\AdminMessage\InputEvent instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\AdminMessage\ModuleConfigType instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class AdminMessage_ModuleConfigType {}
|
||||
}
|
||||
class_exists(AdminMessage\ModuleConfigType::class);
|
||||
@trigger_error('Meshtastic\AdminMessage_ModuleConfigType is deprecated and will be removed in the next major release. Use Meshtastic\AdminMessage\ModuleConfigType instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/admin.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\AdminMessage\OTAEvent instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class AdminMessage_OTAEvent {}
|
||||
}
|
||||
class_exists(AdminMessage\OTAEvent::class);
|
||||
@trigger_error('Meshtastic\AdminMessage_OTAEvent is deprecated and will be removed in the next major release. Use Meshtastic\AdminMessage\OTAEvent instead', E_USER_DEPRECATED);
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,277 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/deviceonly.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* The on-disk backup of the node's preferences
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.BackupPreferences</code>
|
||||
*/
|
||||
class BackupPreferences extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The version of the backup
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 version = 1;</code>
|
||||
*/
|
||||
protected $version = 0;
|
||||
/**
|
||||
* The timestamp of the backup (if node has time)
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 timestamp = 2;</code>
|
||||
*/
|
||||
protected $timestamp = 0;
|
||||
/**
|
||||
* The node's configuration
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LocalConfig config = 3;</code>
|
||||
*/
|
||||
protected $config = null;
|
||||
/**
|
||||
* The node's module configuration
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LocalModuleConfig module_config = 4;</code>
|
||||
*/
|
||||
protected $module_config = null;
|
||||
/**
|
||||
* The node's channels
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ChannelFile channels = 5;</code>
|
||||
*/
|
||||
protected $channels = null;
|
||||
/**
|
||||
* The node's user (owner) information
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.User owner = 6;</code>
|
||||
*/
|
||||
protected $owner = null;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $version
|
||||
* The version of the backup
|
||||
* @type int $timestamp
|
||||
* The timestamp of the backup (if node has time)
|
||||
* @type \Meshtastic\LocalConfig $config
|
||||
* The node's configuration
|
||||
* @type \Meshtastic\LocalModuleConfig $module_config
|
||||
* The node's module configuration
|
||||
* @type \Meshtastic\ChannelFile $channels
|
||||
* The node's channels
|
||||
* @type \Meshtastic\User $owner
|
||||
* The node's user (owner) information
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Deviceonly::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The version of the backup
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 version = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getVersion()
|
||||
{
|
||||
return $this->version;
|
||||
}
|
||||
|
||||
/**
|
||||
* The version of the backup
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 version = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setVersion($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->version = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The timestamp of the backup (if node has time)
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 timestamp = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getTimestamp()
|
||||
{
|
||||
return $this->timestamp;
|
||||
}
|
||||
|
||||
/**
|
||||
* The timestamp of the backup (if node has time)
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 timestamp = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTimestamp($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->timestamp = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's configuration
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LocalConfig config = 3;</code>
|
||||
* @return \Meshtastic\LocalConfig|null
|
||||
*/
|
||||
public function getConfig()
|
||||
{
|
||||
return $this->config;
|
||||
}
|
||||
|
||||
public function hasConfig()
|
||||
{
|
||||
return isset($this->config);
|
||||
}
|
||||
|
||||
public function clearConfig()
|
||||
{
|
||||
unset($this->config);
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's configuration
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LocalConfig config = 3;</code>
|
||||
* @param \Meshtastic\LocalConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setConfig($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\LocalConfig::class);
|
||||
$this->config = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's module configuration
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LocalModuleConfig module_config = 4;</code>
|
||||
* @return \Meshtastic\LocalModuleConfig|null
|
||||
*/
|
||||
public function getModuleConfig()
|
||||
{
|
||||
return $this->module_config;
|
||||
}
|
||||
|
||||
public function hasModuleConfig()
|
||||
{
|
||||
return isset($this->module_config);
|
||||
}
|
||||
|
||||
public function clearModuleConfig()
|
||||
{
|
||||
unset($this->module_config);
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's module configuration
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LocalModuleConfig module_config = 4;</code>
|
||||
* @param \Meshtastic\LocalModuleConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setModuleConfig($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\LocalModuleConfig::class);
|
||||
$this->module_config = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's channels
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ChannelFile channels = 5;</code>
|
||||
* @return \Meshtastic\ChannelFile|null
|
||||
*/
|
||||
public function getChannels()
|
||||
{
|
||||
return $this->channels;
|
||||
}
|
||||
|
||||
public function hasChannels()
|
||||
{
|
||||
return isset($this->channels);
|
||||
}
|
||||
|
||||
public function clearChannels()
|
||||
{
|
||||
unset($this->channels);
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's channels
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ChannelFile channels = 5;</code>
|
||||
* @param \Meshtastic\ChannelFile $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setChannels($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\ChannelFile::class);
|
||||
$this->channels = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's user (owner) information
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.User owner = 6;</code>
|
||||
* @return \Meshtastic\User|null
|
||||
*/
|
||||
public function getOwner()
|
||||
{
|
||||
return $this->owner;
|
||||
}
|
||||
|
||||
public function hasOwner()
|
||||
{
|
||||
return isset($this->owner);
|
||||
}
|
||||
|
||||
public function clearOwner()
|
||||
{
|
||||
unset($this->owner);
|
||||
}
|
||||
|
||||
/**
|
||||
* The node's user (owner) information
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.User owner = 6;</code>
|
||||
* @param \Meshtastic\User $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setOwner($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\User::class);
|
||||
$this->owner = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,135 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/connection_status.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Bluetooth connection status
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.BluetoothConnectionStatus</code>
|
||||
*/
|
||||
class BluetoothConnectionStatus extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The pairing PIN for bluetooth
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 pin = 1;</code>
|
||||
*/
|
||||
protected $pin = 0;
|
||||
/**
|
||||
* RSSI of bluetooth connection
|
||||
*
|
||||
* Generated from protobuf field <code>int32 rssi = 2;</code>
|
||||
*/
|
||||
protected $rssi = 0;
|
||||
/**
|
||||
* Whether the device has an active connection or not
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_connected = 3;</code>
|
||||
*/
|
||||
protected $is_connected = false;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $pin
|
||||
* The pairing PIN for bluetooth
|
||||
* @type int $rssi
|
||||
* RSSI of bluetooth connection
|
||||
* @type bool $is_connected
|
||||
* Whether the device has an active connection or not
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\ConnectionStatus::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The pairing PIN for bluetooth
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 pin = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getPin()
|
||||
{
|
||||
return $this->pin;
|
||||
}
|
||||
|
||||
/**
|
||||
* The pairing PIN for bluetooth
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 pin = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPin($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->pin = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* RSSI of bluetooth connection
|
||||
*
|
||||
* Generated from protobuf field <code>int32 rssi = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRssi()
|
||||
{
|
||||
return $this->rssi;
|
||||
}
|
||||
|
||||
/**
|
||||
* RSSI of bluetooth connection
|
||||
*
|
||||
* Generated from protobuf field <code>int32 rssi = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRssi($var)
|
||||
{
|
||||
GPBUtil::checkInt32($var);
|
||||
$this->rssi = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether the device has an active connection or not
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_connected = 3;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getIsConnected()
|
||||
{
|
||||
return $this->is_connected;
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether the device has an active connection or not
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_connected = 3;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIsConnected($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->is_connected = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,67 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/cannedmessages.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Canned message module configuration.
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.CannedMessageModuleConfig</code>
|
||||
*/
|
||||
class CannedMessageModuleConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Predefined messages for canned message module separated by '|' characters.
|
||||
*
|
||||
* Generated from protobuf field <code>string messages = 1;</code>
|
||||
*/
|
||||
protected $messages = '';
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type string $messages
|
||||
* Predefined messages for canned message module separated by '|' characters.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Cannedmessages::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Predefined messages for canned message module separated by '|' characters.
|
||||
*
|
||||
* Generated from protobuf field <code>string messages = 1;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getMessages()
|
||||
{
|
||||
return $this->messages;
|
||||
}
|
||||
|
||||
/**
|
||||
* Predefined messages for canned message module separated by '|' characters.
|
||||
*
|
||||
* Generated from protobuf field <code>string messages = 1;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setMessages($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->messages = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,153 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/channel.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* A pair of a channel number, mode and the (sharable) settings for that channel
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Channel</code>
|
||||
*/
|
||||
class Channel extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The index of this channel in the channel table (from 0 to MAX_NUM_CHANNELS-1)
|
||||
* (Someday - not currently implemented) An index of -1 could be used to mean "set by name",
|
||||
* in which case the target node will find and set the channel by settings.name.
|
||||
*
|
||||
* Generated from protobuf field <code>int32 index = 1;</code>
|
||||
*/
|
||||
protected $index = 0;
|
||||
/**
|
||||
* The new settings, or NULL to disable that channel
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ChannelSettings settings = 2;</code>
|
||||
*/
|
||||
protected $settings = null;
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Channel.Role role = 3;</code>
|
||||
*/
|
||||
protected $role = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $index
|
||||
* The index of this channel in the channel table (from 0 to MAX_NUM_CHANNELS-1)
|
||||
* (Someday - not currently implemented) An index of -1 could be used to mean "set by name",
|
||||
* in which case the target node will find and set the channel by settings.name.
|
||||
* @type \Meshtastic\ChannelSettings $settings
|
||||
* The new settings, or NULL to disable that channel
|
||||
* @type int $role
|
||||
* TODO: REPLACE
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Channel::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The index of this channel in the channel table (from 0 to MAX_NUM_CHANNELS-1)
|
||||
* (Someday - not currently implemented) An index of -1 could be used to mean "set by name",
|
||||
* in which case the target node will find and set the channel by settings.name.
|
||||
*
|
||||
* Generated from protobuf field <code>int32 index = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getIndex()
|
||||
{
|
||||
return $this->index;
|
||||
}
|
||||
|
||||
/**
|
||||
* The index of this channel in the channel table (from 0 to MAX_NUM_CHANNELS-1)
|
||||
* (Someday - not currently implemented) An index of -1 could be used to mean "set by name",
|
||||
* in which case the target node will find and set the channel by settings.name.
|
||||
*
|
||||
* Generated from protobuf field <code>int32 index = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIndex($var)
|
||||
{
|
||||
GPBUtil::checkInt32($var);
|
||||
$this->index = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The new settings, or NULL to disable that channel
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ChannelSettings settings = 2;</code>
|
||||
* @return \Meshtastic\ChannelSettings|null
|
||||
*/
|
||||
public function getSettings()
|
||||
{
|
||||
return $this->settings;
|
||||
}
|
||||
|
||||
public function hasSettings()
|
||||
{
|
||||
return isset($this->settings);
|
||||
}
|
||||
|
||||
public function clearSettings()
|
||||
{
|
||||
unset($this->settings);
|
||||
}
|
||||
|
||||
/**
|
||||
* The new settings, or NULL to disable that channel
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ChannelSettings settings = 2;</code>
|
||||
* @param \Meshtastic\ChannelSettings $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSettings($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\ChannelSettings::class);
|
||||
$this->settings = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Channel.Role role = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRole()
|
||||
{
|
||||
return $this->role;
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO: REPLACE
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Channel.Role role = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRole($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Channel\Role::class);
|
||||
$this->role = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/channel.proto
|
||||
|
||||
namespace Meshtastic\Channel;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* How this channel is being used (or not).
|
||||
* Note: this field is an enum to give us options for the future.
|
||||
* In particular, someday we might make a 'SCANNING' option.
|
||||
* SCANNING channels could have different frequencies and the radio would
|
||||
* occasionally check that freq to see if anything is being transmitted.
|
||||
* For devices that have multiple physical radios attached, we could keep multiple PRIMARY/SCANNING channels active at once to allow
|
||||
* cross band routing as needed.
|
||||
* If a device has only a single radio (the common case) only one channel can be PRIMARY at a time
|
||||
* (but any number of SECONDARY channels can't be sent received on that common frequency)
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Channel.Role</code>
|
||||
*/
|
||||
class Role
|
||||
{
|
||||
/**
|
||||
* This channel is not in use right now
|
||||
*
|
||||
* Generated from protobuf enum <code>DISABLED = 0;</code>
|
||||
*/
|
||||
const DISABLED = 0;
|
||||
/**
|
||||
* This channel is used to set the frequency for the radio - all other enabled channels must be SECONDARY
|
||||
*
|
||||
* Generated from protobuf enum <code>PRIMARY = 1;</code>
|
||||
*/
|
||||
const PRIMARY = 1;
|
||||
/**
|
||||
* Secondary channels are only used for encryption/decryption/authentication purposes.
|
||||
* Their radio settings (freq etc) are ignored, only psk is used.
|
||||
*
|
||||
* Generated from protobuf enum <code>SECONDARY = 2;</code>
|
||||
*/
|
||||
const SECONDARY = 2;
|
||||
|
||||
private static $valueToName = [
|
||||
self::DISABLED => 'DISABLED',
|
||||
self::PRIMARY => 'PRIMARY',
|
||||
self::SECONDARY => 'SECONDARY',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(Role::class, \Meshtastic\Channel_Role::class);
|
||||
|
||||
@@ -0,0 +1,109 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/deviceonly.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* The on-disk saved channels
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.ChannelFile</code>
|
||||
*/
|
||||
class ChannelFile extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The channels our node knows about
|
||||
*
|
||||
* Generated from protobuf field <code>repeated .meshtastic.Channel channels = 1;</code>
|
||||
*/
|
||||
private $channels;
|
||||
/**
|
||||
* A version integer used to invalidate old save files when we make
|
||||
* incompatible changes This integer is set at build time and is private to
|
||||
* NodeDB.cpp in the device code.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 version = 2;</code>
|
||||
*/
|
||||
protected $version = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type array<\Meshtastic\Channel>|\Google\Protobuf\Internal\RepeatedField $channels
|
||||
* The channels our node knows about
|
||||
* @type int $version
|
||||
* A version integer used to invalidate old save files when we make
|
||||
* incompatible changes This integer is set at build time and is private to
|
||||
* NodeDB.cpp in the device code.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Deviceonly::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The channels our node knows about
|
||||
*
|
||||
* Generated from protobuf field <code>repeated .meshtastic.Channel channels = 1;</code>
|
||||
* @return \Google\Protobuf\Internal\RepeatedField
|
||||
*/
|
||||
public function getChannels()
|
||||
{
|
||||
return $this->channels;
|
||||
}
|
||||
|
||||
/**
|
||||
* The channels our node knows about
|
||||
*
|
||||
* Generated from protobuf field <code>repeated .meshtastic.Channel channels = 1;</code>
|
||||
* @param array<\Meshtastic\Channel>|\Google\Protobuf\Internal\RepeatedField $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setChannels($var)
|
||||
{
|
||||
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Meshtastic\Channel::class);
|
||||
$this->channels = $arr;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* A version integer used to invalidate old save files when we make
|
||||
* incompatible changes This integer is set at build time and is private to
|
||||
* NodeDB.cpp in the device code.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 version = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getVersion()
|
||||
{
|
||||
return $this->version;
|
||||
}
|
||||
|
||||
/**
|
||||
* A version integer used to invalidate old save files when we make
|
||||
* incompatible changes This integer is set at build time and is private to
|
||||
* NodeDB.cpp in the device code.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 version = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setVersion($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->version = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/apponly.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* This is the most compact possible representation for a set of channels.
|
||||
* It includes only one PRIMARY channel (which must be first) and
|
||||
* any SECONDARY channels.
|
||||
* No DISABLED channels are included.
|
||||
* This abstraction is used only on the the 'app side' of the world (ie python, javascript and android etc) to show a group of Channels as a (long) URL
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.ChannelSet</code>
|
||||
*/
|
||||
class ChannelSet extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Channel list with settings
|
||||
*
|
||||
* Generated from protobuf field <code>repeated .meshtastic.ChannelSettings settings = 1;</code>
|
||||
*/
|
||||
private $settings;
|
||||
/**
|
||||
* LoRa config
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig lora_config = 2;</code>
|
||||
*/
|
||||
protected $lora_config = null;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type array<\Meshtastic\ChannelSettings>|\Google\Protobuf\Internal\RepeatedField $settings
|
||||
* Channel list with settings
|
||||
* @type \Meshtastic\Config\LoRaConfig $lora_config
|
||||
* LoRa config
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Apponly::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Channel list with settings
|
||||
*
|
||||
* Generated from protobuf field <code>repeated .meshtastic.ChannelSettings settings = 1;</code>
|
||||
* @return \Google\Protobuf\Internal\RepeatedField
|
||||
*/
|
||||
public function getSettings()
|
||||
{
|
||||
return $this->settings;
|
||||
}
|
||||
|
||||
/**
|
||||
* Channel list with settings
|
||||
*
|
||||
* Generated from protobuf field <code>repeated .meshtastic.ChannelSettings settings = 1;</code>
|
||||
* @param array<\Meshtastic\ChannelSettings>|\Google\Protobuf\Internal\RepeatedField $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSettings($var)
|
||||
{
|
||||
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Meshtastic\ChannelSettings::class);
|
||||
$this->settings = $arr;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* LoRa config
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig lora_config = 2;</code>
|
||||
* @return \Meshtastic\Config\LoRaConfig|null
|
||||
*/
|
||||
public function getLoraConfig()
|
||||
{
|
||||
return $this->lora_config;
|
||||
}
|
||||
|
||||
public function hasLoraConfig()
|
||||
{
|
||||
return isset($this->lora_config);
|
||||
}
|
||||
|
||||
public function clearLoraConfig()
|
||||
{
|
||||
unset($this->lora_config);
|
||||
}
|
||||
|
||||
/**
|
||||
* LoRa config
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig lora_config = 2;</code>
|
||||
* @param \Meshtastic\Config\LoRaConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setLoraConfig($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\LoRaConfig::class);
|
||||
$this->lora_config = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,404 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/channel.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* This information can be encoded as a QRcode/url so that other users can configure
|
||||
* their radio to join the same channel.
|
||||
* A note about how channel names are shown to users: channelname-X
|
||||
* poundsymbol is a prefix used to indicate this is a channel name (idea from @professr).
|
||||
* Where X is a letter from A-Z (base 26) representing a hash of the PSK for this
|
||||
* channel - so that if the user changes anything about the channel (which does
|
||||
* force a new PSK) this letter will also change. Thus preventing user confusion if
|
||||
* two friends try to type in a channel name of "BobsChan" and then can't talk
|
||||
* because their PSKs will be different.
|
||||
* The PSK is hashed into this letter by "0x41 + [xor all bytes of the psk ] modulo 26"
|
||||
* This also allows the option of someday if people have the PSK off (zero), the
|
||||
* users COULD type in a channel name and be able to talk.
|
||||
* FIXME: Add description of multi-channel support and how primary vs secondary channels are used.
|
||||
* FIXME: explain how apps use channels for security.
|
||||
* explain how remote settings and remote gpio are managed as an example
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.ChannelSettings</code>
|
||||
*/
|
||||
class ChannelSettings extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Deprecated in favor of LoraConfig.channel_num
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 channel_num = 1 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $channel_num = 0;
|
||||
/**
|
||||
* A simple pre-shared key for now for crypto.
|
||||
* Must be either 0 bytes (no crypto), 16 bytes (AES128), or 32 bytes (AES256).
|
||||
* A special shorthand is used for 1 byte long psks.
|
||||
* These psks should be treated as only minimally secure,
|
||||
* because they are listed in this source code.
|
||||
* Those bytes are mapped using the following scheme:
|
||||
* `0` = No crypto
|
||||
* `1` = The special "default" channel key: {0xd4, 0xf1, 0xbb, 0x3a, 0x20, 0x29, 0x07, 0x59, 0xf0, 0xbc, 0xff, 0xab, 0xcf, 0x4e, 0x69, 0x01}
|
||||
* `2` through 10 = The default channel key, except with 1 through 9 added to the last byte.
|
||||
* Shown to user as simple1 through 10
|
||||
*
|
||||
* Generated from protobuf field <code>bytes psk = 2;</code>
|
||||
*/
|
||||
protected $psk = '';
|
||||
/**
|
||||
* A SHORT name that will be packed into the URL.
|
||||
* Less than 12 bytes.
|
||||
* Something for end users to call the channel
|
||||
* If this is the empty string it is assumed that this channel
|
||||
* is the special (minimally secure) "Default"channel.
|
||||
* In user interfaces it should be rendered as a local language translation of "X".
|
||||
* For channel_num hashing empty string will be treated as "X".
|
||||
* Where "X" is selected based on the English words listed above for ModemPreset
|
||||
*
|
||||
* Generated from protobuf field <code>string name = 3;</code>
|
||||
*/
|
||||
protected $name = '';
|
||||
/**
|
||||
* Used to construct a globally unique channel ID.
|
||||
* The full globally unique ID will be: "name.id" where ID is shown as base36.
|
||||
* Assuming that the number of meshtastic users is below 20K (true for a long time)
|
||||
* the chance of this 64 bit random number colliding with anyone else is super low.
|
||||
* And the penalty for collision is low as well, it just means that anyone trying to decrypt channel messages might need to
|
||||
* try multiple candidate channels.
|
||||
* Any time a non wire compatible change is made to a channel, this field should be regenerated.
|
||||
* There are a small number of 'special' globally known (and fairly) insecure standard channels.
|
||||
* Those channels do not have a numeric id included in the settings, but instead it is pulled from
|
||||
* a table of well known IDs.
|
||||
* (see Well Known Channels FIXME)
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 id = 4;</code>
|
||||
*/
|
||||
protected $id = 0;
|
||||
/**
|
||||
* If true, messages on the mesh will be sent to the *public* internet by any gateway ndoe
|
||||
*
|
||||
* Generated from protobuf field <code>bool uplink_enabled = 5;</code>
|
||||
*/
|
||||
protected $uplink_enabled = false;
|
||||
/**
|
||||
* If true, messages seen on the internet will be forwarded to the local mesh.
|
||||
*
|
||||
* Generated from protobuf field <code>bool downlink_enabled = 6;</code>
|
||||
*/
|
||||
protected $downlink_enabled = false;
|
||||
/**
|
||||
* Per-channel module settings.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ModuleSettings module_settings = 7;</code>
|
||||
*/
|
||||
protected $module_settings = null;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $channel_num
|
||||
* Deprecated in favor of LoraConfig.channel_num
|
||||
* @type string $psk
|
||||
* A simple pre-shared key for now for crypto.
|
||||
* Must be either 0 bytes (no crypto), 16 bytes (AES128), or 32 bytes (AES256).
|
||||
* A special shorthand is used for 1 byte long psks.
|
||||
* These psks should be treated as only minimally secure,
|
||||
* because they are listed in this source code.
|
||||
* Those bytes are mapped using the following scheme:
|
||||
* `0` = No crypto
|
||||
* `1` = The special "default" channel key: {0xd4, 0xf1, 0xbb, 0x3a, 0x20, 0x29, 0x07, 0x59, 0xf0, 0xbc, 0xff, 0xab, 0xcf, 0x4e, 0x69, 0x01}
|
||||
* `2` through 10 = The default channel key, except with 1 through 9 added to the last byte.
|
||||
* Shown to user as simple1 through 10
|
||||
* @type string $name
|
||||
* A SHORT name that will be packed into the URL.
|
||||
* Less than 12 bytes.
|
||||
* Something for end users to call the channel
|
||||
* If this is the empty string it is assumed that this channel
|
||||
* is the special (minimally secure) "Default"channel.
|
||||
* In user interfaces it should be rendered as a local language translation of "X".
|
||||
* For channel_num hashing empty string will be treated as "X".
|
||||
* Where "X" is selected based on the English words listed above for ModemPreset
|
||||
* @type int $id
|
||||
* Used to construct a globally unique channel ID.
|
||||
* The full globally unique ID will be: "name.id" where ID is shown as base36.
|
||||
* Assuming that the number of meshtastic users is below 20K (true for a long time)
|
||||
* the chance of this 64 bit random number colliding with anyone else is super low.
|
||||
* And the penalty for collision is low as well, it just means that anyone trying to decrypt channel messages might need to
|
||||
* try multiple candidate channels.
|
||||
* Any time a non wire compatible change is made to a channel, this field should be regenerated.
|
||||
* There are a small number of 'special' globally known (and fairly) insecure standard channels.
|
||||
* Those channels do not have a numeric id included in the settings, but instead it is pulled from
|
||||
* a table of well known IDs.
|
||||
* (see Well Known Channels FIXME)
|
||||
* @type bool $uplink_enabled
|
||||
* If true, messages on the mesh will be sent to the *public* internet by any gateway ndoe
|
||||
* @type bool $downlink_enabled
|
||||
* If true, messages seen on the internet will be forwarded to the local mesh.
|
||||
* @type \Meshtastic\ModuleSettings $module_settings
|
||||
* Per-channel module settings.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Channel::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Deprecated in favor of LoraConfig.channel_num
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 channel_num = 1 [deprecated = true];</code>
|
||||
* @return int
|
||||
* @deprecated
|
||||
*/
|
||||
public function getChannelNum()
|
||||
{
|
||||
@trigger_error('channel_num is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->channel_num;
|
||||
}
|
||||
|
||||
/**
|
||||
* Deprecated in favor of LoraConfig.channel_num
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 channel_num = 1 [deprecated = true];</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setChannelNum($var)
|
||||
{
|
||||
@trigger_error('channel_num is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->channel_num = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* A simple pre-shared key for now for crypto.
|
||||
* Must be either 0 bytes (no crypto), 16 bytes (AES128), or 32 bytes (AES256).
|
||||
* A special shorthand is used for 1 byte long psks.
|
||||
* These psks should be treated as only minimally secure,
|
||||
* because they are listed in this source code.
|
||||
* Those bytes are mapped using the following scheme:
|
||||
* `0` = No crypto
|
||||
* `1` = The special "default" channel key: {0xd4, 0xf1, 0xbb, 0x3a, 0x20, 0x29, 0x07, 0x59, 0xf0, 0xbc, 0xff, 0xab, 0xcf, 0x4e, 0x69, 0x01}
|
||||
* `2` through 10 = The default channel key, except with 1 through 9 added to the last byte.
|
||||
* Shown to user as simple1 through 10
|
||||
*
|
||||
* Generated from protobuf field <code>bytes psk = 2;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getPsk()
|
||||
{
|
||||
return $this->psk;
|
||||
}
|
||||
|
||||
/**
|
||||
* A simple pre-shared key for now for crypto.
|
||||
* Must be either 0 bytes (no crypto), 16 bytes (AES128), or 32 bytes (AES256).
|
||||
* A special shorthand is used for 1 byte long psks.
|
||||
* These psks should be treated as only minimally secure,
|
||||
* because they are listed in this source code.
|
||||
* Those bytes are mapped using the following scheme:
|
||||
* `0` = No crypto
|
||||
* `1` = The special "default" channel key: {0xd4, 0xf1, 0xbb, 0x3a, 0x20, 0x29, 0x07, 0x59, 0xf0, 0xbc, 0xff, 0xab, 0xcf, 0x4e, 0x69, 0x01}
|
||||
* `2` through 10 = The default channel key, except with 1 through 9 added to the last byte.
|
||||
* Shown to user as simple1 through 10
|
||||
*
|
||||
* Generated from protobuf field <code>bytes psk = 2;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPsk($var)
|
||||
{
|
||||
GPBUtil::checkString($var, False);
|
||||
$this->psk = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* A SHORT name that will be packed into the URL.
|
||||
* Less than 12 bytes.
|
||||
* Something for end users to call the channel
|
||||
* If this is the empty string it is assumed that this channel
|
||||
* is the special (minimally secure) "Default"channel.
|
||||
* In user interfaces it should be rendered as a local language translation of "X".
|
||||
* For channel_num hashing empty string will be treated as "X".
|
||||
* Where "X" is selected based on the English words listed above for ModemPreset
|
||||
*
|
||||
* Generated from protobuf field <code>string name = 3;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getName()
|
||||
{
|
||||
return $this->name;
|
||||
}
|
||||
|
||||
/**
|
||||
* A SHORT name that will be packed into the URL.
|
||||
* Less than 12 bytes.
|
||||
* Something for end users to call the channel
|
||||
* If this is the empty string it is assumed that this channel
|
||||
* is the special (minimally secure) "Default"channel.
|
||||
* In user interfaces it should be rendered as a local language translation of "X".
|
||||
* For channel_num hashing empty string will be treated as "X".
|
||||
* Where "X" is selected based on the English words listed above for ModemPreset
|
||||
*
|
||||
* Generated from protobuf field <code>string name = 3;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setName($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->name = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Used to construct a globally unique channel ID.
|
||||
* The full globally unique ID will be: "name.id" where ID is shown as base36.
|
||||
* Assuming that the number of meshtastic users is below 20K (true for a long time)
|
||||
* the chance of this 64 bit random number colliding with anyone else is super low.
|
||||
* And the penalty for collision is low as well, it just means that anyone trying to decrypt channel messages might need to
|
||||
* try multiple candidate channels.
|
||||
* Any time a non wire compatible change is made to a channel, this field should be regenerated.
|
||||
* There are a small number of 'special' globally known (and fairly) insecure standard channels.
|
||||
* Those channels do not have a numeric id included in the settings, but instead it is pulled from
|
||||
* a table of well known IDs.
|
||||
* (see Well Known Channels FIXME)
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 id = 4;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getId()
|
||||
{
|
||||
return $this->id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Used to construct a globally unique channel ID.
|
||||
* The full globally unique ID will be: "name.id" where ID is shown as base36.
|
||||
* Assuming that the number of meshtastic users is below 20K (true for a long time)
|
||||
* the chance of this 64 bit random number colliding with anyone else is super low.
|
||||
* And the penalty for collision is low as well, it just means that anyone trying to decrypt channel messages might need to
|
||||
* try multiple candidate channels.
|
||||
* Any time a non wire compatible change is made to a channel, this field should be regenerated.
|
||||
* There are a small number of 'special' globally known (and fairly) insecure standard channels.
|
||||
* Those channels do not have a numeric id included in the settings, but instead it is pulled from
|
||||
* a table of well known IDs.
|
||||
* (see Well Known Channels FIXME)
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 id = 4;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setId($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->id = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, messages on the mesh will be sent to the *public* internet by any gateway ndoe
|
||||
*
|
||||
* Generated from protobuf field <code>bool uplink_enabled = 5;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getUplinkEnabled()
|
||||
{
|
||||
return $this->uplink_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, messages on the mesh will be sent to the *public* internet by any gateway ndoe
|
||||
*
|
||||
* Generated from protobuf field <code>bool uplink_enabled = 5;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setUplinkEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->uplink_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, messages seen on the internet will be forwarded to the local mesh.
|
||||
*
|
||||
* Generated from protobuf field <code>bool downlink_enabled = 6;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getDownlinkEnabled()
|
||||
{
|
||||
return $this->downlink_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, messages seen on the internet will be forwarded to the local mesh.
|
||||
*
|
||||
* Generated from protobuf field <code>bool downlink_enabled = 6;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDownlinkEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->downlink_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Per-channel module settings.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ModuleSettings module_settings = 7;</code>
|
||||
* @return \Meshtastic\ModuleSettings|null
|
||||
*/
|
||||
public function getModuleSettings()
|
||||
{
|
||||
return $this->module_settings;
|
||||
}
|
||||
|
||||
public function hasModuleSettings()
|
||||
{
|
||||
return isset($this->module_settings);
|
||||
}
|
||||
|
||||
public function clearModuleSettings()
|
||||
{
|
||||
unset($this->module_settings);
|
||||
}
|
||||
|
||||
/**
|
||||
* Per-channel module settings.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.ModuleSettings module_settings = 7;</code>
|
||||
* @param \Meshtastic\ModuleSettings $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setModuleSettings($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\ModuleSettings::class);
|
||||
$this->module_settings = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/channel.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Channel\Role instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Channel_Role {}
|
||||
}
|
||||
class_exists(Channel\Role::class);
|
||||
@trigger_error('Meshtastic\Channel_Role is deprecated and will be removed in the next major release. Use Meshtastic\Channel\Role instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,167 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/mesh.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Generated from protobuf message <code>meshtastic.ChunkedPayload</code>
|
||||
*/
|
||||
class ChunkedPayload extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The ID of the entire payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 payload_id = 1;</code>
|
||||
*/
|
||||
protected $payload_id = 0;
|
||||
/**
|
||||
* The total number of chunks in the payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 chunk_count = 2;</code>
|
||||
*/
|
||||
protected $chunk_count = 0;
|
||||
/**
|
||||
* The current chunk index in the total
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 chunk_index = 3;</code>
|
||||
*/
|
||||
protected $chunk_index = 0;
|
||||
/**
|
||||
* The binary data of the current chunk
|
||||
*
|
||||
* Generated from protobuf field <code>bytes payload_chunk = 4;</code>
|
||||
*/
|
||||
protected $payload_chunk = '';
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $payload_id
|
||||
* The ID of the entire payload
|
||||
* @type int $chunk_count
|
||||
* The total number of chunks in the payload
|
||||
* @type int $chunk_index
|
||||
* The current chunk index in the total
|
||||
* @type string $payload_chunk
|
||||
* The binary data of the current chunk
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Mesh::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The ID of the entire payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 payload_id = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getPayloadId()
|
||||
{
|
||||
return $this->payload_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* The ID of the entire payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 payload_id = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPayloadId($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->payload_id = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The total number of chunks in the payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 chunk_count = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getChunkCount()
|
||||
{
|
||||
return $this->chunk_count;
|
||||
}
|
||||
|
||||
/**
|
||||
* The total number of chunks in the payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 chunk_count = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setChunkCount($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->chunk_count = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The current chunk index in the total
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 chunk_index = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getChunkIndex()
|
||||
{
|
||||
return $this->chunk_index;
|
||||
}
|
||||
|
||||
/**
|
||||
* The current chunk index in the total
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 chunk_index = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setChunkIndex($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->chunk_index = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The binary data of the current chunk
|
||||
*
|
||||
* Generated from protobuf field <code>bytes payload_chunk = 4;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getPayloadChunk()
|
||||
{
|
||||
return $this->payload_chunk;
|
||||
}
|
||||
|
||||
/**
|
||||
* The binary data of the current chunk
|
||||
*
|
||||
* Generated from protobuf field <code>bytes payload_chunk = 4;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPayloadChunk($var)
|
||||
{
|
||||
GPBUtil::checkString($var, False);
|
||||
$this->payload_chunk = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,175 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/mesh.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Responses to a ChunkedPayload request
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.ChunkedPayloadResponse</code>
|
||||
*/
|
||||
class ChunkedPayloadResponse extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The ID of the entire payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 payload_id = 1;</code>
|
||||
*/
|
||||
protected $payload_id = 0;
|
||||
protected $payload_variant;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $payload_id
|
||||
* The ID of the entire payload
|
||||
* @type bool $request_transfer
|
||||
* Request to transfer chunked payload
|
||||
* @type bool $accept_transfer
|
||||
* Accept the transfer chunked payload
|
||||
* @type \Meshtastic\resend_chunks $resend_chunks
|
||||
* Request missing indexes in the chunked payload
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Mesh::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The ID of the entire payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 payload_id = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getPayloadId()
|
||||
{
|
||||
return $this->payload_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* The ID of the entire payload
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 payload_id = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPayloadId($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->payload_id = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Request to transfer chunked payload
|
||||
*
|
||||
* Generated from protobuf field <code>bool request_transfer = 2;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getRequestTransfer()
|
||||
{
|
||||
return $this->readOneof(2);
|
||||
}
|
||||
|
||||
public function hasRequestTransfer()
|
||||
{
|
||||
return $this->hasOneof(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Request to transfer chunked payload
|
||||
*
|
||||
* Generated from protobuf field <code>bool request_transfer = 2;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRequestTransfer($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->writeOneof(2, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Accept the transfer chunked payload
|
||||
*
|
||||
* Generated from protobuf field <code>bool accept_transfer = 3;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getAcceptTransfer()
|
||||
{
|
||||
return $this->readOneof(3);
|
||||
}
|
||||
|
||||
public function hasAcceptTransfer()
|
||||
{
|
||||
return $this->hasOneof(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Accept the transfer chunked payload
|
||||
*
|
||||
* Generated from protobuf field <code>bool accept_transfer = 3;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setAcceptTransfer($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->writeOneof(3, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Request missing indexes in the chunked payload
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.resend_chunks resend_chunks = 4;</code>
|
||||
* @return \Meshtastic\resend_chunks|null
|
||||
*/
|
||||
public function getResendChunks()
|
||||
{
|
||||
return $this->readOneof(4);
|
||||
}
|
||||
|
||||
public function hasResendChunks()
|
||||
{
|
||||
return $this->hasOneof(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Request missing indexes in the chunked payload
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.resend_chunks resend_chunks = 4;</code>
|
||||
* @param \Meshtastic\resend_chunks $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setResendChunks($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\resend_chunks::class);
|
||||
$this->writeOneof(4, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getPayloadVariant()
|
||||
{
|
||||
return $this->whichOneof("payload_variant");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,331 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/mesh.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* A notification message from the device to the client
|
||||
* To be used for important messages that should to be displayed to the user
|
||||
* in the form of push notifications or validation messages when saving
|
||||
* invalid configuration.
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.ClientNotification</code>
|
||||
*/
|
||||
class ClientNotification extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The id of the packet we're notifying in response to
|
||||
*
|
||||
* Generated from protobuf field <code>optional uint32 reply_id = 1;</code>
|
||||
*/
|
||||
protected $reply_id = null;
|
||||
/**
|
||||
* Seconds since 1970 - or 0 for unknown/unset
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 time = 2;</code>
|
||||
*/
|
||||
protected $time = 0;
|
||||
/**
|
||||
* The level type of notification
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LogRecord.Level level = 3;</code>
|
||||
*/
|
||||
protected $level = 0;
|
||||
/**
|
||||
* The message body of the notification
|
||||
*
|
||||
* Generated from protobuf field <code>string message = 4;</code>
|
||||
*/
|
||||
protected $message = '';
|
||||
protected $payload_variant;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $reply_id
|
||||
* The id of the packet we're notifying in response to
|
||||
* @type int $time
|
||||
* Seconds since 1970 - or 0 for unknown/unset
|
||||
* @type int $level
|
||||
* The level type of notification
|
||||
* @type string $message
|
||||
* The message body of the notification
|
||||
* @type \Meshtastic\KeyVerificationNumberInform $key_verification_number_inform
|
||||
* @type \Meshtastic\KeyVerificationNumberRequest $key_verification_number_request
|
||||
* @type \Meshtastic\KeyVerificationFinal $key_verification_final
|
||||
* @type \Meshtastic\DuplicatedPublicKey $duplicated_public_key
|
||||
* @type \Meshtastic\LowEntropyKey $low_entropy_key
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Mesh::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The id of the packet we're notifying in response to
|
||||
*
|
||||
* Generated from protobuf field <code>optional uint32 reply_id = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getReplyId()
|
||||
{
|
||||
return isset($this->reply_id) ? $this->reply_id : 0;
|
||||
}
|
||||
|
||||
public function hasReplyId()
|
||||
{
|
||||
return isset($this->reply_id);
|
||||
}
|
||||
|
||||
public function clearReplyId()
|
||||
{
|
||||
unset($this->reply_id);
|
||||
}
|
||||
|
||||
/**
|
||||
* The id of the packet we're notifying in response to
|
||||
*
|
||||
* Generated from protobuf field <code>optional uint32 reply_id = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setReplyId($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->reply_id = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Seconds since 1970 - or 0 for unknown/unset
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 time = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getTime()
|
||||
{
|
||||
return $this->time;
|
||||
}
|
||||
|
||||
/**
|
||||
* Seconds since 1970 - or 0 for unknown/unset
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 time = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTime($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->time = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The level type of notification
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LogRecord.Level level = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getLevel()
|
||||
{
|
||||
return $this->level;
|
||||
}
|
||||
|
||||
/**
|
||||
* The level type of notification
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.LogRecord.Level level = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setLevel($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\LogRecord\Level::class);
|
||||
$this->level = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The message body of the notification
|
||||
*
|
||||
* Generated from protobuf field <code>string message = 4;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getMessage()
|
||||
{
|
||||
return $this->message;
|
||||
}
|
||||
|
||||
/**
|
||||
* The message body of the notification
|
||||
*
|
||||
* Generated from protobuf field <code>string message = 4;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setMessage($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->message = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.KeyVerificationNumberInform key_verification_number_inform = 11;</code>
|
||||
* @return \Meshtastic\KeyVerificationNumberInform|null
|
||||
*/
|
||||
public function getKeyVerificationNumberInform()
|
||||
{
|
||||
return $this->readOneof(11);
|
||||
}
|
||||
|
||||
public function hasKeyVerificationNumberInform()
|
||||
{
|
||||
return $this->hasOneof(11);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.KeyVerificationNumberInform key_verification_number_inform = 11;</code>
|
||||
* @param \Meshtastic\KeyVerificationNumberInform $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setKeyVerificationNumberInform($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\KeyVerificationNumberInform::class);
|
||||
$this->writeOneof(11, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.KeyVerificationNumberRequest key_verification_number_request = 12;</code>
|
||||
* @return \Meshtastic\KeyVerificationNumberRequest|null
|
||||
*/
|
||||
public function getKeyVerificationNumberRequest()
|
||||
{
|
||||
return $this->readOneof(12);
|
||||
}
|
||||
|
||||
public function hasKeyVerificationNumberRequest()
|
||||
{
|
||||
return $this->hasOneof(12);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.KeyVerificationNumberRequest key_verification_number_request = 12;</code>
|
||||
* @param \Meshtastic\KeyVerificationNumberRequest $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setKeyVerificationNumberRequest($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\KeyVerificationNumberRequest::class);
|
||||
$this->writeOneof(12, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.KeyVerificationFinal key_verification_final = 13;</code>
|
||||
* @return \Meshtastic\KeyVerificationFinal|null
|
||||
*/
|
||||
public function getKeyVerificationFinal()
|
||||
{
|
||||
return $this->readOneof(13);
|
||||
}
|
||||
|
||||
public function hasKeyVerificationFinal()
|
||||
{
|
||||
return $this->hasOneof(13);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.KeyVerificationFinal key_verification_final = 13;</code>
|
||||
* @param \Meshtastic\KeyVerificationFinal $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setKeyVerificationFinal($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\KeyVerificationFinal::class);
|
||||
$this->writeOneof(13, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.DuplicatedPublicKey duplicated_public_key = 14;</code>
|
||||
* @return \Meshtastic\DuplicatedPublicKey|null
|
||||
*/
|
||||
public function getDuplicatedPublicKey()
|
||||
{
|
||||
return $this->readOneof(14);
|
||||
}
|
||||
|
||||
public function hasDuplicatedPublicKey()
|
||||
{
|
||||
return $this->hasOneof(14);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.DuplicatedPublicKey duplicated_public_key = 14;</code>
|
||||
* @param \Meshtastic\DuplicatedPublicKey $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDuplicatedPublicKey($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\DuplicatedPublicKey::class);
|
||||
$this->writeOneof(14, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.LowEntropyKey low_entropy_key = 15;</code>
|
||||
* @return \Meshtastic\LowEntropyKey|null
|
||||
*/
|
||||
public function getLowEntropyKey()
|
||||
{
|
||||
return $this->readOneof(15);
|
||||
}
|
||||
|
||||
public function hasLowEntropyKey()
|
||||
{
|
||||
return $this->hasOneof(15);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.LowEntropyKey low_entropy_key = 15;</code>
|
||||
* @param \Meshtastic\LowEntropyKey $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setLowEntropyKey($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\LowEntropyKey::class);
|
||||
$this->writeOneof(15, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getPayloadVariant()
|
||||
{
|
||||
return $this->whichOneof("payload_variant");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/device_ui.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.CompassMode</code>
|
||||
*/
|
||||
class CompassMode
|
||||
{
|
||||
/**
|
||||
* Compass with dynamic ring and heading
|
||||
*
|
||||
* Generated from protobuf enum <code>DYNAMIC = 0;</code>
|
||||
*/
|
||||
const DYNAMIC = 0;
|
||||
/**
|
||||
* Compass with fixed ring and heading
|
||||
*
|
||||
* Generated from protobuf enum <code>FIXED_RING = 1;</code>
|
||||
*/
|
||||
const FIXED_RING = 1;
|
||||
/**
|
||||
* Compass with heading and freeze option
|
||||
*
|
||||
* Generated from protobuf enum <code>FREEZE_HEADING = 2;</code>
|
||||
*/
|
||||
const FREEZE_HEADING = 2;
|
||||
|
||||
private static $valueToName = [
|
||||
self::DYNAMIC => 'DYNAMIC',
|
||||
self::FIXED_RING => 'FIXED_RING',
|
||||
self::FREEZE_HEADING => 'FREEZE_HEADING',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,101 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/mesh.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Compressed message payload
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Compressed</code>
|
||||
*/
|
||||
class Compressed extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* PortNum to determine the how to handle the compressed payload.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.PortNum portnum = 1;</code>
|
||||
*/
|
||||
protected $portnum = 0;
|
||||
/**
|
||||
* Compressed data.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes data = 2;</code>
|
||||
*/
|
||||
protected $data = '';
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $portnum
|
||||
* PortNum to determine the how to handle the compressed payload.
|
||||
* @type string $data
|
||||
* Compressed data.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Mesh::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* PortNum to determine the how to handle the compressed payload.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.PortNum portnum = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getPortnum()
|
||||
{
|
||||
return $this->portnum;
|
||||
}
|
||||
|
||||
/**
|
||||
* PortNum to determine the how to handle the compressed payload.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.PortNum portnum = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPortnum($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\PortNum::class);
|
||||
$this->portnum = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Compressed data.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes data = 2;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getData()
|
||||
{
|
||||
return $this->data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Compressed data.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes data = 2;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setData($var)
|
||||
{
|
||||
GPBUtil::checkString($var, False);
|
||||
$this->data = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,320 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Generated from protobuf message <code>meshtastic.Config</code>
|
||||
*/
|
||||
class Config extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
protected $payload_variant;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type \Meshtastic\Config\DeviceConfig $device
|
||||
* @type \Meshtastic\Config\PositionConfig $position
|
||||
* @type \Meshtastic\Config\PowerConfig $power
|
||||
* @type \Meshtastic\Config\NetworkConfig $network
|
||||
* @type \Meshtastic\Config\DisplayConfig $display
|
||||
* @type \Meshtastic\Config\LoRaConfig $lora
|
||||
* @type \Meshtastic\Config\BluetoothConfig $bluetooth
|
||||
* @type \Meshtastic\Config\SecurityConfig $security
|
||||
* @type \Meshtastic\Config\SessionkeyConfig $sessionkey
|
||||
* @type \Meshtastic\DeviceUIConfig $device_ui
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig device = 1;</code>
|
||||
* @return \Meshtastic\Config\DeviceConfig|null
|
||||
*/
|
||||
public function getDevice()
|
||||
{
|
||||
return $this->readOneof(1);
|
||||
}
|
||||
|
||||
public function hasDevice()
|
||||
{
|
||||
return $this->hasOneof(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig device = 1;</code>
|
||||
* @param \Meshtastic\Config\DeviceConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDevice($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\DeviceConfig::class);
|
||||
$this->writeOneof(1, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PositionConfig position = 2;</code>
|
||||
* @return \Meshtastic\Config\PositionConfig|null
|
||||
*/
|
||||
public function getPosition()
|
||||
{
|
||||
return $this->readOneof(2);
|
||||
}
|
||||
|
||||
public function hasPosition()
|
||||
{
|
||||
return $this->hasOneof(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PositionConfig position = 2;</code>
|
||||
* @param \Meshtastic\Config\PositionConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPosition($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\PositionConfig::class);
|
||||
$this->writeOneof(2, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PowerConfig power = 3;</code>
|
||||
* @return \Meshtastic\Config\PowerConfig|null
|
||||
*/
|
||||
public function getPower()
|
||||
{
|
||||
return $this->readOneof(3);
|
||||
}
|
||||
|
||||
public function hasPower()
|
||||
{
|
||||
return $this->hasOneof(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PowerConfig power = 3;</code>
|
||||
* @param \Meshtastic\Config\PowerConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPower($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\PowerConfig::class);
|
||||
$this->writeOneof(3, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig network = 4;</code>
|
||||
* @return \Meshtastic\Config\NetworkConfig|null
|
||||
*/
|
||||
public function getNetwork()
|
||||
{
|
||||
return $this->readOneof(4);
|
||||
}
|
||||
|
||||
public function hasNetwork()
|
||||
{
|
||||
return $this->hasOneof(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig network = 4;</code>
|
||||
* @param \Meshtastic\Config\NetworkConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setNetwork($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\NetworkConfig::class);
|
||||
$this->writeOneof(4, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig display = 5;</code>
|
||||
* @return \Meshtastic\Config\DisplayConfig|null
|
||||
*/
|
||||
public function getDisplay()
|
||||
{
|
||||
return $this->readOneof(5);
|
||||
}
|
||||
|
||||
public function hasDisplay()
|
||||
{
|
||||
return $this->hasOneof(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig display = 5;</code>
|
||||
* @param \Meshtastic\Config\DisplayConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDisplay($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\DisplayConfig::class);
|
||||
$this->writeOneof(5, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig lora = 6;</code>
|
||||
* @return \Meshtastic\Config\LoRaConfig|null
|
||||
*/
|
||||
public function getLora()
|
||||
{
|
||||
return $this->readOneof(6);
|
||||
}
|
||||
|
||||
public function hasLora()
|
||||
{
|
||||
return $this->hasOneof(6);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig lora = 6;</code>
|
||||
* @param \Meshtastic\Config\LoRaConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setLora($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\LoRaConfig::class);
|
||||
$this->writeOneof(6, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.BluetoothConfig bluetooth = 7;</code>
|
||||
* @return \Meshtastic\Config\BluetoothConfig|null
|
||||
*/
|
||||
public function getBluetooth()
|
||||
{
|
||||
return $this->readOneof(7);
|
||||
}
|
||||
|
||||
public function hasBluetooth()
|
||||
{
|
||||
return $this->hasOneof(7);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.BluetoothConfig bluetooth = 7;</code>
|
||||
* @param \Meshtastic\Config\BluetoothConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setBluetooth($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\BluetoothConfig::class);
|
||||
$this->writeOneof(7, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.SecurityConfig security = 8;</code>
|
||||
* @return \Meshtastic\Config\SecurityConfig|null
|
||||
*/
|
||||
public function getSecurity()
|
||||
{
|
||||
return $this->readOneof(8);
|
||||
}
|
||||
|
||||
public function hasSecurity()
|
||||
{
|
||||
return $this->hasOneof(8);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.SecurityConfig security = 8;</code>
|
||||
* @param \Meshtastic\Config\SecurityConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSecurity($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\SecurityConfig::class);
|
||||
$this->writeOneof(8, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.SessionkeyConfig sessionkey = 9;</code>
|
||||
* @return \Meshtastic\Config\SessionkeyConfig|null
|
||||
*/
|
||||
public function getSessionkey()
|
||||
{
|
||||
return $this->readOneof(9);
|
||||
}
|
||||
|
||||
public function hasSessionkey()
|
||||
{
|
||||
return $this->hasOneof(9);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.Config.SessionkeyConfig sessionkey = 9;</code>
|
||||
* @param \Meshtastic\Config\SessionkeyConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSessionkey($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\SessionkeyConfig::class);
|
||||
$this->writeOneof(9, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.DeviceUIConfig device_ui = 10;</code>
|
||||
* @return \Meshtastic\DeviceUIConfig|null
|
||||
*/
|
||||
public function getDeviceUi()
|
||||
{
|
||||
return $this->readOneof(10);
|
||||
}
|
||||
|
||||
public function hasDeviceUi()
|
||||
{
|
||||
return $this->hasOneof(10);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generated from protobuf field <code>.meshtastic.DeviceUIConfig device_ui = 10;</code>
|
||||
* @param \Meshtastic\DeviceUIConfig $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDeviceUi($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\DeviceUIConfig::class);
|
||||
$this->writeOneof(10, $var);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getPayloadVariant()
|
||||
{
|
||||
return $this->whichOneof("payload_variant");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,136 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Generated from protobuf message <code>meshtastic.Config.BluetoothConfig</code>
|
||||
*/
|
||||
class BluetoothConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Enable Bluetooth on the device
|
||||
*
|
||||
* Generated from protobuf field <code>bool enabled = 1;</code>
|
||||
*/
|
||||
protected $enabled = false;
|
||||
/**
|
||||
* Determines the pairing strategy for the device
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.BluetoothConfig.PairingMode mode = 2;</code>
|
||||
*/
|
||||
protected $mode = 0;
|
||||
/**
|
||||
* Specified PIN for PairingMode.FixedPin
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 fixed_pin = 3;</code>
|
||||
*/
|
||||
protected $fixed_pin = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type bool $enabled
|
||||
* Enable Bluetooth on the device
|
||||
* @type int $mode
|
||||
* Determines the pairing strategy for the device
|
||||
* @type int $fixed_pin
|
||||
* Specified PIN for PairingMode.FixedPin
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable Bluetooth on the device
|
||||
*
|
||||
* Generated from protobuf field <code>bool enabled = 1;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getEnabled()
|
||||
{
|
||||
return $this->enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable Bluetooth on the device
|
||||
*
|
||||
* Generated from protobuf field <code>bool enabled = 1;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines the pairing strategy for the device
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.BluetoothConfig.PairingMode mode = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getMode()
|
||||
{
|
||||
return $this->mode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines the pairing strategy for the device
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.BluetoothConfig.PairingMode mode = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setMode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\BluetoothConfig\PairingMode::class);
|
||||
$this->mode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Specified PIN for PairingMode.FixedPin
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 fixed_pin = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getFixedPin()
|
||||
{
|
||||
return $this->fixed_pin;
|
||||
}
|
||||
|
||||
/**
|
||||
* Specified PIN for PairingMode.FixedPin
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 fixed_pin = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setFixedPin($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->fixed_pin = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(BluetoothConfig::class, \Meshtastic\Config_BluetoothConfig::class);
|
||||
|
||||
@@ -0,0 +1,62 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\BluetoothConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.Config.BluetoothConfig.PairingMode</code>
|
||||
*/
|
||||
class PairingMode
|
||||
{
|
||||
/**
|
||||
* Device generates a random PIN that will be shown on the screen of the device for pairing
|
||||
*
|
||||
* Generated from protobuf enum <code>RANDOM_PIN = 0;</code>
|
||||
*/
|
||||
const RANDOM_PIN = 0;
|
||||
/**
|
||||
* Device requires a specified fixed PIN for pairing
|
||||
*
|
||||
* Generated from protobuf enum <code>FIXED_PIN = 1;</code>
|
||||
*/
|
||||
const FIXED_PIN = 1;
|
||||
/**
|
||||
* Device requires no PIN for pairing
|
||||
*
|
||||
* Generated from protobuf enum <code>NO_PIN = 2;</code>
|
||||
*/
|
||||
const NO_PIN = 2;
|
||||
|
||||
private static $valueToName = [
|
||||
self::RANDOM_PIN => 'RANDOM_PIN',
|
||||
self::FIXED_PIN => 'FIXED_PIN',
|
||||
self::NO_PIN => 'NO_PIN',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(PairingMode::class, \Meshtastic\Config_BluetoothConfig_PairingMode::class);
|
||||
|
||||
@@ -0,0 +1,482 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Configuration
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.DeviceConfig</code>
|
||||
*/
|
||||
class DeviceConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Sets the role of node
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.Role role = 1;</code>
|
||||
*/
|
||||
protected $role = 0;
|
||||
/**
|
||||
* Disabling this will disable the SerialConsole by not initilizing the StreamAPI
|
||||
* Moved to SecurityConfig
|
||||
*
|
||||
* Generated from protobuf field <code>bool serial_enabled = 2 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $serial_enabled = false;
|
||||
/**
|
||||
* For boards without a hard wired button, this is the pin number that will be used
|
||||
* Boards that have more than one button can swap the function with this one. defaults to BUTTON_PIN if defined.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 button_gpio = 4;</code>
|
||||
*/
|
||||
protected $button_gpio = 0;
|
||||
/**
|
||||
* For boards without a PWM buzzer, this is the pin number that will be used
|
||||
* Defaults to PIN_BUZZER if defined.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 buzzer_gpio = 5;</code>
|
||||
*/
|
||||
protected $buzzer_gpio = 0;
|
||||
/**
|
||||
* Sets the role of node
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.RebroadcastMode rebroadcast_mode = 6;</code>
|
||||
*/
|
||||
protected $rebroadcast_mode = 0;
|
||||
/**
|
||||
* Send our nodeinfo this often
|
||||
* Defaults to 900 Seconds (15 minutes)
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 node_info_broadcast_secs = 7;</code>
|
||||
*/
|
||||
protected $node_info_broadcast_secs = 0;
|
||||
/**
|
||||
* Treat double tap interrupt on supported accelerometers as a button press if set to true
|
||||
*
|
||||
* Generated from protobuf field <code>bool double_tap_as_button_press = 8;</code>
|
||||
*/
|
||||
protected $double_tap_as_button_press = false;
|
||||
/**
|
||||
* If true, device is considered to be "managed" by a mesh administrator
|
||||
* Clients should then limit available configuration and administrative options inside the user interface
|
||||
* Moved to SecurityConfig
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_managed = 9 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $is_managed = false;
|
||||
/**
|
||||
* Disables the triple-press of user button to enable or disable GPS
|
||||
*
|
||||
* Generated from protobuf field <code>bool disable_triple_click = 10;</code>
|
||||
*/
|
||||
protected $disable_triple_click = false;
|
||||
/**
|
||||
* POSIX Timezone definition string from https://github.com/nayarsystems/posix_tz_db/blob/master/zones.csv.
|
||||
*
|
||||
* Generated from protobuf field <code>string tzdef = 11;</code>
|
||||
*/
|
||||
protected $tzdef = '';
|
||||
/**
|
||||
* If true, disable the default blinking LED (LED_PIN) behavior on the device
|
||||
*
|
||||
* Generated from protobuf field <code>bool led_heartbeat_disabled = 12;</code>
|
||||
*/
|
||||
protected $led_heartbeat_disabled = false;
|
||||
/**
|
||||
* Controls buzzer behavior for audio feedback
|
||||
* Defaults to ENABLED
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.BuzzerMode buzzer_mode = 13;</code>
|
||||
*/
|
||||
protected $buzzer_mode = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $role
|
||||
* Sets the role of node
|
||||
* @type bool $serial_enabled
|
||||
* Disabling this will disable the SerialConsole by not initilizing the StreamAPI
|
||||
* Moved to SecurityConfig
|
||||
* @type int $button_gpio
|
||||
* For boards without a hard wired button, this is the pin number that will be used
|
||||
* Boards that have more than one button can swap the function with this one. defaults to BUTTON_PIN if defined.
|
||||
* @type int $buzzer_gpio
|
||||
* For boards without a PWM buzzer, this is the pin number that will be used
|
||||
* Defaults to PIN_BUZZER if defined.
|
||||
* @type int $rebroadcast_mode
|
||||
* Sets the role of node
|
||||
* @type int $node_info_broadcast_secs
|
||||
* Send our nodeinfo this often
|
||||
* Defaults to 900 Seconds (15 minutes)
|
||||
* @type bool $double_tap_as_button_press
|
||||
* Treat double tap interrupt on supported accelerometers as a button press if set to true
|
||||
* @type bool $is_managed
|
||||
* If true, device is considered to be "managed" by a mesh administrator
|
||||
* Clients should then limit available configuration and administrative options inside the user interface
|
||||
* Moved to SecurityConfig
|
||||
* @type bool $disable_triple_click
|
||||
* Disables the triple-press of user button to enable or disable GPS
|
||||
* @type string $tzdef
|
||||
* POSIX Timezone definition string from https://github.com/nayarsystems/posix_tz_db/blob/master/zones.csv.
|
||||
* @type bool $led_heartbeat_disabled
|
||||
* If true, disable the default blinking LED (LED_PIN) behavior on the device
|
||||
* @type int $buzzer_mode
|
||||
* Controls buzzer behavior for audio feedback
|
||||
* Defaults to ENABLED
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the role of node
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.Role role = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRole()
|
||||
{
|
||||
return $this->role;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the role of node
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.Role role = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRole($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DeviceConfig\Role::class);
|
||||
$this->role = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disabling this will disable the SerialConsole by not initilizing the StreamAPI
|
||||
* Moved to SecurityConfig
|
||||
*
|
||||
* Generated from protobuf field <code>bool serial_enabled = 2 [deprecated = true];</code>
|
||||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
public function getSerialEnabled()
|
||||
{
|
||||
@trigger_error('serial_enabled is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->serial_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disabling this will disable the SerialConsole by not initilizing the StreamAPI
|
||||
* Moved to SecurityConfig
|
||||
*
|
||||
* Generated from protobuf field <code>bool serial_enabled = 2 [deprecated = true];</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setSerialEnabled($var)
|
||||
{
|
||||
@trigger_error('serial_enabled is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkBool($var);
|
||||
$this->serial_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* For boards without a hard wired button, this is the pin number that will be used
|
||||
* Boards that have more than one button can swap the function with this one. defaults to BUTTON_PIN if defined.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 button_gpio = 4;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getButtonGpio()
|
||||
{
|
||||
return $this->button_gpio;
|
||||
}
|
||||
|
||||
/**
|
||||
* For boards without a hard wired button, this is the pin number that will be used
|
||||
* Boards that have more than one button can swap the function with this one. defaults to BUTTON_PIN if defined.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 button_gpio = 4;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setButtonGpio($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->button_gpio = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* For boards without a PWM buzzer, this is the pin number that will be used
|
||||
* Defaults to PIN_BUZZER if defined.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 buzzer_gpio = 5;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getBuzzerGpio()
|
||||
{
|
||||
return $this->buzzer_gpio;
|
||||
}
|
||||
|
||||
/**
|
||||
* For boards without a PWM buzzer, this is the pin number that will be used
|
||||
* Defaults to PIN_BUZZER if defined.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 buzzer_gpio = 5;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setBuzzerGpio($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->buzzer_gpio = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the role of node
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.RebroadcastMode rebroadcast_mode = 6;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRebroadcastMode()
|
||||
{
|
||||
return $this->rebroadcast_mode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the role of node
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.RebroadcastMode rebroadcast_mode = 6;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRebroadcastMode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DeviceConfig\RebroadcastMode::class);
|
||||
$this->rebroadcast_mode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Send our nodeinfo this often
|
||||
* Defaults to 900 Seconds (15 minutes)
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 node_info_broadcast_secs = 7;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getNodeInfoBroadcastSecs()
|
||||
{
|
||||
return $this->node_info_broadcast_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Send our nodeinfo this often
|
||||
* Defaults to 900 Seconds (15 minutes)
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 node_info_broadcast_secs = 7;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setNodeInfoBroadcastSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->node_info_broadcast_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Treat double tap interrupt on supported accelerometers as a button press if set to true
|
||||
*
|
||||
* Generated from protobuf field <code>bool double_tap_as_button_press = 8;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getDoubleTapAsButtonPress()
|
||||
{
|
||||
return $this->double_tap_as_button_press;
|
||||
}
|
||||
|
||||
/**
|
||||
* Treat double tap interrupt on supported accelerometers as a button press if set to true
|
||||
*
|
||||
* Generated from protobuf field <code>bool double_tap_as_button_press = 8;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDoubleTapAsButtonPress($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->double_tap_as_button_press = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, device is considered to be "managed" by a mesh administrator
|
||||
* Clients should then limit available configuration and administrative options inside the user interface
|
||||
* Moved to SecurityConfig
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_managed = 9 [deprecated = true];</code>
|
||||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
public function getIsManaged()
|
||||
{
|
||||
@trigger_error('is_managed is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->is_managed;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, device is considered to be "managed" by a mesh administrator
|
||||
* Clients should then limit available configuration and administrative options inside the user interface
|
||||
* Moved to SecurityConfig
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_managed = 9 [deprecated = true];</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setIsManaged($var)
|
||||
{
|
||||
@trigger_error('is_managed is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkBool($var);
|
||||
$this->is_managed = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disables the triple-press of user button to enable or disable GPS
|
||||
*
|
||||
* Generated from protobuf field <code>bool disable_triple_click = 10;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getDisableTripleClick()
|
||||
{
|
||||
return $this->disable_triple_click;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disables the triple-press of user button to enable or disable GPS
|
||||
*
|
||||
* Generated from protobuf field <code>bool disable_triple_click = 10;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDisableTripleClick($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->disable_triple_click = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* POSIX Timezone definition string from https://github.com/nayarsystems/posix_tz_db/blob/master/zones.csv.
|
||||
*
|
||||
* Generated from protobuf field <code>string tzdef = 11;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getTzdef()
|
||||
{
|
||||
return $this->tzdef;
|
||||
}
|
||||
|
||||
/**
|
||||
* POSIX Timezone definition string from https://github.com/nayarsystems/posix_tz_db/blob/master/zones.csv.
|
||||
*
|
||||
* Generated from protobuf field <code>string tzdef = 11;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTzdef($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->tzdef = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, disable the default blinking LED (LED_PIN) behavior on the device
|
||||
*
|
||||
* Generated from protobuf field <code>bool led_heartbeat_disabled = 12;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getLedHeartbeatDisabled()
|
||||
{
|
||||
return $this->led_heartbeat_disabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, disable the default blinking LED (LED_PIN) behavior on the device
|
||||
*
|
||||
* Generated from protobuf field <code>bool led_heartbeat_disabled = 12;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setLedHeartbeatDisabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->led_heartbeat_disabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Controls buzzer behavior for audio feedback
|
||||
* Defaults to ENABLED
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.BuzzerMode buzzer_mode = 13;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getBuzzerMode()
|
||||
{
|
||||
return $this->buzzer_mode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Controls buzzer behavior for audio feedback
|
||||
* Defaults to ENABLED
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DeviceConfig.BuzzerMode buzzer_mode = 13;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setBuzzerMode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DeviceConfig\BuzzerMode::class);
|
||||
$this->buzzer_mode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(DeviceConfig::class, \Meshtastic\Config_DeviceConfig::class);
|
||||
|
||||
@@ -0,0 +1,85 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DeviceConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Defines buzzer behavior for audio feedback
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.DeviceConfig.BuzzerMode</code>
|
||||
*/
|
||||
class BuzzerMode
|
||||
{
|
||||
/**
|
||||
* Default behavior.
|
||||
* Buzzer is enabled for all audio feedback including button presses and alerts.
|
||||
*
|
||||
* Generated from protobuf enum <code>ALL_ENABLED = 0;</code>
|
||||
*/
|
||||
const ALL_ENABLED = 0;
|
||||
/**
|
||||
* Disabled.
|
||||
* All buzzer audio feedback is disabled.
|
||||
*
|
||||
* Generated from protobuf enum <code>DISABLED = 1;</code>
|
||||
*/
|
||||
const DISABLED = 1;
|
||||
/**
|
||||
* Notifications Only.
|
||||
* Buzzer is enabled only for notifications and alerts, but not for button presses.
|
||||
* External notification config determines the specifics of the notification behavior.
|
||||
*
|
||||
* Generated from protobuf enum <code>NOTIFICATIONS_ONLY = 2;</code>
|
||||
*/
|
||||
const NOTIFICATIONS_ONLY = 2;
|
||||
/**
|
||||
* Non-notification system buzzer tones only.
|
||||
* Buzzer is enabled only for non-notification tones such as button presses, startup, shutdown, but not for alerts.
|
||||
*
|
||||
* Generated from protobuf enum <code>SYSTEM_ONLY = 3;</code>
|
||||
*/
|
||||
const SYSTEM_ONLY = 3;
|
||||
/**
|
||||
* Direct Message notifications only.
|
||||
* Buzzer is enabled only for direct messages and alerts, but not for button presses.
|
||||
* External notification config determines the specifics of the notification behavior.
|
||||
*
|
||||
* Generated from protobuf enum <code>DIRECT_MSG_ONLY = 4;</code>
|
||||
*/
|
||||
const DIRECT_MSG_ONLY = 4;
|
||||
|
||||
private static $valueToName = [
|
||||
self::ALL_ENABLED => 'ALL_ENABLED',
|
||||
self::DISABLED => 'DISABLED',
|
||||
self::NOTIFICATIONS_ONLY => 'NOTIFICATIONS_ONLY',
|
||||
self::SYSTEM_ONLY => 'SYSTEM_ONLY',
|
||||
self::DIRECT_MSG_ONLY => 'DIRECT_MSG_ONLY',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(BuzzerMode::class, \Meshtastic\Config_DeviceConfig_BuzzerMode::class);
|
||||
|
||||
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DeviceConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Defines the device's behavior for how messages are rebroadcast
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.DeviceConfig.RebroadcastMode</code>
|
||||
*/
|
||||
class RebroadcastMode
|
||||
{
|
||||
/**
|
||||
* Default behavior.
|
||||
* Rebroadcast any observed message, if it was on our private channel or from another mesh with the same lora params.
|
||||
*
|
||||
* Generated from protobuf enum <code>ALL = 0;</code>
|
||||
*/
|
||||
const ALL = 0;
|
||||
/**
|
||||
* Same as behavior as ALL but skips packet decoding and simply rebroadcasts them.
|
||||
* Only available in Repeater role. Setting this on any other roles will result in ALL behavior.
|
||||
*
|
||||
* Generated from protobuf enum <code>ALL_SKIP_DECODING = 1;</code>
|
||||
*/
|
||||
const ALL_SKIP_DECODING = 1;
|
||||
/**
|
||||
* Ignores observed messages from foreign meshes that are open or those which it cannot decrypt.
|
||||
* Only rebroadcasts message on the nodes local primary / secondary channels.
|
||||
*
|
||||
* Generated from protobuf enum <code>LOCAL_ONLY = 2;</code>
|
||||
*/
|
||||
const LOCAL_ONLY = 2;
|
||||
/**
|
||||
* Ignores observed messages from foreign meshes like LOCAL_ONLY,
|
||||
* but takes it step further by also ignoring messages from nodenums not in the node's known list (NodeDB)
|
||||
*
|
||||
* Generated from protobuf enum <code>KNOWN_ONLY = 3;</code>
|
||||
*/
|
||||
const KNOWN_ONLY = 3;
|
||||
/**
|
||||
* Only permitted for SENSOR, TRACKER and TAK_TRACKER roles, this will inhibit all rebroadcasts, not unlike CLIENT_MUTE role.
|
||||
*
|
||||
* Generated from protobuf enum <code>NONE = 4;</code>
|
||||
*/
|
||||
const NONE = 4;
|
||||
/**
|
||||
* Ignores packets from non-standard portnums such as: TAK, RangeTest, PaxCounter, etc.
|
||||
* Only rebroadcasts packets with standard portnums: NodeInfo, Text, Position, Telemetry, and Routing.
|
||||
*
|
||||
* Generated from protobuf enum <code>CORE_PORTNUMS_ONLY = 5;</code>
|
||||
*/
|
||||
const CORE_PORTNUMS_ONLY = 5;
|
||||
|
||||
private static $valueToName = [
|
||||
self::ALL => 'ALL',
|
||||
self::ALL_SKIP_DECODING => 'ALL_SKIP_DECODING',
|
||||
self::LOCAL_ONLY => 'LOCAL_ONLY',
|
||||
self::KNOWN_ONLY => 'KNOWN_ONLY',
|
||||
self::NONE => 'NONE',
|
||||
self::CORE_PORTNUMS_ONLY => 'CORE_PORTNUMS_ONLY',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(RebroadcastMode::class, \Meshtastic\Config_DeviceConfig_RebroadcastMode::class);
|
||||
|
||||
@@ -0,0 +1,165 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DeviceConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Defines the device's role on the Mesh network
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.DeviceConfig.Role</code>
|
||||
*/
|
||||
class Role
|
||||
{
|
||||
/**
|
||||
* Description: App connected or stand alone messaging device.
|
||||
* Technical Details: Default Role
|
||||
*
|
||||
* Generated from protobuf enum <code>CLIENT = 0;</code>
|
||||
*/
|
||||
const CLIENT = 0;
|
||||
/**
|
||||
* Description: Device that does not forward packets from other devices.
|
||||
*
|
||||
* Generated from protobuf enum <code>CLIENT_MUTE = 1;</code>
|
||||
*/
|
||||
const CLIENT_MUTE = 1;
|
||||
/**
|
||||
* Description: Infrastructure node for extending network coverage by relaying messages. Visible in Nodes list.
|
||||
* Technical Details: Mesh packets will prefer to be routed over this node. This node will not be used by client apps.
|
||||
* The wifi radio and the oled screen will be put to sleep.
|
||||
* This mode may still potentially have higher power usage due to it's preference in message rebroadcasting on the mesh.
|
||||
*
|
||||
* Generated from protobuf enum <code>ROUTER = 2;</code>
|
||||
*/
|
||||
const ROUTER = 2;
|
||||
/**
|
||||
* Generated from protobuf enum <code>ROUTER_CLIENT = 3 [deprecated = true];</code>
|
||||
*/
|
||||
const ROUTER_CLIENT = 3;
|
||||
/**
|
||||
* Description: Infrastructure node for extending network coverage by relaying messages with minimal overhead. Not visible in Nodes list.
|
||||
* Technical Details: Mesh packets will simply be rebroadcasted over this node. Nodes configured with this role will not originate NodeInfo, Position, Telemetry
|
||||
* or any other packet type. They will simply rebroadcast any mesh packets on the same frequency, channel num, spread factor, and coding rate.
|
||||
* Deprecated in v2.7.11 because it creates "holes" in the mesh rebroadcast chain.
|
||||
*
|
||||
* Generated from protobuf enum <code>REPEATER = 4 [deprecated = true];</code>
|
||||
*/
|
||||
const REPEATER = 4;
|
||||
/**
|
||||
* Description: Broadcasts GPS position packets as priority.
|
||||
* Technical Details: Position Mesh packets will be prioritized higher and sent more frequently by default.
|
||||
* When used in conjunction with power.is_power_saving = true, nodes will wake up,
|
||||
* send position, and then sleep for position.position_broadcast_secs seconds.
|
||||
*
|
||||
* Generated from protobuf enum <code>TRACKER = 5;</code>
|
||||
*/
|
||||
const TRACKER = 5;
|
||||
/**
|
||||
* Description: Broadcasts telemetry packets as priority.
|
||||
* Technical Details: Telemetry Mesh packets will be prioritized higher and sent more frequently by default.
|
||||
* When used in conjunction with power.is_power_saving = true, nodes will wake up,
|
||||
* send environment telemetry, and then sleep for telemetry.environment_update_interval seconds.
|
||||
*
|
||||
* Generated from protobuf enum <code>SENSOR = 6;</code>
|
||||
*/
|
||||
const SENSOR = 6;
|
||||
/**
|
||||
* Description: Optimized for ATAK system communication and reduces routine broadcasts.
|
||||
* Technical Details: Used for nodes dedicated for connection to an ATAK EUD.
|
||||
* Turns off many of the routine broadcasts to favor CoT packet stream
|
||||
* from the Meshtastic ATAK plugin -> IMeshService -> Node
|
||||
*
|
||||
* Generated from protobuf enum <code>TAK = 7;</code>
|
||||
*/
|
||||
const TAK = 7;
|
||||
/**
|
||||
* Description: Device that only broadcasts as needed for stealth or power savings.
|
||||
* Technical Details: Used for nodes that "only speak when spoken to"
|
||||
* Turns all of the routine broadcasts but allows for ad-hoc communication
|
||||
* Still rebroadcasts, but with local only rebroadcast mode (known meshes only)
|
||||
* Can be used for clandestine operation or to dramatically reduce airtime / power consumption
|
||||
*
|
||||
* Generated from protobuf enum <code>CLIENT_HIDDEN = 8;</code>
|
||||
*/
|
||||
const CLIENT_HIDDEN = 8;
|
||||
/**
|
||||
* Description: Broadcasts location as message to default channel regularly for to assist with device recovery.
|
||||
* Technical Details: Used to automatically send a text message to the mesh
|
||||
* with the current position of the device on a frequent interval:
|
||||
* "I'm lost! Position: lat / long"
|
||||
*
|
||||
* Generated from protobuf enum <code>LOST_AND_FOUND = 9;</code>
|
||||
*/
|
||||
const LOST_AND_FOUND = 9;
|
||||
/**
|
||||
* Description: Enables automatic TAK PLI broadcasts and reduces routine broadcasts.
|
||||
* Technical Details: Turns off many of the routine broadcasts to favor ATAK CoT packet stream
|
||||
* and automatic TAK PLI (position location information) broadcasts.
|
||||
* Uses position module configuration to determine TAK PLI broadcast interval.
|
||||
*
|
||||
* Generated from protobuf enum <code>TAK_TRACKER = 10;</code>
|
||||
*/
|
||||
const TAK_TRACKER = 10;
|
||||
/**
|
||||
* Description: Will always rebroadcast packets, but will do so after all other modes.
|
||||
* Technical Details: Used for router nodes that are intended to provide additional coverage
|
||||
* in areas not already covered by other routers, or to bridge around problematic terrain,
|
||||
* but should not be given priority over other routers in order to avoid unnecessaraily
|
||||
* consuming hops.
|
||||
*
|
||||
* Generated from protobuf enum <code>ROUTER_LATE = 11;</code>
|
||||
*/
|
||||
const ROUTER_LATE = 11;
|
||||
/**
|
||||
* Description: Treats packets from or to favorited nodes as ROUTER_LATE, and all other packets as CLIENT.
|
||||
* Technical Details: Used for stronger attic/roof nodes to distribute messages more widely
|
||||
* from weaker, indoor, or less-well-positioned nodes. Recommended for users with multiple nodes
|
||||
* where one CLIENT_BASE acts as a more powerful base station, such as an attic/roof node.
|
||||
*
|
||||
* Generated from protobuf enum <code>CLIENT_BASE = 12;</code>
|
||||
*/
|
||||
const CLIENT_BASE = 12;
|
||||
|
||||
private static $valueToName = [
|
||||
self::CLIENT => 'CLIENT',
|
||||
self::CLIENT_MUTE => 'CLIENT_MUTE',
|
||||
self::ROUTER => 'ROUTER',
|
||||
self::ROUTER_CLIENT => 'ROUTER_CLIENT',
|
||||
self::REPEATER => 'REPEATER',
|
||||
self::TRACKER => 'TRACKER',
|
||||
self::SENSOR => 'SENSOR',
|
||||
self::TAK => 'TAK',
|
||||
self::CLIENT_HIDDEN => 'CLIENT_HIDDEN',
|
||||
self::LOST_AND_FOUND => 'LOST_AND_FOUND',
|
||||
self::TAK_TRACKER => 'TAK_TRACKER',
|
||||
self::ROUTER_LATE => 'ROUTER_LATE',
|
||||
self::CLIENT_BASE => 'CLIENT_BASE',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(Role::class, \Meshtastic\Config_DeviceConfig_Role::class);
|
||||
|
||||
@@ -0,0 +1,546 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Display Config
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.DisplayConfig</code>
|
||||
*/
|
||||
class DisplayConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Number of seconds the screen stays on after pressing the user button or receiving a message
|
||||
* 0 for default of one minute MAXUINT for always on
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 screen_on_secs = 1;</code>
|
||||
*/
|
||||
protected $screen_on_secs = 0;
|
||||
/**
|
||||
* Deprecated in 2.7.4: Unused
|
||||
* How the GPS coordinates are formatted on the OLED screen.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DeprecatedGpsCoordinateFormat gps_format = 2 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $gps_format = 0;
|
||||
/**
|
||||
* Automatically toggles to the next page on the screen like a carousel, based the specified interval in seconds.
|
||||
* Potentially useful for devices without user buttons.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 auto_screen_carousel_secs = 3;</code>
|
||||
*/
|
||||
protected $auto_screen_carousel_secs = 0;
|
||||
/**
|
||||
* If this is set, the displayed compass will always point north. if unset, the old behaviour
|
||||
* (top of display is heading direction) is used.
|
||||
*
|
||||
* Generated from protobuf field <code>bool compass_north_top = 4 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $compass_north_top = false;
|
||||
/**
|
||||
* Flip screen vertically, for cases that mount the screen upside down
|
||||
*
|
||||
* Generated from protobuf field <code>bool flip_screen = 5;</code>
|
||||
*/
|
||||
protected $flip_screen = false;
|
||||
/**
|
||||
* Perferred display units
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DisplayUnits units = 6;</code>
|
||||
*/
|
||||
protected $units = 0;
|
||||
/**
|
||||
* Override auto-detect in screen
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.OledType oled = 7;</code>
|
||||
*/
|
||||
protected $oled = 0;
|
||||
/**
|
||||
* Display Mode
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DisplayMode displaymode = 8;</code>
|
||||
*/
|
||||
protected $displaymode = 0;
|
||||
/**
|
||||
* Print first line in pseudo-bold? FALSE is original style, TRUE is bold
|
||||
*
|
||||
* Generated from protobuf field <code>bool heading_bold = 9;</code>
|
||||
*/
|
||||
protected $heading_bold = false;
|
||||
/**
|
||||
* Should we wake the screen up on accelerometer detected motion or tap
|
||||
*
|
||||
* Generated from protobuf field <code>bool wake_on_tap_or_motion = 10;</code>
|
||||
*/
|
||||
protected $wake_on_tap_or_motion = false;
|
||||
/**
|
||||
* Indicates how to rotate or invert the compass output to accurate display on the display.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.CompassOrientation compass_orientation = 11;</code>
|
||||
*/
|
||||
protected $compass_orientation = 0;
|
||||
/**
|
||||
* If false (default), the device will display the time in 24-hour format on screen.
|
||||
* If true, the device will display the time in 12-hour format on screen.
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_12h_clock = 12;</code>
|
||||
*/
|
||||
protected $use_12h_clock = false;
|
||||
/**
|
||||
* If false (default), the device will use short names for various display screens.
|
||||
* If true, node names will show in long format
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_long_node_name = 13;</code>
|
||||
*/
|
||||
protected $use_long_node_name = false;
|
||||
/**
|
||||
* If true, the device will display message bubbles on screen.
|
||||
*
|
||||
* Generated from protobuf field <code>bool enable_message_bubbles = 14;</code>
|
||||
*/
|
||||
protected $enable_message_bubbles = false;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $screen_on_secs
|
||||
* Number of seconds the screen stays on after pressing the user button or receiving a message
|
||||
* 0 for default of one minute MAXUINT for always on
|
||||
* @type int $gps_format
|
||||
* Deprecated in 2.7.4: Unused
|
||||
* How the GPS coordinates are formatted on the OLED screen.
|
||||
* @type int $auto_screen_carousel_secs
|
||||
* Automatically toggles to the next page on the screen like a carousel, based the specified interval in seconds.
|
||||
* Potentially useful for devices without user buttons.
|
||||
* @type bool $compass_north_top
|
||||
* If this is set, the displayed compass will always point north. if unset, the old behaviour
|
||||
* (top of display is heading direction) is used.
|
||||
* @type bool $flip_screen
|
||||
* Flip screen vertically, for cases that mount the screen upside down
|
||||
* @type int $units
|
||||
* Perferred display units
|
||||
* @type int $oled
|
||||
* Override auto-detect in screen
|
||||
* @type int $displaymode
|
||||
* Display Mode
|
||||
* @type bool $heading_bold
|
||||
* Print first line in pseudo-bold? FALSE is original style, TRUE is bold
|
||||
* @type bool $wake_on_tap_or_motion
|
||||
* Should we wake the screen up on accelerometer detected motion or tap
|
||||
* @type int $compass_orientation
|
||||
* Indicates how to rotate or invert the compass output to accurate display on the display.
|
||||
* @type bool $use_12h_clock
|
||||
* If false (default), the device will display the time in 24-hour format on screen.
|
||||
* If true, the device will display the time in 12-hour format on screen.
|
||||
* @type bool $use_long_node_name
|
||||
* If false (default), the device will use short names for various display screens.
|
||||
* If true, node names will show in long format
|
||||
* @type bool $enable_message_bubbles
|
||||
* If true, the device will display message bubbles on screen.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Number of seconds the screen stays on after pressing the user button or receiving a message
|
||||
* 0 for default of one minute MAXUINT for always on
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 screen_on_secs = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getScreenOnSecs()
|
||||
{
|
||||
return $this->screen_on_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Number of seconds the screen stays on after pressing the user button or receiving a message
|
||||
* 0 for default of one minute MAXUINT for always on
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 screen_on_secs = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setScreenOnSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->screen_on_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Deprecated in 2.7.4: Unused
|
||||
* How the GPS coordinates are formatted on the OLED screen.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DeprecatedGpsCoordinateFormat gps_format = 2 [deprecated = true];</code>
|
||||
* @return int
|
||||
* @deprecated
|
||||
*/
|
||||
public function getGpsFormat()
|
||||
{
|
||||
@trigger_error('gps_format is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->gps_format;
|
||||
}
|
||||
|
||||
/**
|
||||
* Deprecated in 2.7.4: Unused
|
||||
* How the GPS coordinates are formatted on the OLED screen.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DeprecatedGpsCoordinateFormat gps_format = 2 [deprecated = true];</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setGpsFormat($var)
|
||||
{
|
||||
@trigger_error('gps_format is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DisplayConfig\DeprecatedGpsCoordinateFormat::class);
|
||||
$this->gps_format = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Automatically toggles to the next page on the screen like a carousel, based the specified interval in seconds.
|
||||
* Potentially useful for devices without user buttons.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 auto_screen_carousel_secs = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getAutoScreenCarouselSecs()
|
||||
{
|
||||
return $this->auto_screen_carousel_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Automatically toggles to the next page on the screen like a carousel, based the specified interval in seconds.
|
||||
* Potentially useful for devices without user buttons.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 auto_screen_carousel_secs = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setAutoScreenCarouselSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->auto_screen_carousel_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If this is set, the displayed compass will always point north. if unset, the old behaviour
|
||||
* (top of display is heading direction) is used.
|
||||
*
|
||||
* Generated from protobuf field <code>bool compass_north_top = 4 [deprecated = true];</code>
|
||||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
public function getCompassNorthTop()
|
||||
{
|
||||
@trigger_error('compass_north_top is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->compass_north_top;
|
||||
}
|
||||
|
||||
/**
|
||||
* If this is set, the displayed compass will always point north. if unset, the old behaviour
|
||||
* (top of display is heading direction) is used.
|
||||
*
|
||||
* Generated from protobuf field <code>bool compass_north_top = 4 [deprecated = true];</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setCompassNorthTop($var)
|
||||
{
|
||||
@trigger_error('compass_north_top is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkBool($var);
|
||||
$this->compass_north_top = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Flip screen vertically, for cases that mount the screen upside down
|
||||
*
|
||||
* Generated from protobuf field <code>bool flip_screen = 5;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getFlipScreen()
|
||||
{
|
||||
return $this->flip_screen;
|
||||
}
|
||||
|
||||
/**
|
||||
* Flip screen vertically, for cases that mount the screen upside down
|
||||
*
|
||||
* Generated from protobuf field <code>bool flip_screen = 5;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setFlipScreen($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->flip_screen = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Perferred display units
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DisplayUnits units = 6;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getUnits()
|
||||
{
|
||||
return $this->units;
|
||||
}
|
||||
|
||||
/**
|
||||
* Perferred display units
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DisplayUnits units = 6;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setUnits($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DisplayConfig\DisplayUnits::class);
|
||||
$this->units = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Override auto-detect in screen
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.OledType oled = 7;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getOled()
|
||||
{
|
||||
return $this->oled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Override auto-detect in screen
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.OledType oled = 7;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setOled($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DisplayConfig\OledType::class);
|
||||
$this->oled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Display Mode
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DisplayMode displaymode = 8;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getDisplaymode()
|
||||
{
|
||||
return $this->displaymode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Display Mode
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.DisplayMode displaymode = 8;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDisplaymode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DisplayConfig\DisplayMode::class);
|
||||
$this->displaymode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Print first line in pseudo-bold? FALSE is original style, TRUE is bold
|
||||
*
|
||||
* Generated from protobuf field <code>bool heading_bold = 9;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getHeadingBold()
|
||||
{
|
||||
return $this->heading_bold;
|
||||
}
|
||||
|
||||
/**
|
||||
* Print first line in pseudo-bold? FALSE is original style, TRUE is bold
|
||||
*
|
||||
* Generated from protobuf field <code>bool heading_bold = 9;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setHeadingBold($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->heading_bold = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Should we wake the screen up on accelerometer detected motion or tap
|
||||
*
|
||||
* Generated from protobuf field <code>bool wake_on_tap_or_motion = 10;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getWakeOnTapOrMotion()
|
||||
{
|
||||
return $this->wake_on_tap_or_motion;
|
||||
}
|
||||
|
||||
/**
|
||||
* Should we wake the screen up on accelerometer detected motion or tap
|
||||
*
|
||||
* Generated from protobuf field <code>bool wake_on_tap_or_motion = 10;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setWakeOnTapOrMotion($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->wake_on_tap_or_motion = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Indicates how to rotate or invert the compass output to accurate display on the display.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.CompassOrientation compass_orientation = 11;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getCompassOrientation()
|
||||
{
|
||||
return $this->compass_orientation;
|
||||
}
|
||||
|
||||
/**
|
||||
* Indicates how to rotate or invert the compass output to accurate display on the display.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.DisplayConfig.CompassOrientation compass_orientation = 11;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setCompassOrientation($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\DisplayConfig\CompassOrientation::class);
|
||||
$this->compass_orientation = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If false (default), the device will display the time in 24-hour format on screen.
|
||||
* If true, the device will display the time in 12-hour format on screen.
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_12h_clock = 12;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getUse12HClock()
|
||||
{
|
||||
return $this->use_12h_clock;
|
||||
}
|
||||
|
||||
/**
|
||||
* If false (default), the device will display the time in 24-hour format on screen.
|
||||
* If true, the device will display the time in 12-hour format on screen.
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_12h_clock = 12;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setUse12HClock($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->use_12h_clock = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If false (default), the device will use short names for various display screens.
|
||||
* If true, node names will show in long format
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_long_node_name = 13;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getUseLongNodeName()
|
||||
{
|
||||
return $this->use_long_node_name;
|
||||
}
|
||||
|
||||
/**
|
||||
* If false (default), the device will use short names for various display screens.
|
||||
* If true, node names will show in long format
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_long_node_name = 13;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setUseLongNodeName($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->use_long_node_name = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, the device will display message bubbles on screen.
|
||||
*
|
||||
* Generated from protobuf field <code>bool enable_message_bubbles = 14;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getEnableMessageBubbles()
|
||||
{
|
||||
return $this->enable_message_bubbles;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, the device will display message bubbles on screen.
|
||||
*
|
||||
* Generated from protobuf field <code>bool enable_message_bubbles = 14;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setEnableMessageBubbles($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->enable_message_bubbles = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(DisplayConfig::class, \Meshtastic\Config_DisplayConfig::class);
|
||||
|
||||
@@ -0,0 +1,97 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DisplayConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.Config.DisplayConfig.CompassOrientation</code>
|
||||
*/
|
||||
class CompassOrientation
|
||||
{
|
||||
/**
|
||||
* The compass and the display are in the same orientation.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_0 = 0;</code>
|
||||
*/
|
||||
const DEGREES_0 = 0;
|
||||
/**
|
||||
* Rotate the compass by 90 degrees.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_90 = 1;</code>
|
||||
*/
|
||||
const DEGREES_90 = 1;
|
||||
/**
|
||||
* Rotate the compass by 180 degrees.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_180 = 2;</code>
|
||||
*/
|
||||
const DEGREES_180 = 2;
|
||||
/**
|
||||
* Rotate the compass by 270 degrees.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_270 = 3;</code>
|
||||
*/
|
||||
const DEGREES_270 = 3;
|
||||
/**
|
||||
* Don't rotate the compass, but invert the result.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_0_INVERTED = 4;</code>
|
||||
*/
|
||||
const DEGREES_0_INVERTED = 4;
|
||||
/**
|
||||
* Rotate the compass by 90 degrees and invert.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_90_INVERTED = 5;</code>
|
||||
*/
|
||||
const DEGREES_90_INVERTED = 5;
|
||||
/**
|
||||
* Rotate the compass by 180 degrees and invert.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_180_INVERTED = 6;</code>
|
||||
*/
|
||||
const DEGREES_180_INVERTED = 6;
|
||||
/**
|
||||
* Rotate the compass by 270 degrees and invert.
|
||||
*
|
||||
* Generated from protobuf enum <code>DEGREES_270_INVERTED = 7;</code>
|
||||
*/
|
||||
const DEGREES_270_INVERTED = 7;
|
||||
|
||||
private static $valueToName = [
|
||||
self::DEGREES_0 => 'DEGREES_0',
|
||||
self::DEGREES_90 => 'DEGREES_90',
|
||||
self::DEGREES_180 => 'DEGREES_180',
|
||||
self::DEGREES_270 => 'DEGREES_270',
|
||||
self::DEGREES_0_INVERTED => 'DEGREES_0_INVERTED',
|
||||
self::DEGREES_90_INVERTED => 'DEGREES_90_INVERTED',
|
||||
self::DEGREES_180_INVERTED => 'DEGREES_180_INVERTED',
|
||||
self::DEGREES_270_INVERTED => 'DEGREES_270_INVERTED',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(CompassOrientation::class, \Meshtastic\Config_DisplayConfig_CompassOrientation::class);
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DisplayConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Deprecated in 2.7.4: Unused
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.DisplayConfig.DeprecatedGpsCoordinateFormat</code>
|
||||
*/
|
||||
class DeprecatedGpsCoordinateFormat
|
||||
{
|
||||
/**
|
||||
* Generated from protobuf enum <code>UNUSED = 0;</code>
|
||||
*/
|
||||
const UNUSED = 0;
|
||||
|
||||
private static $valueToName = [
|
||||
self::UNUSED => 'UNUSED',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(DeprecatedGpsCoordinateFormat::class, \Meshtastic\Config_DisplayConfig_DeprecatedGpsCoordinateFormat::class);
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DisplayConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.Config.DisplayConfig.DisplayMode</code>
|
||||
*/
|
||||
class DisplayMode
|
||||
{
|
||||
/**
|
||||
* Default. The old style for the 128x64 OLED screen
|
||||
*
|
||||
* Generated from protobuf enum <code>DEFAULT = 0;</code>
|
||||
*/
|
||||
const PBDEFAULT = 0;
|
||||
/**
|
||||
* Rearrange display elements to cater for bicolor OLED displays
|
||||
*
|
||||
* Generated from protobuf enum <code>TWOCOLOR = 1;</code>
|
||||
*/
|
||||
const TWOCOLOR = 1;
|
||||
/**
|
||||
* Same as TwoColor, but with inverted top bar. Not so good for Epaper displays
|
||||
*
|
||||
* Generated from protobuf enum <code>INVERTED = 2;</code>
|
||||
*/
|
||||
const INVERTED = 2;
|
||||
/**
|
||||
* TFT Full Color Displays (not implemented yet)
|
||||
*
|
||||
* Generated from protobuf enum <code>COLOR = 3;</code>
|
||||
*/
|
||||
const COLOR = 3;
|
||||
|
||||
private static $valueToName = [
|
||||
self::PBDEFAULT => 'DEFAULT',
|
||||
self::TWOCOLOR => 'TWOCOLOR',
|
||||
self::INVERTED => 'INVERTED',
|
||||
self::COLOR => 'COLOR',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
$pbconst = __CLASS__. '::PB' . strtoupper($name);
|
||||
if (!defined($pbconst)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($pbconst);
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(DisplayMode::class, \Meshtastic\Config_DisplayConfig_DisplayMode::class);
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DisplayConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Unit display preference
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.DisplayConfig.DisplayUnits</code>
|
||||
*/
|
||||
class DisplayUnits
|
||||
{
|
||||
/**
|
||||
* Metric (Default)
|
||||
*
|
||||
* Generated from protobuf enum <code>METRIC = 0;</code>
|
||||
*/
|
||||
const METRIC = 0;
|
||||
/**
|
||||
* Imperial
|
||||
*
|
||||
* Generated from protobuf enum <code>IMPERIAL = 1;</code>
|
||||
*/
|
||||
const IMPERIAL = 1;
|
||||
|
||||
private static $valueToName = [
|
||||
self::METRIC => 'METRIC',
|
||||
self::IMPERIAL => 'IMPERIAL',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(DisplayUnits::class, \Meshtastic\Config_DisplayConfig_DisplayUnits::class);
|
||||
|
||||
@@ -0,0 +1,78 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\DisplayConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Override OLED outo detect with this if it fails.
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.DisplayConfig.OledType</code>
|
||||
*/
|
||||
class OledType
|
||||
{
|
||||
/**
|
||||
* Default / Autodetect
|
||||
*
|
||||
* Generated from protobuf enum <code>OLED_AUTO = 0;</code>
|
||||
*/
|
||||
const OLED_AUTO = 0;
|
||||
/**
|
||||
* Default / Autodetect
|
||||
*
|
||||
* Generated from protobuf enum <code>OLED_SSD1306 = 1;</code>
|
||||
*/
|
||||
const OLED_SSD1306 = 1;
|
||||
/**
|
||||
* Default / Autodetect
|
||||
*
|
||||
* Generated from protobuf enum <code>OLED_SH1106 = 2;</code>
|
||||
*/
|
||||
const OLED_SH1106 = 2;
|
||||
/**
|
||||
* Can not be auto detected but set by proto. Used for 128x64 screens
|
||||
*
|
||||
* Generated from protobuf enum <code>OLED_SH1107 = 3;</code>
|
||||
*/
|
||||
const OLED_SH1107 = 3;
|
||||
/**
|
||||
* Can not be auto detected but set by proto. Used for 128x128 screens
|
||||
*
|
||||
* Generated from protobuf enum <code>OLED_SH1107_128_128 = 4;</code>
|
||||
*/
|
||||
const OLED_SH1107_128_128 = 4;
|
||||
|
||||
private static $valueToName = [
|
||||
self::OLED_AUTO => 'OLED_AUTO',
|
||||
self::OLED_SSD1306 => 'OLED_SSD1306',
|
||||
self::OLED_SH1106 => 'OLED_SH1106',
|
||||
self::OLED_SH1107 => 'OLED_SH1107',
|
||||
self::OLED_SH1107_128_128 => 'OLED_SH1107_128_128',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(OledType::class, \Meshtastic\Config_DisplayConfig_OledType::class);
|
||||
|
||||
@@ -0,0 +1,772 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Lora Config
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.LoRaConfig</code>
|
||||
*/
|
||||
class LoRaConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* When enabled, the `modem_preset` fields will be adhered to, else the `bandwidth`/`spread_factor`/`coding_rate`
|
||||
* will be taked from their respective manually defined fields
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_preset = 1;</code>
|
||||
*/
|
||||
protected $use_preset = false;
|
||||
/**
|
||||
* Either modem_config or bandwidth/spreading/coding will be specified - NOT BOTH.
|
||||
* As a heuristic: If bandwidth is specified, do not use modem_config.
|
||||
* Because protobufs take ZERO space when the value is zero this works out nicely.
|
||||
* This value is replaced by bandwidth/spread_factor/coding_rate.
|
||||
* If you'd like to experiment with other options add them to MeshRadio.cpp in the device code.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig.ModemPreset modem_preset = 2;</code>
|
||||
*/
|
||||
protected $modem_preset = 0;
|
||||
/**
|
||||
* Bandwidth in MHz
|
||||
* Certain bandwidth numbers are 'special' and will be converted to the
|
||||
* appropriate floating point value: 31 -> 31.25MHz
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 bandwidth = 3;</code>
|
||||
*/
|
||||
protected $bandwidth = 0;
|
||||
/**
|
||||
* A number from 7 to 12.
|
||||
* Indicates number of chirps per symbol as 1<<spread_factor.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 spread_factor = 4;</code>
|
||||
*/
|
||||
protected $spread_factor = 0;
|
||||
/**
|
||||
* The denominator of the coding rate.
|
||||
* ie for 4/5, the value is 5. 4/8 the value is 8.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 coding_rate = 5;</code>
|
||||
*/
|
||||
protected $coding_rate = 0;
|
||||
/**
|
||||
* This parameter is for advanced users with advanced test equipment, we do not recommend most users use it.
|
||||
* A frequency offset that is added to to the calculated band center frequency.
|
||||
* Used to correct for crystal calibration errors.
|
||||
*
|
||||
* Generated from protobuf field <code>float frequency_offset = 6;</code>
|
||||
*/
|
||||
protected $frequency_offset = 0.0;
|
||||
/**
|
||||
* The region code for the radio (US, CN, EU433, etc...)
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig.RegionCode region = 7;</code>
|
||||
*/
|
||||
protected $region = 0;
|
||||
/**
|
||||
* Maximum number of hops. This can't be greater than 7.
|
||||
* Default of 3
|
||||
* Attempting to set a value > 7 results in the default
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 hop_limit = 8;</code>
|
||||
*/
|
||||
protected $hop_limit = 0;
|
||||
/**
|
||||
* Disable TX from the LoRa radio. Useful for hot-swapping antennas and other tests.
|
||||
* Defaults to false
|
||||
*
|
||||
* Generated from protobuf field <code>bool tx_enabled = 9;</code>
|
||||
*/
|
||||
protected $tx_enabled = false;
|
||||
/**
|
||||
* If zero, then use default max legal continuous power (ie. something that won't
|
||||
* burn out the radio hardware)
|
||||
* In most cases you should use zero here.
|
||||
* Units are in dBm.
|
||||
*
|
||||
* Generated from protobuf field <code>int32 tx_power = 10;</code>
|
||||
*/
|
||||
protected $tx_power = 0;
|
||||
/**
|
||||
* This controls the actual hardware frequency the radio transmits on.
|
||||
* Most users should never need to be exposed to this field/concept.
|
||||
* A channel number between 1 and NUM_CHANNELS (whatever the max is in the current region).
|
||||
* If ZERO then the rule is "use the old channel name hash based
|
||||
* algorithm to derive the channel number")
|
||||
* If using the hash algorithm the channel number will be: hash(channel_name) %
|
||||
* NUM_CHANNELS (Where num channels depends on the regulatory region).
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 channel_num = 11;</code>
|
||||
*/
|
||||
protected $channel_num = 0;
|
||||
/**
|
||||
* If true, duty cycle limits will be exceeded and thus you're possibly not following
|
||||
* the local regulations if you're not a HAM.
|
||||
* Has no effect if the duty cycle of the used region is 100%.
|
||||
*
|
||||
* Generated from protobuf field <code>bool override_duty_cycle = 12;</code>
|
||||
*/
|
||||
protected $override_duty_cycle = false;
|
||||
/**
|
||||
* If true, sets RX boosted gain mode on SX126X based radios
|
||||
*
|
||||
* Generated from protobuf field <code>bool sx126x_rx_boosted_gain = 13;</code>
|
||||
*/
|
||||
protected $sx126x_rx_boosted_gain = false;
|
||||
/**
|
||||
* This parameter is for advanced users and licensed HAM radio operators.
|
||||
* Ignore Channel Calculation and use this frequency instead. The frequency_offset
|
||||
* will still be applied. This will allow you to use out-of-band frequencies.
|
||||
* Please respect your local laws and regulations. If you are a HAM, make sure you
|
||||
* enable HAM mode and turn off encryption.
|
||||
*
|
||||
* Generated from protobuf field <code>float override_frequency = 14;</code>
|
||||
*/
|
||||
protected $override_frequency = 0.0;
|
||||
/**
|
||||
* If true, disable the build-in PA FAN using pin define in RF95_FAN_EN.
|
||||
*
|
||||
* Generated from protobuf field <code>bool pa_fan_disabled = 15;</code>
|
||||
*/
|
||||
protected $pa_fan_disabled = false;
|
||||
/**
|
||||
* For testing it is useful sometimes to force a node to never listen to
|
||||
* particular other nodes (simulating radio out of range). All nodenums listed
|
||||
* in ignore_incoming will have packets they send dropped on receive (by router.cpp)
|
||||
*
|
||||
* Generated from protobuf field <code>repeated uint32 ignore_incoming = 103;</code>
|
||||
*/
|
||||
private $ignore_incoming;
|
||||
/**
|
||||
* If true, the device will not process any packets received via LoRa that passed via MQTT anywhere on the path towards it.
|
||||
*
|
||||
* Generated from protobuf field <code>bool ignore_mqtt = 104;</code>
|
||||
*/
|
||||
protected $ignore_mqtt = false;
|
||||
/**
|
||||
* Sets the ok_to_mqtt bit on outgoing packets
|
||||
*
|
||||
* Generated from protobuf field <code>bool config_ok_to_mqtt = 105;</code>
|
||||
*/
|
||||
protected $config_ok_to_mqtt = false;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type bool $use_preset
|
||||
* When enabled, the `modem_preset` fields will be adhered to, else the `bandwidth`/`spread_factor`/`coding_rate`
|
||||
* will be taked from their respective manually defined fields
|
||||
* @type int $modem_preset
|
||||
* Either modem_config or bandwidth/spreading/coding will be specified - NOT BOTH.
|
||||
* As a heuristic: If bandwidth is specified, do not use modem_config.
|
||||
* Because protobufs take ZERO space when the value is zero this works out nicely.
|
||||
* This value is replaced by bandwidth/spread_factor/coding_rate.
|
||||
* If you'd like to experiment with other options add them to MeshRadio.cpp in the device code.
|
||||
* @type int $bandwidth
|
||||
* Bandwidth in MHz
|
||||
* Certain bandwidth numbers are 'special' and will be converted to the
|
||||
* appropriate floating point value: 31 -> 31.25MHz
|
||||
* @type int $spread_factor
|
||||
* A number from 7 to 12.
|
||||
* Indicates number of chirps per symbol as 1<<spread_factor.
|
||||
* @type int $coding_rate
|
||||
* The denominator of the coding rate.
|
||||
* ie for 4/5, the value is 5. 4/8 the value is 8.
|
||||
* @type float $frequency_offset
|
||||
* This parameter is for advanced users with advanced test equipment, we do not recommend most users use it.
|
||||
* A frequency offset that is added to to the calculated band center frequency.
|
||||
* Used to correct for crystal calibration errors.
|
||||
* @type int $region
|
||||
* The region code for the radio (US, CN, EU433, etc...)
|
||||
* @type int $hop_limit
|
||||
* Maximum number of hops. This can't be greater than 7.
|
||||
* Default of 3
|
||||
* Attempting to set a value > 7 results in the default
|
||||
* @type bool $tx_enabled
|
||||
* Disable TX from the LoRa radio. Useful for hot-swapping antennas and other tests.
|
||||
* Defaults to false
|
||||
* @type int $tx_power
|
||||
* If zero, then use default max legal continuous power (ie. something that won't
|
||||
* burn out the radio hardware)
|
||||
* In most cases you should use zero here.
|
||||
* Units are in dBm.
|
||||
* @type int $channel_num
|
||||
* This controls the actual hardware frequency the radio transmits on.
|
||||
* Most users should never need to be exposed to this field/concept.
|
||||
* A channel number between 1 and NUM_CHANNELS (whatever the max is in the current region).
|
||||
* If ZERO then the rule is "use the old channel name hash based
|
||||
* algorithm to derive the channel number")
|
||||
* If using the hash algorithm the channel number will be: hash(channel_name) %
|
||||
* NUM_CHANNELS (Where num channels depends on the regulatory region).
|
||||
* @type bool $override_duty_cycle
|
||||
* If true, duty cycle limits will be exceeded and thus you're possibly not following
|
||||
* the local regulations if you're not a HAM.
|
||||
* Has no effect if the duty cycle of the used region is 100%.
|
||||
* @type bool $sx126x_rx_boosted_gain
|
||||
* If true, sets RX boosted gain mode on SX126X based radios
|
||||
* @type float $override_frequency
|
||||
* This parameter is for advanced users and licensed HAM radio operators.
|
||||
* Ignore Channel Calculation and use this frequency instead. The frequency_offset
|
||||
* will still be applied. This will allow you to use out-of-band frequencies.
|
||||
* Please respect your local laws and regulations. If you are a HAM, make sure you
|
||||
* enable HAM mode and turn off encryption.
|
||||
* @type bool $pa_fan_disabled
|
||||
* If true, disable the build-in PA FAN using pin define in RF95_FAN_EN.
|
||||
* @type array<int>|\Google\Protobuf\Internal\RepeatedField $ignore_incoming
|
||||
* For testing it is useful sometimes to force a node to never listen to
|
||||
* particular other nodes (simulating radio out of range). All nodenums listed
|
||||
* in ignore_incoming will have packets they send dropped on receive (by router.cpp)
|
||||
* @type bool $ignore_mqtt
|
||||
* If true, the device will not process any packets received via LoRa that passed via MQTT anywhere on the path towards it.
|
||||
* @type bool $config_ok_to_mqtt
|
||||
* Sets the ok_to_mqtt bit on outgoing packets
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* When enabled, the `modem_preset` fields will be adhered to, else the `bandwidth`/`spread_factor`/`coding_rate`
|
||||
* will be taked from their respective manually defined fields
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_preset = 1;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getUsePreset()
|
||||
{
|
||||
return $this->use_preset;
|
||||
}
|
||||
|
||||
/**
|
||||
* When enabled, the `modem_preset` fields will be adhered to, else the `bandwidth`/`spread_factor`/`coding_rate`
|
||||
* will be taked from their respective manually defined fields
|
||||
*
|
||||
* Generated from protobuf field <code>bool use_preset = 1;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setUsePreset($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->use_preset = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Either modem_config or bandwidth/spreading/coding will be specified - NOT BOTH.
|
||||
* As a heuristic: If bandwidth is specified, do not use modem_config.
|
||||
* Because protobufs take ZERO space when the value is zero this works out nicely.
|
||||
* This value is replaced by bandwidth/spread_factor/coding_rate.
|
||||
* If you'd like to experiment with other options add them to MeshRadio.cpp in the device code.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig.ModemPreset modem_preset = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getModemPreset()
|
||||
{
|
||||
return $this->modem_preset;
|
||||
}
|
||||
|
||||
/**
|
||||
* Either modem_config or bandwidth/spreading/coding will be specified - NOT BOTH.
|
||||
* As a heuristic: If bandwidth is specified, do not use modem_config.
|
||||
* Because protobufs take ZERO space when the value is zero this works out nicely.
|
||||
* This value is replaced by bandwidth/spread_factor/coding_rate.
|
||||
* If you'd like to experiment with other options add them to MeshRadio.cpp in the device code.
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig.ModemPreset modem_preset = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setModemPreset($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\LoRaConfig\ModemPreset::class);
|
||||
$this->modem_preset = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Bandwidth in MHz
|
||||
* Certain bandwidth numbers are 'special' and will be converted to the
|
||||
* appropriate floating point value: 31 -> 31.25MHz
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 bandwidth = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getBandwidth()
|
||||
{
|
||||
return $this->bandwidth;
|
||||
}
|
||||
|
||||
/**
|
||||
* Bandwidth in MHz
|
||||
* Certain bandwidth numbers are 'special' and will be converted to the
|
||||
* appropriate floating point value: 31 -> 31.25MHz
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 bandwidth = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setBandwidth($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->bandwidth = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* A number from 7 to 12.
|
||||
* Indicates number of chirps per symbol as 1<<spread_factor.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 spread_factor = 4;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getSpreadFactor()
|
||||
{
|
||||
return $this->spread_factor;
|
||||
}
|
||||
|
||||
/**
|
||||
* A number from 7 to 12.
|
||||
* Indicates number of chirps per symbol as 1<<spread_factor.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 spread_factor = 4;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSpreadFactor($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->spread_factor = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The denominator of the coding rate.
|
||||
* ie for 4/5, the value is 5. 4/8 the value is 8.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 coding_rate = 5;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getCodingRate()
|
||||
{
|
||||
return $this->coding_rate;
|
||||
}
|
||||
|
||||
/**
|
||||
* The denominator of the coding rate.
|
||||
* ie for 4/5, the value is 5. 4/8 the value is 8.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 coding_rate = 5;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setCodingRate($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->coding_rate = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* This parameter is for advanced users with advanced test equipment, we do not recommend most users use it.
|
||||
* A frequency offset that is added to to the calculated band center frequency.
|
||||
* Used to correct for crystal calibration errors.
|
||||
*
|
||||
* Generated from protobuf field <code>float frequency_offset = 6;</code>
|
||||
* @return float
|
||||
*/
|
||||
public function getFrequencyOffset()
|
||||
{
|
||||
return $this->frequency_offset;
|
||||
}
|
||||
|
||||
/**
|
||||
* This parameter is for advanced users with advanced test equipment, we do not recommend most users use it.
|
||||
* A frequency offset that is added to to the calculated band center frequency.
|
||||
* Used to correct for crystal calibration errors.
|
||||
*
|
||||
* Generated from protobuf field <code>float frequency_offset = 6;</code>
|
||||
* @param float $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setFrequencyOffset($var)
|
||||
{
|
||||
GPBUtil::checkFloat($var);
|
||||
$this->frequency_offset = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The region code for the radio (US, CN, EU433, etc...)
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig.RegionCode region = 7;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRegion()
|
||||
{
|
||||
return $this->region;
|
||||
}
|
||||
|
||||
/**
|
||||
* The region code for the radio (US, CN, EU433, etc...)
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.LoRaConfig.RegionCode region = 7;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRegion($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\LoRaConfig\RegionCode::class);
|
||||
$this->region = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Maximum number of hops. This can't be greater than 7.
|
||||
* Default of 3
|
||||
* Attempting to set a value > 7 results in the default
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 hop_limit = 8;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getHopLimit()
|
||||
{
|
||||
return $this->hop_limit;
|
||||
}
|
||||
|
||||
/**
|
||||
* Maximum number of hops. This can't be greater than 7.
|
||||
* Default of 3
|
||||
* Attempting to set a value > 7 results in the default
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 hop_limit = 8;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setHopLimit($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->hop_limit = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disable TX from the LoRa radio. Useful for hot-swapping antennas and other tests.
|
||||
* Defaults to false
|
||||
*
|
||||
* Generated from protobuf field <code>bool tx_enabled = 9;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getTxEnabled()
|
||||
{
|
||||
return $this->tx_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Disable TX from the LoRa radio. Useful for hot-swapping antennas and other tests.
|
||||
* Defaults to false
|
||||
*
|
||||
* Generated from protobuf field <code>bool tx_enabled = 9;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTxEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->tx_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If zero, then use default max legal continuous power (ie. something that won't
|
||||
* burn out the radio hardware)
|
||||
* In most cases you should use zero here.
|
||||
* Units are in dBm.
|
||||
*
|
||||
* Generated from protobuf field <code>int32 tx_power = 10;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getTxPower()
|
||||
{
|
||||
return $this->tx_power;
|
||||
}
|
||||
|
||||
/**
|
||||
* If zero, then use default max legal continuous power (ie. something that won't
|
||||
* burn out the radio hardware)
|
||||
* In most cases you should use zero here.
|
||||
* Units are in dBm.
|
||||
*
|
||||
* Generated from protobuf field <code>int32 tx_power = 10;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTxPower($var)
|
||||
{
|
||||
GPBUtil::checkInt32($var);
|
||||
$this->tx_power = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* This controls the actual hardware frequency the radio transmits on.
|
||||
* Most users should never need to be exposed to this field/concept.
|
||||
* A channel number between 1 and NUM_CHANNELS (whatever the max is in the current region).
|
||||
* If ZERO then the rule is "use the old channel name hash based
|
||||
* algorithm to derive the channel number")
|
||||
* If using the hash algorithm the channel number will be: hash(channel_name) %
|
||||
* NUM_CHANNELS (Where num channels depends on the regulatory region).
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 channel_num = 11;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getChannelNum()
|
||||
{
|
||||
return $this->channel_num;
|
||||
}
|
||||
|
||||
/**
|
||||
* This controls the actual hardware frequency the radio transmits on.
|
||||
* Most users should never need to be exposed to this field/concept.
|
||||
* A channel number between 1 and NUM_CHANNELS (whatever the max is in the current region).
|
||||
* If ZERO then the rule is "use the old channel name hash based
|
||||
* algorithm to derive the channel number")
|
||||
* If using the hash algorithm the channel number will be: hash(channel_name) %
|
||||
* NUM_CHANNELS (Where num channels depends on the regulatory region).
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 channel_num = 11;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setChannelNum($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->channel_num = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, duty cycle limits will be exceeded and thus you're possibly not following
|
||||
* the local regulations if you're not a HAM.
|
||||
* Has no effect if the duty cycle of the used region is 100%.
|
||||
*
|
||||
* Generated from protobuf field <code>bool override_duty_cycle = 12;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getOverrideDutyCycle()
|
||||
{
|
||||
return $this->override_duty_cycle;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, duty cycle limits will be exceeded and thus you're possibly not following
|
||||
* the local regulations if you're not a HAM.
|
||||
* Has no effect if the duty cycle of the used region is 100%.
|
||||
*
|
||||
* Generated from protobuf field <code>bool override_duty_cycle = 12;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setOverrideDutyCycle($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->override_duty_cycle = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, sets RX boosted gain mode on SX126X based radios
|
||||
*
|
||||
* Generated from protobuf field <code>bool sx126x_rx_boosted_gain = 13;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getSx126XRxBoostedGain()
|
||||
{
|
||||
return $this->sx126x_rx_boosted_gain;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, sets RX boosted gain mode on SX126X based radios
|
||||
*
|
||||
* Generated from protobuf field <code>bool sx126x_rx_boosted_gain = 13;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSx126XRxBoostedGain($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->sx126x_rx_boosted_gain = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* This parameter is for advanced users and licensed HAM radio operators.
|
||||
* Ignore Channel Calculation and use this frequency instead. The frequency_offset
|
||||
* will still be applied. This will allow you to use out-of-band frequencies.
|
||||
* Please respect your local laws and regulations. If you are a HAM, make sure you
|
||||
* enable HAM mode and turn off encryption.
|
||||
*
|
||||
* Generated from protobuf field <code>float override_frequency = 14;</code>
|
||||
* @return float
|
||||
*/
|
||||
public function getOverrideFrequency()
|
||||
{
|
||||
return $this->override_frequency;
|
||||
}
|
||||
|
||||
/**
|
||||
* This parameter is for advanced users and licensed HAM radio operators.
|
||||
* Ignore Channel Calculation and use this frequency instead. The frequency_offset
|
||||
* will still be applied. This will allow you to use out-of-band frequencies.
|
||||
* Please respect your local laws and regulations. If you are a HAM, make sure you
|
||||
* enable HAM mode and turn off encryption.
|
||||
*
|
||||
* Generated from protobuf field <code>float override_frequency = 14;</code>
|
||||
* @param float $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setOverrideFrequency($var)
|
||||
{
|
||||
GPBUtil::checkFloat($var);
|
||||
$this->override_frequency = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, disable the build-in PA FAN using pin define in RF95_FAN_EN.
|
||||
*
|
||||
* Generated from protobuf field <code>bool pa_fan_disabled = 15;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getPaFanDisabled()
|
||||
{
|
||||
return $this->pa_fan_disabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, disable the build-in PA FAN using pin define in RF95_FAN_EN.
|
||||
*
|
||||
* Generated from protobuf field <code>bool pa_fan_disabled = 15;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPaFanDisabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->pa_fan_disabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* For testing it is useful sometimes to force a node to never listen to
|
||||
* particular other nodes (simulating radio out of range). All nodenums listed
|
||||
* in ignore_incoming will have packets they send dropped on receive (by router.cpp)
|
||||
*
|
||||
* Generated from protobuf field <code>repeated uint32 ignore_incoming = 103;</code>
|
||||
* @return \Google\Protobuf\Internal\RepeatedField
|
||||
*/
|
||||
public function getIgnoreIncoming()
|
||||
{
|
||||
return $this->ignore_incoming;
|
||||
}
|
||||
|
||||
/**
|
||||
* For testing it is useful sometimes to force a node to never listen to
|
||||
* particular other nodes (simulating radio out of range). All nodenums listed
|
||||
* in ignore_incoming will have packets they send dropped on receive (by router.cpp)
|
||||
*
|
||||
* Generated from protobuf field <code>repeated uint32 ignore_incoming = 103;</code>
|
||||
* @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIgnoreIncoming($var)
|
||||
{
|
||||
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::UINT32);
|
||||
$this->ignore_incoming = $arr;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, the device will not process any packets received via LoRa that passed via MQTT anywhere on the path towards it.
|
||||
*
|
||||
* Generated from protobuf field <code>bool ignore_mqtt = 104;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getIgnoreMqtt()
|
||||
{
|
||||
return $this->ignore_mqtt;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, the device will not process any packets received via LoRa that passed via MQTT anywhere on the path towards it.
|
||||
*
|
||||
* Generated from protobuf field <code>bool ignore_mqtt = 104;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIgnoreMqtt($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->ignore_mqtt = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the ok_to_mqtt bit on outgoing packets
|
||||
*
|
||||
* Generated from protobuf field <code>bool config_ok_to_mqtt = 105;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getConfigOkToMqtt()
|
||||
{
|
||||
return $this->config_ok_to_mqtt;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the ok_to_mqtt bit on outgoing packets
|
||||
*
|
||||
* Generated from protobuf field <code>bool config_ok_to_mqtt = 105;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setConfigOkToMqtt($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->config_ok_to_mqtt = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(LoRaConfig::class, \Meshtastic\Config_LoRaConfig::class);
|
||||
|
||||
@@ -0,0 +1,119 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\LoRaConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Standard predefined channel settings
|
||||
* Note: these mappings must match ModemPreset Choice in the device code.
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.LoRaConfig.ModemPreset</code>
|
||||
*/
|
||||
class ModemPreset
|
||||
{
|
||||
/**
|
||||
* Long Range - Fast
|
||||
*
|
||||
* Generated from protobuf enum <code>LONG_FAST = 0;</code>
|
||||
*/
|
||||
const LONG_FAST = 0;
|
||||
/**
|
||||
* Long Range - Slow
|
||||
* Deprecated in 2.7: Unpopular slow preset.
|
||||
*
|
||||
* Generated from protobuf enum <code>LONG_SLOW = 1 [deprecated = true];</code>
|
||||
*/
|
||||
const LONG_SLOW = 1;
|
||||
/**
|
||||
* Very Long Range - Slow
|
||||
* Deprecated in 2.5: Works only with txco and is unusably slow
|
||||
*
|
||||
* Generated from protobuf enum <code>VERY_LONG_SLOW = 2 [deprecated = true];</code>
|
||||
*/
|
||||
const VERY_LONG_SLOW = 2;
|
||||
/**
|
||||
* Medium Range - Slow
|
||||
*
|
||||
* Generated from protobuf enum <code>MEDIUM_SLOW = 3;</code>
|
||||
*/
|
||||
const MEDIUM_SLOW = 3;
|
||||
/**
|
||||
* Medium Range - Fast
|
||||
*
|
||||
* Generated from protobuf enum <code>MEDIUM_FAST = 4;</code>
|
||||
*/
|
||||
const MEDIUM_FAST = 4;
|
||||
/**
|
||||
* Short Range - Slow
|
||||
*
|
||||
* Generated from protobuf enum <code>SHORT_SLOW = 5;</code>
|
||||
*/
|
||||
const SHORT_SLOW = 5;
|
||||
/**
|
||||
* Short Range - Fast
|
||||
*
|
||||
* Generated from protobuf enum <code>SHORT_FAST = 6;</code>
|
||||
*/
|
||||
const SHORT_FAST = 6;
|
||||
/**
|
||||
* Long Range - Moderately Fast
|
||||
*
|
||||
* Generated from protobuf enum <code>LONG_MODERATE = 7;</code>
|
||||
*/
|
||||
const LONG_MODERATE = 7;
|
||||
/**
|
||||
* Short Range - Turbo
|
||||
* This is the fastest preset and the only one with 500kHz bandwidth.
|
||||
* It is not legal to use in all regions due to this wider bandwidth.
|
||||
*
|
||||
* Generated from protobuf enum <code>SHORT_TURBO = 8;</code>
|
||||
*/
|
||||
const SHORT_TURBO = 8;
|
||||
/**
|
||||
* Long Range - Turbo
|
||||
* This preset performs similarly to LongFast, but with 500Khz bandwidth.
|
||||
*
|
||||
* Generated from protobuf enum <code>LONG_TURBO = 9;</code>
|
||||
*/
|
||||
const LONG_TURBO = 9;
|
||||
|
||||
private static $valueToName = [
|
||||
self::LONG_FAST => 'LONG_FAST',
|
||||
self::LONG_SLOW => 'LONG_SLOW',
|
||||
self::VERY_LONG_SLOW => 'VERY_LONG_SLOW',
|
||||
self::MEDIUM_SLOW => 'MEDIUM_SLOW',
|
||||
self::MEDIUM_FAST => 'MEDIUM_FAST',
|
||||
self::SHORT_SLOW => 'SHORT_SLOW',
|
||||
self::SHORT_FAST => 'SHORT_FAST',
|
||||
self::LONG_MODERATE => 'LONG_MODERATE',
|
||||
self::SHORT_TURBO => 'SHORT_TURBO',
|
||||
self::LONG_TURBO => 'LONG_TURBO',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(ModemPreset::class, \Meshtastic\Config_LoRaConfig_ModemPreset::class);
|
||||
|
||||
@@ -0,0 +1,234 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\LoRaConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.Config.LoRaConfig.RegionCode</code>
|
||||
*/
|
||||
class RegionCode
|
||||
{
|
||||
/**
|
||||
* Region is not set
|
||||
*
|
||||
* Generated from protobuf enum <code>UNSET = 0;</code>
|
||||
*/
|
||||
const PBUNSET = 0;
|
||||
/**
|
||||
* United States
|
||||
*
|
||||
* Generated from protobuf enum <code>US = 1;</code>
|
||||
*/
|
||||
const US = 1;
|
||||
/**
|
||||
* European Union 433mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>EU_433 = 2;</code>
|
||||
*/
|
||||
const EU_433 = 2;
|
||||
/**
|
||||
* European Union 868mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>EU_868 = 3;</code>
|
||||
*/
|
||||
const EU_868 = 3;
|
||||
/**
|
||||
* China
|
||||
*
|
||||
* Generated from protobuf enum <code>CN = 4;</code>
|
||||
*/
|
||||
const CN = 4;
|
||||
/**
|
||||
* Japan
|
||||
*
|
||||
* Generated from protobuf enum <code>JP = 5;</code>
|
||||
*/
|
||||
const JP = 5;
|
||||
/**
|
||||
* Australia / New Zealand
|
||||
*
|
||||
* Generated from protobuf enum <code>ANZ = 6;</code>
|
||||
*/
|
||||
const ANZ = 6;
|
||||
/**
|
||||
* Korea
|
||||
*
|
||||
* Generated from protobuf enum <code>KR = 7;</code>
|
||||
*/
|
||||
const KR = 7;
|
||||
/**
|
||||
* Taiwan
|
||||
*
|
||||
* Generated from protobuf enum <code>TW = 8;</code>
|
||||
*/
|
||||
const TW = 8;
|
||||
/**
|
||||
* Russia
|
||||
*
|
||||
* Generated from protobuf enum <code>RU = 9;</code>
|
||||
*/
|
||||
const RU = 9;
|
||||
/**
|
||||
* India
|
||||
*
|
||||
* Generated from protobuf enum <code>IN = 10;</code>
|
||||
*/
|
||||
const IN = 10;
|
||||
/**
|
||||
* New Zealand 865mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>NZ_865 = 11;</code>
|
||||
*/
|
||||
const NZ_865 = 11;
|
||||
/**
|
||||
* Thailand
|
||||
*
|
||||
* Generated from protobuf enum <code>TH = 12;</code>
|
||||
*/
|
||||
const TH = 12;
|
||||
/**
|
||||
* WLAN Band
|
||||
*
|
||||
* Generated from protobuf enum <code>LORA_24 = 13;</code>
|
||||
*/
|
||||
const LORA_24 = 13;
|
||||
/**
|
||||
* Ukraine 433mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>UA_433 = 14;</code>
|
||||
*/
|
||||
const UA_433 = 14;
|
||||
/**
|
||||
* Ukraine 868mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>UA_868 = 15;</code>
|
||||
*/
|
||||
const UA_868 = 15;
|
||||
/**
|
||||
* Malaysia 433mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>MY_433 = 16;</code>
|
||||
*/
|
||||
const MY_433 = 16;
|
||||
/**
|
||||
* Malaysia 919mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>MY_919 = 17;</code>
|
||||
*/
|
||||
const MY_919 = 17;
|
||||
/**
|
||||
* Singapore 923mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>SG_923 = 18;</code>
|
||||
*/
|
||||
const SG_923 = 18;
|
||||
/**
|
||||
* Philippines 433mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>PH_433 = 19;</code>
|
||||
*/
|
||||
const PH_433 = 19;
|
||||
/**
|
||||
* Philippines 868mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>PH_868 = 20;</code>
|
||||
*/
|
||||
const PH_868 = 20;
|
||||
/**
|
||||
* Philippines 915mhz
|
||||
*
|
||||
* Generated from protobuf enum <code>PH_915 = 21;</code>
|
||||
*/
|
||||
const PH_915 = 21;
|
||||
/**
|
||||
* Australia / New Zealand 433MHz
|
||||
*
|
||||
* Generated from protobuf enum <code>ANZ_433 = 22;</code>
|
||||
*/
|
||||
const ANZ_433 = 22;
|
||||
/**
|
||||
* Kazakhstan 433MHz
|
||||
*
|
||||
* Generated from protobuf enum <code>KZ_433 = 23;</code>
|
||||
*/
|
||||
const KZ_433 = 23;
|
||||
/**
|
||||
* Kazakhstan 863MHz
|
||||
*
|
||||
* Generated from protobuf enum <code>KZ_863 = 24;</code>
|
||||
*/
|
||||
const KZ_863 = 24;
|
||||
/**
|
||||
* Nepal 865MHz
|
||||
*
|
||||
* Generated from protobuf enum <code>NP_865 = 25;</code>
|
||||
*/
|
||||
const NP_865 = 25;
|
||||
/**
|
||||
* Brazil 902MHz
|
||||
*
|
||||
* Generated from protobuf enum <code>BR_902 = 26;</code>
|
||||
*/
|
||||
const BR_902 = 26;
|
||||
|
||||
private static $valueToName = [
|
||||
self::PBUNSET => 'UNSET',
|
||||
self::US => 'US',
|
||||
self::EU_433 => 'EU_433',
|
||||
self::EU_868 => 'EU_868',
|
||||
self::CN => 'CN',
|
||||
self::JP => 'JP',
|
||||
self::ANZ => 'ANZ',
|
||||
self::KR => 'KR',
|
||||
self::TW => 'TW',
|
||||
self::RU => 'RU',
|
||||
self::IN => 'IN',
|
||||
self::NZ_865 => 'NZ_865',
|
||||
self::TH => 'TH',
|
||||
self::LORA_24 => 'LORA_24',
|
||||
self::UA_433 => 'UA_433',
|
||||
self::UA_868 => 'UA_868',
|
||||
self::MY_433 => 'MY_433',
|
||||
self::MY_919 => 'MY_919',
|
||||
self::SG_923 => 'SG_923',
|
||||
self::PH_433 => 'PH_433',
|
||||
self::PH_868 => 'PH_868',
|
||||
self::PH_915 => 'PH_915',
|
||||
self::ANZ_433 => 'ANZ_433',
|
||||
self::KZ_433 => 'KZ_433',
|
||||
self::KZ_863 => 'KZ_863',
|
||||
self::NP_865 => 'NP_865',
|
||||
self::BR_902 => 'BR_902',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
$pbconst = __CLASS__. '::PB' . strtoupper($name);
|
||||
if (!defined($pbconst)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($pbconst);
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(RegionCode::class, \Meshtastic\Config_LoRaConfig_RegionCode::class);
|
||||
|
||||
@@ -0,0 +1,390 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Network Config
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.NetworkConfig</code>
|
||||
*/
|
||||
class NetworkConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Enable WiFi (disables Bluetooth)
|
||||
*
|
||||
* Generated from protobuf field <code>bool wifi_enabled = 1;</code>
|
||||
*/
|
||||
protected $wifi_enabled = false;
|
||||
/**
|
||||
* If set, this node will try to join the specified wifi network and
|
||||
* acquire an address via DHCP
|
||||
*
|
||||
* Generated from protobuf field <code>string wifi_ssid = 3;</code>
|
||||
*/
|
||||
protected $wifi_ssid = '';
|
||||
/**
|
||||
* If set, will be use to authenticate to the named wifi
|
||||
*
|
||||
* Generated from protobuf field <code>string wifi_psk = 4;</code>
|
||||
*/
|
||||
protected $wifi_psk = '';
|
||||
/**
|
||||
* NTP server to use if WiFi is conneced, defaults to `meshtastic.pool.ntp.org`
|
||||
*
|
||||
* Generated from protobuf field <code>string ntp_server = 5;</code>
|
||||
*/
|
||||
protected $ntp_server = '';
|
||||
/**
|
||||
* Enable Ethernet
|
||||
*
|
||||
* Generated from protobuf field <code>bool eth_enabled = 6;</code>
|
||||
*/
|
||||
protected $eth_enabled = false;
|
||||
/**
|
||||
* acquire an address via DHCP or assign static
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig.AddressMode address_mode = 7;</code>
|
||||
*/
|
||||
protected $address_mode = 0;
|
||||
/**
|
||||
* struct to keep static address
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig.IpV4Config ipv4_config = 8;</code>
|
||||
*/
|
||||
protected $ipv4_config = null;
|
||||
/**
|
||||
* rsyslog Server and Port
|
||||
*
|
||||
* Generated from protobuf field <code>string rsyslog_server = 9;</code>
|
||||
*/
|
||||
protected $rsyslog_server = '';
|
||||
/**
|
||||
* Flags for enabling/disabling network protocols
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 enabled_protocols = 10;</code>
|
||||
*/
|
||||
protected $enabled_protocols = 0;
|
||||
/**
|
||||
* Enable/Disable ipv6 support
|
||||
*
|
||||
* Generated from protobuf field <code>bool ipv6_enabled = 11;</code>
|
||||
*/
|
||||
protected $ipv6_enabled = false;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type bool $wifi_enabled
|
||||
* Enable WiFi (disables Bluetooth)
|
||||
* @type string $wifi_ssid
|
||||
* If set, this node will try to join the specified wifi network and
|
||||
* acquire an address via DHCP
|
||||
* @type string $wifi_psk
|
||||
* If set, will be use to authenticate to the named wifi
|
||||
* @type string $ntp_server
|
||||
* NTP server to use if WiFi is conneced, defaults to `meshtastic.pool.ntp.org`
|
||||
* @type bool $eth_enabled
|
||||
* Enable Ethernet
|
||||
* @type int $address_mode
|
||||
* acquire an address via DHCP or assign static
|
||||
* @type \Meshtastic\Config\NetworkConfig\IpV4Config $ipv4_config
|
||||
* struct to keep static address
|
||||
* @type string $rsyslog_server
|
||||
* rsyslog Server and Port
|
||||
* @type int $enabled_protocols
|
||||
* Flags for enabling/disabling network protocols
|
||||
* @type bool $ipv6_enabled
|
||||
* Enable/Disable ipv6 support
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable WiFi (disables Bluetooth)
|
||||
*
|
||||
* Generated from protobuf field <code>bool wifi_enabled = 1;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getWifiEnabled()
|
||||
{
|
||||
return $this->wifi_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable WiFi (disables Bluetooth)
|
||||
*
|
||||
* Generated from protobuf field <code>bool wifi_enabled = 1;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setWifiEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->wifi_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If set, this node will try to join the specified wifi network and
|
||||
* acquire an address via DHCP
|
||||
*
|
||||
* Generated from protobuf field <code>string wifi_ssid = 3;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getWifiSsid()
|
||||
{
|
||||
return $this->wifi_ssid;
|
||||
}
|
||||
|
||||
/**
|
||||
* If set, this node will try to join the specified wifi network and
|
||||
* acquire an address via DHCP
|
||||
*
|
||||
* Generated from protobuf field <code>string wifi_ssid = 3;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setWifiSsid($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->wifi_ssid = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If set, will be use to authenticate to the named wifi
|
||||
*
|
||||
* Generated from protobuf field <code>string wifi_psk = 4;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getWifiPsk()
|
||||
{
|
||||
return $this->wifi_psk;
|
||||
}
|
||||
|
||||
/**
|
||||
* If set, will be use to authenticate to the named wifi
|
||||
*
|
||||
* Generated from protobuf field <code>string wifi_psk = 4;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setWifiPsk($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->wifi_psk = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* NTP server to use if WiFi is conneced, defaults to `meshtastic.pool.ntp.org`
|
||||
*
|
||||
* Generated from protobuf field <code>string ntp_server = 5;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getNtpServer()
|
||||
{
|
||||
return $this->ntp_server;
|
||||
}
|
||||
|
||||
/**
|
||||
* NTP server to use if WiFi is conneced, defaults to `meshtastic.pool.ntp.org`
|
||||
*
|
||||
* Generated from protobuf field <code>string ntp_server = 5;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setNtpServer($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->ntp_server = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable Ethernet
|
||||
*
|
||||
* Generated from protobuf field <code>bool eth_enabled = 6;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getEthEnabled()
|
||||
{
|
||||
return $this->eth_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable Ethernet
|
||||
*
|
||||
* Generated from protobuf field <code>bool eth_enabled = 6;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setEthEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->eth_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* acquire an address via DHCP or assign static
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig.AddressMode address_mode = 7;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getAddressMode()
|
||||
{
|
||||
return $this->address_mode;
|
||||
}
|
||||
|
||||
/**
|
||||
* acquire an address via DHCP or assign static
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig.AddressMode address_mode = 7;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setAddressMode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\NetworkConfig\AddressMode::class);
|
||||
$this->address_mode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* struct to keep static address
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig.IpV4Config ipv4_config = 8;</code>
|
||||
* @return \Meshtastic\Config\NetworkConfig\IpV4Config|null
|
||||
*/
|
||||
public function getIpv4Config()
|
||||
{
|
||||
return $this->ipv4_config;
|
||||
}
|
||||
|
||||
public function hasIpv4Config()
|
||||
{
|
||||
return isset($this->ipv4_config);
|
||||
}
|
||||
|
||||
public function clearIpv4Config()
|
||||
{
|
||||
unset($this->ipv4_config);
|
||||
}
|
||||
|
||||
/**
|
||||
* struct to keep static address
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.NetworkConfig.IpV4Config ipv4_config = 8;</code>
|
||||
* @param \Meshtastic\Config\NetworkConfig\IpV4Config $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIpv4Config($var)
|
||||
{
|
||||
GPBUtil::checkMessage($var, \Meshtastic\Config\NetworkConfig\IpV4Config::class);
|
||||
$this->ipv4_config = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* rsyslog Server and Port
|
||||
*
|
||||
* Generated from protobuf field <code>string rsyslog_server = 9;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getRsyslogServer()
|
||||
{
|
||||
return $this->rsyslog_server;
|
||||
}
|
||||
|
||||
/**
|
||||
* rsyslog Server and Port
|
||||
*
|
||||
* Generated from protobuf field <code>string rsyslog_server = 9;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRsyslogServer($var)
|
||||
{
|
||||
GPBUtil::checkString($var, True);
|
||||
$this->rsyslog_server = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Flags for enabling/disabling network protocols
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 enabled_protocols = 10;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getEnabledProtocols()
|
||||
{
|
||||
return $this->enabled_protocols;
|
||||
}
|
||||
|
||||
/**
|
||||
* Flags for enabling/disabling network protocols
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 enabled_protocols = 10;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setEnabledProtocols($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->enabled_protocols = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable/Disable ipv6 support
|
||||
*
|
||||
* Generated from protobuf field <code>bool ipv6_enabled = 11;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getIpv6Enabled()
|
||||
{
|
||||
return $this->ipv6_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enable/Disable ipv6 support
|
||||
*
|
||||
* Generated from protobuf field <code>bool ipv6_enabled = 11;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIpv6Enabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->ipv6_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(NetworkConfig::class, \Meshtastic\Config_NetworkConfig::class);
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\NetworkConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.Config.NetworkConfig.AddressMode</code>
|
||||
*/
|
||||
class AddressMode
|
||||
{
|
||||
/**
|
||||
* obtain ip address via DHCP
|
||||
*
|
||||
* Generated from protobuf enum <code>DHCP = 0;</code>
|
||||
*/
|
||||
const DHCP = 0;
|
||||
/**
|
||||
* use static ip address
|
||||
*
|
||||
* Generated from protobuf enum <code>STATIC = 1;</code>
|
||||
*/
|
||||
const PBSTATIC = 1;
|
||||
|
||||
private static $valueToName = [
|
||||
self::DHCP => 'DHCP',
|
||||
self::PBSTATIC => 'STATIC',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
$pbconst = __CLASS__. '::PB' . strtoupper($name);
|
||||
if (!defined($pbconst)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($pbconst);
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(AddressMode::class, \Meshtastic\Config_NetworkConfig_AddressMode::class);
|
||||
|
||||
@@ -0,0 +1,170 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\NetworkConfig;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Generated from protobuf message <code>meshtastic.Config.NetworkConfig.IpV4Config</code>
|
||||
*/
|
||||
class IpV4Config extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Static IP address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 ip = 1;</code>
|
||||
*/
|
||||
protected $ip = 0;
|
||||
/**
|
||||
* Static gateway address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 gateway = 2;</code>
|
||||
*/
|
||||
protected $gateway = 0;
|
||||
/**
|
||||
* Static subnet mask
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 subnet = 3;</code>
|
||||
*/
|
||||
protected $subnet = 0;
|
||||
/**
|
||||
* Static DNS server address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 dns = 4;</code>
|
||||
*/
|
||||
protected $dns = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $ip
|
||||
* Static IP address
|
||||
* @type int $gateway
|
||||
* Static gateway address
|
||||
* @type int $subnet
|
||||
* Static subnet mask
|
||||
* @type int $dns
|
||||
* Static DNS server address
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Static IP address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 ip = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getIp()
|
||||
{
|
||||
return $this->ip;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static IP address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 ip = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIp($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->ip = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static gateway address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 gateway = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getGateway()
|
||||
{
|
||||
return $this->gateway;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static gateway address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 gateway = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setGateway($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->gateway = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static subnet mask
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 subnet = 3;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getSubnet()
|
||||
{
|
||||
return $this->subnet;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static subnet mask
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 subnet = 3;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSubnet($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->subnet = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static DNS server address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 dns = 4;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getDns()
|
||||
{
|
||||
return $this->dns;
|
||||
}
|
||||
|
||||
/**
|
||||
* Static DNS server address
|
||||
*
|
||||
* Generated from protobuf field <code>fixed32 dns = 4;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDns($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->dns = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(IpV4Config::class, \Meshtastic\Config_NetworkConfig_IpV4Config::class);
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\NetworkConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Available flags auxiliary network protocols
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.NetworkConfig.ProtocolFlags</code>
|
||||
*/
|
||||
class ProtocolFlags
|
||||
{
|
||||
/**
|
||||
* Do not broadcast packets over any network protocol
|
||||
*
|
||||
* Generated from protobuf enum <code>NO_BROADCAST = 0;</code>
|
||||
*/
|
||||
const NO_BROADCAST = 0;
|
||||
/**
|
||||
* Enable broadcasting packets via UDP over the local network
|
||||
*
|
||||
* Generated from protobuf enum <code>UDP_BROADCAST = 1;</code>
|
||||
*/
|
||||
const UDP_BROADCAST = 1;
|
||||
|
||||
private static $valueToName = [
|
||||
self::NO_BROADCAST => 'NO_BROADCAST',
|
||||
self::UDP_BROADCAST => 'UDP_BROADCAST',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(ProtocolFlags::class, \Meshtastic\Config_NetworkConfig_ProtocolFlags::class);
|
||||
|
||||
@@ -0,0 +1,512 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Position Config
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.PositionConfig</code>
|
||||
*/
|
||||
class PositionConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* We should send our position this often (but only if it has changed significantly)
|
||||
* Defaults to 15 minutes
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 position_broadcast_secs = 1;</code>
|
||||
*/
|
||||
protected $position_broadcast_secs = 0;
|
||||
/**
|
||||
* Adaptive position braoadcast, which is now the default.
|
||||
*
|
||||
* Generated from protobuf field <code>bool position_broadcast_smart_enabled = 2;</code>
|
||||
*/
|
||||
protected $position_broadcast_smart_enabled = false;
|
||||
/**
|
||||
* If set, this node is at a fixed position.
|
||||
* We will generate GPS position updates at the regular interval, but use whatever the last lat/lon/alt we have for the node.
|
||||
* The lat/lon/alt can be set by an internal GPS or with the help of the app.
|
||||
*
|
||||
* Generated from protobuf field <code>bool fixed_position = 3;</code>
|
||||
*/
|
||||
protected $fixed_position = false;
|
||||
/**
|
||||
* Is GPS enabled for this node?
|
||||
*
|
||||
* Generated from protobuf field <code>bool gps_enabled = 4 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $gps_enabled = false;
|
||||
/**
|
||||
* How often should we try to get GPS position (in seconds)
|
||||
* or zero for the default of once every 30 seconds
|
||||
* or a very large value (maxint) to update only once at boot.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_update_interval = 5;</code>
|
||||
*/
|
||||
protected $gps_update_interval = 0;
|
||||
/**
|
||||
* Deprecated in favor of using smart / regular broadcast intervals as implicit attempt time
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_attempt_time = 6 [deprecated = true];</code>
|
||||
* @deprecated
|
||||
*/
|
||||
protected $gps_attempt_time = 0;
|
||||
/**
|
||||
* Bit field of boolean configuration options for POSITION messages
|
||||
* (bitwise OR of PositionFlags)
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 position_flags = 7;</code>
|
||||
*/
|
||||
protected $position_flags = 0;
|
||||
/**
|
||||
* (Re)define GPS_RX_PIN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 rx_gpio = 8;</code>
|
||||
*/
|
||||
protected $rx_gpio = 0;
|
||||
/**
|
||||
* (Re)define GPS_TX_PIN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 tx_gpio = 9;</code>
|
||||
*/
|
||||
protected $tx_gpio = 0;
|
||||
/**
|
||||
* The minimum distance in meters traveled (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 broadcast_smart_minimum_distance = 10;</code>
|
||||
*/
|
||||
protected $broadcast_smart_minimum_distance = 0;
|
||||
/**
|
||||
* The minimum number of seconds (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 broadcast_smart_minimum_interval_secs = 11;</code>
|
||||
*/
|
||||
protected $broadcast_smart_minimum_interval_secs = 0;
|
||||
/**
|
||||
* (Re)define PIN_GPS_EN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_en_gpio = 12;</code>
|
||||
*/
|
||||
protected $gps_en_gpio = 0;
|
||||
/**
|
||||
* Set where GPS is enabled, disabled, or not present
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PositionConfig.GpsMode gps_mode = 13;</code>
|
||||
*/
|
||||
protected $gps_mode = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type int $position_broadcast_secs
|
||||
* We should send our position this often (but only if it has changed significantly)
|
||||
* Defaults to 15 minutes
|
||||
* @type bool $position_broadcast_smart_enabled
|
||||
* Adaptive position braoadcast, which is now the default.
|
||||
* @type bool $fixed_position
|
||||
* If set, this node is at a fixed position.
|
||||
* We will generate GPS position updates at the regular interval, but use whatever the last lat/lon/alt we have for the node.
|
||||
* The lat/lon/alt can be set by an internal GPS or with the help of the app.
|
||||
* @type bool $gps_enabled
|
||||
* Is GPS enabled for this node?
|
||||
* @type int $gps_update_interval
|
||||
* How often should we try to get GPS position (in seconds)
|
||||
* or zero for the default of once every 30 seconds
|
||||
* or a very large value (maxint) to update only once at boot.
|
||||
* @type int $gps_attempt_time
|
||||
* Deprecated in favor of using smart / regular broadcast intervals as implicit attempt time
|
||||
* @type int $position_flags
|
||||
* Bit field of boolean configuration options for POSITION messages
|
||||
* (bitwise OR of PositionFlags)
|
||||
* @type int $rx_gpio
|
||||
* (Re)define GPS_RX_PIN for your board.
|
||||
* @type int $tx_gpio
|
||||
* (Re)define GPS_TX_PIN for your board.
|
||||
* @type int $broadcast_smart_minimum_distance
|
||||
* The minimum distance in meters traveled (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
* @type int $broadcast_smart_minimum_interval_secs
|
||||
* The minimum number of seconds (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
* @type int $gps_en_gpio
|
||||
* (Re)define PIN_GPS_EN for your board.
|
||||
* @type int $gps_mode
|
||||
* Set where GPS is enabled, disabled, or not present
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* We should send our position this often (but only if it has changed significantly)
|
||||
* Defaults to 15 minutes
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 position_broadcast_secs = 1;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getPositionBroadcastSecs()
|
||||
{
|
||||
return $this->position_broadcast_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* We should send our position this often (but only if it has changed significantly)
|
||||
* Defaults to 15 minutes
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 position_broadcast_secs = 1;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPositionBroadcastSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->position_broadcast_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Adaptive position braoadcast, which is now the default.
|
||||
*
|
||||
* Generated from protobuf field <code>bool position_broadcast_smart_enabled = 2;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getPositionBroadcastSmartEnabled()
|
||||
{
|
||||
return $this->position_broadcast_smart_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Adaptive position braoadcast, which is now the default.
|
||||
*
|
||||
* Generated from protobuf field <code>bool position_broadcast_smart_enabled = 2;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPositionBroadcastSmartEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->position_broadcast_smart_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If set, this node is at a fixed position.
|
||||
* We will generate GPS position updates at the regular interval, but use whatever the last lat/lon/alt we have for the node.
|
||||
* The lat/lon/alt can be set by an internal GPS or with the help of the app.
|
||||
*
|
||||
* Generated from protobuf field <code>bool fixed_position = 3;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getFixedPosition()
|
||||
{
|
||||
return $this->fixed_position;
|
||||
}
|
||||
|
||||
/**
|
||||
* If set, this node is at a fixed position.
|
||||
* We will generate GPS position updates at the regular interval, but use whatever the last lat/lon/alt we have for the node.
|
||||
* The lat/lon/alt can be set by an internal GPS or with the help of the app.
|
||||
*
|
||||
* Generated from protobuf field <code>bool fixed_position = 3;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setFixedPosition($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->fixed_position = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Is GPS enabled for this node?
|
||||
*
|
||||
* Generated from protobuf field <code>bool gps_enabled = 4 [deprecated = true];</code>
|
||||
* @return bool
|
||||
* @deprecated
|
||||
*/
|
||||
public function getGpsEnabled()
|
||||
{
|
||||
@trigger_error('gps_enabled is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->gps_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Is GPS enabled for this node?
|
||||
*
|
||||
* Generated from protobuf field <code>bool gps_enabled = 4 [deprecated = true];</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setGpsEnabled($var)
|
||||
{
|
||||
@trigger_error('gps_enabled is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkBool($var);
|
||||
$this->gps_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* How often should we try to get GPS position (in seconds)
|
||||
* or zero for the default of once every 30 seconds
|
||||
* or a very large value (maxint) to update only once at boot.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_update_interval = 5;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getGpsUpdateInterval()
|
||||
{
|
||||
return $this->gps_update_interval;
|
||||
}
|
||||
|
||||
/**
|
||||
* How often should we try to get GPS position (in seconds)
|
||||
* or zero for the default of once every 30 seconds
|
||||
* or a very large value (maxint) to update only once at boot.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_update_interval = 5;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setGpsUpdateInterval($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->gps_update_interval = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Deprecated in favor of using smart / regular broadcast intervals as implicit attempt time
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_attempt_time = 6 [deprecated = true];</code>
|
||||
* @return int
|
||||
* @deprecated
|
||||
*/
|
||||
public function getGpsAttemptTime()
|
||||
{
|
||||
@trigger_error('gps_attempt_time is deprecated.', E_USER_DEPRECATED);
|
||||
return $this->gps_attempt_time;
|
||||
}
|
||||
|
||||
/**
|
||||
* Deprecated in favor of using smart / regular broadcast intervals as implicit attempt time
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_attempt_time = 6 [deprecated = true];</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
* @deprecated
|
||||
*/
|
||||
public function setGpsAttemptTime($var)
|
||||
{
|
||||
@trigger_error('gps_attempt_time is deprecated.', E_USER_DEPRECATED);
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->gps_attempt_time = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Bit field of boolean configuration options for POSITION messages
|
||||
* (bitwise OR of PositionFlags)
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 position_flags = 7;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getPositionFlags()
|
||||
{
|
||||
return $this->position_flags;
|
||||
}
|
||||
|
||||
/**
|
||||
* Bit field of boolean configuration options for POSITION messages
|
||||
* (bitwise OR of PositionFlags)
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 position_flags = 7;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPositionFlags($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->position_flags = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* (Re)define GPS_RX_PIN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 rx_gpio = 8;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getRxGpio()
|
||||
{
|
||||
return $this->rx_gpio;
|
||||
}
|
||||
|
||||
/**
|
||||
* (Re)define GPS_RX_PIN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 rx_gpio = 8;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setRxGpio($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->rx_gpio = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* (Re)define GPS_TX_PIN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 tx_gpio = 9;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getTxGpio()
|
||||
{
|
||||
return $this->tx_gpio;
|
||||
}
|
||||
|
||||
/**
|
||||
* (Re)define GPS_TX_PIN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 tx_gpio = 9;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setTxGpio($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->tx_gpio = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The minimum distance in meters traveled (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 broadcast_smart_minimum_distance = 10;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getBroadcastSmartMinimumDistance()
|
||||
{
|
||||
return $this->broadcast_smart_minimum_distance;
|
||||
}
|
||||
|
||||
/**
|
||||
* The minimum distance in meters traveled (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 broadcast_smart_minimum_distance = 10;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setBroadcastSmartMinimumDistance($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->broadcast_smart_minimum_distance = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The minimum number of seconds (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 broadcast_smart_minimum_interval_secs = 11;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getBroadcastSmartMinimumIntervalSecs()
|
||||
{
|
||||
return $this->broadcast_smart_minimum_interval_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* The minimum number of seconds (since the last send) before we can send a position to the mesh if position_broadcast_smart_enabled
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 broadcast_smart_minimum_interval_secs = 11;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setBroadcastSmartMinimumIntervalSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->broadcast_smart_minimum_interval_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* (Re)define PIN_GPS_EN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_en_gpio = 12;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getGpsEnGpio()
|
||||
{
|
||||
return $this->gps_en_gpio;
|
||||
}
|
||||
|
||||
/**
|
||||
* (Re)define PIN_GPS_EN for your board.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 gps_en_gpio = 12;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setGpsEnGpio($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->gps_en_gpio = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set where GPS is enabled, disabled, or not present
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PositionConfig.GpsMode gps_mode = 13;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getGpsMode()
|
||||
{
|
||||
return $this->gps_mode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set where GPS is enabled, disabled, or not present
|
||||
*
|
||||
* Generated from protobuf field <code>.meshtastic.Config.PositionConfig.GpsMode gps_mode = 13;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setGpsMode($var)
|
||||
{
|
||||
GPBUtil::checkEnum($var, \Meshtastic\Config\PositionConfig\GpsMode::class);
|
||||
$this->gps_mode = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(PositionConfig::class, \Meshtastic\Config_PositionConfig::class);
|
||||
|
||||
@@ -0,0 +1,62 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\PositionConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Protobuf type <code>meshtastic.Config.PositionConfig.GpsMode</code>
|
||||
*/
|
||||
class GpsMode
|
||||
{
|
||||
/**
|
||||
* GPS is present but disabled
|
||||
*
|
||||
* Generated from protobuf enum <code>DISABLED = 0;</code>
|
||||
*/
|
||||
const DISABLED = 0;
|
||||
/**
|
||||
* GPS is present and enabled
|
||||
*
|
||||
* Generated from protobuf enum <code>ENABLED = 1;</code>
|
||||
*/
|
||||
const ENABLED = 1;
|
||||
/**
|
||||
* GPS is not present on the device
|
||||
*
|
||||
* Generated from protobuf enum <code>NOT_PRESENT = 2;</code>
|
||||
*/
|
||||
const NOT_PRESENT = 2;
|
||||
|
||||
private static $valueToName = [
|
||||
self::DISABLED => 'DISABLED',
|
||||
self::ENABLED => 'ENABLED',
|
||||
self::NOT_PRESENT => 'NOT_PRESENT',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(GpsMode::class, \Meshtastic\Config_PositionConfig_GpsMode::class);
|
||||
|
||||
@@ -0,0 +1,133 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config\PositionConfig;
|
||||
|
||||
use UnexpectedValueException;
|
||||
|
||||
/**
|
||||
* Bit field of boolean configuration options, indicating which optional
|
||||
* fields to include when assembling POSITION messages.
|
||||
* Longitude, latitude, altitude, speed, heading, and DOP
|
||||
* are always included (also time if GPS-synced)
|
||||
* NOTE: the more fields are included, the larger the message will be -
|
||||
* leading to longer airtime and a higher risk of packet loss
|
||||
*
|
||||
* Protobuf type <code>meshtastic.Config.PositionConfig.PositionFlags</code>
|
||||
*/
|
||||
class PositionFlags
|
||||
{
|
||||
/**
|
||||
* Required for compilation
|
||||
*
|
||||
* Generated from protobuf enum <code>UNSET = 0;</code>
|
||||
*/
|
||||
const PBUNSET = 0;
|
||||
/**
|
||||
* Include an altitude value (if available)
|
||||
*
|
||||
* Generated from protobuf enum <code>ALTITUDE = 1;</code>
|
||||
*/
|
||||
const ALTITUDE = 1;
|
||||
/**
|
||||
* Altitude value is MSL
|
||||
*
|
||||
* Generated from protobuf enum <code>ALTITUDE_MSL = 2;</code>
|
||||
*/
|
||||
const ALTITUDE_MSL = 2;
|
||||
/**
|
||||
* Include geoidal separation
|
||||
*
|
||||
* Generated from protobuf enum <code>GEOIDAL_SEPARATION = 4;</code>
|
||||
*/
|
||||
const GEOIDAL_SEPARATION = 4;
|
||||
/**
|
||||
* Include the DOP value ; PDOP used by default, see below
|
||||
*
|
||||
* Generated from protobuf enum <code>DOP = 8;</code>
|
||||
*/
|
||||
const DOP = 8;
|
||||
/**
|
||||
* If POS_DOP set, send separate HDOP / VDOP values instead of PDOP
|
||||
*
|
||||
* Generated from protobuf enum <code>HVDOP = 16;</code>
|
||||
*/
|
||||
const HVDOP = 16;
|
||||
/**
|
||||
* Include number of "satellites in view"
|
||||
*
|
||||
* Generated from protobuf enum <code>SATINVIEW = 32;</code>
|
||||
*/
|
||||
const SATINVIEW = 32;
|
||||
/**
|
||||
* Include a sequence number incremented per packet
|
||||
*
|
||||
* Generated from protobuf enum <code>SEQ_NO = 64;</code>
|
||||
*/
|
||||
const SEQ_NO = 64;
|
||||
/**
|
||||
* Include positional timestamp (from GPS solution)
|
||||
*
|
||||
* Generated from protobuf enum <code>TIMESTAMP = 128;</code>
|
||||
*/
|
||||
const TIMESTAMP = 128;
|
||||
/**
|
||||
* Include positional heading
|
||||
* Intended for use with vehicle not walking speeds
|
||||
* walking speeds are likely to be error prone like the compass
|
||||
*
|
||||
* Generated from protobuf enum <code>HEADING = 256;</code>
|
||||
*/
|
||||
const HEADING = 256;
|
||||
/**
|
||||
* Include positional speed
|
||||
* Intended for use with vehicle not walking speeds
|
||||
* walking speeds are likely to be error prone like the compass
|
||||
*
|
||||
* Generated from protobuf enum <code>SPEED = 512;</code>
|
||||
*/
|
||||
const SPEED = 512;
|
||||
|
||||
private static $valueToName = [
|
||||
self::PBUNSET => 'UNSET',
|
||||
self::ALTITUDE => 'ALTITUDE',
|
||||
self::ALTITUDE_MSL => 'ALTITUDE_MSL',
|
||||
self::GEOIDAL_SEPARATION => 'GEOIDAL_SEPARATION',
|
||||
self::DOP => 'DOP',
|
||||
self::HVDOP => 'HVDOP',
|
||||
self::SATINVIEW => 'SATINVIEW',
|
||||
self::SEQ_NO => 'SEQ_NO',
|
||||
self::TIMESTAMP => 'TIMESTAMP',
|
||||
self::HEADING => 'HEADING',
|
||||
self::SPEED => 'SPEED',
|
||||
];
|
||||
|
||||
public static function name($value)
|
||||
{
|
||||
if (!isset(self::$valueToName[$value])) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no name defined for value %s', __CLASS__, $value));
|
||||
}
|
||||
return self::$valueToName[$value];
|
||||
}
|
||||
|
||||
|
||||
public static function value($name)
|
||||
{
|
||||
$const = __CLASS__ . '::' . strtoupper($name);
|
||||
if (!defined($const)) {
|
||||
$pbconst = __CLASS__. '::PB' . strtoupper($name);
|
||||
if (!defined($pbconst)) {
|
||||
throw new UnexpectedValueException(sprintf(
|
||||
'Enum %s has no value defined for name %s', __CLASS__, $name));
|
||||
}
|
||||
return constant($pbconst);
|
||||
}
|
||||
return constant($const);
|
||||
}
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(PositionFlags::class, \Meshtastic\Config_PositionConfig_PositionFlags::class);
|
||||
|
||||
@@ -0,0 +1,391 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Power Config\
|
||||
* See [Power Config](/docs/settings/config/power) for additional power config details.
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.PowerConfig</code>
|
||||
*/
|
||||
class PowerConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* Description: Will sleep everything as much as possible, for the tracker and sensor role this will also include the lora radio.
|
||||
* Don't use this setting if you want to use your device with the phone apps or are using a device without a user button.
|
||||
* Technical Details: Works for ESP32 devices and NRF52 devices in the Sensor or Tracker roles
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_power_saving = 1;</code>
|
||||
*/
|
||||
protected $is_power_saving = false;
|
||||
/**
|
||||
* Description: If non-zero, the device will fully power off this many seconds after external power is removed.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 on_battery_shutdown_after_secs = 2;</code>
|
||||
*/
|
||||
protected $on_battery_shutdown_after_secs = 0;
|
||||
/**
|
||||
* Ratio of voltage divider for battery pin eg. 3.20 (R1=100k, R2=220k)
|
||||
* Overrides the ADC_MULTIPLIER defined in variant for battery voltage calculation.
|
||||
* https://meshtastic.org/docs/configuration/radio/power/#adc-multiplier-override
|
||||
* Should be set to floating point value between 2 and 6
|
||||
*
|
||||
* Generated from protobuf field <code>float adc_multiplier_override = 3;</code>
|
||||
*/
|
||||
protected $adc_multiplier_override = 0.0;
|
||||
/**
|
||||
* Description: The number of seconds for to wait before turning off BLE in No Bluetooth states
|
||||
* Technical Details: ESP32 Only 0 for default of 1 minute
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 wait_bluetooth_secs = 4;</code>
|
||||
*/
|
||||
protected $wait_bluetooth_secs = 0;
|
||||
/**
|
||||
* Super Deep Sleep Seconds
|
||||
* While in Light Sleep if mesh_sds_timeout_secs is exceeded we will lower into super deep sleep
|
||||
* for this value (default 1 year) or a button press
|
||||
* 0 for default of one year
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 sds_secs = 6;</code>
|
||||
*/
|
||||
protected $sds_secs = 0;
|
||||
/**
|
||||
* Description: In light sleep the CPU is suspended, LoRa radio is on, BLE is off an GPS is on
|
||||
* Technical Details: ESP32 Only 0 for default of 300
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 ls_secs = 7;</code>
|
||||
*/
|
||||
protected $ls_secs = 0;
|
||||
/**
|
||||
* Description: While in light sleep when we receive packets on the LoRa radio we will wake and handle them and stay awake in no BLE mode for this value
|
||||
* Technical Details: ESP32 Only 0 for default of 10 seconds
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 min_wake_secs = 8;</code>
|
||||
*/
|
||||
protected $min_wake_secs = 0;
|
||||
/**
|
||||
* I2C address of INA_2XX to use for reading device battery voltage
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 device_battery_ina_address = 9;</code>
|
||||
*/
|
||||
protected $device_battery_ina_address = 0;
|
||||
/**
|
||||
* If non-zero, we want powermon log outputs. With the particular (bitfield) sources enabled.
|
||||
* Note: we picked an ID of 32 so that lower more efficient IDs can be used for more frequently used options.
|
||||
*
|
||||
* Generated from protobuf field <code>uint64 powermon_enables = 32;</code>
|
||||
*/
|
||||
protected $powermon_enables = 0;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type bool $is_power_saving
|
||||
* Description: Will sleep everything as much as possible, for the tracker and sensor role this will also include the lora radio.
|
||||
* Don't use this setting if you want to use your device with the phone apps or are using a device without a user button.
|
||||
* Technical Details: Works for ESP32 devices and NRF52 devices in the Sensor or Tracker roles
|
||||
* @type int $on_battery_shutdown_after_secs
|
||||
* Description: If non-zero, the device will fully power off this many seconds after external power is removed.
|
||||
* @type float $adc_multiplier_override
|
||||
* Ratio of voltage divider for battery pin eg. 3.20 (R1=100k, R2=220k)
|
||||
* Overrides the ADC_MULTIPLIER defined in variant for battery voltage calculation.
|
||||
* https://meshtastic.org/docs/configuration/radio/power/#adc-multiplier-override
|
||||
* Should be set to floating point value between 2 and 6
|
||||
* @type int $wait_bluetooth_secs
|
||||
* Description: The number of seconds for to wait before turning off BLE in No Bluetooth states
|
||||
* Technical Details: ESP32 Only 0 for default of 1 minute
|
||||
* @type int $sds_secs
|
||||
* Super Deep Sleep Seconds
|
||||
* While in Light Sleep if mesh_sds_timeout_secs is exceeded we will lower into super deep sleep
|
||||
* for this value (default 1 year) or a button press
|
||||
* 0 for default of one year
|
||||
* @type int $ls_secs
|
||||
* Description: In light sleep the CPU is suspended, LoRa radio is on, BLE is off an GPS is on
|
||||
* Technical Details: ESP32 Only 0 for default of 300
|
||||
* @type int $min_wake_secs
|
||||
* Description: While in light sleep when we receive packets on the LoRa radio we will wake and handle them and stay awake in no BLE mode for this value
|
||||
* Technical Details: ESP32 Only 0 for default of 10 seconds
|
||||
* @type int $device_battery_ina_address
|
||||
* I2C address of INA_2XX to use for reading device battery voltage
|
||||
* @type int|string $powermon_enables
|
||||
* If non-zero, we want powermon log outputs. With the particular (bitfield) sources enabled.
|
||||
* Note: we picked an ID of 32 so that lower more efficient IDs can be used for more frequently used options.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: Will sleep everything as much as possible, for the tracker and sensor role this will also include the lora radio.
|
||||
* Don't use this setting if you want to use your device with the phone apps or are using a device without a user button.
|
||||
* Technical Details: Works for ESP32 devices and NRF52 devices in the Sensor or Tracker roles
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_power_saving = 1;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getIsPowerSaving()
|
||||
{
|
||||
return $this->is_power_saving;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: Will sleep everything as much as possible, for the tracker and sensor role this will also include the lora radio.
|
||||
* Don't use this setting if you want to use your device with the phone apps or are using a device without a user button.
|
||||
* Technical Details: Works for ESP32 devices and NRF52 devices in the Sensor or Tracker roles
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_power_saving = 1;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIsPowerSaving($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->is_power_saving = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: If non-zero, the device will fully power off this many seconds after external power is removed.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 on_battery_shutdown_after_secs = 2;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getOnBatteryShutdownAfterSecs()
|
||||
{
|
||||
return $this->on_battery_shutdown_after_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: If non-zero, the device will fully power off this many seconds after external power is removed.
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 on_battery_shutdown_after_secs = 2;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setOnBatteryShutdownAfterSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->on_battery_shutdown_after_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Ratio of voltage divider for battery pin eg. 3.20 (R1=100k, R2=220k)
|
||||
* Overrides the ADC_MULTIPLIER defined in variant for battery voltage calculation.
|
||||
* https://meshtastic.org/docs/configuration/radio/power/#adc-multiplier-override
|
||||
* Should be set to floating point value between 2 and 6
|
||||
*
|
||||
* Generated from protobuf field <code>float adc_multiplier_override = 3;</code>
|
||||
* @return float
|
||||
*/
|
||||
public function getAdcMultiplierOverride()
|
||||
{
|
||||
return $this->adc_multiplier_override;
|
||||
}
|
||||
|
||||
/**
|
||||
* Ratio of voltage divider for battery pin eg. 3.20 (R1=100k, R2=220k)
|
||||
* Overrides the ADC_MULTIPLIER defined in variant for battery voltage calculation.
|
||||
* https://meshtastic.org/docs/configuration/radio/power/#adc-multiplier-override
|
||||
* Should be set to floating point value between 2 and 6
|
||||
*
|
||||
* Generated from protobuf field <code>float adc_multiplier_override = 3;</code>
|
||||
* @param float $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setAdcMultiplierOverride($var)
|
||||
{
|
||||
GPBUtil::checkFloat($var);
|
||||
$this->adc_multiplier_override = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: The number of seconds for to wait before turning off BLE in No Bluetooth states
|
||||
* Technical Details: ESP32 Only 0 for default of 1 minute
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 wait_bluetooth_secs = 4;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getWaitBluetoothSecs()
|
||||
{
|
||||
return $this->wait_bluetooth_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: The number of seconds for to wait before turning off BLE in No Bluetooth states
|
||||
* Technical Details: ESP32 Only 0 for default of 1 minute
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 wait_bluetooth_secs = 4;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setWaitBluetoothSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->wait_bluetooth_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Super Deep Sleep Seconds
|
||||
* While in Light Sleep if mesh_sds_timeout_secs is exceeded we will lower into super deep sleep
|
||||
* for this value (default 1 year) or a button press
|
||||
* 0 for default of one year
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 sds_secs = 6;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getSdsSecs()
|
||||
{
|
||||
return $this->sds_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Super Deep Sleep Seconds
|
||||
* While in Light Sleep if mesh_sds_timeout_secs is exceeded we will lower into super deep sleep
|
||||
* for this value (default 1 year) or a button press
|
||||
* 0 for default of one year
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 sds_secs = 6;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSdsSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->sds_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: In light sleep the CPU is suspended, LoRa radio is on, BLE is off an GPS is on
|
||||
* Technical Details: ESP32 Only 0 for default of 300
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 ls_secs = 7;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getLsSecs()
|
||||
{
|
||||
return $this->ls_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: In light sleep the CPU is suspended, LoRa radio is on, BLE is off an GPS is on
|
||||
* Technical Details: ESP32 Only 0 for default of 300
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 ls_secs = 7;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setLsSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->ls_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: While in light sleep when we receive packets on the LoRa radio we will wake and handle them and stay awake in no BLE mode for this value
|
||||
* Technical Details: ESP32 Only 0 for default of 10 seconds
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 min_wake_secs = 8;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getMinWakeSecs()
|
||||
{
|
||||
return $this->min_wake_secs;
|
||||
}
|
||||
|
||||
/**
|
||||
* Description: While in light sleep when we receive packets on the LoRa radio we will wake and handle them and stay awake in no BLE mode for this value
|
||||
* Technical Details: ESP32 Only 0 for default of 10 seconds
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 min_wake_secs = 8;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setMinWakeSecs($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->min_wake_secs = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* I2C address of INA_2XX to use for reading device battery voltage
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 device_battery_ina_address = 9;</code>
|
||||
* @return int
|
||||
*/
|
||||
public function getDeviceBatteryInaAddress()
|
||||
{
|
||||
return $this->device_battery_ina_address;
|
||||
}
|
||||
|
||||
/**
|
||||
* I2C address of INA_2XX to use for reading device battery voltage
|
||||
*
|
||||
* Generated from protobuf field <code>uint32 device_battery_ina_address = 9;</code>
|
||||
* @param int $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDeviceBatteryInaAddress($var)
|
||||
{
|
||||
GPBUtil::checkUint32($var);
|
||||
$this->device_battery_ina_address = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If non-zero, we want powermon log outputs. With the particular (bitfield) sources enabled.
|
||||
* Note: we picked an ID of 32 so that lower more efficient IDs can be used for more frequently used options.
|
||||
*
|
||||
* Generated from protobuf field <code>uint64 powermon_enables = 32;</code>
|
||||
* @return int|string
|
||||
*/
|
||||
public function getPowermonEnables()
|
||||
{
|
||||
return $this->powermon_enables;
|
||||
}
|
||||
|
||||
/**
|
||||
* If non-zero, we want powermon log outputs. With the particular (bitfield) sources enabled.
|
||||
* Note: we picked an ID of 32 so that lower more efficient IDs can be used for more frequently used options.
|
||||
*
|
||||
* Generated from protobuf field <code>uint64 powermon_enables = 32;</code>
|
||||
* @param int|string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPowermonEnables($var)
|
||||
{
|
||||
GPBUtil::checkUint64($var);
|
||||
$this->powermon_enables = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(PowerConfig::class, \Meshtastic\Config_PowerConfig::class);
|
||||
|
||||
@@ -0,0 +1,288 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Generated from protobuf message <code>meshtastic.Config.SecurityConfig</code>
|
||||
*/
|
||||
class SecurityConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
/**
|
||||
* The public key of the user's device.
|
||||
* Sent out to other nodes on the mesh to allow them to compute a shared secret key.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes public_key = 1;</code>
|
||||
*/
|
||||
protected $public_key = '';
|
||||
/**
|
||||
* The private key of the device.
|
||||
* Used to create a shared key with a remote device.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes private_key = 2;</code>
|
||||
*/
|
||||
protected $private_key = '';
|
||||
/**
|
||||
* The public key authorized to send admin messages to this node.
|
||||
*
|
||||
* Generated from protobuf field <code>repeated bytes admin_key = 3;</code>
|
||||
*/
|
||||
private $admin_key;
|
||||
/**
|
||||
* If true, device is considered to be "managed" by a mesh administrator via admin messages
|
||||
* Device is managed by a mesh administrator.
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_managed = 4;</code>
|
||||
*/
|
||||
protected $is_managed = false;
|
||||
/**
|
||||
* Serial Console over the Stream API."
|
||||
*
|
||||
* Generated from protobuf field <code>bool serial_enabled = 5;</code>
|
||||
*/
|
||||
protected $serial_enabled = false;
|
||||
/**
|
||||
* By default we turn off logging as soon as an API client connects (to keep shared serial link quiet).
|
||||
* Output live debug logging over serial or bluetooth is set to true.
|
||||
*
|
||||
* Generated from protobuf field <code>bool debug_log_api_enabled = 6;</code>
|
||||
*/
|
||||
protected $debug_log_api_enabled = false;
|
||||
/**
|
||||
* Allow incoming device control over the insecure legacy admin channel.
|
||||
*
|
||||
* Generated from protobuf field <code>bool admin_channel_enabled = 8;</code>
|
||||
*/
|
||||
protected $admin_channel_enabled = false;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* @type string $public_key
|
||||
* The public key of the user's device.
|
||||
* Sent out to other nodes on the mesh to allow them to compute a shared secret key.
|
||||
* @type string $private_key
|
||||
* The private key of the device.
|
||||
* Used to create a shared key with a remote device.
|
||||
* @type array<string>|\Google\Protobuf\Internal\RepeatedField $admin_key
|
||||
* The public key authorized to send admin messages to this node.
|
||||
* @type bool $is_managed
|
||||
* If true, device is considered to be "managed" by a mesh administrator via admin messages
|
||||
* Device is managed by a mesh administrator.
|
||||
* @type bool $serial_enabled
|
||||
* Serial Console over the Stream API."
|
||||
* @type bool $debug_log_api_enabled
|
||||
* By default we turn off logging as soon as an API client connects (to keep shared serial link quiet).
|
||||
* Output live debug logging over serial or bluetooth is set to true.
|
||||
* @type bool $admin_channel_enabled
|
||||
* Allow incoming device control over the insecure legacy admin channel.
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* The public key of the user's device.
|
||||
* Sent out to other nodes on the mesh to allow them to compute a shared secret key.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes public_key = 1;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getPublicKey()
|
||||
{
|
||||
return $this->public_key;
|
||||
}
|
||||
|
||||
/**
|
||||
* The public key of the user's device.
|
||||
* Sent out to other nodes on the mesh to allow them to compute a shared secret key.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes public_key = 1;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPublicKey($var)
|
||||
{
|
||||
GPBUtil::checkString($var, False);
|
||||
$this->public_key = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The private key of the device.
|
||||
* Used to create a shared key with a remote device.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes private_key = 2;</code>
|
||||
* @return string
|
||||
*/
|
||||
public function getPrivateKey()
|
||||
{
|
||||
return $this->private_key;
|
||||
}
|
||||
|
||||
/**
|
||||
* The private key of the device.
|
||||
* Used to create a shared key with a remote device.
|
||||
*
|
||||
* Generated from protobuf field <code>bytes private_key = 2;</code>
|
||||
* @param string $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setPrivateKey($var)
|
||||
{
|
||||
GPBUtil::checkString($var, False);
|
||||
$this->private_key = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The public key authorized to send admin messages to this node.
|
||||
*
|
||||
* Generated from protobuf field <code>repeated bytes admin_key = 3;</code>
|
||||
* @return \Google\Protobuf\Internal\RepeatedField
|
||||
*/
|
||||
public function getAdminKey()
|
||||
{
|
||||
return $this->admin_key;
|
||||
}
|
||||
|
||||
/**
|
||||
* The public key authorized to send admin messages to this node.
|
||||
*
|
||||
* Generated from protobuf field <code>repeated bytes admin_key = 3;</code>
|
||||
* @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setAdminKey($var)
|
||||
{
|
||||
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::BYTES);
|
||||
$this->admin_key = $arr;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, device is considered to be "managed" by a mesh administrator via admin messages
|
||||
* Device is managed by a mesh administrator.
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_managed = 4;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getIsManaged()
|
||||
{
|
||||
return $this->is_managed;
|
||||
}
|
||||
|
||||
/**
|
||||
* If true, device is considered to be "managed" by a mesh administrator via admin messages
|
||||
* Device is managed by a mesh administrator.
|
||||
*
|
||||
* Generated from protobuf field <code>bool is_managed = 4;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setIsManaged($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->is_managed = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Serial Console over the Stream API."
|
||||
*
|
||||
* Generated from protobuf field <code>bool serial_enabled = 5;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getSerialEnabled()
|
||||
{
|
||||
return $this->serial_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Serial Console over the Stream API."
|
||||
*
|
||||
* Generated from protobuf field <code>bool serial_enabled = 5;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setSerialEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->serial_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* By default we turn off logging as soon as an API client connects (to keep shared serial link quiet).
|
||||
* Output live debug logging over serial or bluetooth is set to true.
|
||||
*
|
||||
* Generated from protobuf field <code>bool debug_log_api_enabled = 6;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getDebugLogApiEnabled()
|
||||
{
|
||||
return $this->debug_log_api_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* By default we turn off logging as soon as an API client connects (to keep shared serial link quiet).
|
||||
* Output live debug logging over serial or bluetooth is set to true.
|
||||
*
|
||||
* Generated from protobuf field <code>bool debug_log_api_enabled = 6;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setDebugLogApiEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->debug_log_api_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Allow incoming device control over the insecure legacy admin channel.
|
||||
*
|
||||
* Generated from protobuf field <code>bool admin_channel_enabled = 8;</code>
|
||||
* @return bool
|
||||
*/
|
||||
public function getAdminChannelEnabled()
|
||||
{
|
||||
return $this->admin_channel_enabled;
|
||||
}
|
||||
|
||||
/**
|
||||
* Allow incoming device control over the insecure legacy admin channel.
|
||||
*
|
||||
* Generated from protobuf field <code>bool admin_channel_enabled = 8;</code>
|
||||
* @param bool $var
|
||||
* @return $this
|
||||
*/
|
||||
public function setAdminChannelEnabled($var)
|
||||
{
|
||||
GPBUtil::checkBool($var);
|
||||
$this->admin_channel_enabled = $var;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(SecurityConfig::class, \Meshtastic\Config_SecurityConfig::class);
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic\Config;
|
||||
|
||||
use Google\Protobuf\Internal\GPBType;
|
||||
use Google\Protobuf\Internal\RepeatedField;
|
||||
use Google\Protobuf\Internal\GPBUtil;
|
||||
|
||||
/**
|
||||
* Blank config request, strictly for getting the session key
|
||||
*
|
||||
* Generated from protobuf message <code>meshtastic.Config.SessionkeyConfig</code>
|
||||
*/
|
||||
class SessionkeyConfig extends \Google\Protobuf\Internal\Message
|
||||
{
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param array $data {
|
||||
* Optional. Data for populating the Message object.
|
||||
*
|
||||
* }
|
||||
*/
|
||||
public function __construct($data = NULL) {
|
||||
\GPBMetadata\Meshtastic\Config::initOnce();
|
||||
parent::__construct($data);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Adding a class alias for backwards compatibility with the previous class name.
|
||||
class_alias(SessionkeyConfig::class, \Meshtastic\Config_SessionkeyConfig::class);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\BluetoothConfig instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_BluetoothConfig {}
|
||||
}
|
||||
class_exists(Config\BluetoothConfig::class);
|
||||
@trigger_error('Meshtastic\Config_BluetoothConfig is deprecated and will be removed in the next major release. Use Meshtastic\Config\BluetoothConfig instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\BluetoothConfig\PairingMode instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_BluetoothConfig_PairingMode {}
|
||||
}
|
||||
class_exists(Config\BluetoothConfig\PairingMode::class);
|
||||
@trigger_error('Meshtastic\Config_BluetoothConfig_PairingMode is deprecated and will be removed in the next major release. Use Meshtastic\Config\BluetoothConfig\PairingMode instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DeviceConfig instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DeviceConfig {}
|
||||
}
|
||||
class_exists(Config\DeviceConfig::class);
|
||||
@trigger_error('Meshtastic\Config_DeviceConfig is deprecated and will be removed in the next major release. Use Meshtastic\Config\DeviceConfig instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DeviceConfig\BuzzerMode instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DeviceConfig_BuzzerMode {}
|
||||
}
|
||||
class_exists(Config\DeviceConfig\BuzzerMode::class);
|
||||
@trigger_error('Meshtastic\Config_DeviceConfig_BuzzerMode is deprecated and will be removed in the next major release. Use Meshtastic\Config\DeviceConfig\BuzzerMode instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DeviceConfig\RebroadcastMode instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DeviceConfig_RebroadcastMode {}
|
||||
}
|
||||
class_exists(Config\DeviceConfig\RebroadcastMode::class);
|
||||
@trigger_error('Meshtastic\Config_DeviceConfig_RebroadcastMode is deprecated and will be removed in the next major release. Use Meshtastic\Config\DeviceConfig\RebroadcastMode instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DeviceConfig\Role instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DeviceConfig_Role {}
|
||||
}
|
||||
class_exists(Config\DeviceConfig\Role::class);
|
||||
@trigger_error('Meshtastic\Config_DeviceConfig_Role is deprecated and will be removed in the next major release. Use Meshtastic\Config\DeviceConfig\Role instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DisplayConfig instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DisplayConfig {}
|
||||
}
|
||||
class_exists(Config\DisplayConfig::class);
|
||||
@trigger_error('Meshtastic\Config_DisplayConfig is deprecated and will be removed in the next major release. Use Meshtastic\Config\DisplayConfig instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DisplayConfig\CompassOrientation instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DisplayConfig_CompassOrientation {}
|
||||
}
|
||||
class_exists(Config\DisplayConfig\CompassOrientation::class);
|
||||
@trigger_error('Meshtastic\Config_DisplayConfig_CompassOrientation is deprecated and will be removed in the next major release. Use Meshtastic\Config\DisplayConfig\CompassOrientation instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DisplayConfig\DeprecatedGpsCoordinateFormat instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DisplayConfig_DeprecatedGpsCoordinateFormat {}
|
||||
}
|
||||
class_exists(Config\DisplayConfig\DeprecatedGpsCoordinateFormat::class);
|
||||
@trigger_error('Meshtastic\Config_DisplayConfig_DeprecatedGpsCoordinateFormat is deprecated and will be removed in the next major release. Use Meshtastic\Config\DisplayConfig\DeprecatedGpsCoordinateFormat instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DisplayConfig\DisplayMode instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DisplayConfig_DisplayMode {}
|
||||
}
|
||||
class_exists(Config\DisplayConfig\DisplayMode::class);
|
||||
@trigger_error('Meshtastic\Config_DisplayConfig_DisplayMode is deprecated and will be removed in the next major release. Use Meshtastic\Config\DisplayConfig\DisplayMode instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DisplayConfig\DisplayUnits instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DisplayConfig_DisplayUnits {}
|
||||
}
|
||||
class_exists(Config\DisplayConfig\DisplayUnits::class);
|
||||
@trigger_error('Meshtastic\Config_DisplayConfig_DisplayUnits is deprecated and will be removed in the next major release. Use Meshtastic\Config\DisplayConfig\DisplayUnits instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\DisplayConfig\OledType instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_DisplayConfig_OledType {}
|
||||
}
|
||||
class_exists(Config\DisplayConfig\OledType::class);
|
||||
@trigger_error('Meshtastic\Config_DisplayConfig_OledType is deprecated and will be removed in the next major release. Use Meshtastic\Config\DisplayConfig\OledType instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\LoRaConfig instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_LoRaConfig {}
|
||||
}
|
||||
class_exists(Config\LoRaConfig::class);
|
||||
@trigger_error('Meshtastic\Config_LoRaConfig is deprecated and will be removed in the next major release. Use Meshtastic\Config\LoRaConfig instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\LoRaConfig\ModemPreset instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_LoRaConfig_ModemPreset {}
|
||||
}
|
||||
class_exists(Config\LoRaConfig\ModemPreset::class);
|
||||
@trigger_error('Meshtastic\Config_LoRaConfig_ModemPreset is deprecated and will be removed in the next major release. Use Meshtastic\Config\LoRaConfig\ModemPreset instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\LoRaConfig\RegionCode instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_LoRaConfig_RegionCode {}
|
||||
}
|
||||
class_exists(Config\LoRaConfig\RegionCode::class);
|
||||
@trigger_error('Meshtastic\Config_LoRaConfig_RegionCode is deprecated and will be removed in the next major release. Use Meshtastic\Config\LoRaConfig\RegionCode instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\NetworkConfig instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_NetworkConfig {}
|
||||
}
|
||||
class_exists(Config\NetworkConfig::class);
|
||||
@trigger_error('Meshtastic\Config_NetworkConfig is deprecated and will be removed in the next major release. Use Meshtastic\Config\NetworkConfig instead', E_USER_DEPRECATED);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
# source: meshtastic/config.proto
|
||||
|
||||
namespace Meshtastic;
|
||||
|
||||
if (false) {
|
||||
/**
|
||||
* This class is deprecated. Use Meshtastic\Config\NetworkConfig\AddressMode instead.
|
||||
* @deprecated
|
||||
*/
|
||||
class Config_NetworkConfig_AddressMode {}
|
||||
}
|
||||
class_exists(Config\NetworkConfig\AddressMode::class);
|
||||
@trigger_error('Meshtastic\Config_NetworkConfig_AddressMode is deprecated and will be removed in the next major release. Use Meshtastic\Config\NetworkConfig\AddressMode instead', E_USER_DEPRECATED);
|
||||
|
||||
Loaded 100 of 285 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user