Skip to content

Commit 4095afb

Browse files
author
Erik Hougaard
committed
Endian-swap implemented in setMajorMinor
1 parent a401e80 commit 4095afb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libraries/Bluefruit52Lib/src/services/BLEBeacon.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,8 @@ void BLEBeacon::setUuid(uint8_t const uuid128[16])
7777

7878
void BLEBeacon::setMajorMinor(uint16_t major, uint16_t minor)
7979
{
80-
_major_be = major;
81-
_minor_be = minor;
80+
_major_be = __swap16(major);
81+
_minor_be = __swap16(minor);
8282
}
8383

8484
void BLEBeacon::setRssiAt1m(int8_t rssi)

0 commit comments

Comments
 (0)