<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[How to extract Device Address from Payload ?]]></title><description><![CDATA[<p dir="auto">Hi everyone !<br />
I need to know how to extract the device address from the payload ?<br />
data = s.recv(64)<br />
I use this one to receive data. Once the data is received, I have to extract the packet. Once extracting, I have to check with my list.<br />
Sorry for posting this again, I am just confused with this.<br />
Thank you in Advance.</p>
]]></description><link>https://forum.pycom.io/topic/3532/how-to-extract-device-address-from-payload</link><generator>RSS for Node</generator><lastBuildDate>Thu, 16 Jul 2026 23:33:26 GMT</lastBuildDate><atom:link href="https://forum.pycom.io/topic/3532.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 23 Jul 2018 13:46:58 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to extract Device Address from Payload ? on Mon, 23 Jul 2018 13:46:58 GMT]]></title><description><![CDATA[<p dir="auto">Hi everyone !<br />
I need to know how to extract the device address from the payload ?<br />
data = s.recv(64)<br />
I use this one to receive data. Once the data is received, I have to extract the packet. Once extracting, I have to check with my list.<br />
Sorry for posting this again, I am just confused with this.<br />
Thank you in Advance.</p>
]]></description><link>https://forum.pycom.io/post/21057</link><guid isPermaLink="true">https://forum.pycom.io/post/21057</guid><dc:creator><![CDATA[Harish kumar]]></dc:creator><pubDate>Mon, 23 Jul 2018 13:46:58 GMT</pubDate></item><item><title><![CDATA[Reply to How to extract Device Address from Payload ? on Mon, 23 Jul 2018 14:52:58 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.pycom.io/uid/2889">@harish-kumar</a> As far as I understand the LoRa Spec, the Dev address is contained in the first four bytes of the payload. You may extract it from there and use it for comparison. Depending on how your reference list is formatted, you may have to convert it, eg. with ubinascii.bin2hex().</p>
]]></description><link>https://forum.pycom.io/post/21058</link><guid isPermaLink="true">https://forum.pycom.io/post/21058</guid><dc:creator><![CDATA[robert-hh]]></dc:creator><pubDate>Mon, 23 Jul 2018 14:52:58 GMT</pubDate></item><item><title><![CDATA[Reply to How to extract Device Address from Payload ? on Mon, 23 Jul 2018 15:10:01 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.pycom.io/uid/98">@robert-hh</a> you mean like once I get the data, I have to convert it and I have to compare ?<br />
Is ubinascii.bin2hex() for extracting from payload ?If not, what is the command for extracting ?</p>
]]></description><link>https://forum.pycom.io/post/21060</link><guid isPermaLink="true">https://forum.pycom.io/post/21060</guid><dc:creator><![CDATA[Harish kumar]]></dc:creator><pubDate>Mon, 23 Jul 2018 15:10:01 GMT</pubDate></item><item><title><![CDATA[Reply to How to extract Device Address from Payload ? on Mon, 23 Jul 2018 15:36:40 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.pycom.io/uid/2889">@harish-kumar</a> it should be hexlify(). I just try to verify my post.</p>
]]></description><link>https://forum.pycom.io/post/21062</link><guid isPermaLink="true">https://forum.pycom.io/post/21062</guid><dc:creator><![CDATA[robert-hh]]></dc:creator><pubDate>Mon, 23 Jul 2018 15:36:40 GMT</pubDate></item><item><title><![CDATA[Reply to How to extract Device Address from Payload ? on Mon, 23 Jul 2018 15:44:26 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.pycom.io/uid/2889">@harish-kumar</a> Actually it is the second to fifth byte in big endian format. So if you receive data from the socket, e.g.:</p>
<pre><code>rx_data = lora_sock.recv(256)
dev_addr = rx_data[1:5]
print(&quot;Dev-Addr: &quot;,  ubinascii.hexlify(dev_addr))
</code></pre>
]]></description><link>https://forum.pycom.io/post/21064</link><guid isPermaLink="true">https://forum.pycom.io/post/21064</guid><dc:creator><![CDATA[robert-hh]]></dc:creator><pubDate>Mon, 23 Jul 2018 15:44:26 GMT</pubDate></item><item><title><![CDATA[Reply to How to extract Device Address from Payload ? on Mon, 23 Jul 2018 16:17:20 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.pycom.io/uid/98">@robert-hh</a> Thank you so much ! I got the output.</p>
]]></description><link>https://forum.pycom.io/post/21067</link><guid isPermaLink="true">https://forum.pycom.io/post/21067</guid><dc:creator><![CDATA[Harish kumar]]></dc:creator><pubDate>Mon, 23 Jul 2018 16:17:20 GMT</pubDate></item></channel></rss>