Guest User

Untitled

a guest
Jun 1st, 2015
549
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 41.42 KB | None | 0 0
  1. # fw_type will always be developer for Mario.
  2. # Alex and ZGB need the developer BIOS installed though.
  3. fw_type="`crossystem mainfw_type`"
  4. if [ ! "$fw_type" = "developer" ]
  5. then
  6. echo -e "\nYou're Chromebook is not running a developer BIOS!"
  7. echo -e "You need to run:"
  8. echo -e ""
  9. echo -e "sudo chromeos-firmwareupdate --mode=todev"
  10. echo -e ""
  11. echo -e "and then re-run this script."
  12. return
  13. else
  14. echo -e "\nOh good. You're running a developer BIOS...\n"
  15. fi
  16.  
  17. # hwid lets us know if this is a Mario (Cr-48), Alex (Samsung Series 5), ZGB (Acer), etc
  18. hwid="`crossystem hwid`"
  19.  
  20. echo -e "Chome OS model is: $hwid\n"
  21.  
  22. chromebook_arch="`uname -m`"
  23. if [ ! "$chromebook_arch" = "x86_64" ]
  24. then
  25. echo -e "This version of Chrome OS isn't 64-bit. We'll use an unofficial Chromium OS kernel to get around this...\n"
  26. else
  27. echo -e "and you're running a 64-bit version of Chrome OS! That's just dandy!\n"
  28. fi
  29.  
  30. read -p "Press [Enter] to continue..."
  31.  
  32. powerd_status="`initctl status powerd`"
  33. if [ ! "$powerd_status" = "powerd stop/waiting" ]
  34. then
  35. echo -e "Stopping powerd to keep display from timing out..."
  36. initctl stop powerd
  37. fi
  38.  
  39. powerm_status="`initctl status powerm`"
  40. if [ ! "$powerm_status" = "powerm stop/waiting" ]
  41. then
  42. echo -e "Stopping powerm to keep display from timing out..."
  43. initctl stop powerm
  44. fi
  45.  
  46. setterm -blank 0
  47.  
  48. if [ "$1" != "" ]; then
  49. target_disk=$1
  50. echo "Got ${target_disk} as target drive"
  51. echo ""
  52. echo "WARNING! All data on this device will be wiped out! Continue at your own risk!"
  53. echo ""
  54. read -p "Press [Enter] to install ChrUbuntu on ${target_disk} or CTRL+C to quit"
  55.  
  56. ext_size="`blockdev --getsz ${target_disk}`"
  57. aroot_size=$((ext_size - 65600 - 33))
  58. parted --script ${target_disk} "mktable gpt"
  59. cgpt create ${target_disk}
  60. cgpt add -i 6 -b 64 -s 32768 -S 1 -P 5 -l KERN-A -t "kernel" ${target_disk}
  61. cgpt add -i 7 -b 65600 -s $aroot_size -l ROOT-A -t "rootfs" ${target_disk}
  62. sync
  63. blockdev --rereadpt ${target_disk}
  64. partprobe ${target_disk}
  65. crossystem dev_boot_usb=1
  66. else
  67. target_disk="`rootdev -d -s`"
  68. # Do partitioning (if we haven't already)
  69. ckern_size="`cgpt show -i 6 -n -s -q ${target_disk}`"
  70. croot_size="`cgpt show -i 7 -n -s -q ${target_disk}`"
  71. state_size="`cgpt show -i 1 -n -s -q ${target_disk}`"
  72.  
  73. max_ubuntu_size=$(($state_size/1024/1024/2))
  74. rec_ubuntu_size=$(($max_ubuntu_size - 1))
  75. # If KERN-C and ROOT-C are one, we partition, otherwise assume they're what they need to be...
  76. if [ "$ckern_size" = "1" -o "$croot_size" = "1" ]
  77. then
  78. while :
  79. do
  80. read -p "Enter the size in gigabytes you want to reserve for Ubuntu. Acceptable range is 5 to $max_ubuntu_size but $rec_ubuntu_size is the recommended maximum: " ubuntu_size
  81. if [ ! $ubuntu_size -ne 0 2>/dev/null ]
  82. then
  83. echo -e "\n\nNumbers only please...\n\n"
  84. continue
  85. fi
  86. if [ $ubuntu_size -lt 5 -o $ubuntu_size -gt $max_ubuntu_size ]
  87. then
  88. echo -e "\n\nThat number is out of range. Enter a number 5 through $max_ubuntu_size\n\n"
  89. continue
  90. fi
  91. break
  92. done
  93. # We've got our size in GB for ROOT-C so do the math...
  94.  
  95. #calculate sector size for rootc
  96. rootc_size=$(($ubuntu_size*1024*1024*2))
  97.  
  98. #kernc is always 16mb
  99. kernc_size=32768
  100.  
  101. #new stateful size with rootc and kernc subtracted from original
  102. stateful_size=$(($state_size - $rootc_size - $kernc_size))
  103.  
  104. #start stateful at the same spot it currently starts at
  105. stateful_start="`cgpt show -i 1 -n -b -q ${target_disk}`"
  106.  
  107. #start kernc at stateful start plus stateful size
  108. kernc_start=$(($stateful_start + $stateful_size))
  109.  
  110. #start rootc at kernc start plus kernc size
  111. rootc_start=$(($kernc_start + $kernc_size))
  112.  
  113. #Do the real work
  114.  
  115. echo -e "\n\nModifying partition table to make room for Ubuntu."
  116. echo -e "Your Chromebook will reboot, wipe your data and then"
  117. echo -e "you should re-run this script..."
  118. umount /mnt/stateful_partition
  119.  
  120. # stateful first
  121. cgpt add -i 1 -b $stateful_start -s $stateful_size -l STATE ${target_disk}
  122.  
  123. # now kernc
  124. cgpt add -i 6 -b $kernc_start -s $kernc_size -l KERN-C ${target_disk}
  125.  
  126. # finally rootc
  127. cgpt add -i 7 -b $rootc_start -s $rootc_size -l ROOT-C ${target_disk}
  128.  
  129. reboot
  130. exit
  131. fi
  132. fi
  133.  
  134. if [ ! -d /mnt/stateful_partition/ubuntu ]
  135. then
  136. mkdir /mnt/stateful_partition/ubuntu
  137. fi
  138.  
  139. cd /mnt/stateful_partition/ubuntu
  140.  
  141. # try mounting a USB / SD Card if it's there...
  142. if [ ! -d /tmp/usb_files ]
  143. then
  144. mkdir /tmp/usb_files
  145. fi
  146. mount /dev/sdb /tmp/usb_files > /dev/null 2>&1
  147. mount /dev/sdb1 /tmp/usb_files > /dev/null 2>&1
  148.  
  149. # Copy /tmp/usb_files/ubuntu (.sha1 and foo.6 files) to SSD if they're there
  150. if [ -d /tmp/usb_files/ubuntu ]
  151. then
  152. cp -rf /tmp/usb_files/ubuntu/* /mnt/stateful_partition/ubuntu/
  153. fi
  154.  
  155. if [[ "${target_disk}" =~ "mmcblk" ]]
  156. then
  157. target_rootfs="${target_disk}p7"
  158. target_kern="${target_disk}p6"
  159. else
  160. target_rootfs="${target_disk}7"
  161. target_kern="${target_disk}6"
  162. fi
  163.  
  164. echo "Target Kernel Partition: $target_kern Target Root FS: ${target_rootfs}"
  165.  
  166. # hwid lets us know if this is a Mario (Cr-48), Alex (Samsung Series 5), ZGB (Acer), etc
  167. hwid="`crossystem hwid`"
  168.  
  169. chromebook_arch="`uname -m`"
  170.  
  171. ubuntu_metapackage=${1:-default}
  172.  
  173. if [ "$chromebook_arch" = "x86_64" ]
  174. then
  175. ubuntu_arch="amd64"
  176. if [ "$ubuntu_metapackage" = "default" ]
  177. then
  178. ubuntu_metapackage="ubuntu-desktop"
  179. fi
  180. elif [ "$chromebook_arch" = "i686" ]
  181. then
  182. ubuntu_arch="i386"
  183. if [ "$ubuntu_metapackage" = "default" ]
  184. then
  185. ubuntu_metapackage="ubuntu-desktop"
  186. fi
  187. elif [ "$chromebook_arch" = "armv7l" ]
  188. then
  189. ubuntu_arch="armhf"
  190. if [ "$ubuntu_metapackage" = "default" ]
  191. then
  192. ubuntu_metapackage="xubuntu-desktop"
  193. fi
  194. else
  195. echo -e "Error: This script doesn't know how to install ChrUbuntu on $chromebook_arch"
  196. exit
  197. fi
  198.  
  199. echo -e "\nChrome device model is: $hwid\n"
  200.  
  201. echo -e "Installing Ubuntu ${ubuntu_version} with metapackage ${ubuntu_metapackage}\n"
  202.  
  203. echo -e "Kernel Arch is: $chromebook_arch Installing Ubuntu Arch: $ubuntu_arch\n"
  204.  
  205. read -p "Press [Enter] to continue..."
  206.  
  207. if [ ! -d /mnt/stateful_partition/ubuntu ]
  208. then
  209. mkdir /mnt/stateful_partition/ubuntu
  210. fi
  211.  
  212. cd /mnt/stateful_partition/ubuntu
  213.  
  214. if [[ "${target_disk}" =~ "mmcblk" ]]
  215. then
  216. target_rootfs="${target_disk}p7"
  217. target_kern="${target_disk}p6"
  218. else
  219. target_rootfs="${target_disk}7"
  220. target_kern="${target_disk}6"
  221. fi
  222.  
  223. echo "Target Kernel Partition: $target_kern Target Root FS: ${target_rootfs}"
  224.  
  225. if mount|grep ${target_rootfs}
  226. then
  227. echo "Refusing to continue since ${target_rootfs} is formatted and mounted. Try rebooting"
  228. exit
  229. fi
  230.  
  231. mkfs.ext4 ${target_rootfs}
  232.  
  233. if [ ! -d /tmp/urfs ]
  234. then
  235. mkdir /tmp/urfs
  236. fi
  237. mount -t ext4 ${target_rootfs} /tmp/urfs
  238.  
  239. tar_file="http://cdimage.ubuntu.com/ubuntu-core/releases/trusty/release/ubuntu-core-14.04.2-core-armhf.tar.gz"
  240. if [ $ubuntu_version = "dev" ]
  241. then
  242. ubuntu_animal=`wget --quiet -O - http://changelogs.ubuntu.com/meta-release-development | grep "^Dist: " | tail -1 | sed -r 's/^Dist: (.*)$/\1/'`
  243. tar_file="http://cdimage.ubuntu.com/ubuntu-core/daily/current/$ubuntu_animal-core-$ubuntu_arch.tar.gz"
  244. fi
  245. wget -O - $tar_file | tar xzvvp -C /tmp/urfs/
  246.  
  247. mount -o bind /proc /tmp/urfs/proc
  248. mount -o bind /dev /tmp/urfs/dev
  249. mount -o bind /dev/pts /tmp/urfs/dev/pts
  250. mount -o bind /sys /tmp/urfs/sys
  251.  
  252. if [ -f /usr/bin/old_bins/cgpt ]
  253. then
  254. cp /usr/bin/old_bins/cgpt /tmp/urfs/usr/bin/
  255. else
  256. cp /usr/bin/cgpt /tmp/urfs/usr/bin/
  257. fi
  258.  
  259. chmod a+rx /tmp/urfs/usr/bin/cgpt
  260. if [ ! -d /tmp/urfs/run/resolvconf/ ]
  261. then
  262. mkdir /tmp/urfs/run/resolvconf/
  263. fi
  264. cp /etc/resolv.conf /tmp/urfs/run/resolvconf/
  265. ln -s -f /run/resolvconf/resolv.conf /tmp/urfs/etc/resolv.conf
  266. echo chrubuntu > /tmp/urfs/etc/hostname
  267. #echo -e "127.0.0.1 localhost
  268. echo -e "\n127.0.1.1 chrubuntu" >> /tmp/urfs/etc/hosts
  269. # The following lines are desirable for IPv6 capable hosts
  270. #::1 localhost ip6-localhost ip6-loopback
  271. #fe00::0 ip6-localnet
  272. #ff00::0 ip6-mcastprefix
  273. #ff02::1 ip6-allnodes
  274. #ff02::2 ip6-allrouters" > /tmp/urfs/etc/hosts
  275.  
  276. cr_install="wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
  277. add-apt-repository \"deb http://dl.google.com/linux/chrome/deb/ stable main\"
  278. apt-get update
  279. apt-get -y install google-chrome-stable"
  280. if [ $ubuntu_arch = 'armhf' ]
  281. then
  282. cr_install='apt-get -y install chromium-browser'
  283. fi
  284.  
  285. add_apt_repository_package='software-properties-common'
  286. ubuntu_major_version=${ubuntu_version:0:2}
  287. ubuntu_minor_version=${ubuntu_version:3:2}
  288. if [ $ubuntu_major_version -le 12 ] && [ $ubuntu_minor_version -lt 10 ]
  289. then
  290. add_apt_repository_package='python-software-properties'
  291. fi
  292.  
  293. echo -e "apt-get -y update
  294. apt-get -y dist-upgrade
  295. apt-get -y install ubuntu-minimal
  296. apt-get -y install wget
  297. apt-get -y install $add_apt_repository_package
  298. add-apt-repository main
  299. add-apt-repository universe
  300. add-apt-repository restricted
  301. add-apt-repository multiverse
  302. apt-get update
  303. apt-get -y install $ubuntu_metapackage
  304. $cr_install
  305. if [ -f /usr/lib/lightdm/lightdm-set-defaults ]
  306. then
  307. /usr/lib/lightdm/lightdm-set-defaults --autologin user
  308. fi
  309. useradd -m user -s /bin/bash
  310. echo user | echo user:user | chpasswd
  311. adduser user adm
  312. adduser user sudo
  313. update-alternatives --set x-www-browser /usr/bin/chromium-browser
  314. locale-gen en_US en_US.UTF-8
  315. echo -e 'LANG=en_US.UTF-8\nLC_ALL=en_US.UTF-8' > /etc/default/locale
  316. LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8 dpkg-reconfigure locales" > /tmp/urfs/install-ubuntu.sh
  317.  
  318. chmod a+x /tmp/urfs/install-ubuntu.sh
  319. chroot /tmp/urfs /bin/bash -c /install-ubuntu.sh
  320. rm /tmp/urfs/install-ubuntu.sh
  321.  
  322. KERN_VER=`uname -r`
  323. mkdir -p /tmp/urfs/lib/modules/$KERN_VER/
  324. cp -ar /lib/modules/$KERN_VER/* /tmp/urfs/lib/modules/$KERN_VER/
  325. if [ ! -d /tmp/urfs/lib/firmware/ ]
  326. then
  327. mkdir /tmp/urfs/lib/firmware/
  328. fi
  329. cp -ar /lib/firmware/* /tmp/urfs/lib/firmware/
  330.  
  331.  
  332. # copy adobe flash player plugin
  333. cp /opt/google/chrome/pepper/libpepflashplayer.so /tmp/urfs/usr/lib/chromium-browser
  334.  
  335. # tell chromium-browser where to find flash plugin
  336. echo -e 'CHROMIUM_FLAGS="${CHROMIUM_FLAGS} --ppapi-flash-path=/usr/lib/chromium-browser/libpepflashplayer.so"' >> /tmp/urfs/etc/chromium-browser/default
  337.  
  338. # flash plugin requires a new version of libstdc++6 from test repository
  339. cat > /tmp/urfs/install-flash.sh <<EOF
  340. add-apt-repository -y ppa:ubuntu-toolchain-r/test
  341. apt-get update
  342. apt-get install -y libstdc++6
  343. EOF
  344.  
  345. chmod a+x /tmp/urfs/install-flash.sh
  346. chroot /tmp/urfs /bin/bash -c /install-flash.sh
  347. rm /tmp/urfs/install-flash.sh
  348.  
  349.  
  350. # BIG specific files here
  351. cp /etc/X11/xorg.conf.d/tegra.conf /tmp/urfs/usr/share/X11/xorg.conf.d/
  352. l4tdir=`mktemp -d`
  353. l4t=Tegra124_Linux_R21.2.0_armhf.tbz2
  354. wget -P ${l4tdir} http://developer.download.nvidia.com/mobile/tegra/l4t/r21.2.0/pm375_release_armhf/Tegra124_Linux_R21.2.0_armhf.tbz2
  355. cd ${l4tdir}
  356. tar xvpf ${l4t}
  357. cd Linux_for_Tegra/rootfs/
  358. tar xvpf ../nv_tegra/nvidia_drivers.tbz2
  359. tar cf - usr/lib | ( cd /tmp/urfs ; tar xvf -)
  360.  
  361. # cuda symlinks
  362. ln -s libcuda.so.1 /tmp/urfs/usr/lib/arm-linux-gnueabihf/libcuda.so
  363. ln -s tegra/libcuda.so.1 /tmp/urfs/usr/lib/arm-linux-gnueabihf/libcuda.so.1
  364. ln -s tegra/libcuda.so.1.1 /tmp/urfs/usr/lib/arm-linux-gnueabihf/libcuda.so.1.1
  365.  
  366. echo "/usr/lib/arm-linux-gnueabihf/tegra" > /tmp/urfs/etc/ld.so.conf.d/nvidia-tegra.conf
  367. echo "/usr/lib/arm-linux-gnueabihf/tegra-egl" > /tmp/urfs/usr/lib/arm-linux-gnueabihf/tegra-egl/ld.so.conf
  368. echo "/usr/lib/arm-linux-gnueabihf/tegra" > /tmp/urfs/usr/lib/arm-linux-gnueabihf/tegra/ld.so.conf
  369.  
  370. cat >/tmp/urfs/etc/udev/rules.d/99-tegra-lid-switch.rules <<EOF
  371. ACTION=="remove", GOTO="tegra_lid_switch_end"
  372.  
  373. SUBSYSTEM=="input", KERNEL=="event*", SUBSYSTEMS=="platform", KERNELS=="gpio-keys.4", TAG+="power-switch"
  374.  
  375. LABEL="tegra_lid_switch_end"
  376. EOF
  377.  
  378. # nvidia device node permissions
  379. cat > /tmp/urfs/lib/udev/rules.d/51-nvrm.rules <<EOF
  380. KERNEL=="knvmap", GROUP="video", MODE="0660"
  381. KERNEL=="nvhdcp1", GROUP="video", MODE="0660"
  382. KERNEL=="nvhost-as-gpu", GROUP="video", MODE="0660"
  383. KERNEL=="nvhost-ctrl", GROUP="video", MODE="0660"
  384. KERNEL=="nvhost-ctrl-gpu", GROUP="video", MODE="0660"
  385. KERNEL=="nvhost-dbg-gpu", GROUP="video", MODE="0660"
  386. KERNEL=="nvhost-gpu", GROUP="video", MODE="0660"
  387. KERNEL=="nvhost-msenc", GROUP="video", MODE=0660"
  388. KERNEL=="nvhost-prof-gpu", GROUP="video", MODE=0660"
  389. KERNEL=="nvhost-tsec", GROUP="video", MODE="0660"
  390. KERNEL=="nvhost-vic", GROUP="video", MODE="0660"
  391. KERNEL=="nvmap", GROUP="video", MODE="0660"
  392. KERNEL=="tegra_dc_0", GROUP="video", MODE="0660"
  393. KERNEL=="tegra_dc_1", GROUP="video", MODE="0660"
  394. KERNEL=="tegra_dc_ctrl", GROUP="video", MODE="0660"
  395. EOF
  396.  
  397. # alsa mixer settings to enable internal speakers
  398. cat > /tmp/urfs/var/lib/alsa/asound.state <<EOF
  399. state.HDATegra {
  400. control.1 {
  401. iface CARD
  402. name 'HDMI/DP,pcm=3 Jack'
  403. value false
  404. comment {
  405. access read
  406. type BOOLEAN
  407. count 1
  408. }
  409. }
  410. control.2 {
  411. iface MIXER
  412. name 'IEC958 Playback Con Mask'
  413. value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
  414. comment {
  415. access read
  416. type IEC958
  417. count 1
  418. }
  419. }
  420. control.3 {
  421. iface MIXER
  422. name 'IEC958 Playback Pro Mask'
  423. value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
  424. comment {
  425. access read
  426. type IEC958
  427. count 1
  428. }
  429. }
  430. control.4 {
  431. iface MIXER
  432. name 'IEC958 Playback Default'
  433. value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
  434. comment {
  435. access 'read write'
  436. type IEC958
  437. count 1
  438. }
  439. }
  440. control.5 {
  441. iface MIXER
  442. name 'IEC958 Playback Switch'
  443. value false
  444. comment {
  445. access 'read write'
  446. type BOOLEAN
  447. count 1
  448. }
  449. }
  450. control.6 {
  451. iface PCM
  452. device 3
  453. name ELD
  454. value ''
  455. comment {
  456. access 'read volatile'
  457. type BYTES
  458. count 0
  459. }
  460. }
  461. control.7 {
  462. iface PCM
  463. device 3
  464. name 'Playback Channel Map'
  465. value.0 0
  466. value.1 0
  467. value.2 0
  468. value.3 0
  469. value.4 0
  470. value.5 0
  471. value.6 0
  472. value.7 0
  473. comment {
  474. access 'read write'
  475. type INTEGER
  476. count 8
  477. range '0 - 36'
  478. }
  479. }
  480. }
  481. state.Venice2 {
  482. control.1 {
  483. iface MIXER
  484. name 'MIC Bias VCM Bandgap'
  485. value 'High Performance'
  486. comment {
  487. access 'read write'
  488. type ENUMERATED
  489. count 1
  490. item.0 'Low Power'
  491. item.1 'High Performance'
  492. }
  493. }
  494. control.2 {
  495. iface MIXER
  496. name 'DMIC MIC Comp Filter Config'
  497. value 6
  498. comment {
  499. access 'read write'
  500. type INTEGER
  501. count 1
  502. range '0 - 15'
  503. }
  504. }
  505. control.3 {
  506. iface MIXER
  507. name 'MIC1 Boost Volume'
  508. value 0
  509. comment {
  510. access 'read write'
  511. type INTEGER
  512. count 1
  513. range '0 - 2'
  514. dbmin 0
  515. dbmax 3000
  516. dbvalue.0 0
  517. }
  518. }
  519. control.4 {
  520. iface MIXER
  521. name 'MIC2 Boost Volume'
  522. value 0
  523. comment {
  524. access 'read write'
  525. type INTEGER
  526. count 1
  527. range '0 - 2'
  528. dbmin 0
  529. dbmax 3000
  530. dbvalue.0 0
  531. }
  532. }
  533. control.5 {
  534. iface MIXER
  535. name 'MIC1 Volume'
  536. value 0
  537. comment {
  538. access 'read write'
  539. type INTEGER
  540. count 1
  541. range '0 - 20'
  542. dbmin 0
  543. dbmax 2000
  544. dbvalue.0 0
  545. }
  546. }
  547. control.6 {
  548. iface MIXER
  549. name 'MIC2 Volume'
  550. value 0
  551. comment {
  552. access 'read write'
  553. type INTEGER
  554. count 1
  555. range '0 - 20'
  556. dbmin 0
  557. dbmax 2000
  558. dbvalue.0 0
  559. }
  560. }
  561. control.7 {
  562. iface MIXER
  563. name 'LINEA Single Ended Volume'
  564. value 1
  565. comment {
  566. access 'read write'
  567. type INTEGER
  568. count 1
  569. range '0 - 1'
  570. dbmin -600
  571. dbmax 0
  572. dbvalue.0 0
  573. }
  574. }
  575. control.8 {
  576. iface MIXER
  577. name 'LINEB Single Ended Volume'
  578. value 1
  579. comment {
  580. access 'read write'
  581. type INTEGER
  582. count 1
  583. range '0 - 1'
  584. dbmin -600
  585. dbmax 0
  586. dbvalue.0 0
  587. }
  588. }
  589. control.9 {
  590. iface MIXER
  591. name 'LINEA Volume'
  592. value 2
  593. comment {
  594. access 'read write'
  595. type INTEGER
  596. count 1
  597. range '0 - 5'
  598. dbmin -600
  599. dbmax 2000
  600. dbvalue.0 0
  601. }
  602. }
  603. control.10 {
  604. iface MIXER
  605. name 'LINEB Volume'
  606. value 2
  607. comment {
  608. access 'read write'
  609. type INTEGER
  610. count 1
  611. range '0 - 5'
  612. dbmin -600
  613. dbmax 2000
  614. dbvalue.0 0
  615. }
  616. }
  617. control.11 {
  618. iface MIXER
  619. name 'LINEA Ext Resistor Gain Mode'
  620. value false
  621. comment {
  622. access 'read write'
  623. type BOOLEAN
  624. count 1
  625. }
  626. }
  627. control.12 {
  628. iface MIXER
  629. name 'LINEB Ext Resistor Gain Mode'
  630. value false
  631. comment {
  632. access 'read write'
  633. type BOOLEAN
  634. count 1
  635. }
  636. }
  637. control.13 {
  638. iface MIXER
  639. name 'ADCL Boost Volume'
  640. value 0
  641. comment {
  642. access 'read write'
  643. type INTEGER
  644. count 1
  645. range '0 - 7'
  646. dbmin 0
  647. dbmax 4200
  648. dbvalue.0 0
  649. }
  650. }
  651. control.14 {
  652. iface MIXER
  653. name 'ADCR Boost Volume'
  654. value 0
  655. comment {
  656. access 'read write'
  657. type INTEGER
  658. count 1
  659. range '0 - 7'
  660. dbmin 0
  661. dbmax 4200
  662. dbvalue.0 0
  663. }
  664. }
  665. control.15 {
  666. iface MIXER
  667. name 'ADCL Volume'
  668. value 12
  669. comment {
  670. access 'read write'
  671. type INTEGER
  672. count 1
  673. range '0 - 15'
  674. dbmin -1200
  675. dbmax 300
  676. dbvalue.0 0
  677. }
  678. }
  679. control.16 {
  680. iface MIXER
  681. name 'ADCR Volume'
  682. value 12
  683. comment {
  684. access 'read write'
  685. type INTEGER
  686. count 1
  687. range '0 - 15'
  688. dbmin -1200
  689. dbmax 300
  690. dbvalue.0 0
  691. }
  692. }
  693. control.17 {
  694. iface MIXER
  695. name 'ADC Oversampling Rate'
  696. value '128*fs'
  697. comment {
  698. access 'read write'
  699. type ENUMERATED
  700. count 1
  701. item.0 '64*fs'
  702. item.1 '128*fs'
  703. }
  704. }
  705. control.18 {
  706. iface MIXER
  707. name 'ADC Quantizer Dither'
  708. value true
  709. comment {
  710. access 'read write'
  711. type BOOLEAN
  712. count 1
  713. }
  714. }
  715. control.19 {
  716. iface MIXER
  717. name 'ADC High Performance Mode'
  718. value 'High Performance'
  719. comment {
  720. access 'read write'
  721. type ENUMERATED
  722. count 1
  723. item.0 'Low Power'
  724. item.1 'High Performance'
  725. }
  726. }
  727. control.20 {
  728. iface MIXER
  729. name 'DAC Mono Mode'
  730. value false
  731. comment {
  732. access 'read write'
  733. type BOOLEAN
  734. count 1
  735. }
  736. }
  737. control.21 {
  738. iface MIXER
  739. name 'SDIN Mode'
  740. value false
  741. comment {
  742. access 'read write'
  743. type BOOLEAN
  744. count 1
  745. }
  746. }
  747. control.22 {
  748. iface MIXER
  749. name 'SDOUT Mode'
  750. value false
  751. comment {
  752. access 'read write'
  753. type BOOLEAN
  754. count 1
  755. }
  756. }
  757. control.23 {
  758. iface MIXER
  759. name 'SDOUT Hi-Z Mode'
  760. value true
  761. comment {
  762. access 'read write'
  763. type BOOLEAN
  764. count 1
  765. }
  766. }
  767. control.24 {
  768. iface MIXER
  769. name 'Filter Mode'
  770. value Music
  771. comment {
  772. access 'read write'
  773. type ENUMERATED
  774. count 1
  775. item.0 Voice
  776. item.1 Music
  777. }
  778. }
  779. control.25 {
  780. iface MIXER
  781. name 'Record Path DC Blocking'
  782. value false
  783. comment {
  784. access 'read write'
  785. type BOOLEAN
  786. count 1
  787. }
  788. }
  789. control.26 {
  790. iface MIXER
  791. name 'Playback Path DC Blocking'
  792. value false
  793. comment {
  794. access 'read write'
  795. type BOOLEAN
  796. count 1
  797. }
  798. }
  799. control.27 {
  800. iface MIXER
  801. name 'Digital BQ Volume'
  802. value 15
  803. comment {
  804. access 'read write'
  805. type INTEGER
  806. count 1
  807. range '0 - 15'
  808. dbmin -1500
  809. dbmax 0
  810. dbvalue.0 0
  811. }
  812. }
  813. control.28 {
  814. iface MIXER
  815. name 'Digital Sidetone Volume'
  816. value 0
  817. comment {
  818. access 'read write'
  819. type INTEGER
  820. count 1
  821. range '0 - 30'
  822. dbmin 0
  823. dbmax 3000
  824. dbvalue.0 0
  825. }
  826. }
  827. control.29 {
  828. iface MIXER
  829. name 'Digital Coarse Volume'
  830. value 0
  831. comment {
  832. access 'read write'
  833. type INTEGER
  834. count 1
  835. range '0 - 3'
  836. dbmin 0
  837. dbmax 1800
  838. dbvalue.0 0
  839. }
  840. }
  841. control.30 {
  842. iface MIXER
  843. name 'Digital Volume'
  844. value 15
  845. comment {
  846. access 'read write'
  847. type INTEGER
  848. count 1
  849. range '0 - 15'
  850. dbmin -1500
  851. dbmax 0
  852. dbvalue.0 0
  853. }
  854. }
  855. control.31 {
  856. iface MIXER
  857. name 'EQ Coefficients'
  858. value '000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
  859. comment {
  860. access 'read write'
  861. type BYTES
  862. count 105
  863. }
  864. }
  865. control.32 {
  866. iface MIXER
  867. name 'Digital EQ 3 Band Switch'
  868. value false
  869. comment {
  870. access 'read write'
  871. type BOOLEAN
  872. count 1
  873. }
  874. }
  875. control.33 {
  876. iface MIXER
  877. name 'Digital EQ 5 Band Switch'
  878. value false
  879. comment {
  880. access 'read write'
  881. type BOOLEAN
  882. count 1
  883. }
  884. }
  885. control.34 {
  886. iface MIXER
  887. name 'Digital EQ 7 Band Switch'
  888. value false
  889. comment {
  890. access 'read write'
  891. type BOOLEAN
  892. count 1
  893. }
  894. }
  895. control.35 {
  896. iface MIXER
  897. name 'Digital EQ Clipping Detection'
  898. value true
  899. comment {
  900. access 'read write'
  901. type BOOLEAN
  902. count 1
  903. }
  904. }
  905. control.36 {
  906. iface MIXER
  907. name 'Digital EQ Volume'
  908. value 15
  909. comment {
  910. access 'read write'
  911. type INTEGER
  912. count 1
  913. range '0 - 15'
  914. dbmin -1500
  915. dbmax 0
  916. dbvalue.0 0
  917. }
  918. }
  919. control.37 {
  920. iface MIXER
  921. name 'ALC Enable'
  922. value false
  923. comment {
  924. access 'read write'
  925. type BOOLEAN
  926. count 1
  927. }
  928. }
  929. control.38 {
  930. iface MIXER
  931. name 'ALC Attack Time'
  932. value '0.5ms'
  933. comment {
  934. access 'read write'
  935. type ENUMERATED
  936. count 1
  937. item.0 '0.5ms'
  938. item.1 '1ms'
  939. item.2 '5ms'
  940. item.3 '10ms'
  941. item.4 '25ms'
  942. item.5 '50ms'
  943. item.6 '100ms'
  944. item.7 '200ms'
  945. }
  946. }
  947. control.39 {
  948. iface MIXER
  949. name 'ALC Release Time'
  950. value '8s'
  951. comment {
  952. access 'read write'
  953. type ENUMERATED
  954. count 1
  955. item.0 '8s'
  956. item.1 '4s'
  957. item.2 '2s'
  958. item.3 '1s'
  959. item.4 '0.5s'
  960. item.5 '0.25s'
  961. item.6 '0.125s'
  962. item.7 '0.0625s'
  963. }
  964. }
  965. control.40 {
  966. iface MIXER
  967. name 'ALC Make Up Volume'
  968. value 0
  969. comment {
  970. access 'read write'
  971. type INTEGER
  972. count 1
  973. range '0 - 12'
  974. dbmin 0
  975. dbmax 1200
  976. dbvalue.0 0
  977. }
  978. }
  979. control.41 {
  980. iface MIXER
  981. name 'ALC Compression Ratio'
  982. value '1:1'
  983. comment {
  984. access 'read write'
  985. type ENUMERATED
  986. count 1
  987. item.0 '1:1'
  988. item.1 '1:1.5'
  989. item.2 '1:2'
  990. item.3 '1:4'
  991. item.4 '1:INF'
  992. }
  993. }
  994. control.42 {
  995. iface MIXER
  996. name 'ALC Expansion Ratio'
  997. value '1:1'
  998. comment {
  999. access 'read write'
  1000. type ENUMERATED
  1001. count 1
  1002. item.0 '1:1'
  1003. item.1 '2:1'
  1004. item.2 '3:1'
  1005. }
  1006. }
  1007. control.43 {
  1008. iface MIXER
  1009. name 'ALC Compression Threshold Volume'
  1010. value 31
  1011. comment {
  1012. access 'read write'
  1013. type INTEGER
  1014. count 1
  1015. range '0 - 31'
  1016. dbmin -3100
  1017. dbmax 0
  1018. dbvalue.0 0
  1019. }
  1020. }
  1021. control.44 {
  1022. iface MIXER
  1023. name 'ALC Expansion Threshold Volume'
  1024. value 31
  1025. comment {
  1026. access 'read write'
  1027. type INTEGER
  1028. count 1
  1029. range '0 - 31'
  1030. dbmin -6600
  1031. dbmax -3500
  1032. dbvalue.0 -3500
  1033. }
  1034. }
  1035. control.45 {
  1036. iface MIXER
  1037. name 'DAC HP Playback Performance Mode'
  1038. value 'High Performance'
  1039. comment {
  1040. access 'read write'
  1041. type ENUMERATED
  1042. count 1
  1043. item.0 'High Performance'
  1044. item.1 'Low Power'
  1045. }
  1046. }
  1047. control.46 {
  1048. iface MIXER
  1049. name 'DAC High Performance Mode'
  1050. value 'High Performance'
  1051. comment {
  1052. access 'read write'
  1053. type ENUMERATED
  1054. count 1
  1055. item.0 'Low Power'
  1056. item.1 'High Performance'
  1057. }
  1058. }
  1059. control.47 {
  1060. iface MIXER
  1061. name 'Headphone Left Mixer Volume'
  1062. value 3
  1063. comment {
  1064. access 'read write'
  1065. type INTEGER
  1066. count 1
  1067. range '0 - 3'
  1068. dbmin -1200
  1069. dbmax 0
  1070. dbvalue.0 0
  1071. }
  1072. }
  1073. control.48 {
  1074. iface MIXER
  1075. name 'Headphone Right Mixer Volume'
  1076. value 3
  1077. comment {
  1078. access 'read write'
  1079. type INTEGER
  1080. count 1
  1081. range '0 - 3'
  1082. dbmin -1200
  1083. dbmax 0
  1084. dbvalue.0 0
  1085. }
  1086. }
  1087. control.49 {
  1088. iface MIXER
  1089. name 'Speaker Left Mixer Volume'
  1090. value 3
  1091. comment {
  1092. access 'read write'
  1093. type INTEGER
  1094. count 1
  1095. range '0 - 3'
  1096. dbmin -1200
  1097. dbmax 0
  1098. dbvalue.0 0
  1099. }
  1100. }
  1101. control.50 {
  1102. iface MIXER
  1103. name 'Speaker Right Mixer Volume'
  1104. value 3
  1105. comment {
  1106. access 'read write'
  1107. type INTEGER
  1108. count 1
  1109. range '0 - 3'
  1110. dbmin -1200
  1111. dbmax 0
  1112. dbvalue.0 0
  1113. }
  1114. }
  1115. control.51 {
  1116. iface MIXER
  1117. name 'Receiver Left Mixer Volume'
  1118. value 3
  1119. comment {
  1120. access 'read write'
  1121. type INTEGER
  1122. count 1
  1123. range '0 - 3'
  1124. dbmin -1200
  1125. dbmax 0
  1126. dbvalue.0 0
  1127. }
  1128. }
  1129. control.52 {
  1130. iface MIXER
  1131. name 'Receiver Right Mixer Volume'
  1132. value 3
  1133. comment {
  1134. access 'read write'
  1135. type INTEGER
  1136. count 1
  1137. range '0 - 3'
  1138. dbmin -1200
  1139. dbmax 0
  1140. dbvalue.0 0
  1141. }
  1142. }
  1143. control.53 {
  1144. iface MIXER
  1145. name 'Headphone Volume'
  1146. value.0 26
  1147. value.1 26
  1148. comment {
  1149. access 'read write'
  1150. type INTEGER
  1151. count 2
  1152. range '0 - 31'
  1153. dbmin -6700
  1154. dbmax 300
  1155. dbvalue.0 0
  1156. dbvalue.1 0
  1157. }
  1158. }
  1159. control.54 {
  1160. iface MIXER
  1161. name 'Speaker Volume'
  1162. value.0 20
  1163. value.1 20
  1164. comment {
  1165. access 'read write'
  1166. type INTEGER
  1167. count 2
  1168. range '0 - 39'
  1169. dbmin -4800
  1170. dbmax 1400
  1171. dbvalue.0 0
  1172. dbvalue.1 0
  1173. }
  1174. }
  1175. control.55 {
  1176. iface MIXER
  1177. name 'Receiver Volume'
  1178. value.0 21
  1179. value.1 21
  1180. comment {
  1181. access 'read write'
  1182. type INTEGER
  1183. count 2
  1184. range '0 - 31'
  1185. dbmin -6200
  1186. dbmax 800
  1187. dbvalue.0 0
  1188. dbvalue.1 0
  1189. }
  1190. }
  1191. control.56 {
  1192. iface MIXER
  1193. name 'Headphone Left Switch'
  1194. value true
  1195. comment {
  1196. access 'read write'
  1197. type BOOLEAN
  1198. count 1
  1199. }
  1200. }
  1201. control.57 {
  1202. iface MIXER
  1203. name 'Headphone Right Switch'
  1204. value true
  1205. comment {
  1206. access 'read write'
  1207. type BOOLEAN
  1208. count 1
  1209. }
  1210. }
  1211. control.58 {
  1212. iface MIXER
  1213. name 'Speaker Left Switch'
  1214. value true
  1215. comment {
  1216. access 'read write'
  1217. type BOOLEAN
  1218. count 1
  1219. }
  1220. }
  1221. control.59 {
  1222. iface MIXER
  1223. name 'Speaker Right Switch'
  1224. value true
  1225. comment {
  1226. access 'read write'
  1227. type BOOLEAN
  1228. count 1
  1229. }
  1230. }
  1231. control.60 {
  1232. iface MIXER
  1233. name 'Receiver Left Switch'
  1234. value true
  1235. comment {
  1236. access 'read write'
  1237. type BOOLEAN
  1238. count 1
  1239. }
  1240. }
  1241. control.61 {
  1242. iface MIXER
  1243. name 'Receiver Right Switch'
  1244. value true
  1245. comment {
  1246. access 'read write'
  1247. type BOOLEAN
  1248. count 1
  1249. }
  1250. }
  1251. control.62 {
  1252. iface MIXER
  1253. name 'Zero-Crossing Detection'
  1254. value true
  1255. comment {
  1256. access 'read write'
  1257. type BOOLEAN
  1258. count 1
  1259. }
  1260. }
  1261. control.63 {
  1262. iface MIXER
  1263. name 'Enhanced Vol Smoothing'
  1264. value true
  1265. comment {
  1266. access 'read write'
  1267. type BOOLEAN
  1268. count 1
  1269. }
  1270. }
  1271. control.64 {
  1272. iface MIXER
  1273. name 'Volume Adjustment Smoothing'
  1274. value true
  1275. comment {
  1276. access 'read write'
  1277. type BOOLEAN
  1278. count 1
  1279. }
  1280. }
  1281. control.65 {
  1282. iface MIXER
  1283. name 'Biquad Coefficients'
  1284. value '000000000000000000000000000000'
  1285. comment {
  1286. access 'read write'
  1287. type BYTES
  1288. count 15
  1289. }
  1290. }
  1291. control.66 {
  1292. iface MIXER
  1293. name 'Biquad Switch'
  1294. value false
  1295. comment {
  1296. access 'read write'
  1297. type BOOLEAN
  1298. count 1
  1299. }
  1300. }
  1301. control.67 {
  1302. iface MIXER
  1303. name 'HP Right Out Switch'
  1304. value false
  1305. comment {
  1306. access 'read write'
  1307. type BOOLEAN
  1308. count 1
  1309. }
  1310. }
  1311. control.68 {
  1312. iface MIXER
  1313. name 'HP Left Out Switch'
  1314. value false
  1315. comment {
  1316. access 'read write'
  1317. type BOOLEAN
  1318. count 1
  1319. }
  1320. }
  1321. control.69 {
  1322. iface MIXER
  1323. name 'MIXHPRSEL Mux'
  1324. value 'DAC Only'
  1325. comment {
  1326. access 'read write'
  1327. type ENUMERATED
  1328. count 1
  1329. item.0 'DAC Only'
  1330. item.1 'HP Mixer'
  1331. }
  1332. }
  1333. control.70 {
  1334. iface MIXER
  1335. name 'MIXHPLSEL Mux'
  1336. value 'DAC Only'
  1337. comment {
  1338. access 'read write'
  1339. type ENUMERATED
  1340. count 1
  1341. item.0 'DAC Only'
  1342. item.1 'HP Mixer'
  1343. }
  1344. }
  1345. control.71 {
  1346. iface MIXER
  1347. name 'LINMOD Mux'
  1348. value 'Left Only'
  1349. comment {
  1350. access 'read write'
  1351. type ENUMERATED
  1352. count 1
  1353. item.0 'Left Only'
  1354. item.1 'Left and Right'
  1355. }
  1356. }
  1357. control.72 {
  1358. iface MIXER
  1359. name 'Right Receiver Mixer Left DAC Switch'
  1360. value false
  1361. comment {
  1362. access 'read write'
  1363. type BOOLEAN
  1364. count 1
  1365. }
  1366. }
  1367. control.73 {
  1368. iface MIXER
  1369. name 'Right Receiver Mixer Right DAC Switch'
  1370. value false
  1371. comment {
  1372. access 'read write'
  1373. type BOOLEAN
  1374. count 1
  1375. }
  1376. }
  1377. control.74 {
  1378. iface MIXER
  1379. name 'Right Receiver Mixer LINEA Switch'
  1380. value false
  1381. comment {
  1382. access 'read write'
  1383. type BOOLEAN
  1384. count 1
  1385. }
  1386. }
  1387. control.75 {
  1388. iface MIXER
  1389. name 'Right Receiver Mixer LINEB Switch'
  1390. value false
  1391. comment {
  1392. access 'read write'
  1393. type BOOLEAN
  1394. count 1
  1395. }
  1396. }
  1397. control.76 {
  1398. iface MIXER
  1399. name 'Right Receiver Mixer MIC1 Switch'
  1400. value false
  1401. comment {
  1402. access 'read write'
  1403. type BOOLEAN
  1404. count 1
  1405. }
  1406. }
  1407. control.77 {
  1408. iface MIXER
  1409. name 'Right Receiver Mixer MIC2 Switch'
  1410. value false
  1411. comment {
  1412. access 'read write'
  1413. type BOOLEAN
  1414. count 1
  1415. }
  1416. }
  1417. control.78 {
  1418. iface MIXER
  1419. name 'Left Receiver Mixer Left DAC Switch'
  1420. value false
  1421. comment {
  1422. access 'read write'
  1423. type BOOLEAN
  1424. count 1
  1425. }
  1426. }
  1427. control.79 {
  1428. iface MIXER
  1429. name 'Left Receiver Mixer Right DAC Switch'
  1430. value false
  1431. comment {
  1432. access 'read write'
  1433. type BOOLEAN
  1434. count 1
  1435. }
  1436. }
  1437. control.80 {
  1438. iface MIXER
  1439. name 'Left Receiver Mixer LINEA Switch'
  1440. value false
  1441. comment {
  1442. access 'read write'
  1443. type BOOLEAN
  1444. count 1
  1445. }
  1446. }
  1447. control.81 {
  1448. iface MIXER
  1449. name 'Left Receiver Mixer LINEB Switch'
  1450. value false
  1451. comment {
  1452. access 'read write'
  1453. type BOOLEAN
  1454. count 1
  1455. }
  1456. }
  1457. control.82 {
  1458. iface MIXER
  1459. name 'Left Receiver Mixer MIC1 Switch'
  1460. value false
  1461. comment {
  1462. access 'read write'
  1463. type BOOLEAN
  1464. count 1
  1465. }
  1466. }
  1467. control.83 {
  1468. iface MIXER
  1469. name 'Left Receiver Mixer MIC2 Switch'
  1470. value false
  1471. comment {
  1472. access 'read write'
  1473. type BOOLEAN
  1474. count 1
  1475. }
  1476. }
  1477. control.84 {
  1478. iface MIXER
  1479. name 'Right Speaker Mixer Left DAC Switch'
  1480. value false
  1481. comment {
  1482. access 'read write'
  1483. type BOOLEAN
  1484. count 1
  1485. }
  1486. }
  1487. control.85 {
  1488. iface MIXER
  1489. name 'Right Speaker Mixer Right DAC Switch'
  1490. value true
  1491. comment {
  1492. access 'read write'
  1493. type BOOLEAN
  1494. count 1
  1495. }
  1496. }
  1497. control.86 {
  1498. iface MIXER
  1499. name 'Right Speaker Mixer LINEA Switch'
  1500. value false
  1501. comment {
  1502. access 'read write'
  1503. type BOOLEAN
  1504. count 1
  1505. }
  1506. }
  1507. control.87 {
  1508. iface MIXER
  1509. name 'Right Speaker Mixer LINEB Switch'
  1510. value false
  1511. comment {
  1512. access 'read write'
  1513. type BOOLEAN
  1514. count 1
  1515. }
  1516. }
  1517. control.88 {
  1518. iface MIXER
  1519. name 'Right Speaker Mixer MIC1 Switch'
  1520. value false
  1521. comment {
  1522. access 'read write'
  1523. type BOOLEAN
  1524. count 1
  1525. }
  1526. }
  1527. control.89 {
  1528. iface MIXER
  1529. name 'Right Speaker Mixer MIC2 Switch'
  1530. value false
  1531. comment {
  1532. access 'read write'
  1533. type BOOLEAN
  1534. count 1
  1535. }
  1536. }
  1537. control.90 {
  1538. iface MIXER
  1539. name 'Left Speaker Mixer Left DAC Switch'
  1540. value true
  1541. comment {
  1542. access 'read write'
  1543. type BOOLEAN
  1544. count 1
  1545. }
  1546. }
  1547. control.91 {
  1548. iface MIXER
  1549. name 'Left Speaker Mixer Right DAC Switch'
  1550. value false
  1551. comment {
  1552. access 'read write'
  1553. type BOOLEAN
  1554. count 1
  1555. }
  1556. }
  1557. control.92 {
  1558. iface MIXER
  1559. name 'Left Speaker Mixer LINEA Switch'
  1560. value false
  1561. comment {
  1562. access 'read write'
  1563. type BOOLEAN
  1564. count 1
  1565. }
  1566. }
  1567. control.93 {
  1568. iface MIXER
  1569. name 'Left Speaker Mixer LINEB Switch'
  1570. value false
  1571. comment {
  1572. access 'read write'
  1573. type BOOLEAN
  1574. count 1
  1575. }
  1576. }
  1577. control.94 {
  1578. iface MIXER
  1579. name 'Left Speaker Mixer MIC1 Switch'
  1580. value false
  1581. comment {
  1582. access 'read write'
  1583. type BOOLEAN
  1584. count 1
  1585. }
  1586. }
  1587. control.95 {
  1588. iface MIXER
  1589. name 'Left Speaker Mixer MIC2 Switch'
  1590. value false
  1591. comment {
  1592. access 'read write'
  1593. type BOOLEAN
  1594. count 1
  1595. }
  1596. }
  1597. control.96 {
  1598. iface MIXER
  1599. name 'Right Headphone Mixer Left DAC Switch'
  1600. value false
  1601. comment {
  1602. access 'read write'
  1603. type BOOLEAN
  1604. count 1
  1605. }
  1606. }
  1607. control.97 {
  1608. iface MIXER
  1609. name 'Right Headphone Mixer Right DAC Switch'
  1610. value false
  1611. comment {
  1612. access 'read write'
  1613. type BOOLEAN
  1614. count 1
  1615. }
  1616. }
  1617. control.98 {
  1618. iface MIXER
  1619. name 'Right Headphone Mixer LINEA Switch'
  1620. value false
  1621. comment {
  1622. access 'read write'
  1623. type BOOLEAN
  1624. count 1
  1625. }
  1626. }
  1627. control.99 {
  1628. iface MIXER
  1629. name 'Right Headphone Mixer LINEB Switch'
  1630. value false
  1631. comment {
  1632. access 'read write'
  1633. type BOOLEAN
  1634. count 1
  1635. }
  1636. }
  1637. control.100 {
  1638. iface MIXER
  1639. name 'Right Headphone Mixer MIC1 Switch'
  1640. value false
  1641. comment {
  1642. access 'read write'
  1643. type BOOLEAN
  1644. count 1
  1645. }
  1646. }
  1647. control.101 {
  1648. iface MIXER
  1649. name 'Right Headphone Mixer MIC2 Switch'
  1650. value false
  1651. comment {
  1652. access 'read write'
  1653. type BOOLEAN
  1654. count 1
  1655. }
  1656. }
  1657. control.102 {
  1658. iface MIXER
  1659. name 'Left Headphone Mixer Left DAC Switch'
  1660. value false
  1661. comment {
  1662. access 'read write'
  1663. type BOOLEAN
  1664. count 1
  1665. }
  1666. }
  1667. control.103 {
  1668. iface MIXER
  1669. name 'Left Headphone Mixer Right DAC Switch'
  1670. value false
  1671. comment {
  1672. access 'read write'
  1673. type BOOLEAN
  1674. count 1
  1675. }
  1676. }
  1677. control.104 {
  1678. iface MIXER
  1679. name 'Left Headphone Mixer LINEA Switch'
  1680. value false
  1681. comment {
  1682. access 'read write'
  1683. type BOOLEAN
  1684. count 1
  1685. }
  1686. }
  1687. control.105 {
  1688. iface MIXER
  1689. name 'Left Headphone Mixer LINEB Switch'
  1690. value false
  1691. comment {
  1692. access 'read write'
  1693. type BOOLEAN
  1694. count 1
  1695. }
  1696. }
  1697. control.106 {
  1698. iface MIXER
  1699. name 'Left Headphone Mixer MIC1 Switch'
  1700. value false
  1701. comment {
  1702. access 'read write'
  1703. type BOOLEAN
  1704. count 1
  1705. }
  1706. }
  1707. control.107 {
  1708. iface MIXER
  1709. name 'Left Headphone Mixer MIC2 Switch'
  1710. value false
  1711. comment {
  1712. access 'read write'
  1713. type BOOLEAN
  1714. count 1
  1715. }
  1716. }
  1717. control.108 {
  1718. iface MIXER
  1719. name 'STENR Mux'
  1720. value Normal
  1721. comment {
  1722. access 'read write'
  1723. type ENUMERATED
  1724. count 1
  1725. item.0 Normal
  1726. item.1 'Sidetone Right'
  1727. }
  1728. }
  1729. control.109 {
  1730. iface MIXER
  1731. name 'STENL Mux'
  1732. value Normal
  1733. comment {
  1734. access 'read write'
  1735. type ENUMERATED
  1736. count 1
  1737. item.0 Normal
  1738. item.1 'Sidetone Left'
  1739. }
  1740. }
  1741. control.110 {
  1742. iface MIXER
  1743. name 'LTENR Mux'
  1744. value Normal
  1745. comment {
  1746. access 'read write'
  1747. type ENUMERATED
  1748. count 1
  1749. item.0 Normal
  1750. item.1 Loopthrough
  1751. }
  1752. }
  1753. control.111 {
  1754. iface MIXER
  1755. name 'LTENL Mux'
  1756. value Normal
  1757. comment {
  1758. access 'read write'
  1759. type ENUMERATED
  1760. count 1
  1761. item.0 Normal
  1762. item.1 Loopthrough
  1763. }
  1764. }
  1765. control.112 {
  1766. iface MIXER
  1767. name 'LBENR Mux'
  1768. value Normal
  1769. comment {
  1770. access 'read write'
  1771. type ENUMERATED
  1772. count 1
  1773. item.0 Normal
  1774. item.1 Loopback
  1775. }
  1776. }
  1777. control.113 {
  1778. iface MIXER
  1779. name 'LBENL Mux'
  1780. value Normal
  1781. comment {
  1782. access 'read write'
  1783. type ENUMERATED
  1784. count 1
  1785. item.0 Normal
  1786. item.1 Loopback
  1787. }
  1788. }
  1789. control.114 {
  1790. iface MIXER
  1791. name 'Right ADC Mixer IN12 Switch'
  1792. value false
  1793. comment {
  1794. access 'read write'
  1795. type BOOLEAN
  1796. count 1
  1797. }
  1798. }
  1799. control.115 {
  1800. iface MIXER
  1801. name 'Right ADC Mixer IN34 Switch'
  1802. value false
  1803. comment {
  1804. access 'read write'
  1805. type BOOLEAN
  1806. count 1
  1807. }
  1808. }
  1809. control.116 {
  1810. iface MIXER
  1811. name 'Right ADC Mixer IN56 Switch'
  1812. value false
  1813. comment {
  1814. access 'read write'
  1815. type BOOLEAN
  1816. count 1
  1817. }
  1818. }
  1819. control.117 {
  1820. iface MIXER
  1821. name 'Right ADC Mixer LINEA Switch'
  1822. value false
  1823. comment {
  1824. access 'read write'
  1825. type BOOLEAN
  1826. count 1
  1827. }
  1828. }
  1829. control.118 {
  1830. iface MIXER
  1831. name 'Right ADC Mixer LINEB Switch'
  1832. value false
  1833. comment {
  1834. access 'read write'
  1835. type BOOLEAN
  1836. count 1
  1837. }
  1838. }
  1839. control.119 {
  1840. iface MIXER
  1841. name 'Right ADC Mixer MIC1 Switch'
  1842. value false
  1843. comment {
  1844. access 'read write'
  1845. type BOOLEAN
  1846. count 1
  1847. }
  1848. }
  1849. control.120 {
  1850. iface MIXER
  1851. name 'Right ADC Mixer MIC2 Switch'
  1852. value false
  1853. comment {
  1854. access 'read write'
  1855. type BOOLEAN
  1856. count 1
  1857. }
  1858. }
  1859. control.121 {
  1860. iface MIXER
  1861. name 'Left ADC Mixer IN12 Switch'
  1862. value false
  1863. comment {
  1864. access 'read write'
  1865. type BOOLEAN
  1866. count 1
  1867. }
  1868. }
  1869. control.122 {
  1870. iface MIXER
  1871. name 'Left ADC Mixer IN34 Switch'
  1872. value false
  1873. comment {
  1874. access 'read write'
  1875. type BOOLEAN
  1876. count 1
  1877. }
  1878. }
  1879. control.123 {
  1880. iface MIXER
  1881. name 'Left ADC Mixer IN56 Switch'
  1882. value false
  1883. comment {
  1884. access 'read write'
  1885. type BOOLEAN
  1886. count 1
  1887. }
  1888. }
  1889. control.124 {
  1890. iface MIXER
  1891. name 'Left ADC Mixer LINEA Switch'
  1892. value false
  1893. comment {
  1894. access 'read write'
  1895. type BOOLEAN
  1896. count 1
  1897. }
  1898. }
  1899. control.125 {
  1900. iface MIXER
  1901. name 'Left ADC Mixer LINEB Switch'
  1902. value false
  1903. comment {
  1904. access 'read write'
  1905. type BOOLEAN
  1906. count 1
  1907. }
  1908. }
  1909. control.126 {
  1910. iface MIXER
  1911. name 'Left ADC Mixer MIC1 Switch'
  1912. value false
  1913. comment {
  1914. access 'read write'
  1915. type BOOLEAN
  1916. count 1
  1917. }
  1918. }
  1919. control.127 {
  1920. iface MIXER
  1921. name 'Left ADC Mixer MIC2 Switch'
  1922. value false
  1923. comment {
  1924. access 'read write'
  1925. type BOOLEAN
  1926. count 1
  1927. }
  1928. }
  1929. control.128 {
  1930. iface MIXER
  1931. name 'LINEB Mixer IN2 Switch'
  1932. value false
  1933. comment {
  1934. access 'read write'
  1935. type BOOLEAN
  1936. count 1
  1937. }
  1938. }
  1939. control.129 {
  1940. iface MIXER
  1941. name 'LINEB Mixer IN4 Switch'
  1942. value false
  1943. comment {
  1944. access 'read write'
  1945. type BOOLEAN
  1946. count 1
  1947. }
  1948. }
  1949. control.130 {
  1950. iface MIXER
  1951. name 'LINEB Mixer IN6 Switch'
  1952. value false
  1953. comment {
  1954. access 'read write'
  1955. type BOOLEAN
  1956. count 1
  1957. }
  1958. }
  1959. control.131 {
  1960. iface MIXER
  1961. name 'LINEB Mixer IN56 Switch'
  1962. value false
  1963. comment {
  1964. access 'read write'
  1965. type BOOLEAN
  1966. count 1
  1967. }
  1968. }
  1969. control.132 {
  1970. iface MIXER
  1971. name 'LINEA Mixer IN1 Switch'
  1972. value false
  1973. comment {
  1974. access 'read write'
  1975. type BOOLEAN
  1976. count 1
  1977. }
  1978. }
  1979. control.133 {
  1980. iface MIXER
  1981. name 'LINEA Mixer IN3 Switch'
  1982. value false
  1983. comment {
  1984. access 'read write'
  1985. type BOOLEAN
  1986. count 1
  1987. }
  1988. }
  1989. control.134 {
  1990. iface MIXER
  1991. name 'LINEA Mixer IN5 Switch'
  1992. value false
  1993. comment {
  1994. access 'read write'
  1995. type BOOLEAN
  1996. count 1
  1997. }
  1998. }
  1999. control.135 {
  2000. iface MIXER
  2001. name 'LINEA Mixer IN34 Switch'
  2002. value false
  2003. comment {
  2004. access 'read write'
  2005. type BOOLEAN
  2006. count 1
  2007. }
  2008. }
  2009. control.136 {
  2010. iface MIXER
  2011. name 'DMIC Mux'
  2012. value ADC
  2013. comment {
  2014. access 'read write'
  2015. type ENUMERATED
  2016. count 1
  2017. item.0 ADC
  2018. item.1 DMIC
  2019. }
  2020. }
  2021. control.137 {
  2022. iface MIXER
  2023. name 'MIC2 Mux'
  2024. value IN34
  2025. comment {
  2026. access 'read write'
  2027. type ENUMERATED
  2028. count 1
  2029. item.0 IN34
  2030. item.1 IN56
  2031. }
  2032. }
  2033. control.138 {
  2034. iface MIXER
  2035. name 'MIC1 Mux'
  2036. value IN12
  2037. comment {
  2038. access 'read write'
  2039. type ENUMERATED
  2040. count 1
  2041. item.0 IN12
  2042. item.1 IN56
  2043. }
  2044. }
  2045. control.139 {
  2046. iface MIXER
  2047. name 'Speakers Switch'
  2048. value true
  2049. comment {
  2050. access 'read write'
  2051. type BOOLEAN
  2052. count 1
  2053. }
  2054. }
  2055. control.140 {
  2056. iface MIXER
  2057. name 'Headphone Jack Switch'
  2058. value false
  2059. comment {
  2060. access 'read write'
  2061. type BOOLEAN
  2062. count 1
  2063. }
  2064. }
  2065. control.141 {
  2066. iface MIXER
  2067. name 'Mic Jack Switch'
  2068. value false
  2069. comment {
  2070. access 'read write'
  2071. type BOOLEAN
  2072. count 1
  2073. }
  2074. }
  2075. control.142 {
  2076. iface MIXER
  2077. name 'Int Mic Switch'
  2078. value true
  2079. comment {
  2080. access 'read write'
  2081. type BOOLEAN
  2082. count 1
  2083. }
  2084. }
  2085. }
  2086. EOF
  2087.  
  2088. cat > /tmp/urfs/install-tegra.sh <<EOF
  2089. update-alternatives --install /etc/ld.so.conf.d/arm-linux-gnueabihf_EGL.conf arm-linux-gnueabihf_egl_conf /usr/lib/arm-linux-gnueabihf/tegra-egl/ld.so.conf 1000
  2090. update-alternatives --install /etc/ld.so.conf.d/arm-linux-gnueabihf_GL.conf arm-linux-gnueabihf_gl_conf /usr/lib/arm-linux-gnueabihf/tegra/ld.so.conf 1000
  2091. ldconfig
  2092. adduser user video
  2093. EOF
  2094. #su user -c "xdg-settings set default-web-browser chromium.desktop"
  2095.  
  2096. chmod a+x /tmp/urfs/install-tegra.sh
  2097. chroot /tmp/urfs /bin/bash -c /install-tegra.sh
  2098. rm /tmp/urfs/install-tegra.sh
  2099.  
  2100. echo "console=tty1 debug verbose root=${target_rootfs} rootwait rw lsm.module_locking=0" > kernel-config
  2101. vbutil_arch="x86"
  2102. if [ $ubuntu_arch = "armhf" ]
  2103. then
  2104. vbutil_arch="arm"
  2105. fi
  2106.  
  2107. current_rootfs="`rootdev -s`"
  2108. current_kernfs_num=$((${current_rootfs: -1:1}-1))
  2109. current_kernfs=${current_rootfs: 0:-1}$current_kernfs_num
  2110.  
  2111. vbutil_kernel --repack ${target_kern} \
  2112. --oldblob $current_kernfs \
  2113. --keyblock /usr/share/vboot/devkeys/kernel.keyblock \
  2114. --version 1 \
  2115. --signprivate /usr/share/vboot/devkeys/kernel_data_key.vbprivk \
  2116. --config kernel-config \
  2117. --arch $vbutil_arch
  2118.  
  2119. #Set Ubuntu kernel partition as top priority for next boot (and next boot only)
  2120. cgpt add -i 6 -P 5 -T 1 ${target_disk}
  2121.  
  2122. echo -e "
  2123.  
  2124. Installation seems to be complete. If ChrUbuntu fails when you reboot,
  2125. power off your Chrome OS device and then turn it back on. You'll be back
  2126. in Chrome OS. If you're happy with ChrUbuntu when you reboot be sure to run:
  2127.  
  2128. sudo cgpt add -i 6 -P 5 -S 1 ${target_disk}
  2129.  
  2130. To make it the default boot option. The ChrUbuntu login is:
  2131.  
  2132. Username: user
  2133. Password: user
  2134.  
  2135. We're now ready to start ChrUbuntu!
  2136. "
  2137.  
  2138. read -p "Press [Enter] to reboot..."
  2139.  
  2140. reboot
Advertisement
Add Comment
Please, Sign In to add comment