<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://mediawiki.compulab.com/w/index.php?action=history&amp;feed=atom&amp;title=UCM-iMX7%3A_Linux%3A_Debian</id>
	<title>UCM-iMX7: Linux: Debian - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://mediawiki.compulab.com/w/index.php?action=history&amp;feed=atom&amp;title=UCM-iMX7%3A_Linux%3A_Debian"/>
	<link rel="alternate" type="text/html" href="https://mediawiki.compulab.com/w/index.php?title=UCM-iMX7:_Linux:_Debian&amp;action=history"/>
	<updated>2026-09-02T06:11:23Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.31.0</generator>
	<entry>
		<id>https://mediawiki.compulab.com/w/index.php?title=UCM-iMX7:_Linux:_Debian&amp;diff=3360&amp;oldid=prev</id>
		<title>Ilya: /* Host Controller Interface (HCI) Initialization */</title>
		<link rel="alternate" type="text/html" href="https://mediawiki.compulab.com/w/index.php?title=UCM-iMX7:_Linux:_Debian&amp;diff=3360&amp;oldid=prev"/>
		<updated>2017-06-15T11:55:20Z</updated>

		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Host Controller Interface (HCI) Initialization&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Overview ==&lt;br /&gt;
The example run-time Linux filesystem image for the CompuLab UCM-iMX7 System-on-Module / Computer-on-Module is based on Debian GNU/Linux Sid.&lt;br /&gt;
The CompuLab Linux package for UCM-iMX7 includes ready to run image, Linux kernel configuration and source code patches, and an archive of the root filesystem, used to create the image.&lt;br /&gt;
&lt;br /&gt;
The default Debian Wheezy Linux image includes more than 400 software packages. Among them:&lt;br /&gt;
&lt;br /&gt;
* Core system&lt;br /&gt;
* Debian package management system&lt;br /&gt;
* X11 Windowing System&lt;br /&gt;
* Fluxbox desktop manager&lt;br /&gt;
* SSH server and client&lt;br /&gt;
* PulseAudio configuration and usage utilities &lt;br /&gt;
* Bluez5 Bluetooth tools and daemons&lt;br /&gt;
&lt;br /&gt;
The [[UCM-iMX7: Linux: Automatic Installation|Automatic Linux installation on UCM-iMX7]] page provides a brief introduction on how to install the run-time Linux image.&lt;br /&gt;
This article describes package structure and peripheral device options specific to the UCM-iMX7.&lt;br /&gt;
&lt;br /&gt;
{{Note|The article uses {{cmd|cl-rootfs}} hostname. A real hostname may be different.}}&lt;br /&gt;
&lt;br /&gt;
== Using Debian Linux on UCM-iMX7 ==&lt;br /&gt;
&lt;br /&gt;
=== Connection and Logging In ===&lt;br /&gt;
{{:Transclusion: Debian: Logging In}}&lt;br /&gt;
&lt;br /&gt;
=== Networking ===&lt;br /&gt;
{{:Transclusion: Debian: Networking}}&lt;br /&gt;
&lt;br /&gt;
=== Consoles ===&lt;br /&gt;
{{:Transclusion: Debian: Consoles}}&lt;br /&gt;
&lt;br /&gt;
=== X Windows system ===&lt;br /&gt;
{{:Transclusion: Debian: X Windows: Fluxbox}}&lt;br /&gt;
&lt;br /&gt;
=== Software Management ===&lt;br /&gt;
{{:Transclusion: Debian: Software Management}}&lt;br /&gt;
&lt;br /&gt;
=== Analog Audio ===&lt;br /&gt;
UCM-iMX7 provides an analog audio interface, which is registered as a standard ALSA sound card. &lt;br /&gt;
Use {{cmd|aplay -l}} to list all soundcards and digital audio devices registered on the system:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# aplay -l&lt;br /&gt;
**** List of PLAYBACK Hardware Devices ****&lt;br /&gt;
card 0: ucmimx7 [ucm-imx7], device 0: 308a0000.sai-wm8731-hifi wm8731-hifi-0 []&lt;br /&gt;
  Subdevices: 1/1&lt;br /&gt;
  Subdevice #0: subdevice #0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
{{:Transclusion: Debian: CL-SOM-iMX7: Analog Audio}}&lt;br /&gt;
&lt;br /&gt;
=== USB On-The-Go (OTG) ===&lt;br /&gt;
{{:Transclusion: Debian: iMX7: USB OTG}}&lt;br /&gt;
&lt;br /&gt;
=== WiFi ===&lt;br /&gt;
UCM-iMX7 features 802.11b/g/n wireless connectivity solution, implemented with a Broadcom BCM4343W chipset.&lt;br /&gt;
&lt;br /&gt;
==== WiFi Initialization ====&lt;br /&gt;
* WiFi requires no user interaction for being configured. The driver gets loaded automatically by the means of ''/etc/modules-load.d/wifi.conf'' configuration file. The driver options are specified with the options file ''/etc/modprobe.d/bcmdhd.conf''. Make sure that the WiFi driver is loaded:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# lsmod | grep bcmdhd&lt;br /&gt;
bcmdhd                597255  0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* The WiFi driver can be loaded manually. &lt;br /&gt;
&amp;lt;blockquote&amp;gt;&lt;br /&gt;
* Create the driver options file:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cat &amp;lt;&amp;lt; eof &amp;gt; /etc/modprobe.d/bcmdhd.conf&lt;br /&gt;
options bcmdhd firmware_path=/lib/firmware/brcm/1DX/fw_bcmdhd.bin&lt;br /&gt;
options bcmdhd nvram_path=/lib/firmware/brcm/1DX/bcmdhd.1DX.SDIO.cal&lt;br /&gt;
options bcmdhd dhd_msg_level=0x1&lt;br /&gt;
eof&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Load the WiFi driver module:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-debian:~# modprobe bcmdhd &lt;br /&gt;
dhd_module_init in&lt;br /&gt;
...&lt;br /&gt;
Register interface [wlan0]  MAC: b0:72:bf:09:b5:fc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/blockquote&amp;gt;&lt;br /&gt;
* {{cmd|iwconfig}} command from {{filename|wireless-tools}} package can be used to retrieve detailed information about the WiFi interfaces:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# iwconfig wlan0&lt;br /&gt;
wlan0     IEEE 802.11bg  ESSID:off/any  &lt;br /&gt;
          Mode:Managed  Access Point: Not-Associated   &lt;br /&gt;
          Retry short limit:7   RTS thr:off   Fragment thr:off&lt;br /&gt;
          Encryption key:off&lt;br /&gt;
          Power Management:on&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Activate the interface:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# ifconfig wlan0 up&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Sample WiFi scanning:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# iwlist wlan0 scan&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The output will show the list of Access Points and Ad-Hoc cells in range.&lt;br /&gt;
For more information about connecting to wireless networks and tuning WiFi interfaces refer to “wpa_supplicant” and “wireless-tools” man pages.&lt;br /&gt;
&lt;br /&gt;
==== wpa_supplicant ====&lt;br /&gt;
* Configuration sample&lt;br /&gt;
{{cmd|wpa_supplicant}} requires a configuration file to be created in order to get connected to a scanned wireless network.&amp;lt;br&amp;gt;&lt;br /&gt;
Make use of the example bellow and put the network name and the password into the &amp;quot;ssid/psk&amp;quot; fields.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# cat &amp;lt;&amp;lt; eof &amp;gt; /etc/wpa_supplicant.conf&lt;br /&gt;
ctrl_interface=/var/run/wpa_supplicant&lt;br /&gt;
&lt;br /&gt;
network={&lt;br /&gt;
	ssid=&amp;quot;wireless_network_name&amp;quot;&lt;br /&gt;
	key_mgmt=WPA-PSK&lt;br /&gt;
	psk=&amp;quot;wireless_network_password&amp;quot;&lt;br /&gt;
}&lt;br /&gt;
eof&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Sample run&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# ifconfig wlan0 up&lt;br /&gt;
root@cl-rootfs:~# wpa_supplicant -B -Dwext -c /etc/wpa_supplicant.conf -i wlan0&lt;br /&gt;
root@cl-rootfs:~# dhclient wlan0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Bluetooth ===&lt;br /&gt;
UCM-iMX7 features Bluetooth 4.1 + High Speed (HS) interface. Following sections describe the initialization and simple use cases of the Bluetooth interface.&lt;br /&gt;
&lt;br /&gt;
==== Host Controller Interface (HCI) Initialization ==== &lt;br /&gt;
* Start Bluetooth:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-debian:~# bt-start &lt;br /&gt;
bcm43xx_init&lt;br /&gt;
Set Controller UART speed to 3000000 bit/s&lt;br /&gt;
Flash firmware /etc/firmware/BCM43430A1.1DX.hcd&lt;br /&gt;
Set Controller UART speed to 3000000 bit/s&lt;br /&gt;
Bluetooth: HCI UART driver ver 2.3&lt;br /&gt;
Bluetooth: HCI UART protocol H4 registered&lt;br /&gt;
Bluetooth: HCI UART protocol BCM registered&lt;br /&gt;
Device setup complete&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Make sure that the Bluetooth drivers are loaded:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-debian:~# lsmod&lt;br /&gt;
Module                  Size  Used by&lt;br /&gt;
hci_uart                7594  1&lt;br /&gt;
btbcm                   5344  1 hci_uart&lt;br /&gt;
...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* HCI device configuration utility can be run to retrieve detailed information about the Bluetooth interfaces:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-debian:~# hciconfig -a&lt;br /&gt;
hci0:   Type: BR/EDR  Bus: UART&lt;br /&gt;
        BD Address: 43:43:A1:12:1F:AC  ACL MTU: 1021:8  SCO MTU: 64:1&lt;br /&gt;
        UP RUNNING &lt;br /&gt;
        RX bytes:675 acl:0 sco:0 events:39 errors:0&lt;br /&gt;
        TX bytes:1271 acl:0 sco:0 commands:39 errors:0&lt;br /&gt;
        Features: 0xbf 0xfe 0xcf 0xfe 0xdb 0xff 0x7b 0x87&lt;br /&gt;
        Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3 &lt;br /&gt;
        Link policy: RSWITCH SNIFF &lt;br /&gt;
        Link mode: SLAVE ACCEPT &lt;br /&gt;
        Name: 'BlueZ 5.36'&lt;br /&gt;
        Class: 0x000000&lt;br /&gt;
        Service Classes: Unspecified&lt;br /&gt;
        Device Class: Miscellaneous, &lt;br /&gt;
        HCI Version: 4.0 (0x6)  Revision: 0x16&lt;br /&gt;
        LMP Version: 4.0 (0x6)  Subversion: 0x2209&lt;br /&gt;
        Manufacturer: Broadcom Corporation (15)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* If the HCI device is not running, use the below command to enable the HCI device:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-debian:~# hciconfig hci0 up&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{:Transclusion: Debian: iMX7: Bluez5 PulseAudio}}&lt;br /&gt;
&lt;br /&gt;
=== Controller–area network (CAN) ===&lt;br /&gt;
UCM-iMX7 features two Flexible Controller Area Network (FLEXCAN) modules. Each FLEXCAN implements full CAN protocol version 2.0B and supports both the standard and the extended frame format as well as a programmable data bit rate up to 1Mbit/s.&lt;br /&gt;
{{Note|Please prepare the hardware as described in the [[UCM-iMX7: Evaluation Kit: Hardware Guide#CAN | UCM-iMX7  Evaluation Kit Hardware Guide]] and [[SB-UCM: HOWTO: CAN Connection |  CAN node connection guide]].}}&lt;br /&gt;
{{:Transclusion: Debian: iMX7: CAN Bus}}&lt;br /&gt;
&lt;br /&gt;
=== Touchscreen ===&lt;br /&gt;
The touchscreen driver is modularized if you use default UCM-iMX7 configuration and is not loaded by {{filename|udev}} automatically on Linux boot. Use the following command to load the touchscreen driver module:&lt;br /&gt;
&lt;br /&gt;
* For TI TSC2046 touch panel:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# modprobe ads7846&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The X Windows system of UCM-iMX7 uses tslib X server input driver to get the input from the touchscreen.&lt;br /&gt;
&lt;br /&gt;
==== Touchscreen calibration ====&lt;br /&gt;
All supported touchscreen devices can be calibrated using {{cmd|xinput_calibrator}} utility.&lt;br /&gt;
&lt;br /&gt;
To calibrate the touchscreen:&lt;br /&gt;
* Run X Server by issuing {{cmd|startx &amp;amp;}} command&lt;br /&gt;
* Make sure the touchscreen driver is loaded as described in [[#Touchscreen|Touchscreen]] section&lt;br /&gt;
* Set the {{parameter|DISPLAY}} environment variable:&lt;br /&gt;
&amp;lt;pre&amp;gt; export DISPLAY=:0&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Run {{cmd|xinput_calibrator}} utility. For proper calibration you are required to touch the touchscreen corners and center in the following order: top-left, top-right, bottom-right, bottom-left, center.&lt;br /&gt;
* Create a file {{filename|/usr/share/X11/xorg.conf.d/99-calibration.conf}} and paste there a snippet with the calibration results:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
root@cl-rootfs:~# xinput_calibrator &lt;br /&gt;
Setting calibration data: 0, 4095, 0, 4095&lt;br /&gt;
Calibrating EVDEV driver for &amp;quot;ADS7846 Touchscreen&amp;quot; id=6&lt;br /&gt;
        current calibration values (from XInput): min_x=0, max_x=4095 and min_y=0, max_y=4095&lt;br /&gt;
&lt;br /&gt;
Doing dynamic recalibration:&lt;br /&gt;
        Setting calibration data: 165, 3864, 3789, 268&lt;br /&gt;
        --&amp;gt; Making the calibration permanent &amp;lt;--&lt;br /&gt;
  copy the snippet below into '/etc/X11/xorg.conf.d/99-calibration.conf' (/usr/share/X11/xorg.conf.d/ in some distro's)&lt;br /&gt;
Section &amp;quot;InputClass&amp;quot;&lt;br /&gt;
        Identifier      &amp;quot;calibration&amp;quot;&lt;br /&gt;
        MatchProduct    &amp;quot;ADS7846 Touchscreen&amp;quot;&lt;br /&gt;
        Option  &amp;quot;Calibration&amp;quot;   &amp;quot;165 3864 3789 268&amp;quot;&lt;br /&gt;
        Option  &amp;quot;SwapAxes&amp;quot;      &amp;quot;0&amp;quot;&lt;br /&gt;
EndSection&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== MMC/SD ===&lt;br /&gt;
{{:Transclusion: Debian: CL-SOM-iMX7: MMC}}&lt;br /&gt;
&lt;br /&gt;
=== GPIO access ===&lt;br /&gt;
{{:Transclusion: Debian: GPIO}}&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* [[UCM-iMX7: Evaluation Kit: Getting Started]]&lt;br /&gt;
* [[UCM-iMX7: Evaluation Kit: Hardware Guide]]&lt;br /&gt;
* [[UCM-iMX7: Linux: Automatic Installation]]&lt;br /&gt;
* [[UCM-iMX7: Linux: Manual Installation]]&lt;br /&gt;
* [[UCM-iMX7: Linux: Kernel]]&lt;br /&gt;
* [[Linux: Development for ARM modules]]&lt;br /&gt;
* [[Linux: Debian: Minimal ARM filesystem]]&lt;br /&gt;
* [http://www.debian.org/doc/manuals/reference/index.en.html Debian Reference].&lt;br /&gt;
&lt;br /&gt;
[[Category:Linux]]&lt;br /&gt;
[[Category:UCM-iMX7]]&lt;/div&gt;</summary>
		<author><name>Ilya</name></author>
		
	</entry>
</feed>