Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
| software:linux:toradex:eim [2015-06-30 16:11] – angelegt abajric | software:linux:toradex:eim [Unbekanntes Datum] (aktuell) – gelöscht - Externe Bearbeitung (Unbekanntes Datum) 127.0.0.1 | ||
|---|---|---|---|
| Zeile 1: | Zeile 1: | ||
| - | ====== Toradex Colibri i.MX6 - EIM driver ====== | ||
| - | Fetch and build flinklinux: | ||
| - | |||
| - | < | ||
| - | $ cd $WD | ||
| - | $ git clone https:// | ||
| - | $ cd flinklinux | ||
| - | $ make | ||
| - | </ | ||
| - | |||
| - | |||
| - | |||
| - | The device tree file is compiled with the kernel. The output file is: '' | ||
| - | This file has to be passed to the kernel during boot. The source of this file was based on the device tree file of the eval board. The '' | ||
| - | |||
| - | The relevant part is listed here: | ||
| - | |||
| - | < | ||
| - | &weim { | ||
| - | status = " | ||
| - | /* weim memory map: 32MB on CS0, 32MB on CS1, 32MB on CS2 */ | ||
| - | ranges = <0 0 0x08000000 0x02000000 | ||
| - | 1 0 0x0a000000 0x02000000 | ||
| - | 2 0 0x0c000000 0x02000000>; | ||
| - | /* FPGA on CS0 */ | ||
| - | fpga@0,0 { | ||
| - | compatible = " | ||
| - | reg = <0 0 0x00080000>; | ||
| - | # | ||
| - | # | ||
| - | bank-width = <2>; | ||
| - | fsl, | ||
| - | 0x00000000 0x04000040 0x00000000>; | ||
| - | }; | ||
| - | }; | ||
| - | </ | ||
| - | |||
| - | The //ranges// property determines the memory areas for 3 chip selects. The size of each region is 32 MB. CS0 starts at 0x08000000 and is used for the FPGA. Only 512 KB are used for the FPGA because the address width is 16 bit. The kernel module maps the amount of memory which is in the //reg// property of the //fpga// node. | ||
| - | |||
| - | The property '' | ||
| - | |||
| - | The // | ||
| - | |||
| - | This is the complete file: | ||
| - | |||
| - | < | ||
| - | /* | ||
| - | * Copyright 2014 Toradex AG | ||
| - | * Copyright 2012 Freescale Semiconductor, | ||
| - | * Copyright 2011 Linaro Ltd. | ||
| - | * | ||
| - | * The code contained herein is licensed under the GNU General Public | ||
| - | * License. You may obtain a copy of the GNU General Public License | ||
| - | * Version 2 or later at the following locations: | ||
| - | * | ||
| - | * http:// | ||
| - | * http:// | ||
| - | */ | ||
| - | |||
| - | /dts-v1/; | ||
| - | |||
| - | #include < | ||
| - | #include " | ||
| - | #include " | ||
| - | |||
| - | / { | ||
| - | model = " | ||
| - | compatible = " | ||
| - | |||
| - | aliases { | ||
| - | rtc0 = & | ||
| - | rtc1 = "/ | ||
| - | }; | ||
| - | |||
| - | aliases { | ||
| - | /* the following, together with kernel patches, forces a fixed assignment | ||
| - | | ||
| - | /* i.e. the eMMC on usdhc3 will be / | ||
| - | mmc0 = & | ||
| - | mmc1 = & | ||
| - | }; | ||
| - | |||
| - | gpio-keys { | ||
| - | compatible = " | ||
| - | pinctrl-names = " | ||
| - | pinctrl-0 = <& | ||
| - | |||
| - | wakeup { | ||
| - | label = " | ||
| - | gpios = <& | ||
| - | linux, | ||
| - | debounce-interval = <10>; | ||
| - | gpio-key, | ||
| - | }; | ||
| - | }; | ||
| - | |||
| - | pwmleds { | ||
| - | compatible = " | ||
| - | ledpwm2 { | ||
| - | label = " | ||
| - | pwms = <& | ||
| - | max-brightness = < | ||
| - | }; | ||
| - | |||
| - | ledpwm3 { | ||
| - | label = " | ||
| - | pwms = <& | ||
| - | max-brightness = < | ||
| - | }; | ||
| - | |||
| - | ledpwm4 { | ||
| - | label = " | ||
| - | pwms = <& | ||
| - | max-brightness = < | ||
| - | }; | ||
| - | }; | ||
| - | |||
| - | regulators { | ||
| - | reg_usb_host_vbus: | ||
| - | status = " | ||
| - | }; | ||
| - | }; | ||
| - | }; | ||
| - | |||
| - | & | ||
| - | #if 0 | ||
| - | /* PWM polarity: 1 is brightest */ | ||
| - | brightness-levels = <0 4 8 16 32 64 128 255>; | ||
| - | default-brightness-level = <6>; | ||
| - | #else | ||
| - | /* PWM plarity: 0 is brightest */ | ||
| - | brightness-levels = <0 74 128 164 192 210 255>; | ||
| - | default-brightness-level = <1>; | ||
| - | #endif | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | /* Colibri SPI */ | ||
| - | &ecspi4 { | ||
| - | status = " | ||
| - | |||
| - | spidev0: spidev@1 { | ||
| - | compatible = " | ||
| - | reg = <0>; | ||
| - | spi-max-frequency = < | ||
| - | }; | ||
| - | }; | ||
| - | |||
| - | & | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | & | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | & | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | /* | ||
| - | * I2C: I2C3_SDA/ | ||
| - | * board) | ||
| - | */ | ||
| - | &i2c3 { | ||
| - | status = " | ||
| - | #if 0 /* not standard pinout, disable PWM< | ||
| - | pcap@10 { | ||
| - | /* TouchRevolution Fusion 7 and 10 multi-touch controller */ | ||
| - | compatible = " | ||
| - | reg = < | ||
| - | gpios = <& | ||
| - | &gpio2 10 0 /* SODIMM-30, Reset */ | ||
| - | >; | ||
| - | }; | ||
| - | #endif | ||
| - | /* M41T0M6 real time clock on carrier board */ | ||
| - | rtc_i2c: rtc@68 { | ||
| - | compatible = " | ||
| - | reg = < | ||
| - | }; | ||
| - | }; | ||
| - | |||
| - | /* | ||
| - | * DDC_I2C: I2C2_SDA/ | ||
| - | */ | ||
| - | &i2cddc { | ||
| - | status = " | ||
| - | |||
| - | hdmi: edid@50 { | ||
| - | compatible = " | ||
| - | reg = < | ||
| - | }; | ||
| - | }; | ||
| - | |||
| - | &iomuxc { | ||
| - | /* | ||
| - | * Mux all pins which are unused to be GPIOs | ||
| - | * so they are ready for export to user space | ||
| - | */ | ||
| - | pinctrl-names = " | ||
| - | pinctrl-0 = <& | ||
| - | & | ||
| - | & | ||
| - | & | ||
| - | & | ||
| - | & | ||
| - | & | ||
| - | }; | ||
| - | |||
| - | &lcd { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &mxcfb1 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &mxcfb2 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &pwm1 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &pwm2 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &pwm3 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &pwm4 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | & | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &uart1 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &uart2 { | ||
| - | status = " | ||
| - | #if 0 | ||
| - | linux, | ||
| - | #endif | ||
| - | }; | ||
| - | |||
| - | &uart3 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &usbh1 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &usbotg { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | /* MMC */ | ||
| - | &usdhc1 { | ||
| - | status = " | ||
| - | }; | ||
| - | |||
| - | &weim { | ||
| - | status = " | ||
| - | /* weim memory map: 32MB on CS0, 32MB on CS1, 32MB on CS2 */ | ||
| - | ranges = <0 0 0x08000000 0x02000000 | ||
| - | 1 0 0x0a000000 0x02000000 | ||
| - | 2 0 0x0c000000 0x02000000>; | ||
| - | /* FPGA on CS0 */ | ||
| - | fpga@0,0 { | ||
| - | compatible = " | ||
| - | reg = <0 0 0x00080000>; | ||
| - | # | ||
| - | # | ||
| - | bank-width = <2>; | ||
| - | fsl, | ||
| - | 0x00000000 0x04000040 0x00000000>; | ||
| - | }; | ||
| - | }; | ||
| - | </ | ||