Skip to content

Instantly share code, notes, and snippets.

@adujardin
Last active February 13, 2018 15:21
Show Gist options
  • Save adujardin/6e36288682044ab6c931eb04a01bf07f to your computer and use it in GitHub Desktop.
Save adujardin/6e36288682044ab6c931eb04a01bf07f to your computer and use it in GitHub Desktop.
NVIDIA Tegra version detection
#!/bin/bash
tegra_detection=$(
case "$(cat /sys/module/tegra_fuse/parameters/tegra_chip_id)" in
("64") echo "tegra_k1" ;;
("33") echo "tegra_x1" ;;
("24") echo "tegra_x2" ;;
(*) echo "unknown" ;;
esac)
echo "${tegra_detection}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment