dio.c

来自「DM642的一些基本功能例程。包括一些图像处理例子」· C语言 代码 · 共 56 行

C
56
字号
/*
 *  Copyright 2003 by Texas Instruments Incorporated.
 *  All rights reserved. Property of Texas Instruments Incorporated.
 *  Restricted rights to use, duplicate or disclose this code are
 *  granted through contract.
 *  
 */
/* "@(#) DDK 1.11.00.00 11-04-03 (ddk-b13)" */
/*
 *  ======== dio.c ========
 *
 *  DSP/BIOS SIO device driver (DEV) which interfaces to IOM mini-
 *  drivers. See the DSP/BIOS Users Guide for more information on SIO
 *
 */

#include <std.h>

#include <dev.h>
#include <sys.h>

#include <dio.h>

Int     DIO_ctrl(DEV_Handle device, Uns cmd, Arg arg);
Int     DIO_issue(DEV_Handle device);

/*
 *  ======== DIO_ctrl ========
 *  Simply call down to the mini-driver.
 */
Int DIO_ctrl(DEV_Handle device, Uns cmd, Arg arg)
{
    Int status;

    DIO_Handle dio = (DIO_Handle)device->object;

    status = dio->fxns->mdControlChan(dio->chanp, cmd, (Ptr)arg);

    if (status < 0 ) {
        return (SYS_EBADIO);
    }
    else {
        return (SYS_OK);
    }
}

/*  ======== DIO_init ========
 *
 */
Void DIO_init(Void)
{
    /*
     *  Module initialization
     */
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?