background image

In MII mode, there are 18 signals defined by the IEEE 802.3 standard and supported by
the EMAC. MII, RMII modes uses a subset of the 18 signals. These signals are listed in
table below.

Table 27-1. Pin Usage in MII, RMII

Direction

EMAC Pin

Name

MII Usage

RMII Usage

RGMII Usage (i.MX 6SL cannot

support)

In/Out

FEC_MDIO

Management Data Input/Output Management Data

Input/output

Management Data Input/Output

Out

FEC_MDC

Management Data Clock

General output

Management Data Clock

Out

FEC_TXD[0]

Data out, bit 0

Data out, bit 0

Data out, bit 0

Out

FEC_TXD[1]

Data out, bit 1

Data out, bit 1

Data out, bit 1

Out

FEC_TXD[2]

Data out, bit 2

Not Used

Data out, bit 2

Out

FEC_TXD[3]

Data out, bit 3

Not Used

Data out, bit 3

Out

FEC_TX_EN

Transmit Enable

Transmit Enable

Transmit Enable

Out

FEC_TX_ER

Transmit Error

Not Used

Not Used

In

FEC_CRS

Carrier Sense

Not Used

Not Used

In

FEC_COL

Collision

Not Used

Not Used

In

FEC_TX_CLK

Transmit Clock

Not Used

Synchronous clock reference (REF_CLK,
can connect from PHY)

In

FEC_RX_ER

Receive Error

Receive Error

Not Used

In

FEC_RX_CLK

Receive Clock

Not Used

Synchronous clock reference (REF_CLK,
can connect from PHY)

In

FEC_RX_DV

Receive Data Valid

Receive Data Valid
and generate CRS

RXDV XOR RXERR on the falling edge
of FEC_RX_CLK.

In

FEC_RXD[0]

Data in, bit 0

Data in, bit 0

Data in, bit 0

In

FEC_RXD[1]

Data in, bit 1

Data in, bit 1

Data in, bit 1

In

FEC_RXD[2]

Data in, bit 2

Not Used

Data in, bit 2

In

FEC_RXD[3]

Data in, bit 3

Not Used

Data in, bit 3

The MII management interface consists of two pins, FEC_MDIO, and FEC_MDC. The
FEC hardware operation can be divided in the parts listed below. For detailed information
consult the i.MX 6SoloLite Multimedia Applications Processor Reference Manual.

• Transmission-The Ethernet transmitter is designed to work with almost no

intervention from software. Once ECR[ETHER_EN] is asserted and data appears in
the transmit FIFO, the Ethernet MAC is able to transmit onto the network. When the
transmit FIFO fills to the watermark (defined by the TFWR), the MAC transmit logic
asserts FEC_TX_EN and starts transmitting the preamble (PA) sequence, the start
frame delimiter (SFD), and then the frame information from the FIFO. However, the
controller defers the transmission if the network is busy (FEC_CRS asserts).

Hardware Operation

i.MX 6SoloLite Linux Reference Manual, Rev. L3.0.35_4.1.0, 09/2013

174

Freescale Semiconductor, Inc.

Содержание i.MX 6SoloLite Linux

Страница 1: ...i MX 6SoloLite Linux Reference Manual Document Number IMXL6SLRM Rev L3 0 35_4 1 0 09 2013 ...

Страница 2: ...i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 2 Freescale Semiconductor Inc ...

Страница 3: ...rdware Operation 28 3 2 2 Interrupt Software Operation 28 3 2 3 Interrupt Features 29 3 2 4 Interrupt Source Code Structure 29 3 2 5 Interrupt Programming Interface 29 3 3 Timer 30 3 3 1 Timer Software Operation 30 3 3 2 Timer Features 30 3 3 3 Timer Source Code Structure 31 3 3 4 Timer Programming Interface 31 3 4 Memory Map 31 3 4 1 Memory Map Hardware Operation 31 3 4 2 Memory Map Software Oper...

Страница 4: ... 6 2 GPIO Software Operation general 35 3 5 6 3 GPIO Implementation 35 3 5 6 4 GPIO Source Code Structure 36 3 5 6 5 GPIO Programming Interface 36 3 6 General Purpose Input Output GPIO 36 3 6 1 GPIO Software Operation 36 3 6 1 1 API for GPIO 37 3 6 2 GPIO Features 37 3 6 3 GPIO Module Source Code Structure 37 3 6 4 GPIO Programming Interface 2 38 Chapter 4 Smart Direct Memory Access SDMA API 4 1 O...

Страница 5: ...t Waveform File 47 5 3 4 2 Using a Custom Waveform File 48 5 3 5 EPDC Panel Initialization 48 5 3 6 Grayscale Framebuffer Selection 49 5 3 7 Enabling An EPDC Splash Screen 49 5 4 Source Code Structure 50 5 5 Menu Configuration Options 51 5 6 Programming Interface 51 5 6 1 IOCTLs Functions 52 5 6 2 Structures and Defines 55 Chapter 6 Sipix Display Controller SPDC Frame Buffer Driver 6 1 Introductio...

Страница 6: ...6 6 1 IOCTLs Functions 65 6 6 2 Structures and Defines 68 Chapter 7 Pixel Pipeline PxP DMA ENGINE Driver 7 1 Introduction 71 7 2 Hardware Operation 71 7 3 Software Operation 71 7 3 1 Key Data Structs 71 7 3 2 Channel Management 72 7 3 3 Descriptor Management 72 7 3 4 Completion Notification 72 7 3 5 Limitations 73 7 4 Menu Configuration Options 73 7 5 Source Code Structure 73 Chapter 8 ELCDIF Fram...

Страница 7: ...inition Multimedia Interface HDMI 10 1 Introduction 81 10 2 Software Operation 81 10 2 1 Hotplug Handling and Video Mode Changes 81 10 3 Source Code Structure 82 10 3 1 Linux Menu Configuration Options 83 10 4 Unit Test 83 10 4 1 Video 83 10 4 2 Audio 84 Chapter 11 X Windows Acceleration 11 1 Introduction 85 11 2 Hardware Operation 85 11 3 Software Operation 85 11 3 1 X Windows Acceleration Archit...

Страница 8: ...ns 96 12 5 Programming Interface 96 Chapter 13 OV5640 Using parallel interface 13 1 Hardware Operation 97 13 2 Software Operation 97 13 3 Source Code Structure 98 13 4 Linux Menu Configuration Options 98 Chapter 14 Low level Power Management PM Driver 14 1 Hardware Operation 99 14 1 1 Software Operation 99 14 1 2 Source Code Structure 100 14 1 3 Menu Configuration Options 100 14 1 4 Programming In...

Страница 9: ...ce Code Structure 110 16 2 Menu Configuration Options 110 16 2 1 Board Configuration Options 111 Chapter 17 Dynamic Voltage Frequency Scaling DVFS Driver 17 1 Introduction 113 17 1 1 Operation 113 17 1 2 Software Operation 113 17 1 3 Source Code Structure 114 17 2 Menu Configuration Options 114 17 2 1 Board Configuration Options 114 Chapter 18 Thermal Driver 18 1 Introduction 115 18 1 1 Thermal Dr...

Страница 10: ...erface Details 121 19 2 4 Source Code Structure 121 19 2 5 Menu Configuration Options 121 Chapter 20 SNVS Real Time Clock SRTC Driver 20 1 Introduction 123 20 1 1 Hardware Operation 123 20 2 Software Operation 123 20 2 1 IOCTL 123 20 2 2 Keeping Alive in the Power Off State 124 20 3 Driver Features 124 20 3 1 Source Code Structure 125 20 3 2 Menu Configuration Options 125 Chapter 21 Advanced Linux...

Страница 11: ...34 21 5 1 Stereo CODEC Unit Test 134 Chapter 22 SPI NOR Flash Memory Technology Device MTD Driver 22 1 Introduction 137 22 1 1 Hardware Operation 137 22 1 2 Software Operation 138 22 1 3 Driver Features 138 22 1 4 Source Code Structure 138 22 1 5 Menu Configuration Options 139 Chapter 23 MMC SD SDIO Host Driver 23 1 Introduction 141 23 1 1 Hardware Operation 141 23 1 2 Software Operation 142 23 2 ...

Страница 12: ...51 24 3 1 Source Code Structure 152 24 3 2 Menu Configuration Options 152 24 3 3 Programming Interface 152 24 3 4 Interrupt Requirements 152 Chapter 25 Enhanced Configurable Serial Peripheral Interface ECSPI Driver 25 1 Introduction 155 25 1 1 Hardware Operation 155 25 2 Software Operation 156 25 2 1 SPI Sub System in Linux 156 25 2 2 Software Limitations 157 25 2 3 Standard Operations 157 25 2 4 ...

Страница 13: ...ble USB WakeUp System Ability 169 26 3 3 WakeUp Events Supported by USB 170 26 3 4 How to Close the USB Child Device Power 171 Chapter 27 Fast Ethernet Controller FEC Driver 27 1 Introduction 173 27 2 Hardware Operation 173 27 2 1 Software Operation 176 27 2 2 Source Code Structure 176 27 2 3 Menu Configuration Options 176 27 3 Programming Interface 177 27 3 1 Device Specific Defines 177 27 3 2 Ge...

Страница 14: ...nts 183 Chapter 29 Pulse Width Modulator PWM Driver 29 1 Introduction 185 29 1 1 Hardware Operation 185 29 1 2 Clocks 186 29 1 3 Software Operation 187 29 1 4 Driver Features 187 29 1 5 Source Code Structure 187 29 1 6 Menu Configuration Options 188 Chapter 30 Watchdog WDOG Driver 30 1 Introduction 189 30 1 1 Hardware Operation 189 30 1 2 Software Operation 189 30 2 Generic WDOG Driver 190 30 2 1 ...

Страница 15: ...ture Specific Components 194 31 2 2 oprofilefs Pseudo Filesystem 195 31 2 3 Generic Kernel Driver 195 31 2 4 OProfile Daemon 195 31 2 5 Post Profiling Tools 196 31 3 Requirements 196 31 3 1 Source Code Structure 196 31 3 2 Menu Configuration Options 196 31 3 3 Programming Interface 197 31 3 4 Interrupt Requirements 197 i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semic...

Страница 16: ...i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 16 Freescale Semiconductor Inc ...

Страница 17: ...le and directory names Italic type indicates replaceable command or function parameters Bold type indicates function names 1 1 2 Definitions Acronyms and Abbreviations The following table defines the acronyms and abbreviations used in this document Definitions and Acronyms Term Definition ADC Asynchronous Display Controller address translation Address conversion from virtual domain to physical dom...

Страница 18: ...FIFO First In First Out FIPS Federal Information Processing Standards United States Government technical standards published by the National Institute of Standards and Technology NIST NIST develops FIPS when there are compelling Federal government requirements such as for security and interoperability but no acceptable industry standards FIPS 140 Security requirements for cryptographic modules Fed...

Страница 19: ... Card International Association a multi company organization that has developed a standard for small credit card sized devices called PC Cards There are three types of PCMCIA cards that have the same rectangular size 85 6 by 54 millimeters but different widths physical address The address by which the memory in the system is physically accessed PLL Phase Locked Loop an electronic circuit controlli...

Страница 20: ...iversal Serial Bus an external bus standard that supports high speed data transfers The USB 1 1 specification supports data transfer rates of up to 12 Mb s and USB 2 0 has a maximum transfer rate of 480 Mbps A single USB port can be used to connect up to 127 peripheral devices such as mice modems and keyboards USB also supports Plug and Play installation and hot plugging USBOTG USB On The Go an ex...

Страница 21: ...It does not contain all of the product specific drivers hardware independent software stacks Graphical User Interface GUI components Java Virtual Machine JVM and applications required for a product Some of these are made available in their original open source form as part of the base kernel The BSP is not intended to be used for silicon verification While it can play a role in this the BSP functi...

Страница 22: ...hanges are centralized in the GPIO module so that changes are not required in the various drivers SPBA The Shared Peripheral Bus Arbiter SPBA provides an arbitration mechanism among multiple masters to allow access to the shared peripherals The SPBA implementation under MSL defines the API to allow different masters to take or release ownership of a shared peripheral Machine Specific Layer MSL All...

Страница 23: ... a high performance low cost solution for SiPix EPDs Electronic Paper Display Sipix Display Controller SPDC Frame Buffer i MX 6SoloLite PxP The Pixel Pipeline PxP DMA ENGINE driver provides a unique API which are implemented as a dmaengine client that smooths over the details of different hardware offload engine implementations PXP DMA ENGINE Driver i MX 6SoloLite Sound Drivers ALSA Sound The Adva...

Страница 24: ...ite MMC SD SDIO uSDHC The MMC SD SDIO Host driver implements the standard Linux driver interface to eSDHC MMC SD SDIO Host Driver i MX 6SoloLite UART Drivers MXC UART The Universal Asynchronous Receiver Transmitter UART driver interfaces the Linux serial driver API to all of the UART ports A kernel configuration parameter gives the user the ability to choose the UART driver and also to choose whet...

Страница 25: ... driver will monitor the SoC s temperature in a certain frequency It defines three trip points critical hot and active Thermal Driver i MX 6SoloLite OProfile OProfile is a system wide profiler for Linux systems capable of profiling all running code at low overhead OProfile i MX 6SoloLite Chapter 2 Introduction i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor ...

Страница 26: ...Overview i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 26 Freescale Semiconductor Inc ...

Страница 27: ...ntains not only the modules common to all the boards using the same processor such as the interrupts and timer but it also contains modules specific to each board such as the memory map The following sections describe the basic hardware and software operations and the software interfaces for MSL modules First the common modules such as Interrupts and Timer are discussed Next the board specific mod...

Страница 28: ...ity There are 16 normal interrupt levels for all interrupt sources with level zero being the lowest priority The interrupt levels are configurable through eight normal interrupt priority level registers Those registers along with the Normal Interrupt Mask Register support software controlled priority levels for normal interrupts and priority masking 3 2 2 Interrupt Software Operation For ARM based...

Страница 29: ...ng of this chapter hardware h irqs h The following table lists the source files for interrupts Table 3 1 Interrupt Files File Description hardware h Register descriptions irqs h Declarations for number of interrupts supported gic c Actual interrupt functions for GIC modules 3 2 5 Interrupt Programming Interface The machine specific interrupt implementation exports a single function This function i...

Страница 30: ...e statistics The timer hardware on most i MX platforms consists of either Enhanced Periodic Interrupt Timer EPIT or general purpose timer GPT or both GPT is configured to generate a periodic interrupt at a certain interval every 10 ms and is used by the Linux kernel 3 3 1 Timer Software Operation The timer software implementation provides an initialization function that initializes the GPT with th...

Страница 31: ...ng of this chapter 3 4 Memory Map A predefined virtual to physical memory map table is required for the device drivers to access to the device registers since the Linux kernel is running under the virtual address space with the Memory Management Unit MMU enabled 3 4 1 Memory Map Hardware Operation The MMU as a part of the ARM core provides the virtual to physical address mapping defined by the pag...

Страница 32: ...he Memory Map is implemented in the mm c file to provide the map between physical and virtual addresses It defines an initialization function to be called during system startup 3 5 IOMUX The limited number of pins of highly integrated processors can have multiple purposes The IOMUX module controls a pin usage so that the same pin can be configured for different purposes and can be used by differen...

Страница 33: ...errupting the ARM core it should be configured as GPIO input pin with interrupt enabled The software does not have control over what function a pin should have The software only configures pin usage according to the system design 3 5 1 IOMUX Hardware Operation The following information applies only to those processors that have an IOMUX hardware module The IOMUX controller registers are briefly de...

Страница 34: ...mplemented in the iomux v3 c file 3 5 6 IOMUX Control Through GPIO Module For a multi purpose pin the GPIO controller provides the multiplexing control so that each pin may be configured either as a functional pin or a GPIO pin The operation of the functional pin which can be subdivided into either major function or one alternate function is controlled by a specific hardware module If it is config...

Страница 35: ... to the system design 3 5 6 1 GPIO Hardware Operation The GPIO controller module is divided into MUX control and PULLUP control sub modules The following sections briefly describe the hardware operation For detailed information refer to the relevant device documentation 3 5 6 1 1 Muxing Control The GPIO In Use Registers control a multiplexer in the GPIO module The settings in these registers choos...

Страница 36: ...All the GPIO muxing functions required for the Linux port are implemented in the iomux v3 c file 3 6 General Purpose Input Output GPIO The GPIO module provides general purpose pins that can be configured as either inputs or outputs When configured as an output the pin state high or low can be controlled by writing to an internal register When configured as an input the pin input state can be read ...

Страница 37: ...ned by NR_IRQS is expanded to accommodate all the possible GPIO pins that are capable of generating interrupts Functions to request and free an IOMUX pin If a pin is used as GPIO another set of request free function calls are provided The user should check the return value of the request calls to see if the pin has already been reserved before modifying the pin state The free function calls should...

Страница 38: ...les File Description iomux mx 6sl h IOMUX common header file gpio h GPIO public header file gpio c Function implementation 3 6 4 GPIO Programming Interface 2 For more information see the Documentation gpio txt under the Linux source code directory for the programming interface General Purpose Input Output GPIO i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 38 Freescale Semiconduct...

Страница 39: ...e SDMA controller is responsible for transferring data between the MCU memory space and peripherals It has the following features Multi channel DMA supporting up to 32 time division multiplexed DMA channels Powered by a 16 bit Instruction Set micro RISC engine Each channel executes specific script Very fast context switching with two level priority based preemptive multi tasking 4 KB ROM containin...

Страница 40: ...annel 1 Upon finding a free channel that channel is allocated for the requested DMA transfers Table 4 1 SDMA Channel Usage Driver Name Number of SDMA Channels SDMA Channel Used SDMA CMD 1 Static Channel allocation uses SDMA channels 0 SSI 2 per device Dynamic channel allocation UART 2 per device Dynamic channel allocation SPDIF 2 per device Dynamic channel allocation ESAI 2 per device Dynamic chan...

Страница 41: ...tion option for the SDMA API driver In menuconfig this option is available under DMA Engine support 4 1 5 Programming Interface The module implements standard DMA API For more information on the functions implemented in the driver refer to the API documents which are included in the Linux documentation package For additional information refer to the ESAI driver 4 1 6 Usage Example Refer to one of ...

Страница 42: ...Overview i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 42 Freescale Semiconductor Inc ...

Страница 43: ...upport for EPDC driver as a loadable or built in module Support for RGB565 and Y8 frame buffer formats Support for full and partial EPD screen updates Support for up to 256 panel specific waveform modes Support for automatic optimal waveform selection for a given update Support for synchronization by waiting for a specific update request to complete Support for screen updates from an alternate ove...

Страница 44: ...Driver Overview The frame buffer device provides an abstraction for the graphics hardware It represents the frame buffer video hardware and allows application software to access the graphics hardware through a well defined interface so that the software is not required to know anything about the low level hardware registers The EPDC driver supports this model with one key caveat the contents of th...

Страница 45: ...g screen update latencies between 300 980ms which introduces the need for a mechanism to allow the user to wait for a given screen update to complete The custom API extensions to the frame buffer device are accessible both from user space applications and from within kernel space The standard device IOCTL interface provides access to the custom API for user space applications The IOCTL extensions ...

Страница 46: ...c_epdc_fb_mode epdc_mode int num_modes void get_pins void void put_pins void void enable_pins void void disable_pins void In addition to the EPDC panel mode data functions may be passed to the EPDC driver to define how to handle the EPDC pins when the EPDC driver is enabled or disabled These functions should disable the EPDC pins for purposes of power savings 5 3 3 1 Boot Command Line Parameters A...

Страница 47: ... a non panel specific waveform file for an E Ink panel results in more ghosting artifacts and overall poorer color quality The following default waveform files included in the BSP reside in firmware imx epdc_E60_V110 fw Default waveform for the 6 0 inch V110 E Ink panel epdc_E60_V220 fw Default waveform for the 6 0 inch V220 E Ink panel supports animation mode updates epdc_E97_V110 fw Default wave...

Страница 48: ...ng firmware sh You ll need to create an imx directory in one of these paths and add your new epdc_ panel_name fw file there NOTE If the EPDC driver is searching for a firmware waveform file that matches the names of one of the default waveform files see preceding chapter it will choose the default firmware files that are built into the BSP over any firmware file that has been added in the firmware...

Страница 49: ... the framebuffer format There are two key members of the fb_var_screeninfo parameter that must be set in order to request a change to 8 bit grayscale format bits_per_pixel and grayscale bits_per_pixel must be set to 8 and grayscale must be set to one of the 2 valid grayscale format values GRAYSCALE_8BIT or GRAYSCALE_8BIT_INVERTED The following code snippet demonstrates a request to change the fram...

Страница 50: ... seek 6144 5 4 Source Code Structure Table below lists the source files associated with the EPDC driver These files are available in the following directory drivers video mxc Table 5 1 EPDC Driver Files File Description mxc_epdc_fb c The EPDC frame buffer driver epdc_regs h Register definitions for the EPDC module Table below lists the global header files associated with the EPDC driver These file...

Страница 51: ...uto update mode requires an additional IOCTL call using the MXCFB_SET_AUTO_UPDATE_MODE IOCTL CONFIG_FB to include frame buffer support in the Linux kernel In menuconfig this option is available under Device Drivers Graphics support Support for frame buffer devices By default this option is Y for all architectures CONFIG_FB_MXC is a configuration option for the MXC Frame buffer driver This option i...

Страница 52: ...alues for common waveform modes These values must be configured in order for automatic waveform mode selection to function properly MXCFB_SET_TEMPERATURE mxc_epdc_fb_set_temperature Description Set the temperature to be used by the EPDC driver in subsequent panel updates Parameters int32_t temperature Temperature value in degrees Celsius Note that this temperature setting may be overridden by sett...

Страница 53: ...ronously handle the processing and submission of all updates When an update is submitted via MXCFB_SEND_UPDATE the update is added to the queue and then processed in order as EPDC hardware resources become available As a result the framebuffer contents processed and updated are not guaranteed to reflect what was present in the framebuffer when the update was sent to the driver UPDATE_SCHEME_QUEUE_...

Страница 54: ...ate request to complete Parameters mxfb_update_marker_data marker_data The update_marker value used to identify a particular update passed as a parameter in MXCFB_SEND_UPDATE IOCTL call should be re used here to wait for the update to complete If the update was a collision test update the collision_test variable will return the result indicating whether a collision occurred MXCFB_SET_PWRDOWN_DELAY...

Страница 55: ...tarting Y coordinate for update region __u32 width Width of update region __u32 height Height of update region struct mxcfb_waveform_modes int mode_init INIT waveform mode int mode_du DU waveform mode int mode_gc4 GC4 waveform mode int mode_gc8 GC8 waveform mode int mode_gc16 GC16 waveform mode int mode_gc32 GC32 waveform mode struct mxcfb_alt_buffer_data __u32 phys_addr physical address of altern...

Страница 56: ...rrent update struct mxcfb_alt_buffer_data alt_buffer_data Alternate buffer data struct mxcfb_update_marker_data __u32 update_marker __u32 collision_test Programming Interface i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 56 Freescale Semiconductor Inc ...

Страница 57: ...adable or built in module Support for RGB565 and Y4 frame buffer formats Support 800x600 resolution Support for full and partial EPD screen updates Support for automatic optimal waveform selection for a given update Support for synchronization by waiting for a specific update request to complete Support for screen updates from an alternate overlay buffer Support for 90 180 and 270 degree HW accele...

Страница 58: ...ware is not required to know anything about the low level hardware registers The SPDC driver supports this model with one key caveat the contents of the frame buffer are not automatically updated to the Sipix display Instead a custom API function call is required to trigger an update to the Sipix display The details of this process are explained in SPDC Frame Buffer Driver Extensions The frame buf...

Страница 59: ...rame buffer device are accessible both from user space applications and from within kernel space The standard device IOCTL interface provides access to the custom API for user space applications The IOCTL extensions along with relevant data structures and definitions can be found in include linux mxcfb h A full description of these IOCTLs can be found in the Programming Interface section Programmi...

Страница 60: ...r is enabled or disabled These functions should disable the SPDC pins for purposes of power savings 6 3 3 1 Boot Command Line Parameters Additional configuration for the SPDC driver is provided through boot command line parameters The format of the command line option is as follows spdc video mxcspdcfb panel_name bpp 16 The SPDC driver parses these options and tries to match panel_name to the name...

Страница 61: ...he SPDC driver attempts to load a waveform file with the name imx spdc_ wave_timing fw where wave_timing refers to the string specified in the imx_spdc_fb_mode wave_timing field 6 3 4 2 Using a Custom Waveform File To ensure the optimal Sipix display quality use a waveform file specific to Sipix panel being used The raw waveform file type requires conversion to a format that can be understood and ...

Страница 62: ...ected over a new waveform file placed in the firmware search path 6 3 5 SPDC Panel Initialization The framebuffer driver will not typically see note below for exceptions go through any hardware initialization steps when the framebuffer driver module is loaded Instead a subsequent user mode call must be made to request that the driver initialize itself for a specific EPD panel To initialize the SPD...

Страница 63: ...4BIT_INVERTED The following code snippet demonstrates a request to change the framebuffer to use the Y4 pixel format fb_screen_info screen_info screen_info bits_per_pixel 4 screen_info grayscale GRAYSCALE_4BIT retval ioctl fd_fb0 FBIOPUT_VSCREENINFO screen_info 6 4 Source Code Structure Table below lists the source files associated with the SPDC driver These files are available in the following di...

Страница 64: ...an additional IOCTL call using the MXCFB_SET_AUTO_UPDATE_MODE IOCTL CONFIG_FB is the configuration option to include frame buffer support in the Linux kernel In menuconfig this option is available under Device Drivers Graphics support Support for frame buffer devices By default this option is Y for all architectures CONFIG_FB_MXC is the configuration option for the MXC Frame buffer driver This opt...

Страница 65: ...eform modes These values must be configured in order for automatic waveform mode selection to function properly MXCFB_SET_TEMPERATURE mxc_spdc_fb_set_temperature Description Set the temperature to be used by the SPDC driver in subsequent panel updates Parameters int32_t temperature Temperature value in degrees Celsius Note that this temperature setting may be overridden by setting the temperature ...

Страница 66: ... submission of all updates When an update is submitted via MXCFB_SEND_UPDATE the update is added to the queue and then processed in order as SPDC hardware resources become available As a result the framebuffer contents processed and updated are not guaranteed to reflect what was present in the framebuffer when the update was sent to the driver UPDATE_SCHEME_QUEUE_AND_MERGE The Queue and Merge sche...

Страница 67: ...lete Parameters mxfb_update_marker_data marker_data The update_marker value used to identify a particular update passed as a parameter in MXCFB_SEND_UPDATE IOCTL call should be re used here to wait for the update to complete If the update was a collision test update the collision_test variable will return the result indicating whether a collision occurred MXCFB_SET_PWRDOWN_DELAY mxc_spdc_fb_set_pw...

Страница 68: ...n __u32 width Width of update region __u32 height Height of update region struct mxcfb_waveform_modes int mode_init INIT waveform mode int mode_du DU waveform mode int mode_gc4 GC4 waveform mode int mode_gc8 GC8 waveform mode int mode_gc16 GC16 waveform mode int mode_gc32 GC32 waveform mode struct mxcfb_alt_buffer_data __u32 phys_addr physical address of alternate image buffer __u32 width width of...

Страница 69: ...lternate buffer data struct mxcfb_update_marker_data __u32 update_marker __u32 collision_test Chapter 6 Sipix Display Controller SPDC Frame Buffer Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 69 ...

Страница 70: ...Programming Interface i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 70 Freescale Semiconductor Inc ...

Страница 71: ...erence Manual 7 3 Software Operation 7 3 1 Key Data Structs The PxP DMA Engine driver implementation depends on the DMA Engine Framework There are three important structs in the DMA Engine Framework which are extended by the PxP driver struct dma_device struct dma_chan struct dma_async_tx_descriptor The PxP driver implements several callback functions which are called by the DMA Engine Framework o...

Страница 72: ...rdware 16 virtual channels are supported in the driver this provides flexibility in the multiple instance client design At any time a user can call dma_request_channel to get a free channel and then configure this channel with several descriptors a descriptor is required for each input plane and for the output plane When the PxP is no longer being used the channel should be released by calling dma...

Страница 73: ...d Instead of using the scatterlist parameter object to provide a chain of memory sources and destinations the driver currently uses it to provide the input and output buffers and overlay buffers if needed for one transfer The PxP driver may not properly execute a series of transfers that is queued in rapid sequence It is recommended to wait for each transfer to complete before submitting a new one...

Страница 74: ...Source Code Structure i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 74 Freescale Semiconductor Inc ...

Страница 75: ...y referring to the existing one 8 2 Hardware Operation For detailed hardware operation please refer to the i MX 6SoloLite Multimedia Applications Processor Reference Manual 8 3 Software Operation A frame buffer device is a memory device similar to dev mem and it has the same features It can be read from written to or some location in it can be sought and maped using mmap The difference is that the...

Страница 76: ...EL Y N M CONFIG_FB_MXC_ELCDIF_FB Y N M Configuration option to compile support for the MXC ELCDIF frame buffer driver into the kernel 8 5 Source Code Structure The frame buffer driver source code is in drivers video mxc mxc_elcdif_fb c The panel support code is located in drivers video mxc mxcfb_claa_wvga c and drivers video mxc mxcfb_seiko_wvga c The frame buffer driver includes the source header...

Страница 77: ... but the libs are delivered as binary only 9 1 1 Driver Features The GPU driver enables this board to provide the following software and hardware support EGL EGL is an interface between Khronos rendering APIs such as OpenGL ES or OpenVG and the underlying native platform window system 1 4 API defined by Khronos Group OpenVG OpenVG is a royalty free cross platform API that provides a low level hard...

Страница 78: ...module source structure ltib_dir rpm BUILD linux drivers mxc gpu viv Table 9 1 GPU Driver Files File Description Kconfig Kbuild config kernel configure file and makefile arch XAQ2 hal kernel hardware specific driver code for and GC320 arch GC350 hal kernel hardware specific driver code for GC350 hal kernel Kernel mode HAL driver hal os os layer HAL driver 9 1 1 4 Library Structure Table below list...

Страница 79: ...1 These libraries are actually symbolic links to the actual library file in the folder By default these symbolic links are installed to point to the frame buffer version of the libraries as such libGAL so libGAL fb so libEGL so libEGL fb so libVIVANTE so libVIVANTE fb so On X11 systems the symbolic links to these libraries need to be redirected This can be done using the following sequence of comm...

Страница 80: ...MXC Vivante GPU support MXC Vivante GPU support To get to the GPU library package in LTIB use the command ltib c when located in the ltib dir On the displayed screen select Configure the kernel select Device Drivers MXC support drivers MXC Vivante GPU support MXC Vivante GPU support and then exit When the next screen appears select the following options to enable the GPU driver Package list gpu vi...

Страница 81: ...olutions Support for reading EDID information from an HDMI sink device for video Hotplug detection HDMI audio playback 2 channels 16 24bit 44 1KHz sample rate 10 2 Software Operation The HDMI driver is divided into sub components based on its two primary purposes providing video and audio to an HDMI sink device The audio output depends on video display 10 2 1 Hotplug Handling and Video Mode Change...

Страница 82: ...de 4 Finally the HDMI module is enabled to generate output to the HDMI sink device 10 3 Source Code Structure The bulk of the source code for the HDMI driver is divided amongst the three software components that comprise the driver the HDMI display driver and the HDMI audio driver The source code for the HDMI display driver is available in the ltib_dir rpm BUILD linux drivers video mxc directory T...

Страница 83: ...io support for IMX S PDIF 10 4 Unit Test The HDMI video and audio drivers each have their own set of tests The preparation for HDMI test Insert the HDMI daughter card into J13 on EVK Insert the HDMI cable into the HDMI slots of both HDMI daughter board and the HDMI sink device Power on the HDMI sink device 10 4 1 Video The following set of manual tests can be used to verify the proper operation of...

Страница 84: ...er 10 4 2 Audio The following sequence of tests verifies the correct operation of the HDMI audio driver 1 Ensure that an HDMI cable is connected between the HDMI daughter board and the HDMI sink device and that the HDMI video image is being properly displayed on the device 2 Use this command line to play out a pcm audio file file wav to HDMI sink device aplay Dplughw 1 0 file wav Unit Test i MX 6S...

Страница 85: ...tions are accelerated for X Windows System 11 2 Hardware Operation X Windows System acceleration on i MX 6 uses the Vivante GC320 2D GPU Acceleration is also dependent on the frame buffer memory 11 3 Software Operation X Windows acceleration is supported by X org X Server version 1 7 6 and later versions as well as the EXA interface version 2 5 The types of operations that are accelerated for X11 ...

Страница 86: ... be allocated directly in frame buffer memory 11 3 1 X Windows Acceleration Architecture The following block diagram shows the components that are involved in the acceleration of X Windows System Figure 11 1 X Driver Architecture The components shown in green are those provided as part of the Vivante 2D 3D GPU driver support which includes OpenGL ES and EGL though some of the families in the i MX ...

Страница 87: ... of the X server in providing acceleration The implementation details are as follows The implementation builds upon the source from the fbdev frame buffer driver for X so that it can be the fallback when the acceleration is disabled The implementation is based on X server EXA version 2 5 0 The EXA solid fill operation is accelerated except for source target drawables containing less than 1024x1024...

Страница 88: ...GPU accelerated option The number of pitch bytes used to access the pixmap memory may be different depending on whether it was allocated from GPU accessible memory or from the system Once the memory for X pixmap has been allocated no matter it is from GPU accessible memory or from the system the pixmap is locked and can never migrate to other type of memory Pixmap migration from GPU accessible mem...

Страница 89: ...dentifier Configured Monitor EndSection Section Screen Identifier Default Screen Monitor Configured Monitor Device i MX Accelerated Framebuffer Device EndSection Section ServerLayout Identifier Default Layout Screen Default Screen EndSection Some important entries recognized by the i MX X Driver are described as follows Device Identifier and Screen Device String The mandatory Identifierentry in th...

Страница 90: ...debian packages are only available for ubuntu root fs There s no gpu driver for X11 on gnome mobile root fs or LTIB Package installation and verification Verify that the following packages are available and installed gpu viv bin mx6q_ bsp version _armel deb This package contains gpu driver develop headers and is installed in the usr include folder This package contains gpu driver hal librarylibGAL...

Страница 91: ...lor 33 881 VIVANTE 0 Using gamma correction 1 0 1 0 1 0 33 881 II VIVANTE 0 hardware mxc_elcdif_fb video memory 2250kB 33 882 II VIVANTE 0 checking modes against framebuffer device 33 882 II VIVANTE 0 checking modes against monitor 33 882 VIVANTE 0 Virtual size is 800x480 pitch 800 33 882 VIVANTE 0 Built in mode current 33 5 MHz 31 2 kHz 58 6 Hz 33 882 II VIVANTE 0 Modeline current x0 0 33 50 800 ...

Страница 92: ...Software Operation i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 92 Freescale Semiconductor Inc ...

Страница 93: ... pixel or 16 bit pixel data format to 32 bit receive FIFO packing 128X32 FIFO to store received image pixel data Receive FIFO overrun protection mechanism Embedded DMA controllers to transfer data from receive FIFO or statistic FIFO through AHB bus Support for double buffering two frames in the external memory Single interrupt source to interrupt controller from maskable interrupt sources Start of...

Страница 94: ...camera sends the data to the CSI receive FIFO through the 8 bit 10 bit data port 2 The embedded DMA controllers transfer data from the receive FIFO to external memory through the AHB bus 3 The data is saved to the user space memory or exported to the frame buffer directly 12 2 2 1 V4L2 Capture Device V4L2 capture support can be selected during kernel configuration The driver for this device is in ...

Страница 95: ...user space 5 Queue the buffer by using the IOCTL command VIDIOC_QBUF 6 Start the stream by executing IOCTL VIDIOC_STREAMON 7 Execute the IOCTL VIDIOC_DQBUF 8 Pass the data that requires post processing to the buffer 9 Queue the buffer by using the IOCTL command VIDIOC_QBUF 10 Go to step 7 11 Stop the queuing by using the IOCTL command VIDIOC_STREAMOFF 12 3 Source Code Structure The following table...

Страница 96: ...edia support Video capture adapters MXC Video For Linux Camera MXC Camera V4L2 PRP Features support By default this option is enabled MXC_CAMERA_OV5640 Option for the OV5640 sensor driver In menuconfig this option is available under Device Drivers Multimedia support Video capture adapters MXC Video For Linux Camera MXC Camera V4L2 PRP Features support By default this option is enabled 12 5 Program...

Страница 97: ...camera and starting the camera preview The OV5640 uses the serial camera control bus SCCB interface to control the sensor operation It works as an I2C client V4L2 driver uses I2C bus to control camera operation OV5640 supports only parallel interface Refer to OV5640 datasheet to get more information on the sensor Refer to the i MX 6 Multimedia Applications Processor Reference Manual for more infor...

Страница 98: ...inux Menu Configuration Options The following Linux kernel configuration option is provided for this module To get to this option use the ltib c command when located in the ltib dir On the displayed screen select Configure the Kernel and exit When the next screen appears select the following option to enable this module Device Drivers Multimedia devices Video capture adapters MXC Video For Linux C...

Страница 99: ...On On On STOP Disable Disable Off Off On DORMANT Power off Disable Off Off On For the detailed information about lower power modes see the i MX 6SoloLite Multimedia Applications Processor Reference Manual IMX6SLRM 14 1 1 Software Operation The i MX 6 PM driver maps the low power modes to the kernel power management states as follows Standby maps to STOP mode that offers significant power saving as...

Страница 100: ...it mode 4 Execute mx6_do_suspend in IRAM 5 If it is in DORMANT mode save the ARM context change the drive strength of MMDC PADs to low to minimize the power leakage in DDR PADs Execute WFI pending instructions for stop mode 6 Generate a wakeup interrupt and exit low power mode If it is in DORMANT mode restore the ARM core and DDR drive strength In DORMANT and STOP mode the i MX 6 can assert the VS...

Страница 101: ...terface The mxc_cpu_lp_set API in the system c function is provided for low power modes This implements all the steps required to put the system into WAIT and STOP modes 14 1 5 Unit Test To enter different system level low power modes echo mem sys power state echo standby sys power state To wake up system from low power modes enable wake up source first USB device debug uart or RTC etc can be used...

Страница 102: ...Hardware Operation i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 102 Freescale Semiconductor Inc ...

Страница 103: ...de the power supply to processor cores and to other low voltage circuits such as memory Dynamic voltage scaling is provided to allow controlled supply rail adjustments for the processor cores and other circuitry Linear regulators are directly supplied from the battery or from the switchers including supplies for I O and peripherals audio camera BT and WLAN Naming conventions are suggestive of typi...

Страница 104: ...hanges that use the power management driver and the regulator client driver can affect the operation or stability of the entire system 15 3 1 Regulator APIs The regulator power architecture is designed to provide a generic interface to voltage and current regulators within the Linux kernel It is intended to provide voltage and current control to client or consumer drivers and to provide status inf...

Страница 105: ...is_enabled is the regulator output enabled int regulator_is_enabled struct regulator regulator regulator_set_voltage is an unified API call to set regulator output voltage int regulator_set_voltage struct regulator regulator int uV regulator_get_voltage is an unified API call to get regulator output voltage int regulator_get_voltage struct regulator regulator You can find more APIs and details in ...

Страница 106: ...ture of the PF100 regulator driver Regulator core driver PF100 regulator driver PF100 core driver MFD I2C or SPI driver Device drivers PF100 driver Driver Architecture i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 106 Freescale Semiconductor Inc ...

Страница 107: ...sign Therefore you cannot find the kernel by using PF100 regulators The PF100 regulator driver has implemented these regulators so that customers can use it freely if default PF100 value can t meet their hardware design 15 4 2 Source Code Structure The PF100 regulator driver is located in the regulator device driver directory ltib_dir rpm BUILD linux drivers regulator Table 15 1 PF100 core Driver ...

Страница 108: ...ation screen select Configure Kernel and then exit When the next screen appears choose the following Device Drivers Voltage and Current regulator support Support regulators on Freescale PF100 PMIC Driver Architecture i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 108 Freescale Semiconductor Inc ...

Страница 109: ... nearest higher frequency in the array The frequencies are manipulated using the clock framework API while the voltage is set using the regulators API The CPU frequencies in the array are based on the boot CPU frequency which can be changed by using the clock command in U Boot By default the conservative CPU frequency governor is used Refer to the API document for more information on the functions...

Страница 110: ...frequency governor echo interactive sys devices system cpu cpu0 cpufreq scaling_governor 16 1 2 Source Code Structure Table below shows the source files and headers available in the following directory ltib_dir rpm BUILD linux arch arm plat mxc Table 16 1 CPUFREQ Driver Files File Description cpufreq c CPUFREQ functions For CPU frequency working point settings see arch arm mach mx6 cpu_op mx6 c 16...

Страница 111: ...nor for userspace frequency scaling Interactive CPU frequency policy governor Conservative CPU frequency governor CPU frequency driver for i MX CPUs 16 2 1 Board Configuration Options There are no board configuration options for the CPUFREQ device driver Chapter 16 CPU Frequency Scaling CPUFREQ Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 111 ...

Страница 112: ...Menu Configuration Options i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 112 Freescale Semiconductor Inc ...

Страница 113: ...s operating frequency of the system clocks like AHB DDR AXI etc based on peripheral activity and CPU loading 17 1 2 Software Operation The bus frequency depends on the usecount of the various clocks in the system for its operation Drivers enable disable their clocks based on peripheral activity Every peripheral is associated with a frequency setpoint The bus frequency will set the system frequency...

Страница 114: ... 17 1 3 Source Code Structure Table below lists the source files and headers available in the following directory ltib_dir rpm BUILD linux arch arm mach mx6 Table 17 1 BusFrequency Driver Files File Description bus_freq c Bus Frequency functions mx6_mmdc c mx6_ddr_freq S mx6sl_ddr S DDR frequency change functions 17 2 Menu Configuration Options There are no menu configuration options for this driv...

Страница 115: ...e all the cooling actions Thermal driver has two parts Thermal zone defines trip points and monitors the SoC s temperature Cooling device takes the actions according to different trip points 18 1 1 Thermal Driver Overview The thermal driver implements the SoC temperature monitoring function and protection It creates a system file interface of sys class thermal thermal_zone0 for user Internally the...

Страница 116: ... 3 1 Source Code Structure Table below shows the driver source files available in the directory ltib_dir rpm BUILD linux drivers mxc thermal Table 18 1 Thermal Driver Files File Description thermal c thermal zone driver source file cooling c cooling device source file 18 3 2 Menu Configuration Options The following Linux kernel configuration option is provided for this module To get to this option...

Страница 117: ...e0 trip_point_x_temp Here x can be 0 1 and 2 indicating critical hot and active trip point and the value of trip points should be critical hot active Then run some program to make SoC in heavy loading When the SoC temperature reaches the trip points the thermal driver will take action to do some protections according to each trip point s mechanism Restore the trip point s temperature When SoC temp...

Страница 118: ...Unit Test i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 118 Freescale Semiconductor Inc ...

Страница 119: ...nal load interconnection and requirements Using seven LDO regulators the number of external supplies is greatly reduced If the backup coin and USB inputs are neglected the number of external supplies is reduced to two Missing from this external supply total are the necessary external supplies to power the desired memory interface This will change depending on the type of external memory selected O...

Страница 120: ...n is to allow systems to dynamically control regulator output to save power and prolong battery life This applies to both voltage regulators where voltage output is controllable and current sinks where current output is controllable For more details visit http opensource wolfsonmicro com node 15 Under this framework most power operations can be done by the following unified API calls regulator_get...

Страница 121: ...Anatop hardware registers 19 2 4 Source Code Structure The Anatop regulator driver is located in the regulator device driver directory ltib_dir rpm BUILD linux drivers regulator Table 19 1 Anatop Power Management Driver Files File Description core c Linux kernel interface for regulators anatop regulator c Implementation of the Anatop regulator client driver 19 2 5 Menu Configuration Options To get...

Страница 122: ...Driver Features i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 122 Freescale Semiconductor Inc ...

Страница 123: ...ith enhanced security capabilities It provides an accurate and constant time regardless of the main system power state and without the need to use an external on board time source such as an external RTC The SRTC can wake up the system when a preset alarm threshold is reached 20 2 Software Operation The following sections describe the software operation of the SRTC driver 20 2 1 IOCTL The SRTC dri...

Страница 124: ...ain active Usually these signals are connected to the PMIC and software can configure the PMIC registers to enable the SRTC clock source and power supply Generally when the main battery is removed and the device is in power off state a coin cell battery is used as a backup power supply To avoid SRTC time loss the voltage of the coin cell battery should be sufficient to power the SRTC If the coin c...

Страница 125: ... the SRTC function implementations 20 3 2 Menu Configuration Options To get to the SRTC driver use the command ltib c when located in the ltib dir On the displayed screen select Configure the kernel and exit When the next screen appears select the following options to enable the SRTC driver Device Drivers Real Time Clock Freescale SNVS Real Time Clock Chapter 20 SNVS Real Time Clock SRTC Driver i ...

Страница 126: ...Driver Features i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 126 Freescale Semiconductor Inc ...

Страница 127: ...SA System on Chip ASoC layer is designed for SoC audio The overall project goal of the ASoC layer provides better ALSA support for embedded system on chip processors and portable audio CODECs The ASoC layer also provides the following features CODEC independence allows reuse of CODEC drivers on other platforms and machines Easy I2S PCM audio interface setup between CODEC and SoC Each SoC interface...

Страница 128: ...ng using digital mute ASoC signals the CODEC when to change power states Machine specific controls allows machines to add controls to the sound card for example volume control for speaker amp ALSA Sound Driver Introduction i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 128 Freescale Semiconductor Inc ...

Страница 129: ...ASoC basically splits an embedded audio system into 3 components Chapter 21 Advanced Linux Sound Architecture ALSA System on a Chip ASoC Sound Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 129 ...

Страница 130: ...project org main index php ASoC 21 2 SoC Sound Card Currently the stereo CODEC wm8962 drivers are implemented by using SoC architecture These sound card drivers are built in independently The stereo sound card supports stereo playback and capture 21 2 1 Stereo CODEC Features The stereo CODEC supports the following features Sample rates for playback and capture are 8KHz 32 KHz 44 1 KHz 48 KHz and 9...

Страница 131: ...d provides the BCLK and LRCLK The BCLK and LRCLK can be configured according to the audio sample rate The WM8962 ASoC CODEC driver exports the audio record playback mixer APIs according to the ASoC architecture The CODEC driver is generic and hardware independent code that configures the CODEC to provide audio capture and playback It does not contain code that is specific to the target platform or...

Страница 132: ...sound card The following table shows the stereo CODEC SoC driver source files These files are under the ltib_dir rpm BUILD linux sound soc directory Table 21 1 Stereo Codec SoC Driver Files File Description imx imx wm8962 c Machine layer for stereo CODEC ALSA SoC imx imx pcm dma mx2 c Platform layer for stereo CODEC ALSA SoC imx imx pcm h Header file for PCM driver and AUDMUX register definitions ...

Страница 133: ...MA callback 21 4 4 Platform Data struct mxc_audio_platform_data defined in include linux fsl_devices h is used to pass the platform data of audio CODEC The value of platform data needs to be updated according to Hardware design Take wm8962 CODEC platform data as a example to show the parameter of mxc_audio_platform_data See header file for the details of more variables ssi_num indicates which SSI ...

Страница 134: ...for the Freescale i MX CPU SoC Audio support for WM8962 21 5 Unit Test This section shows how to use ALSA driver and assume the rootfs is GNOME 21 5 1 Stereo CODEC Unit Test Stereo CODEC driver supports playback and record features There are a default volume and you may adjust volume by alsamixer command Playback feature may be tested by the following command aplay Dplughw 0 0 audio wav Because an...

Страница 135: ...lay h arecord h amixer h Chapter 21 Advanced Linux Sound Architecture ALSA System on a Chip ASoC Sound Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 135 ...

Страница 136: ...Unit Test i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 136 Freescale Semiconductor Inc ...

Страница 137: ...compatible for frequencies up to 66 MHz The memory is organized as 8 192 pages of 512 bytes or 528 bytes The AT45DB321D also contains two SRAM buffers of 512 528 bytes each which allow receiving of data while a page in the main memory is being reprogrammed as well as writing a continuous data stream The M25P32 is a 32 Mbit 4M x 8 Serial Flash memory with advanced write protection mechanisms access...

Страница 138: ...ystem for Linux is a generic interface to memory devices such as Flash and RAM providing simple read write and erase access to physical memory devices Devices called mtdblock devices can be mounted by JFFS JFFS2 and CRAMFS file systems The SPI NOR MTD driver is based on the MTD data Flash driver in the kernel by adding SPI access In the initialization phase the SPI NOR MTD driver detects a data Fl...

Страница 139: ...ir On the screen displayed select Configure the kernel and exit When the next screen appears select the following options to enable the SPI NOR MTD driver accordingly CONFIG_MTD_M25P80 This config enables access to most modern SPI flash chips used for program and data storage Device Drivers Memory Technology Device MTD support Self contained MTD device drivers Support most SPI Flash chips AT26DF M...

Страница 140: ...Introduction i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 140 Freescale Semiconductor Inc ...

Страница 141: ... and DMA data transfers Power management Supports 1 4 8 bit operations for MMC cards Support eMMC4 4 SDR and DDR modes Support SD3 0 SDR50 and SDR104 modes 23 1 1 Hardware Operation The MMC communication is based on an advanced 11 pin serial bus designed to operate in a low voltage range The uSDHC module supports MMC along with SD memory and I O functions The uSDHC controls the MMC SD memory and I...

Страница 142: ... the steps are as follows 1 The uSDHC controller generates a DMA request whenever the amount of the buffer space exceeds the value set in the WR_WML register 2 Upon receiving this request the DMA engine starts moving data from the system memory to the uSDHC FIFO by writing to the Data Buffer Access Register for a number of pre defined bytes The read only uSDHC Present State and Interrupt Status Re...

Страница 143: ...upported by the platform esdhc_pltfm_get_ro gets the card read only status plt_8bit_width handles 8 bit mode switching on the platform plt_clk_ctrl handles clock management on the platform esdhc_prepare_tuning handles the preparation for tuning It s only used for SD3 0 UHS I mode esdhc_post_tuning handles the post operation for tuning esdhc_set_clock handles the clock change request cd_irq it s th...

Страница 144: ...entry points to interface with the Linux MMC core driver MMC and SD cards SDIO cards SD3 0 cards Recognizes data transfer errors such as command time outs and CRC errors Power management It supports to be built as loadable or builtin module Driver Features i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 144 Freescale Semiconductor Inc ...

Страница 145: ... available under Device Drivers MMC SD SDIO Card support By default this option is Y CONFIG_MMC_BLOCK builds support for MMC block device driver which can be used to mount the file system In menuconfig this option is available under Device Drivers MMC SD Card Support MMC block device driver By default this option is Y CONFIG_MMC_SDHCI_ESDHC_IMX is used for the i MX USDHC ports In menuconfig this o...

Страница 146: ...nterface support SDHCI support on the platform specific bus SDHCI platform support for the Freescale eSDHC i MX controller CONFIG_MMC_UNSAFE_RESUME is used for embedded systems which use a MMC SD SDIO card for rootfs In menuconfig this option is found under Device drivers MMC SD SDIO Card Support Assume MMC SD cards are non removable 23 2 3 Platform Data struct esdhc_platform_data defined in arch ...

Страница 147: ...t Controller Interface support SDHCI support on the platform specific bus SDHCI platform support for the Freescale eSDHC i MX controller 2 How to load and unload SDHCI module Due to dependency please load or unload the module following the module sequence shown below run the following commands to load module load modules via insmod command assuming the files of sdhci ko and sdhci platform ko exist...

Страница 148: ... modprobe r sdhci platform modprobe r sdhci Driver Features i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 148 Freescale Semiconductor Inc ...

Страница 149: ...rd Linux kernel contains a core I2C module that is used by the chip driver to access the I2C bus driver to transfer data over the I2C bus The chip driver uses a standard kernel space API that is provided in the Linux kernel to access the core I2C module The standard I2C kernel functions are documented in the files available under Documentation i2c in the kernel source tree This bus driver supports...

Страница 150: ...te to the device registers The camera driver uses the APIs provided by this driver to interact with the camera 24 1 3 Hardware Operation The I2C module provides the functionality of a standard I2C master and slave It is designed to be compatible with the standard Philips I2C bus protocol The module supports up to 64 different clock frequencies that can be programmed by setting a value to the Frequ...

Страница 151: ...plete signal is not received Because the I2C bus driver uses wait queues for its operation other device drivers should be careful not to call the I2C API methods from an interrupt mode 24 2 2 I2C Device Driver Software Operation The I2C driver controls an individual I2C device on the I2C bus A structure i2c_driver describes the I2C chip driver The fields of interest in this structure are flags and...

Страница 152: ...ivers I2C support I2C Hardware Bus support IMX I2C interface 24 3 3 Programming Interface The I2C device driver can use the standard SMBus interface to read and write the registers of the device connected to the I2C bus For more information see ltib_dir rpm BUILD linux include linux i2c h 24 3 4 Interrupt Requirements The I2C module generates many kinds of interrupts The highest interrupt rate is ...

Страница 153: ...te is 200 Kbps The best case values are based on a baud rate of 400 Kbps the maximum supported by the I2C interface Chapter 24 Inter IC I2C Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 153 ...

Страница 154: ...Driver Features i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 154 Freescale Semiconductor Inc ...

Страница 155: ...e interrupts than conventional serial communications Each ECSPI is equipped with a data FIFO and is a master slave configurable serial peripheral interface module allowing the processor to interface with external SPI master or slave devices The primary features of the ECSPI includes Master slave configurable Four chip select signals to support multiple peripherals Up to 32 bit programmable data tr...

Страница 156: ... simple synchronous wrappers for those calls including the ones for common transaction types such as writing a command and then reading its response SPI NOR mtd driver Client 2 driver Client 3 driver SPI Subsystem ECSPI Hardware SPI NOR Flash Client 2 Client 3 Figure 25 1 SPI Subsystem All SPI clients must have a protocol driver associated with them and they all must be sharing the same controller...

Страница 157: ...ip select and transfer The driver implements the following functions Init function spi_imx_init registers the device_driver structure Probe function spi_imx_probe performs initialization and registration of the SPI device specific structure with SPI core driver The driver probes for memory and IRQ resources Configures the IOMUX to enable ECSPI I O pins requests for IRQ and resets the hardware Chip...

Страница 158: ... Synchronous Operation Figure below shows how the ECSPI provides synchronous read write operations Software Operation i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 158 Freescale Semiconductor Inc ...

Страница 159: ...spi_enable_rx_intr spi_load_TxFifo spi_init_exchange Rx_Data_Ready_intr spi_getRxData callback after transfer completion return Chapter 25 Enhanced Configurable Serial Peripheral Interface ECSPI Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 159 ...

Страница 160: ...when located in the ltib dir On the screen displayed select Configure the Kernel and exit When the next screen appears select the following options to enable this module CONFIG_SPI build support for the SPI core In menuconfig this option is available under Device Drivers SPI Support CONFIG_BITBANG is the Library code that is automatically selected by drivers that need it SPI_IMX selects it In menu...

Страница 161: ... 25 2 ECSPI Interrupt Requirements Parameter Equation Typical Worst Case BaudRate Transfer Length BaudRate TransferLength 1 Rxtl 31250 1500000 The typical values are based on a baud rate of 1 Mbps with a receiver trigger level Rxtl of 1 and a 32 bit transfer length The worst case is based on a baud rate of 12 Mbps max supported by the SPI interface with a 8 bits transfer length Chapter 25 Enhanced...

Страница 162: ...Driver Features i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 162 Freescale Semiconductor Inc ...

Страница 163: ...e OTG2 high speed full speed and low devices are supported An USB2Pci bridge is connected to OTG2 by default Therefore User may not be able to connect other USB devices on this port High Speed Inter Chip core Host2 Host mode Supports HID Human Interface Devices MSC Mass Storage Class Peripheral mode Supports MSC and CDC Communication Devices Class drivers which include ethernet and serial support ...

Страница 164: ... driver which implements the USB protocols For the USB host it only implements the hardware specified initialization functions For the USB peripheral it implements the gadget framework static struct usb_ep_ops fsl_ep_ops enable fsl_ep_enable disable fsl_ep_disable alloc_request fsl_alloc_request free_request fsl_free_request Hardware Operation i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 ...

Страница 165: ...ber of bytes to be moved with this transfer descriptor For OTG ID dynamic switch host device modes are supported Full OTG functions are temporarily not supported 26 2 2 Source Code Structure Table below shows the source files available in the source directory ltib_dir rpm BUILD linux drivers usb Table 26 1 USB Driver Files File Description host ehci hcd c Host driver source file host ehci arc c Ho...

Страница 166: ...e directory ltib_dir rpm BUILD linux arch arm mach mx6 Table 26 3 USB Platform Header Files File Description usb_dr c Platform related initialization usb_h1 c Platform related initialization usb_h2 c Platform related initialization usb_h3 c Platform related initialization Table below shows the common platform source files in the directory ltib_dir rpm BUILD linux arch arm plat mxc Table 26 4 USB C...

Страница 167: ...nfig this option is available under Device drivers USB support EHCI HCD USB 2 0 support Support for DR host port on Freescale controller By default this option is Y CONFIG_USB_EHCI_ARC_HSIC Freescale HSIC USB Host Controller By default this option is N CONFIG_USB_EHCI_ROOT_HUB_TT Some EHCI chips have vendor specific extensions to integrate transaction translators so that no OHCI or UHCI companion ...

Страница 168: ... role with ID pin detection By default this option is Y CONFIG_MXC_OTG USB OTG pin detect support for Freescale USB OTG Controller By default this option is Y CONFIG_USB_ETH Build support for Ethernet gadget In menuconfig this option is available under Device drivers USB support USB Gadget Support Ethernet Gadget with CDC Ethernet Support By default this option is M CONFIG_USB_ETH_RNDIS Build supp...

Страница 169: ...ll the wakeup functions depend on the USB PHY power supply including 1p1 2p5 3p3 no power supply all the wakeup function behavior will be unpredictable For host remote wake feature there is a limitation that our system clock needs a short time to be stable after resume if the resume signal sent by the connected device only last very short time less than the time need to make clock stable the remot...

Страница 170: ...r wakeup Host mode wakeup connect wakeup when USB device connects to host port Wakeup signal ID dm dp change echo enabled sys devices platform fsl usb2 otg power wakeup disconnect wakeup when USB device disconnects to host port Wakeup signal ID dm dp change echo enabled sys devices platform fsl usb2 otg power wakeup remote wakeup press USB device i e press USB key on the USB keyboard when USB devi...

Страница 171: ...SB device wakeup that device connects at second level hub 1 1 1 is the USB device name 26 3 4 How to Close the USB Child Device Power The following code string outlines how to close the USB child device power echo auto sys bus usb devices 1 1 power control echo auto sys bus usb devices 1 1 1 power control If there is a hub at usb device Chapter 26 ARC USB Driver i MX 6SoloLite Linux Reference Manu...

Страница 172: ...System WakeUp i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 172 Freescale Semiconductor Inc ...

Страница 173: ...uch as automatic retransmission on collision and CRC generation Obtaining statistics from the device such as transmit collisions The network adapter can be accessed through the ifconfig command with interface name ethx The driver auto probes the external adaptor PHY device 27 2 Hardware Operation The FEC is an Ethernet controller that interfaces the system to the LAN network The FEC supports diffe...

Страница 174: ...onous clock reference REF_CLK can connect from PHY In FEC_RX_DV Receive Data Valid Receive Data Valid and generate CRS RXDV XOR RXERR on the falling edge of FEC_RX_CLK In FEC_RXD 0 Data in bit 0 Data in bit 0 Data in bit 0 In FEC_RXD 1 Data in bit 1 Data in bit 1 Data in bit 1 In FEC_RXD 2 Data in bit 2 Not Used Data in bit 2 In FEC_RXD 3 Data in bit 3 Not Used Data in bit 3 The MII management int...

Страница 175: ...f enabled by the EIMR register When the receive frame is complete the FEC sets the L bit in the RxBD writes the other frame status bits into the RxBD and clears the E bit The Ethernet controller next generates a maskable interrupt RXF bit in EIR maskable by RXF bit in EIMR indicating that a frame has been received and is in memory The Ethernet controller then waits for a new frame Interrupt manage...

Страница 176: ...information about the generic Linux driver see the ltib_dir rpm BUILD linux drivers net fec c source file 27 2 3 Menu Configuration Options To get to the Linux kernel configuration option provided for this module use the ltib c command when located in the ltib dir On the screen displayed select Configure the Kernel and exit When the next screen appears select the following option to enable this mo...

Страница 177: ...fine FEC_X_DES_ACTIVE 0x014 Transmit descriptor reg define FEC_ECNTRL 0x024 Ethernet control reg define FEC_MII_DATA 0x040 MII manage frame reg define FEC_MII_SPEED 0x044 MII speed control reg define FEC_MIB_CTRLSTAT 0x064 MIB control status reg define FEC_R_CNTRL 0x084 Receive control reg define FEC_X_CNTRL 0x0c4 Transmit Control reg define FEC_ADDR_LOW 0x0e4 Low 32bits MAC address define FEC_ADD...

Страница 178: ...efault for i MX 6 The MAC address can be set through bootloader such as u boot FEC driver will use it to confiure the MAC address for network devices i MX 6 user needs to provide MAC address by kernel command line so that user can use sb_loader to load kernel and run it without bootloader interaction Programming Interface i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 178 Freescal...

Страница 179: ...re flow control Serial communication using software flow control is reliable when communication speeds are not too high and the probability of buffer overruns is minimal CTS RTS hardware flow control both interrupt driven software controlled hardware flow and hardware driven hardware controlled flow Send and receive break characters through the standard Linux serial API Recognizes frame and parity...

Страница 180: ...er that manages many of the serial operations that are common across UART drivers for various platforms The low level UART driver is responsible for supplying information such as the UART port information and a set of control functions to the core UART driver These functions are implemented as a low level interface between the Linux OS and the UART hardware They cannot be called from other drivers...

Страница 181: ...lable IOCTL calls If the user wishes to assert the CTS line then control is transferred back to the receiver as long as the driver has been configured to use hardware driven hardware flow control 28 2 2 Driver Features The UART driver supports the following features Baud rates up to 4 Mbps Recognizes frame and parity errors only in interrupt driven mode does not recognize these errors in DMA drive...

Страница 182: ... use the ltib c command when located in the ltib dir On the screen displayed select Configure the Kernel and exit When the next screen appears select the following options to enable this module CONFIG_SERIAL_IMX Used for the UART driver for the UART ports In menuconfig this option is available under Device Drivers Character devices Serial drivers IMX serial port support By default this option is Y...

Страница 183: ...UART port The driver implements and provides a set of control methods to the Linux core UART driver For more information about the methods implemented in the driver see the API document 28 4 1 Interrupt Requirements The UART driver interface generates only one interrupt The status is used to determine which kinds of interrupt occurs such as RX or TX With the SDMA enabled the DMA RX interrupt occur...

Страница 184: ...Programming Interface i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 184 Freescale Semiconductor Inc ...

Страница 185: ...The PWM has 16 bit resolution and uses a 4x16 data FIFO to generate sound The software module is composed of a Linux driver that allows privileged users to control the backlight by the appropriate duty cycle of the PWM Output PWMO signal 29 1 1 Hardware Operation Figure below shows the PWM block diagram i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 185...

Страница 186: ... the processor interrupt handler The PWM includes a single external output signal PMWO The PWM includes the following internal signals Three clock inputs Four interrupt lines One hardware reset line Four low power and debug mode signals Four scan signals Standard IP slave bus signals 29 1 2 Clocks The clock that feeds the prescaler can be selected from Introduction i MX 6SoloLite Linux Reference M...

Страница 187: ...ummary Function Description struct pwm_device pwm_request int pwm_id const char label Request a PWM device void pwm_free struct pwm_device pwm Free a PWM device int pwm_config struct pwm_device pwm int duty_ns int period_ns Change a PWM device configuration int pwm_enable struct pwm_device pwm Start a PWM output toggling int pwm_disable struct pwm_device pwm Stop a PWM output toggling The function...

Страница 188: ...uration Options To get to the PWM driver use the command ltib c when located in the ltib dir On the screen displayed select Configure the kernel and exit When the next screen appears select the following option to enable the PWM driver System Type Enable PWM driver Select the following option to enable the Backlight driver Device Drivers Graphics support Backlight LCD device support Generic PWM ba...

Страница 189: ...me the WDOG times out Upon a time out the WDOG either asserts the wdog_b signal or a wdog_rst_b system reset signal depending on software configuration The watchdog module cannot be deactivated once it is activated 30 1 2 Software Operation The Linux OS has a standard WDOG interface that allows support of a WDOG driver for a specific platform WDOG can be suspended resumed in STOP DOZE and WAIT mod...

Страница 190: ...rd WDOG subsystem 30 2 2 Menu Configuration Options To get to the Linux kernel configuration option provided for this module use the ltib c command when located in the ltib dir On the screen displayed select Configure the Kernel and exit When the next screen appears select the following option to enable this module CONFIG_IMX2_WDT Enables Watchdog timer module This option is available under Device...

Страница 191: ...supported in the WDOG driver WDIOC_GETSUPPORT WDIOC_GETSTATUS WDIOC_GETBOOTSTATUS WDIOC_KEEPALIVE WDIOC_SETTIMEOUT WDIOC_GETTIMEOUT For detailed descriptions about these IOCTLs see ltib_dir rpm BUILD linux Documentation watchdog Chapter 30 Watchdog WDOG Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 Freescale Semiconductor Inc 191 ...

Страница 192: ...Generic WDOG Driver i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 192 Freescale Semiconductor Inc ...

Страница 193: ...rupt handlers kernel modules the kernel shared libraries and applications 31 1 2 Features OProfile has the following features Unobtrusive No special recompilations or wrapper libraries are necessary Even debug symbols g option to gcc are not necessary unless users want to produce annotated source No kernel patch is needed just insert the module System wide profiling All code running on the system ...

Страница 194: ...hus converted into a tuple group or set of binary image offset The userspace tools can use this data to reconstruct where the code came from including the particular assembly instructions symbol and source line through the binary debug information if present Regularly sampling the PC value like this approximates what actually was executed and how often and more often than not this statistical appr...

Страница 195: ...ion from userspace as well as the actual character device that the OProfile userspace receives samples from At setup time the architecture specific code may add further configuration files related to the details of the performance counters The filesystem also contains a stats directory with a number of useful counters for various OProfile events 31 2 3 Generic Kernel Driver The generic kernel driv...

Страница 196: ...ble sample files load and process each one correlated against the relevant binary file and produce user readable information 31 3 Requirements OProfile has the following requirements Add Oprofile support with Cortex A8 Event Monitor 31 3 1 Source Code Structure Oprofile platform specific source files are available in the directory ltib_dir rpm BUILD linux arch arm oprofile Table 31 1 OProfile Sour...

Страница 197: ...AL OProfile system profiling EXPERIMENTAL 31 3 3 Programming Interface This driver implements all the methods required to configure and control PMU and L2 cache EVTMON counters More information see the Linux document generated from build make htmldocs 31 3 4 Interrupt Requirements The number of interrupts generated with respect to the OProfile driver are numerous The latency requirements are not n...

Страница 198: ...Requirements i MX 6SoloLite Linux Reference Manual Rev L3 0 35_4 1 0 09 2013 198 Freescale Semiconductor Inc ...

Страница 199: ...on consequential or incidental damages Typical parameters that may be provided in Freescale data sheets and or specifications can and do vary in different applications and actual performance may vary over time All operating parameters including typicals must be validated for each customer application by customer s technical experts Freescale does not convey any license under its patent rights nor ...

Отзывы: