Improved GPS Settings app and GPS service (#222)
- Fixes and improvements to `GpsSettings` app, `GpsDevice` and `GpsService` - Implemented location/GPS statusbar icon - Added app icon - Added support for other GPS models (based on Meshtastic code)
This commit is contained in:
committed by
GitHub
parent
ad2cad3bf1
commit
5055fa7822
@@ -1,6 +1,7 @@
|
||||
#include "Tactility/StringUtils.h"
|
||||
|
||||
#include <cstring>
|
||||
#include <ranges>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
|
||||
@@ -80,4 +81,19 @@ std::string removeFileExtension(const std::string& input) {
|
||||
}
|
||||
}
|
||||
|
||||
bool isAsciiHexString(const std::string& input) {
|
||||
// Find invalid characters
|
||||
return std::ranges::views::filter(input, [](char character){
|
||||
if (
|
||||
(('0' <= character) && ('9' >= character)) ||
|
||||
(('a' <= character) && ('f' >= character)) ||
|
||||
(('A' <= character) && ('F' >= character))
|
||||
) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}).empty();
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
Reference in New Issue
Block a user