I use external api to retrieve IOT data. In the payload i get such data like below
{
"device_id": "0000000000000000",
"beacon_detected": true,
"beacon_uuid": 238871591613419,
"beacon_rssi": -65,
"beacon_battery": 100,
"temperature": 21,
}
The value of beacon_uuid property correspond to decimal conversion of ee579F2A2113 Hex value.
238 -> EE
87 -> 57
159 -> 9F
42 -> 2A
33 -> 21
19 -> 13
Currently i deserialize payload using class with string attribute
/// <summary>
/// Gets or sets the BeaconUuid.
/// </summary>
[JsonProperty("beacon_uuid")]
public string BeaconUuid { get; set; }
and i get value as string “23887159423319” but i would like to have the decoded value as hexa string “EE:57:9F:2A:21:13”
Is there a way to do the conversion directly with JsonConvert ?
Thanks in adavance for any help doing thos conversion
2