How to read TX2 module's Serial Number in Code?

Hi, everyone. I want to know how to read TX2 module’s Serial Number in my program for secure use. Anyone can help?


Please try to use this unique id.

cat /proc/cmdline


This one should also give you some info about your board.

ls /proc/device-tree/chosen/plugin-manager/ids

Ok,I will try these methods, thank you very much!

Can this be read from a register directly?

Can the device still use if someone manually changes this information?

When I got S/N by above, S/N on label outside module and S/N by getting above command is different No.
Ex ) Command SN = androidboot.serialno= 0335115020673
Label SN = 03208171360034

Whan I use for Device authentication to connect web service, which one should we use?


We used this command to get unique information and use as a check in a program.

cat /proc/cmdline

which will return something like androidboot.serialno=1234567890987
This is unique ID we verified using different devices.

Sorry for late reply.

For this issue, please add below patch in kernel-dts.

diff --git a/kernel-dts/tegra210-porg-p3448-common.dtsi b/kernel-dts/tegra210-porg-p3448-common.dtsi
index 8332dab..a73561e 100644
--- a/kernel-dts/tegra210-porg-p3448-common.dtsi
+++ b/kernel-dts/tegra210-porg-p3448-common.dtsi
@@ -58,6 +58,7 @@
 		stdout-path = "/serial@70006000";
+		no-tnid-sn;
 		bootargs = "kmemleak=on earlycon=uart8250,mmio32,0x70006000";