How to use USB CDC ACM

Kernel Configuration On Embedded Platform Insmod Drivers After that, a new UART device node will be found in /dev/ [crayon-6822feb9012fd197769735/] Connect Target to Host with a USB cable You will see…

How to use USB device networking

Kernel Configuration On Embedded Target Insmod Drivers After that, you will see a new usb ethernet adapter by 'ifconfig -a' [crayon-6822feb9014e5471517627/] Assign ethernet adapter 'usb0' with IP address [crayon-6822feb9014e9468874071/] Connect Target…

T104x SD/MMC boot research

PBL -> load RCW (64 bytes/512 bits) -> write to RCWSRn cfg_rcw_src [0]_[1:4]_[5:8] -> 0_0100_0000 cfg_rcw_src用以决定RCW配置字的来源 RCW[PBI_SRC]用以决定PBL初始化控制器的类别 SD启动,起始地址为0x0000_1000,SD Card block size 512KB Useful macros: CONFIG_SYS_FSL_PBL_RCW CONFIG_SYS_FSL_PBL_PBI Reference https://pagure.io/u-boot/raw/2015-07/f/board/freescale/t104xrdb/README u-boot:board/freescale/t104xrdb/README

CAN review

本人最早在06、07年开始搞CAN总线,采用的是RM9200+SJA1000和LPC2100通信。 当时CAN有CANOpen和DeviceNet 2种架构之分。我们采用了开源的lincan-0.3.2,把CAN注册为一个char设备,然后通过read/write函数进行CAN报文的接收和发送。 最近玩了freescale的i.MX6UL,这颗CPU本身具备2路CAN总线。 查了下当前CAN的支持,发现从2.6.25开始,CAN已经被引入到linux内核中,并被作为一个socket设备进行管理。 工具 由于CAN被整合进network,所以需要新的ip才能支持,点击进官网。或者可以使用GIT同步代码: [crayon-6822feb9018b1455555020/] 常用的CAN命令 查看可设置的配置参数: [crayon-6822feb9018b5049035127/] 设置CAN波特率为1Mbps: [crayon-6822feb9018b7382782872/] 查看CAN的配置: [crayon-6822feb9018b8874255203/] 启动/停止CAN: [crayon-6822feb9018b9981594399/] 或者 [crayon-6822feb9018bb305773192/] 接收CAN报文: [crayon-6822feb9018bc734431528/] 发送CAN报文 [crayon-6822feb9018bd381004157/] 例如使用通道CAN1发送CAN ID为1,带有5个数据(0x01 0x23 0x45 0x67 0x89)的报文: [crayon-6822feb9018be153875954/]…