Sdio WiFi Card Driver

Source: Internet
Author: User
(1) common interfaces of the WiFi card include-CF interface-USB interface-sdio interface-SPI interface-PCMCIA Interface. In many cases, the same WiFi card supports multiple interfaces at the same time, for example, the 8686 WiFi card of Marvell supports both the SPI interface and sdio interface. (2) differences between SD card and sdio card

1. the SD card uses the SD card protocol, while the sdio card uses the sdio protocol. Different protocols have different initialization/read/write methods. the ark1600 Controller supports both SD card and sdio card. The same card slot supports both SD card and sdio card and even combo card on the driver. Therefore, there is a judgment process on the driver, determine whether the SD card or sdio card is inserted. 3. the two pins are defined differently, even though the number of pins is the same (3)

• Sdio protocol-compared with the SD protocol, the sdio Protocol has the following unique commands: limit 5, limit 52, and limit 53-limit 5, which are equivalent to acmd41 in the SD card protocol, used to match the voltage of the sdio card-generally, the listen 52 command is used for reading and writing a single register in the sdio card, and the listen 53 command is used for reading and writing multi-byte data. -The transfer mode of bytes 53 is equivalent to the single-block read/write (Block 17, block 24) of the SD protocol. The block read/write mode is equivalent to that of the SD protocol (Block read/write (Block 18, Block 25) (4)

• Route 53-for the byte transmission mode, it can be 1 ~ Transmission of any length between 512, rather than fixed length-for block transmission mode, its block length can be set manually, but cannot exceed the specified maximum block length-relative to the block transmission mode in the SD card, at the end of the last block transfer, the block Stop command (sequence 12) is not required-each sdio card is composed of 1 ~ Composed of seven functions (optional) and one memory function (mandatory) • What is a function? -A function is an I/O device. It is essentially the organizational distribution of some registers (5) sdio card functions.

• CIA is function0, that is, memory function. Each sdio card must have the following important information:-sdio Protocol version, bus mod, block size. Some of the information is read-only and some are readable and writable • function1 ~ 7 is optional. According to different applications, the number of contained functions is also different. For example, if we use the 8686 chip of Marvell, it only has function0 and function1 (6) sdio 1 ~ 4bit Mode
Pin Sdio 4-Bit mode Sdio 1-Bit mode
1 CD/dat3 Data line 3 N/C Not used
2 CMD Command Line CMD Command Line
3 Vss1 Ground Vss1 Ground
4 VDD Supply Voltage VDD Supply Voltage
5 CLK Clock CLK Clock
6 Vss2 Ground Vss2 Ground
7 Dat [0] Data line 0 Data Data Line
8 Dat [1] Data line1 or Int line IRQ Interruption
9 Dat [2] Data line2 or read wait RW Read wait
1. sdio mode also has 1-bit and 4-bit bus modes. one of the biggest differences between SD and sdio pins is that sdio has an interrupt pin dat [1]. In 4-Bit mode, dat [1] is used for both data lines and line breaks, therefore, it is time-sharing. During command sending on the bus, dat [1] is used for disconnection. (7) SD

Pin SD Mode
1 Name Type Description
2 CD/data3 I/O/PP Card detect/Data line3
3 CMD PP Command/Response
4 Vss1 S Ground
5 VDD S Supply Voltage
6 Vss2 S Ground
7 Dat0 I/O/PP Data line0
8 Dat1 I/O/PP Data line1
9 Dat2 I/O/PP Data line2
• When the host is connected to multiple cards at the same time:-The clock, power supply, and ground wires can be public for each card-but each card has its own data and command bus, avoid interference-during card initialization, commands are sent to each card separately. The driver is allowed to detect the existence of each card slot and allocate the corresponding logical address to each card slot. -Data transmission between the host and the card of each card slot is performed independently, because each card slot has its own data bus. After card Initialization is complete, commands can be sent to each card slot at the same time, this is because the command already contains the logic address of the card (allocated when the card is initialized separately) (8) detection and identification of the SD card and the sdio card

-Power on, send the Listen 5 command. If there is a response and the MP bit in the response is 0, the corresponding card in the card slot is the sdio card, start the initialization process of the sdio card-if the notify 5 command is not responded, it means that the card in the corresponding card slot is SD or mmccard, and then start the initialization process of the SD/mmccard-if the notify 5 command is sent, if there is a response and the MP bit in the response is 1, it means that this card is not only an sdio card, but also an SD card, which is also called a combo card, the combo card initialization process (9) Currently, the WiFi card supported in Linux has the card of the following manufacturer:

-Marvell 8385 and Marvell 8686-intersil prism54 chips series-Intel iwl4965 and iwl3945-atheros Corporation 5xxx chipset-Broadcom (Broadcom) 43xx-ralink (rayling) rt2x00 • Linux supports most of the drivers on the market • Each WiFi card is driven by firmware, in addition, the firmware corresponding to the same card working on different interfaces is different • Note: Many firmware are expensive • firmware is downloaded to the wireless card through its driver, to drive (10) General Software Architecture of wifi driver 1. there are two parts: the above is the host-side driver, and the following is what we mentioned earlier: firmware 2. among them, the main work of firmware is: Because the antenna accepts and sends back 802.11 frames, and the host accepts and transmits All the sent data must be 802.3 frames, so firmware must be responsible for the conversion between 802.3 frames and 802.11 frames. when the antenna receives the data and is processed by firmware, It will be placed in a buffer, resulting in an interruption. After the host receives the interruption, it will read the buffer.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.