diff options
author | Jesse Gilles <jgilles@multitech.com> | 2014-02-28 15:51:45 -0600 |
---|---|---|
committer | Jesse Gilles <jgilles@multitech.com> | 2014-02-28 15:51:45 -0600 |
commit | 2a16dee518f648cae31111bfe6968daa61065544 (patch) | |
tree | ebf8d144f1aaeff1c3eff90f02aee5252c4e296a /multitech/recipes/multitech/mts-io/mtocgd/mts-io.init | |
parent | 89ce252315659d308e76155fd15fb93d6238a498 (diff) |
mts-io: power on radio on boot for mtocgd, add comments to radio-reset-h5
Diffstat (limited to 'multitech/recipes/multitech/mts-io/mtocgd/mts-io.init')
-rw-r--r-- | multitech/recipes/multitech/mts-io/mtocgd/mts-io.init | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/multitech/recipes/multitech/mts-io/mtocgd/mts-io.init b/multitech/recipes/multitech/mts-io/mtocgd/mts-io.init new file mode 100644 index 0000000..fe6c517 --- /dev/null +++ b/multitech/recipes/multitech/mts-io/mtocgd/mts-io.init @@ -0,0 +1,26 @@ +#!/bin/sh + +case $1 in + start) + echo "Loading mts-io module" + modprobe mts_io + radio_power=`mts-io-sysfs show radio-power` + # power on cellular radio if needed + if [ "$radio_power" = "0" ]; then + echo "Powering on radio" + mts-io-sysfs store radio-power 1 & + fi + ;; + + stop) + echo "Unloading mts-io module" + modprobe -r mts_io + ;; + + *) + echo "Usage: $0 {start|stop}" + exit 2 + ;; +esac + + |