Return to sdmmc.c CVS log | Up to [local] / funnyos / dev / sdmmc |
File: [local] / funnyos / dev / sdmmc / sdmmc.c (download)
Revision 1.1, Thu Dec 20 15:23:15 2007 UTC (16 years, 5 months ago) by nbrk
totally uncompleted implementation of SD/MMC protocol over SPI lines. code is not finished yet, but commit it so i can hack at home |
/* * $Id: sdmmc.c,v 1.1 2007/12/20 15:23:15 nbrk Exp $ */ #include <sys/types.h> #include <dev/sdmmc/sdmmcvar.h> struct sdmmc_cmdframe sdmmc_command(uint8_t cmd, uint32_t arg, uint8_t crc) { /* * Construct command frame and return it. */ struct sdmmc_cmdframe cmdframe; cmdframe.sc_cmd = CMDFRAME_CMD(cmd); cmdframe.sc_arg = arg; cmdframe.sc_crc = CMDFRAME_CRC(crc); return(cmdframe); }