i.MXプロセッサ ナレッジベース

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

i.MX Processors Knowledge Base

ディスカッション

ソート順:
Uploading the i.MX 6 Linux Reference Manual here after being un-able to find it on Google or on i.MX6 product page.
記事全体を表示
i.MX6UL OBDS test image
記事全体を表示
INTRODUCTION REQUIREMENTS CREATE A NEW PROJECT GPU EXAMPLE GSTREAMER EXAMPLE 1. INTRODUCTION:      The below steps show how to create different application examples using Elipse IDE. 2. REQUIREMENTS:      A fully working image and meta-toolchain generated in Yocto . You can follow the  next training: Yocto Training - HOME      Install and configure the Yocto Eclipse Plug-in. For more details about this requirement please refer to Setting up the Eclipse IDE for Yocto Application Development         To demonstrate the steps, L3.14.28  BSP, fsl-image-qt5 image and i.MX6Q SABRE-SDP board were used. 3. CREATE A NEW PROJECT      Follow the section Creating a Hello World Project of this document Setting up the Eclipse IDE for Yocto Application Development 4. GPU EXAMPLE           For this project we use the source code found in the fsl-gpu-sdk that can be downloaded from:      https://www.freescale.com/webapp/Download?colCode=IMX6_GPU_SDK&location=null&Parent_nodeId=1337637154535695831062&Parent…      Follow section 3 and create a new project named gputest.      From the IMX6_GPU_SDK choose one of the examples of GLES2.0 folder. In this case the 01_SimpleTriangle is chosen.      Copy the .c and .h files to the src directory of the gputest project. The Project Explorer window should look like this:              Add the needed files and libraries to compile and link in the Makefile.am file found in the ´src´ folder. The Makefile.am file should have the below content:          bin_PROGRAMS = gputest          gputest_SOURCES = gputest.c fsl_egl.c fslutil.c          AM_CFLAGS = @gputest_CFLAGS@          AM_LDFLAGS = @gputest_LIBS@ -lstdc++ -lm -lGLESv2 -lEGL -lX11 -ldl          CLEANFILES = *~ ​    Add the PATH to CFLAGS where the compiler will look for the headers at Project->Properties->Autotools->configure:           In this project there is no need to add extra PATHs for the headers. Apply the changes by clicking on Reconfigure Project. Build the project To test the file you can send the executable to the board with:           $ scp gputest root@<board_ip>:/home/root      $./gputest      You should get the next output in the display: 5. GSTREAMER EXAMPLE      For this project we use the source code found at Basic tutorial 1: Hello world! - GStreamer SDK documentation - GStreamer SDK documentation    Follow section 3 and create a new project named Gstreamer.    Copy the code of the basic tutorial to your Gstreamer.c file.    Add the needed files and libraries to compile and link in the Makefile.am file found in the ´src´ folder. The Makefile.am file should have the below content:                           bin_PROGRAMS = Gstreamer      Gstreamer_SOURCES = Gstreamer.c      AM_CFLAGS = @Gstreamer_CFLAGS@      AM_LDFLAGS = @Gstreamer_LIBS@ -lstdc++  -lVDK -lm -lGLESv2 -lGAL -lEGL  -ldl -lgstreamer-0.10 -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lrt -lxml2 -lglib-2.0      CLEANFILES = *~         ​    Add the PATH to CFLAGS where the compiler will look for the headers at Project->Properties->Autotools->configure:           For this example the next lines are added             -I${Sysroot}/usr/include/gstreamer-1.0        -I${Sysroot}/usr/include/glib-2.0        -I${Sysroot}/usr/include/libxml2        -I${Sysroot}/usr/lib/glib-2.0/include      Apply the changes by clicking on Reconfigure Project. Build the project To test the file you can send the executable to the board with:           $ scp Gstreamer root@<board_ip>:/home/root To execute the application on the board:      $./Gstreamer The board should have internet access and the application should play the video found at http://docs.gstreamer.com/media/sintel_trailer-480p.webm
記事全体を表示
Measuring only 20mm x 50mm, the DART-MX6 from Variscite is the smallest System-on-Module (SoM) supporting Freescale’s i.MX6 quad and dual core ARM Cortex-A9™ processor. The DART-MX6 offers impressive performance and scalability. Together with optimized power consumption this miniature sized SoM is ideal for portable and battery operated embedded systems. The DART-MX6 highly integrated connectivity includes dual band Wi-Fi/BT with optional MIMO, dual USB, Gigabit Ethernet, PCIe and A/V interfaces. Furthermore, the system supports industrial operating temperatures. Performing as the DART-MX6 carrier board, the VAR-DT6CustomBoard completes an attractive full reference kit, which can be used for customers’ evaluation, development and end-product mass production. Key features of the DART-MX6 include: - Miniature size: 20mm x 50mm x 4mm - Freescale i.MX6 800MHz Quad/Dual ARM Cortex-A9 - Up to 1GB LP-DDR2 and 32GB eMMC - Certified Wi-Fi 802.11 a/b/g/n 2.4/5GHz with optional 2x2 MIMO - Bluetooth 4.0/BLE - Full 1080p video encode/decode capability - Vivante GPU 2D/3D graphics accelerator - Display: 2x LVDS, HDMI1.4, MIPI DSI - 10/100/1000 Mbps Ethernet - USB 2.0: Host, OTG - PCIe - Audio In/Out - Camera inputs: MIPI CSI, parallel - Dual CAN, UART, I2C, SPI - Industrial temperature - OS: Linux Yocto, Android Availability and Pricing: The DART-MX6 SoM and development kits are available now. Email [email protected] or call +972 9 9562910 for more information About Variscite: Variscite is a leading System on Modules (SoM) and Single-Board-Computer (SBC) design and manufacture company. A trusted provider of development and production services for a variety of embedded platforms, Variscite transforms clients’ visions into successful products. Learn more about Variscite, visit www.variscite.com
記事全体を表示
This is ov5645 driver and tested with i.MX6 L3.0.35 BSP .  It is modified based on ov5640.c. P.S. The power down function for OV5645 is different from the OV5640. So modify the function in your_board.c like this: static void mx6q_mipi_powerdown(int powerdown) {     if (!powerdown)         gpio_set_value(MIPI_PWDN, 1);     else         gpio_set_value(MIPI_PWDN, 0);     msleep(5); }
記事全体を表示
  When considering EIM bursts (performance, burst length, etc) we should take into account, that some parameters (maximum burst length, which defines length in clocks of back-to-back EIM access) depend on master, which performs the access (EIM always service as slave). The EIM can split a master burst in order to meet own settings, but the EIM cannot join two master accesses. So, the maximum  burst length is defined by master.  Usually three options are applied for EIM burst accesses : - ARM block copy instructions (LDM / STM) ; - ARM NEON copy instructions (VLDM / VSTM) ; - i.MX SDMA.   Below are some details regarding these options.   1. ARM. ARM provide recommendations below about the fastest way to copy memory on a Cortex-A8. http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.faqs/ka13544.html   According to section 8.1.2 (Supported AXI transfers) of ARM Cortex-A9 Technical Reference Manual, it is possible to get maximum 64 bytes (16 beats x 4 bytes) burst for read and 8 bytes burst for write. “INCR N (N:1-16) 32-bit read transfers INCR N (N:1-2) for 32-bit write transfers” http://infocenter.arm.com/help/topic/com.arm.doc.ddi0388i/DDI0388I_cortex_a9_r4p1_trm.pdf 2. SDMA.   According to section 55.4.3.1 (Burst DMA Unit) of the i.MX6 DQ RM : “Perform up to 8-beat read and write bursts to the ARM platform memory, which optimizes throughput when accessing SDRAM-type devices because of an internal, 36-byte FIFO”. This means, that burst length of the SDMA cannot be greater than 32 bytes (8 beat x 4 bytes). As for performance and implementation of SDMA approach, please look at the following : “Measure SDMA Memory To Memory Copy Performance on i.MX6Q” https://community.freescale.com/docs/DOC-103127
記事全体を表示
Here is a BDI3000 config file I used with a SABRE SD board sometimes ago that includes DDR initialization. I had several request on this in the past so I am placing it here in case anyone needs it. Please feel free to comment or update the document according to your own experience and results. Regards Sinan Akman
記事全体を表示
Hi All I make fsl-image-qt5 in yocto. make command: $ MACHINE=imx6slevk source fsl-setup-release.sh -b build -e fb $ bitbake fsl-image-qt5 However, I couldn't make meta-toolchin-qt5 in yocto. The error is as follows. > | WARNING: exit code 1 from a shell command. > | ERROR: Function failed: do_configure (log file is located at /opt/yocto_build/yocto_fsl-bsp-imx6slevk/fsl-release-bsp/build/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/qtdeclarative/5.3.2-r0/temp/log.do_configure.3411) > ERROR: Task 771 (/opt/yocto_build/yocto_fsl-bsp-imx6slevk/fsl-release-bsp/sources/meta-qt5/recipes-qt/qt5/qtdeclarative_5.3.2.bb, do_configure) failed with exit code '1' > NOTE: Tasks Summary: Attempted 1235 tasks of which 1234 didn't need to be rerun and 1 failed. > No currently running tasks (1234 of 3376) > > Summary: 1 task failed: >   /opt/yocto_build/yocto_fsl-bsp-imx6slevk/fsl-release-bsp/sources/meta-qt5/recipes-qt/qt5/qtdeclarative_5.3.2.bb, do_configure > Summary: There was 1 ERROR message shown, returning a non-zero exit code. How do you make toolchain include Qt5?
記事全体を表示
This is an example to show how to connect two cameras (with same I2C address) on the i.MX6Q board. In this example, the I2C switch is PCA9543A. Two cameras are OV5640 & OV5645. OV5640 is connected to CSI0, and other one OV5645 is connected to MIPI. The Linux BSP is L3.0.35. In the your_board.c file, add the following for pca954x. static struct pca954x_platform_mode pca954x_modes[] = {      {            .adap_id = 4,            .deselect_on_exit = true,      },      {            .adap_id = 5,            .deselect_on_exit = true,      }, }; static struct pca954x_platform_data pca954x_data = {      .modes = pca954x_modes,      .num_modes = ARRAY_SIZE(pca954x_modes) }; In this example, the I2C switch is connected to i.MX6Q’s I2C0. The I2C address of the PCA9543A is 0x70. static struct i2c_board_info mxc_i2c0_board_info[] __initdata = {      {            I2C_BOARD_INFO("pca9543", 0x70),            .platform_data = (void *)&pca954x_data,      }, }; The channel 0 of PCA9543A is connected to the I2C of OV5645 MIPI. static struct i2c_board_info mux_i2c4_board_info[] __initdata = {      {            I2C_BOARD_INFO("ov5645_mipi", 0x3c),            .platform_data = (void *)&mipi_csi2_data,      }, }; The channel 1 of PCA9543A is connected to the I2C of OV5640 CSI0. static struct i2c_board_info mux_i2c5_board_info[] __initdata = {      {            I2C_BOARD_INFO("ov5640", 0x3c),            .platform_data = (void *)&csi0_camera_data,      }, }; In the board_init function, register the I2C4 and I2C5. i2c_register_board_info(4, mux_i2c4_board_info,                 ARRAY_SIZE(mux_i2c4_board_info)); i2c_register_board_info(5, mux_i2c5_board_info,                 ARRAY_SIZE(mux_i2c5_board_info)); Select the PCA954x driver In kernel configuration In Kernel Configuration, go to Device Drivers --> I2C support --> I2C bus multiplexing support --> Multiplexer I2C Chip support  --> Select <*> Philips PCA954x I2C Mux/switches
記事全体を表示
Platform: Ubuntu 12.04 Board: Freescale MCIMX6Q-SDP  and  MCIMX-LVDS1 Screen BSP: L3.0.35_4.1.0_ER_SOURCE_BSP Other device: PC , One Router, 3 Network Cable and 2 usb-otg lines The  platform is as follow: Boot form NFS is very convenient in porting and debugging, and will value us much time. If the customers have modified the kernel and rebuild the kernel to generate the uImage running on board, he can directly download the uImage to the board by TFTP network. It is fast and can avoid the normal operation ,  first customers need to copy the images to the mfgtool specified directory and download the u-boot, uImage and file sytem again to the flash device in board, and then change to boot up mode to boot up the board. If customers are doing debug this operation will waste lot of time. So use the NFS is vey convenient. Beyond this, in the target board customers can also read the files and content in host machine. In a word, use NFS it will help save much time and also convenient. So the follows is introduce and show how to set NFS and then boot up the board. 1 Preparation (1)Build the BSP Build up the L3.0.35_4.1.0_ER_SOURCE_BSP use LTIB on the Ubuntu12.04, you can refer to our user guide document here no details. The u-boot, uImage and file system are all under the directory of litb. Boot up from NFS, so when build uImage some items are needed, here you can see the build details in the section of  Setting Target Linux Image to use NFS in this articel. (2)Download the u-boot to the target board Use the mfgtool Mfgtools-Rel-4.1.0_130816_MX6Q_UPDATER to download the u-boot to the SD card of MCIMX6Q-SDP board or use dd command to write the u-boot to SD card.( By the way, writing to the EMMC is also OK) 2 Setting the NFS Environment Set host machine 1 - Install NFS Service on host typing:     $sudo apt-get install nfs-kernel-server       2 - Create symbolic link to ltib/rootfs     $sudo ln -s <ltib instalation folder>/rootfs /tftpboot/rootfs       3 - Setup exports typing:     $sudo gedit /etc/exports       and add the following line:     /tftpboot/rootfs/ *(rw,no_root_squash,no_subtree_check,async) 4 - Restart the NFS server:     $sudo /etc/init.d/nfs-kernel-server restart       Now the host is ready to use NFS Setting Target Linux Image to use NFS       1. Run LTIB configuration by typing: $cd <ltib instalation folder>       $./ltib -c       2. On first page menu, go to "Target Image Generation -> Options"       3. Select the option NFS only and exit LTIB configuration to compile with the new configuration. 4. LTIB should start new compiling and create a new Linux image on /<ltib instalation folder>/rootfs/boot/uImage      5. Copy the created image on /<ltib instalation folder>/rootfs/boot/uImage to /tftpboot/uImage 6. The system is ready to run with NFS. The root file system on target will be located on host on /<ltib instalation folder>/rootfs/ 3 Setting the u-boot command line (1)Download the u-boot to the target board fist according to the section 1 (2) Download the u-boot to the target board. Then give the power to the board, boot up board, u-boot boot up. (2)Configuration the Network Configure the Network and IP , to make the target board and the host machine IP are in the local area network of Router. (3)Set the u-boot command line As follow is my setting for you to refer to : 4 Boot up the board Running the “run bootcmd” after setting the u-boot parameters then boot up the kernel and file system. We can see that the board download the uImage by the TFTP from host machine, then boot up the kernel and finally mount the NFS in the kernel. As follows is the details: Downloading the uImage success and boot up kernel: Input root and access the system. Test: Create a new file in the host machine directory, you can see in the next picture: Then open the target board, in the terminal go to the same directory  in the unit_test we can see the same name. So as we can see in the above operation we can see it is very convenient and fast use the NFS. It will help save time and speed the development time.
記事全体を表示
current imx6 bsp, not only ltib but also yocto couldn't support subtitle. now we have two solution to support subtitle on yocto, 1)one is extract the subtitle, then draw the subtitle on the video by UI, which is supported by the imxplayer. this solution is using QT by imxplayer, so if you build yocto, should choose QT as target. basicly, aiurdemux send the text to the QT by appsink, then QT draw the text on the UI layer. when build the yocot, pls using the command as below: " bitbake fsl-image-qt5" copy the font libary to the /usr/lib/fonts, then when you play the imxplayer, choose the font you need. 2)another one is blending the subtitle on the video buffer by gstreamer, then output with video enable gst pango lib in gstreamer1.0-plugins-base change playbin flag to disable native video flag basetextoverlay apply patch http://cgit.freedesktop.org/gstreamer/gst-plugins-base/commit/ext/pango/gstbasetextoverlay.c?id=267a8c24af4f02ba6f3075bd589d3c5d1dc826e9 use following command line gst-launch-1.0 playbin flags=0x17 uri=file://$VIDEO_FILE suburi=file://$SUBTITLE_FILE
記事全体を表示
Introduction This is a sharing of my experience about porting the audio codec WM8960 in Linux BSP. I know this driver is not the perfect one.  If you find any place is not good in the driver, please let me know. This driver is modified base on the wm8960.c in L3.0.35 Linux BSP. This document is talking about how to modify the codec driver. The Audio Codec driver is located in linux/sound/soc/codec/wm8960.c. ALSA The Audio Codec driver is based on ALSA to setup up all the things. For details, please see : AlsaProject Advanced Linux Sound Architecture - Wikipedia, the free encyclopedia. kcontrols are defined in linux/include/sound/soc.h and soc-dapm.h. Audio controls and path in WM8960 Left and Right Input signal path Output signal path Base on the input and output signal diagrams, we can setup all the controls that we want in the driver. Such as switches, volume controls, PGA controls and so on. All the controls below can be used in the alsamixer. static const struct snd_kcontrol_new wm8960_snd_controls[] = { SOC_DOUBLE_R_TLV("PCM DAC Playback Volume", WM8960_LDAC, WM8960_RDAC, 0, 255, 0, dac_tlv), //LDACVOL , RDACVOL SOC_DOUBLE_R_TLV("PCM ADC Capture Volume", WM8960_LADC, WM8960_RADC, 0, 255, 0, adc_tlv), //LADCVOL, RADCVOL SOC_DOUBLE_R_TLV("Headphone Volume", WM8960_LOUT1, WM8960_ROUT1, 0, 127, 0, out_tlv), SOC_DOUBLE_R("Headphone ZC Switch", WM8960_LOUT1, WM8960_ROUT1,    7, 1, 0), SOC_DOUBLE_R_TLV("Speaker Volume", WM8960_LOUT2, WM8960_ROUT2, 0, 127, 0, out_tlv), SOC_DOUBLE_R("Speaker ZC Switch", WM8960_LOUT2, WM8960_ROUT2, 7, 1, 0), SOC_DOUBLE_R("Capture Volume ZC Switch", WM8960_LINVOL, WM8960_RINVOL, 6, 1, 0), SOC_SINGLE_TLV("Input Volume of LINPUT1", WM8960_LINVOL, 0, 63, 0, in_tlv),  //LINVOL SOC_SINGLE_TLV("Input Volume of RINPUT1", WM8960_RINVOL, 0, 63, 0, in_tlv),  //RINVOL SOC_SINGLE_TLV("Input Boost Volume LINPUT3", WM8960_INBMIX1, 4, 7, 0, boost_tlv),    //RIN3BOOST SOC_SINGLE_TLV("Input Boost Volume LINPUT2", WM8960_INBMIX1, 1, 7, 0, boost_tlv),    //RIN2BOOST SOC_SINGLE_TLV("Input Boost Volume RINPUT3", WM8960_INBMIX2, 4, 7, 0, boost_tlv),    //LIN3BOOST SOC_SINGLE_TLV("Input Boost Volume RINPUT2", WM8960_INBMIX2, 1, 7, 0, boost_tlv),    //LIN2BOOST SOC_SINGLE_TLV("PGA LB2LOVOL-Bypass from Left Boost", WM8960_BYPASS1, 4, 7, 1, bypass_tlv),    //LB2LOVOL SOC_SINGLE_TLV("PGA LI2LOVOL-Bypass from LINPUT3", WM8960_LOUTMIX, 4, 7, 1, bypass_tlv),    //LI2LOVOL SOC_SINGLE_TLV("PGA RB2ROVOL-Bypass from Right Boost", WM8960_BYPASS2, 4, 7, 1, bypass_tlv),    //RB2ROVOL SOC_SINGLE_TLV("PGA RI2ROVOL-Bypass from RINPUT3", WM8960_ROUTMIX, 4, 7, 1, bypass_tlv),    //RI2ROVOL SOC_SINGLE("Capture Mute (Left)", WM8960_LINVOL, 7, 1, 0), // LINMUTE SOC_SINGLE("Capture Mute (Right)", WM8960_RINVOL, 7, 1, 0), // RINMUTE SOC_SINGLE("PCM Playback -6dB Switch", WM8960_DACCTL1, 7, 1, 0), SOC_SINGLE("Speaker DC gain", WM8960_CLASSD3, 3, 5, 0), SOC_SINGLE("Speaker AC gain", WM8960_CLASSD3, 0, 5, 0), SOC_ENUM("ADC Polarity", wm8960_enum[0]), SOC_SINGLE("ADC High Pass Filter Switch", WM8960_DACCTL1, 0, 1, 0), SOC_ENUM("DAC Polarity", wm8960_enum[2]), SOC_SINGLE_BOOL_EXT("DAC Deemphasis Switch", 0, wm8960_get_deemph, wm8960_put_deemph), SOC_ENUM("3D Filter Upper Cut-Off", wm8960_enum[2]), SOC_ENUM("3D Filter Lower Cut-Off", wm8960_enum[3]), SOC_SINGLE("3D Depth", WM8960_3D, 1, 15, 0), SOC_SINGLE("3D", WM8960_3D, 0, 1, 0), SOC_ENUM("ALC Function", wm8960_enum[4]), SOC_SINGLE("ALC Max Gain", WM8960_ALC1, 4, 7, 0), SOC_SINGLE("ALC Target", WM8960_ALC1, 0, 15, 1), SOC_SINGLE("ALC Min Gain", WM8960_ALC2, 4, 7, 0), SOC_SINGLE("ALC Hold Time", WM8960_ALC2, 0, 15, 0), SOC_ENUM("ALC Mode", wm8960_enum[5]), SOC_SINGLE("ALC Decay", WM8960_ALC3, 4, 15, 0), SOC_SINGLE("ALC Attack", WM8960_ALC3, 0, 15, 0), SOC_SINGLE("Noise Gate Threshold", WM8960_NOISEG, 3, 31, 0), SOC_SINGLE("Noise Gate Switch", WM8960_NOISEG, 0, 1, 0), SOC_ENUM("Capture Left Boost", wm8960_enum[6]), //LMICBOOST SOC_ENUM("Capture Right Boost", wm8960_enum[7]), //RMICBOOT }; 1. SOC_SINGLE(xname, reg, shift, max, invert) To setup a simple switch, we can use SOC_SINGLE. e.g SOC_SINGLE("PCM Playback -6dB Switch", WM8960_DACCTL1, 7, 1, 0), - The name of this control is “PCM Playback -6dB Switch”. - The register in WM8960 is WM8960_DACCTL1 . (the register address is 0x5, defined in wm8960.h) - ‘7’ : The 7th bit in DACCTL1 register is used to enable/disable the DAC 6dB Attenuate. - ‘1’ : Only one enable or disable option. - ‘0’ : the value you set is not inverted. 2. SOC_SINGLE_TLV(xname, reg, shift, max, invert, tlv_array) To setup a switch with levels, we can use SOC_SINGLE_TLV. e.g. In this example, the left input volume control is from 000000(-17.25dB) to 111111(+30dB). Each step is 0.75dB. Total is 63 steps. SOC_SINGLE_TLV("Input Volume of LINPUT1", WM8960_LINVOL, 0, 63, 0, in_tlv), The scale of in_tlv declare like this: static const DECLARE_TLV_DB_SCALE(in_tlv, -1725, 75, 0); in_tlv : the name of the scale. -1725 : start from -17.25dB 75: each step is 0.75dB 0: the step is start from 0. For some volume control case the first step is "mute", then the step is start from 1 so change this number to 1. for example: The 0000 0000 of the DAC volume control is digital mute. static const DECLARE_TLV_DB_SCALE(dac_tlv, -12700, 50, 1); 3. SOC_DOUBLE_R(xname, reg_left, reg_right, xshift, xmax, xinvert) SOC_DOUBLE_R is a stereo version of SOC_SINGLE. You can control the left and right channel at the same time. e.g. SOC_DOUBLE_R("Headphone ZC Switch", WM8960_LOUT1, WM8960_ROUT1, 7, 1, 0), 4. SOC_DOUBLE_R_TLV(xname, reg_left, reg_right, xshift, xmax, xinvert, tlv_array) SOC_DOUBLE_R_TLV is the stereo version of SOC_SINGLE_TLV. e.g. SOC_DOUBLE_R_TLV("PCM DAC Playback Volume", WM8960_LDAC, WM8960_RDAC, 0, 255, 0, dac_tlv), 5. SOC_ENUM_SINGLE(xreg, xshift, xmax, xtexts) When the control option are some texts, we can use SOC_ENUM to enum the options. e.g. MIC boost 5.1. setup the array for the texts. static const char *wm8960_micboost[] = {"0dB","+13dB","+20dB","+29dB"}; 5.2. use the SOC_ENUM_SINGLE. static const struct soc_enum wm8960_enum[] = {      SOC_ENUM_SINGLE(WM8960_DACCTL1, 5, 4, wm8960_polarity),      SOC_ENUM_SINGLE(WM8960_DACCTL2, 5, 4, wm8960_polarity),      SOC_ENUM_SINGLE(WM8960_3D, 6, 2, wm8960_3d_upper_cutoff),      SOC_ENUM_SINGLE(WM8960_3D, 5, 2, wm8960_3d_lower_cutoff),      SOC_ENUM_SINGLE(WM8960_ALC1, 7, 4, wm8960_alcfunc),      SOC_ENUM_SINGLE(WM8960_ALC3, 8, 2, wm8960_alcmode),      SOC_ENUM_SINGLE(WM8960_LINPATH, 4, 4, wm8960_micboost),      SOC_ENUM_SINGLE(WM8960_RINPATH, 4, 4, wm8960_micboost), }; 5.3.  use SOC_ENUM to add the controls for MIC boost. SOC_ENUM("Capture Left Boost", wm8960_enum[6]), SOC_ENUM("Capture Right Boost", wm8960_enum[7]), After created all the controls, we can start to create the switches. The following switches created base on the input and output diagrams. I used the same name from datasheet of each switch. It will more easy to find out the proper switch in alsamixer. static const struct snd_kcontrol_new wm8960_lin[] = { SOC_DAPM_SINGLE("<- LMP2", WM8960_LINPATH, 6, 1, 0), //LMP2 SOC_DAPM_SINGLE("<- LMP3", WM8960_LINPATH, 7, 1, 0), //LMP3 SOC_DAPM_SINGLE("<- LMN1", WM8960_LINPATH, 8, 1, 0), //LMN1 }; static const struct snd_kcontrol_new wm8960_lin_boost[] = { SOC_DAPM_SINGLE("<- LMIC2B", WM8960_LINPATH, 3, 1, 0), //LMIC2B }; static const struct snd_kcontrol_new wm8960_rin[] = { SOC_DAPM_SINGLE("<- RMP2", WM8960_RINPATH, 6, 1, 0), //RMP2 SOC_DAPM_SINGLE("<- RMP3", WM8960_RINPATH, 7, 1, 0), //RMP3 SOC_DAPM_SINGLE("<- RMN1", WM8960_RINPATH, 8, 1, 0), //RMN1 }; static const struct snd_kcontrol_new wm8960_rin_boost[] = { SOC_DAPM_SINGLE("<- RMIC2B", WM8960_RINPATH, 3, 1, 0), //RMIC2B }; static const struct snd_kcontrol_new wm8960_loutput_mixer[] = { SOC_DAPM_SINGLE("<- LD2LO", WM8960_LOUTMIX, 8, 1, 0), //LD2LO SOC_DAPM_SINGLE("<- LI2LO", WM8960_LOUTMIX, 7, 1, 0), //LI2LO SOC_DAPM_SINGLE("<- LB2LO", WM8960_BYPASS1, 7, 1, 0), //LB2LO }; static const struct snd_kcontrol_new wm8960_routput_mixer[] = { SOC_DAPM_SINGLE("<- RD2RO", WM8960_ROUTMIX, 8, 1, 0), //RD2RO SOC_DAPM_SINGLE("<- RI2RO", WM8960_ROUTMIX, 7, 1, 0), //RI2RO SOC_DAPM_SINGLE("<- RB2RO", WM8960_BYPASS2, 7, 1, 0), //RB2RO }; static const struct snd_kcontrol_new wm8960_mono_out[] = { SOC_DAPM_SINGLE("<- L2MO", WM8960_MONOMIX1, 7, 1, 0), //L2MO SOC_DAPM_SINGLE("<- R2MO", WM8960_MONOMIX2, 7, 1, 0), //R2MO }; Then, create the inputs, ADC, DAC, mixers, PGA and outputs. static const struct snd_soc_dapm_widget wm8960_dapm_widgets[] = { SND_SOC_DAPM_INPUT("LINPUT1"), SND_SOC_DAPM_INPUT("RINPUT1"), SND_SOC_DAPM_INPUT("LINPUT2"), SND_SOC_DAPM_INPUT("RINPUT2"), SND_SOC_DAPM_INPUT("LINPUT3"), SND_SOC_DAPM_INPUT("RINPUT3"), SND_SOC_DAPM_MICBIAS("MICB", WM8960_POWER1, 1, 0), SND_SOC_DAPM_MIXER("Left Boost Mixer", WM8960_POWER1, 5, 0, wm8960_lin_boost, ARRAY_SIZE(wm8960_lin_boost)), SND_SOC_DAPM_MIXER("Right Boost Mixer", WM8960_POWER1, 4, 0, wm8960_rin_boost, ARRAY_SIZE(wm8960_rin_boost)), SND_SOC_DAPM_MIXER("Left Input PGA", WM8960_POWER3, 5, 0, wm8960_lin, ARRAY_SIZE(wm8960_lin)), SND_SOC_DAPM_MIXER("Right Input PGA", WM8960_POWER3, 4, 0, wm8960_rin, ARRAY_SIZE(wm8960_rin)), SND_SOC_DAPM_ADC("Left ADC", "Capture", WM8960_POWER1, 3, 0), SND_SOC_DAPM_ADC("Right ADC", "Capture", WM8960_POWER1, 2, 0), SND_SOC_DAPM_DAC("Left DAC", "Playback", WM8960_POWER2, 8, 0), SND_SOC_DAPM_DAC("Right DAC", "Playback", WM8960_POWER2, 7, 0), SND_SOC_DAPM_MIXER("Left Output Mixer", WM8960_POWER3, 3, 0, wm8960_loutput_mixer, ARRAY_SIZE(wm8960_loutput_mixer)), SND_SOC_DAPM_MIXER("Right Output Mixer", WM8960_POWER3, 2, 0, wm8960_routput_mixer, ARRAY_SIZE(wm8960_routput_mixer)), SND_SOC_DAPM_PGA("Left HP PGA", WM8960_POWER2, 6, 0, NULL, 0), SND_SOC_DAPM_PGA("Right HP PGA", WM8960_POWER2, 5, 0, NULL, 0), SND_SOC_DAPM_PGA("Left Speaker PGA", WM8960_POWER2, 4, 0, NULL, 0), SND_SOC_DAPM_PGA("Right Speaker PGA", WM8960_POWER2, 3, 0, NULL, 0), SND_SOC_DAPM_PGA("Right Speaker Output", WM8960_CLASSD1, 7, 0, NULL, 0), //SPK_OP_EN SND_SOC_DAPM_PGA("Left Speaker Output", WM8960_CLASSD1, 6, 0, NULL, 0), SND_SOC_DAPM_OUTPUT("SPK_LP"), SND_SOC_DAPM_OUTPUT("SPK_LN"), SND_SOC_DAPM_OUTPUT("HP_L"), SND_SOC_DAPM_OUTPUT("HP_R"), SND_SOC_DAPM_OUTPUT("SPK_RP"), SND_SOC_DAPM_OUTPUT("SPK_RN"), SND_SOC_DAPM_OUTPUT("OUT3"), }; Now, we can start to route the audio path. The path is from right to left , like : { “destination”, “switch”, “source” } So, lets take the LINPUT1 to ADC as an example: { "Left Input PGA", "<- LMN1", "LINPUT1" }, { "Left Boost Mixer", "<- LMIC2B", "Left Input PGA" }, { "Left ADC", NULL, "Left Boost Mixer" }, Another example is DAC to Headphone.                 { "Left Output Mixer", "<- LD2LO", "Left DAC" },                 { "Right Output Mixer", "<- RD2RO", "Right DAC" },                 { "Left HP PGA", NULL, "Left Output Mixer" },                 { "Right HP PGA", NULL, "Right Output Mixer" },                 { "HP_L", NULL, "Left HP PGA" },                 { "HP_R", NULL, "Right HP PGA" }, In linux, you can run "alsamixer" to turn on/off the switches and adjust the volumes. (this picture is an example of alsamixer of other codec, not for wm8960) In alsamixer, use 'M' to turn the switch on/off,  use arrow keys to control the volumes. wm8960_dai_ops is another important part in the driver. Here is the ops of the wm8960_dai. static struct snd_soc_dai_ops wm8960_dai_ops = {                 .hw_params = wm8960_hw_params,                 .digital_mute = wm8960_mute,                 .set_fmt = wm8960_set_dai_fmt,                 .set_clkdiv = wm8960_set_dai_clkdiv,                 .set_pll = wm8960_set_dai_pll, }; wm8960_hw_params : used to set the PCM format (16bit/24bit), set the deemph, alc_rates and etc. wm8960_mute:  used to mute the output wm8960_set_dai_fmt : used to set the Master/Slave mode, set the interface format (I2S, DSP, Left justified and Right justified) and set the clock inversion. wm8960_set_dai_clkdiv: used to set the CLK divider such as DACDIV, ADCDIV, BCLKDIV and so on. wm8960_set_dai_pll: used to calculate the proper PLL values. In the wm8960_set_dai_pll, we need to calculate the proper PLL values. Base on the table, if the MCLK >14.4, the sysclk prescale divider is 2. So, set the sysclk pre-divider to 2 before finding pll_factors. if (freq_in > 15000000 ) {                                 /* update sysclk div */                                 reg = snd_soc_read(codec, WM8960_CLOCK1) & 0x1f9;                                 snd_soc_write(codec, WM8960_CLOCK1, reg | 0x4);                                 clk_in = clk_in/2;                                 }                 if (freq_in && freq_out) {                                 ret = pll_factors(clk_in, freq_out, &pll_div);                                 if (ret != 0)                                                 return ret;                 } In the driver, there are two names are important. One is the name of codec dai. The name is “wm8960”. Make sure this codec dai name is the same codec dai name used in the imx-wm8960.c. static struct snd_soc_dai_driver wm8960_dai = {                 .name = "wm8960",                 .playback = {                                 .stream_name = "Playback",                                 .channels_min = 1,                                 .channels_max = 2,                                 .rates = WM8960_RATES,                                 .formats = WM8960_FORMATS,},                 .capture = {                                 .stream_name = "Capture",                                 .channels_min = 1,                                 .channels_max = 2,                                 .rates = WM8960_RATES,                                 .formats = WM8960_FORMATS,},                 .ops = &wm8960_dai_ops,                 .symmetric_rates = 1, }; Another name is the I2C device id. Make sure the I2C name is same as the name used in your_board.c file. static const struct i2c_device_id wm8960_i2c_id[] = {                 { "wm8960", 0 },                 { } }; MODULE_DEVICE_TABLE(i2c, wm8960_i2c_id); static struct i2c_driver wm8960_i2c_driver = {                 .driver = {                                 .name = "wm8960",                                 .owner = THIS_MODULE,                 },                 .probe =    wm8960_i2c_probe,                 .remove =   __devexit_p(wm8960_i2c_remove),                 .id_table = wm8960_i2c_id, }; Here is the name used in your_board.c static struct i2c_board_info mxc_i2c0_board_info[] __initdata = {     {         I2C_BOARD_INFO("wm8960", 0x1a),     }, } Machine driver imx-wm8960.c Basically, the machine driver is the connection between wm8960.c and the i.MX. It is modified base on the imx-wm8962.c. I didn't add the HP and MIC detection in this driver. If you need the HP and MIC detection, please take the imx-wm8962.c for reference. Here is an example of my_board.c. The following platform data pass to the machine driver from my board. static struct platform_device audio_wm8960_device = {     .name = "imx-wm8960", }; static struct mxc_audio_platform_data wm8960_pdata; static int wm8960_clk_enable(int enable) {     if (enable)         clk_enable(clko);     else         clk_disable(clko);     return 0; } static int mxc_wm8960_init(void) {     int rate;     clko = clk_get(NULL, "clko_clk");     if (IS_ERR(clko)) {         pr_err("can't get CLKO clock.\n");         return PTR_ERR(clko);     }     /* both audio codec and comera use CLKO clk*/     rate = clk_round_rate(clko, 24000000);     clk_set_rate(clko, rate);     wm8960_pdata.sysclk = rate;     return 0; } static struct mxc_audio_platform_data wm8960_pdata = {     .ssi_num = 1,     .src_port = 2,     .ext_port = 3,     .init = mxc_wm8960_init,     .clock_enable = wm8960_clk_enable, }; I attach the driver and the machine driver here. I hope this document is useful for you.
記事全体を表示
According to section 13.5 (Cortex-M4 Boot Requirements) of the i.MX6SX  Reference Manual : • Cortex-A9 always boots as the primary core. • Cortex-M4 does not have a boot ROM and at POR is not provided a clock. • Cortex-A9 ROM is responsible for the following: • Loading and authenticating A9 bootloader and initiating Cortex-M4 firmware as a unified image. • Setting up Cortex-M4 initial exception table in TCRAML • Launching the Cortex-M4 by enabling its clock. In addition :  M4 obtains minimal initial vector table, containing a) Initial Stack pointer b) Reset vector c) NMI vector from a fixed location (zero offset) in TCM(L) after A9 enables it’s clock. So, A9 (bootloader) is responsible for:     Configuring M4 initial vector table  in TCM(L) ;     Loading M4 code ;     Configuring CSU and RDC for TrustZone (if needed)       and A9/M4 domain separation ;     Enabling M4 clock.    Please look at the enclosed projects, which help to understand how to build, load and run startup codes for both Cortex-A9 and Cortex-M4 cores of i.MX6 SoloX.   Also note : the i.MX6 SoloX has two cores with different address mapping. Please refer to Table 2-1 (System memory map) for Cortex-A9 core and to Table 2-2 (CM4 memory map) for Cortex-M4 of the i.MX6 SoloX Reference Manual. To run Cortex-M4 it is needed to fill TCM(L), that is addressed as TCML ALIAS (from zero). The same memory is mapped to 0x007f8000 of the Cortex-A9 (non-reflected in the Table 2-1). Note, this area is accessible by the Cortex-A9 after M4 clock is enabled in CCM_CCGR3. The following resources may be helpful, when working with i.MX6 SoloX : “How to configure Real View ICE  and RealView debugger  to work with i.MX6 SoloX” https://community.freescale.com/docs/DOC-106198 “Integrating Processor Expert for i.MX and ARM GCC with Eclipse” https://community.freescale.com/docs/DOC-103736 “I.MX6SX start M4 from U-Boot with QSPI flash” https://community.freescale.com/message/499465 "Loading Code on Cortex-M4 from Linux for the i.MX 6SoloX and i.MX 7Dual/7Solo " http://cache.nxp.com/files/soft_dev_tools/doc/app_note/AN5317.pdf
記事全体を表示
I am designing settop using iMX.6Q sabre solution. What is the android platform key? Why need  the android platform key? Thank in advance
記事全体を表示
                For the SPI NOR booting on fuse steps. 1.      Please boot your PCB on uboot and type below command for fuse boot setting. MX6Q SABRESD-MFG U-Boot > imxotp blow --force 5 0x0a000030 MX6Q SABRESD-MFG U-Boot > imxotp read 5 Reading fuse at index: 0x5 Fuse at (index: 0x5) value: 0xA000030 MX6Q SABRESD-MFG U-Boot > imxotp read 6 Reading fuse at index: 0x6 Fuse at (index: 0x6) value: 0x0 MX6Q SABRESD-MFG U-Boot > imxotp blow --force 6 0x10 Current fuse at (index: 0x6) value: 0x0 Blowing fuse at index: 0x6, value: 0x10 Reloading shadow registers... Operation succeeded fuse at (index: 0x6) value: 0x10 MX6Q SABRESD-MFG U-Boot > imxotp read 6 Reading fuse at index: 0x6 Fuse at (index: 0x6) value: 0x10 MX6Q SABRESD-MFG U-Boot > 2.      Set the boot mode for 00 as Boot from fuses 3.      You could see the SPI clock on scope after re power on.
記事全体を表示
  “Hardware Development Guide for i.MX 6SoloX …” does not provide any recommendations regarding configuring JTAG tools, assuming ARM DSTREAM  / DS-5 using. Nevertheless, it is possible to apply ARM RealView tools with i.MX6 SoloX. Chapter 7 (Configuring JTAG Tools) of  “Hardware Development Guide for i.MX 6Quad, 6Dual, 6DualLite, 6Solo Families…” contains base considerations, that may be used for i.MX6 SoloX too. http://cache.freescale.com/files/32bit/doc/user_guide/IMX6DQ6SDLHDG.pdf Some addition details  are provided below.   Both A9 core and M4 core have their own DAP, all the resources in its platform will be accessed through its own DAP. JTAG Chain Configuration: − SJC, IR Length = 5, same as i.MX 6Solo; − SDMA, IR Length = 5, same as i.MX 6Solo; − DAP for A9, IR Length = 4, same as i.MX 6Solo; − DAP for M4, IR Length = 4, new in i.MX 6SoloX. It is needed to use the recent RVICE firmware, which may be found in ARM DS5 Community Edition. http://ds.arm.com/ds-5-community-edition/ After installation, please run “Debug Hardware Update” option of the DS5 and select the firmware file for “Install Firware Update” menu. In my case : c:\Program Files\DS-5 v5.21.0\sw\debughw\firmware\ARM-RVI-4.23.0-35-base.rvi   Finally, RealView configuration looks as below. Coresight base address Cortex-A9_0 is 0x82150000. The Cortex-A9 always boots as the primary core and is responsible for launching the Cortex-M4.
記事全体を表示
When the customer want to use the PCIE module on the i.MX6SX SDB board, they can use the oscillator to do the pretset, there are the test report.
記事全体を表示
Abstract: On the time otp driver initializes, it will check the mac bits of eFuse,  when the value is invalid, generate a random mac, and program  it to eFuse. Environment: i.mx6dl android-4.2.2 kernel-3.0.35 Changes: 1. kernel_imx/arch/arm/mach-mx6/mx6_fec.c ---------------------------------------------------------------- void __init imx6_init_fec(struct fec_platform_data fec_data) {   fec_get_mac_addr(fec_data.mac);   if (!is_valid_ether_addr(fec_data.mac))       fec_data.mac[0] = 0x10; // changed by xxx   if (cpu_is_mx6sl())   imx6sl_add_fec(&fec_data);   else   imx6q_add_fec(&fec_data); } 2. kernel_imx/drivers/char/fsl_otp.c ---------------------------------------------------------------- //add by xxx static void check_otp_mac(void) {   unsigned int index_mac0 = 34;   unsigned int index_mac1 = 35;   u32 value_mac0 = 0;   u32 value_mac1 = 0;   u32 value_random_mac0 = 0;   u32 value_random_mac1 = 0;   char otp_mac[6], random_mac[6];   memset(otp_mac, 0, sizeof(otp_mac));   memset(random_mac, 0, sizeof(random_mac));   mutex_lock(&otp_mutex);   //get   if (otp_read_prepare(otp_data)) {   mutex_unlock(&otp_mutex);   return 0;   }   value_mac0 = __raw_readl(REGS_OCOTP_BASE + HW_OCOTP_CUSTn(index_mac0));   value_mac1 = __raw_readl(REGS_OCOTP_BASE + HW_OCOTP_CUSTn(index_mac1));   otp_read_post(otp_data);   mutex_unlock(&otp_mutex);   if(value_mac0 != 0 && value_mac1 != 0)   {   otp_mac[5] = value_mac0 & 0xff;   otp_mac[4] = (value_mac0 >> 😎 & 0xff;   otp_mac[3] = (value_mac0 >> 16) & 0xff;   otp_mac[2] = (value_mac0 >> 24) & 0xff;   otp_mac[1] = value_mac1 & 0xff;   otp_mac[0] = (value_mac1 >> 😎 & 0xff;   }   printk("otp_mac=%pM\n", otp_mac);   //check   if (!is_valid_ether_addr(otp_mac))   {   random_ether_addr(random_mac);   printk("get random mac:%pM\n", random_mac);   //set   value_random_mac0 = 0;   value_random_mac0 = value_random_mac0 | random_mac[2];   value_random_mac0 = (value_random_mac0 << 😎 | random_mac[3];   value_random_mac0 = (value_random_mac0 << 😎 | random_mac[4];   value_random_mac0 = (value_random_mac0 << 😎 | random_mac[5];   value_random_mac1 = 0;   value_random_mac1 = value_random_mac1 | random_mac[0];   value_random_mac1 = (value_random_mac1 << 😎 | random_mac[1];   mutex_lock(&otp_mutex);   if (otp_write_prepare(otp_data)) {   mutex_unlock(&otp_mutex);   return 0;   }   otp_write_bits(index_mac0, value_random_mac0, 0x3e77);   otp_write_bits(index_mac1, value_random_mac1, 0x3e77);   otp_write_post(otp_data);   mutex_unlock(&otp_mutex);   } } //end 3.  kernel_imx/drivers/char/fsl_otp.c ---------------------------------------------------------------- static int __devinit fsl_otp_probe(struct platform_device *pdev) {   ...   retval = sysfs_create_group(otp_kobj, &attr_group);   if (retval)   goto error;   mutex_init(&otp_mutex);   //add by xxx   check_otp_mac();   //end
記事全体を表示
Assemble wxWidgets version 2.8. TinyX used. Powered by touchscreens 4 "- 8".
記事全体を表示
iWave's i.MX6 UltraLite (i.MX6UL) based SODIMM CPU module integrates power efficient high performance ARM Cortex A7 CPU core operating up to 528MHz speed. iMX6 UL SOM is ultra-compact in size and integrated with on-board PMIC, Flash, DDR3 and dual Ethernet PHY. The SOM is ideally suitable for the cost & power optimized general embedded and industrial applications.                                                                                                                                                                                                                                                                                                    i.MX6UL SODIMM Development Kit    i.MX6UL SODIMM SOM                                                                                                                                                                                                                                                                                                 Benefits: Ultra-compact form factor module with size of 67.6mm x 29mm Long term support: 7+ years Technical & Quick customization support Compatible with ARM Cortex A9 i.MX6 Q/D/S SODIMM SOM Highlights: Power efficient ARM Cortex-A7 @ 528MHz Advanced hardware enabled security PMIC with DVFS support Industrial temperature support available  Features: CPU: Freescale’s i.MX6UL1/2/3 @ 528MHz ARM Cortex A7 PMIC: Freescale PF3000 Memory: 256MB DDR3 RAM(Expandable) 256MB NAND Flash (Expandable) MicroSD Slot (Optional) 1 eMMC Flash (Optional) 1 QSPI Flash (Optional) 1 Communication: 10/100 Ethernet PHY – 2 Ports SODIMM Edge Interfaces: Debug UART Data UART – 2 Ports CAN – 2 Ports SD(4-Bit) – 1 Port 10/100 Ethernet – Up to 2 Ports 2 USB OTG – 2 Ports 24bpp RGB display port 8-Bit Parallel Camera Port I2S Audio or JTAG I2C x 1 Port PWM GPIOs OS Support: Linux 3.14.28 Power Supply: 3.3V @ 1A through SODIMM edge Note 1: At a time either NAND Flash or eMMC & QSPI flash or uSD & QSPI flash can be used in the SOM. By default NAND Flash is supported. Note 2: If 2 nd Ethernet (ENET2) not used, it can be used as additional 3 UARTs or Key pad 4x4 or RMII interface. Target Applications: Industrial HMI & Access Control Energy management & IOT gateway Industrial control & automation White goods & Smart appliances Medical & Healthcare equipments Mobile POS & Secure e-commerces To send us an enquiry on this product, please click here Enquiry Form To get more details on this product, please write us on [email protected]
記事全体を表示