mirror of
https://github.com/esphome/esphome.git
synced 2025-10-11 14:23:47 +01:00
Add encode_uint32 method (#1427)
This commit is contained in:
@@ -46,8 +46,7 @@ void rdm6300::RDM6300Component::loop() {
|
||||
} else {
|
||||
// Valid data
|
||||
this->status_clear_warning();
|
||||
const uint32_t result = (uint32_t(this->buffer_[1]) << 24) | (uint32_t(this->buffer_[2]) << 16) |
|
||||
(uint32_t(this->buffer_[3]) << 8) | this->buffer_[4];
|
||||
const uint32_t result = encode_uint32(this->buffer_[1], this->buffer_[2], this->buffer_[3], this->buffer_[4]);
|
||||
bool report = result != last_id_;
|
||||
for (auto *card : this->cards_) {
|
||||
if (card->process(result)) {
|
||||
|
Reference in New Issue
Block a user