mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-20 17:52:35 +00:00
Trunk again
This commit is contained in:
@@ -10,6 +10,7 @@
|
|||||||
#include "linux/gpio/LinuxGPIOPin.h"
|
#include "linux/gpio/LinuxGPIOPin.h"
|
||||||
#include "meshUtils.h"
|
#include "meshUtils.h"
|
||||||
#include "yaml-cpp/yaml.h"
|
#include "yaml-cpp/yaml.h"
|
||||||
|
#include <ErriezCRC32.h>
|
||||||
#include <Utility.h>
|
#include <Utility.h>
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#include <bluetooth/bluetooth.h>
|
#include <bluetooth/bluetooth.h>
|
||||||
@@ -20,8 +21,6 @@
|
|||||||
#include <map>
|
#include <map>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <ErriezCRC32.h>
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef PORTDUINO_LINUX_HARDWARE
|
#ifdef PORTDUINO_LINUX_HARDWARE
|
||||||
#include <cxxabi.h>
|
#include <cxxabi.h>
|
||||||
@@ -311,7 +310,7 @@ void portduinoSetup()
|
|||||||
|
|
||||||
// convert crc32 ascii to raw uint32
|
// convert crc32 ascii to raw uint32
|
||||||
for (int j = 0; j < 4; j++) {
|
for (int j = 0; j < 4; j++) {
|
||||||
crc32_value += std::stoi(crc32_str.substr(j*2, 2), nullptr, 16) << (3 - j)*8;
|
crc32_value += std::stoi(crc32_str.substr(j * 2, 2), nullptr, 16) << (3 - j) * 8;
|
||||||
}
|
}
|
||||||
std::cout << "autoconf: Found eeprom crc " << crc32_start << std::endl;
|
std::cout << "autoconf: Found eeprom crc " << crc32_start << std::endl;
|
||||||
|
|
||||||
@@ -331,7 +330,7 @@ void portduinoSetup()
|
|||||||
if (strlen(devID_start) == 32) {
|
if (strlen(devID_start) == 32) {
|
||||||
std::string devID_str(devID_start);
|
std::string devID_str(devID_start);
|
||||||
for (int j = 0; j < 16; j++) {
|
for (int j = 0; j < 16; j++) {
|
||||||
portduino_config.device_id[j] = std::stoi(devID_str.substr(j*2, 2), nullptr, 16);
|
portduino_config.device_id[j] = std::stoi(devID_str.substr(j * 2, 2), nullptr, 16);
|
||||||
}
|
}
|
||||||
portduino_config.has_device_id = true;
|
portduino_config.has_device_id = true;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user