8 lines
200 B
Bash
8 lines
200 B
Bash
|
#!/bin/bash
|
||
|
|
||
|
# https://gist.github.com/ribasco/c22ab6b791e681800df47dd0a46c7c3a
|
||
|
|
||
|
var="$(xxd -ps /sys/class/i2c-adapter/i2c-1/of_node/clock-frequency)"
|
||
|
var=${var//[[:blank:].\}]/}
|
||
|
printf "%d\n" 0x$var
|