当前位置: 首页>>代码示例>>C++>>正文


C++ IOWR函数代码示例

本文整理汇总了C++中IOWR函数的典型用法代码示例。如果您正苦于以下问题:C++ IOWR函数的具体用法?C++ IOWR怎么用?C++ IOWR使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了IOWR函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: Hal4D13_GetDataFromChipRam

USHORT Hal4D13_GetDataFromChipRam(void)
{
    USHORT i;
    IOWR(USB_0_BASE,D13_COMMAND_PORT,D13CMD_DEV_RD_RAM);
    i = IORD(USB_0_BASE,D13_DATA_PORT);
    return i;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例2: Hal4D13_GetDevConfig

USHORT Hal4D13_GetDevConfig(void)
{
  USHORT i; 
  IOWR(USB_0_BASE,D13_COMMAND_PORT,D13CMD_DEV_RD_CNFG);
  i = IORD(USB_0_BASE,D13_DATA_PORT);
  return i;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例3: Hal4D13_GetDMACounter

USHORT Hal4D13_GetDMACounter(void)
{
    USHORT i;
    IOWR(USB_0_BASE,D13_COMMAND_PORT,D13CMD_DMA_RD_COUNT);
    i = IORD(USB_0_BASE,D13_DATA_PORT);
    return i;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例4: Hal4D13_ReadChipID

USHORT Hal4D13_ReadChipID(void)
{
    USHORT i;
    IOWR(USB_0_BASE, D13_COMMAND_PORT, D13CMD_DEV_RD_CHIPID);
    i=IORD(USB_0_BASE, D13_DATA_PORT);
    return i;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例5: Hal4D13_GetEndpointStatusWOInteruptClear

UCHAR Hal4D13_GetEndpointStatusWOInteruptClear(UCHAR bEPIndex)
{
    UCHAR c;
    IOWR(USB_0_BASE,D13_COMMAND_PORT, D13CMD_EP_RDSTS + bEPIndex);
    c = (UCHAR)(IORD(USB_0_BASE,D13_DATA_PORT) &0x0ff);
    return c;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例6: Hal4D13_GetErrorCode

UCHAR Hal4D13_GetErrorCode(UCHAR bEPIndex)
{
    UCHAR   c;
    IOWR(USB_0_BASE,D13_COMMAND_PORT, D13CMD_EP_RD_ERR+bEPIndex);
    c = (UCHAR)(IORD(USB_0_BASE,D13_DATA_PORT)&0x0ff);
    return c;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例7: UsbRead

/**
 *
 * This function reads data from the internal registers of the Cypress
 * CY7C67200 USB controller.
 *
 * @param    Address is the address of the register.
 *
 * @return   The data read from the specified address
 *
 * @note     None
 *
 ******************************************************************************/
alt_u16 UsbRead(alt_u16 Address)
{
	//XIo_Out16(HPI_ADDR, Address);
	IOWR(CY7C67200_BASE,HPI_ADDR,Address);
	//usleep(20);
	return IORD(CY7C67200_BASE,HPI_DATA);
}
开发者ID:mantrarush,项目名称:Altera-DE-2,代码行数:19,代码来源:usb.c

示例8: test_sigmoid

/* Tests basic sigmoid functionality */
int test_sigmoid(void){

	float M,time,result;

	alltypes_u input;

	M = 2.24;
	time = 3.8;
	result = 0;

	fprintf(stderr,"Starting sigmoid test....\n");

	fprintf(stderr,"Sigmoid block test register returns [%X].\n", IORD(EULERBLOCK_0_BASE,3));

	fprintf(stderr,"Floats have byte count of [%d].\n",(int)sizeof(float));

	input.fl = M;

	IOWR(EULERBLOCK_0_BASE,0,input.ui);

	/* Check it's corrent */
	input.ui = IORD(EULERBLOCK_0_BASE, 0);


	fprintf(stderr,"Inputs are M=[%4.2f], time=[%4.2f].\n",M,time);

	fprintf(stderr,"IORD returns [%4.8f].\n", input.fl);

	sigmoid(M, time, &result);

	fprintf(stderr,"Sigmoid returned [%4.8f].\n", result);

	return 0;
}
开发者ID:wsheppard,项目名称:ecd2012,代码行数:35,代码来源:sigmoid.c

示例9: Hal4D13_ReadCurrentFrameNumber

USHORT Hal4D13_ReadCurrentFrameNumber(void)
{
    USHORT i;
    IOWR(USB_0_BASE,D13_COMMAND_PORT, D13CMD_RD_FRMNUM);
    i= IORD(USB_0_BASE,D13_DATA_PORT);
    return i;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例10: Hal4D13_GetEndpointConfig

UCHAR Hal4D13_GetEndpointConfig(UCHAR bEPIndex)
{
    UCHAR   c;
    IOWR(USB_0_BASE,D13_COMMAND_PORT, D13CMD_EP_RD_CNFG+bEPIndex);
    c = (UCHAR)(IORD(USB_0_BASE,D13_DATA_PORT) & 0x0ff);
    return c;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:7,代码来源:HAL4D13.c

示例11: processCommand

/* Parses user input string and performs relevant method.
 */
void processCommand(char * userInput, int userInputLength)
{
       
    int userParams [50];
    int nParams = 0;
    int error = 0;
    if(userInputLength > 0)
    {
        nParams = getUserParams(userInput, userParams);
        
        if(strncmp(userInput, "help",4) == 0)
            printHelp();

        else if(strncmp(userInput, "wc ", 3) == 0)
            if(nParams == 2)
            {
                IOWR(CONTROL_BASE, userParams[0], userParams[1]);
                printf("%s\n", userInput);
            }
            else
            {
                error = 1;
            }


        else if(strncmp(userInput, "rc ", 3) == 0)
            if(nParams == 1)
            {
                userParams[4] = IORD(CONTROL_BASE, userParams[0]);
                printf("%s: %d  %x\n", userInput, userParams[4], userParams[4]);
            }
            else
                error = 1;

        else if(strncmp(userInput, "restart", 7) == 0)
            restart();
        else if(strncmp(userInput, "pause", 5) == 0)
            pause();

        else if(strncmp(userInput, "set adc", 7) == 0)
        {
            if(nParams == 4)
            {
                setADCParams(userParams[0], userParams[1], userParams[2], userParams[3]);   
            }  
            else
               error = 1;
         
        }
  
        else
        {
            error = 1;
        }
        // Invalid Command
        if(error == 1) printf("%s: Unknown Command. Type 'help' for list of commands.\n", userInput);    
                                       
    }
}
开发者ID:adrianj,项目名称:RangeImaging,代码行数:61,代码来源:PMD19k_Cyclone.c

示例12: Hal4D13_GetIntEnable

ULONG Hal4D13_GetIntEnable(void)
{
    ULONG i;
    IOWR(USB_0_BASE,D13_COMMAND_PORT,D13CMD_DEV_RD_INTEN);
    i = IORD(USB_0_BASE,D13_DATA_PORT);
    i += (((ULONG)IORD(USB_0_BASE,D13_DATA_PORT)) << 16);
    return i;
}
开发者ID:rkj777,项目名称:GestureControlInterfaceCapstone,代码行数:8,代码来源:HAL4D13.c

示例13: init_timer

void init_timer()
{
	ticks = 0;
	
	/* ajastimen keskeytys päälle */
	IOWR(TIMER, TIMER_CONTROL, 1);
	write_irq_mask(1u << TIMER_IRQ);
}
开发者ID:japeq,项目名称:nios-bootloader,代码行数:8,代码来源:timer.c

示例14: pulse_ISR

static void pulse_ISR(void* context, alt_u32 id)
{
   if (IORD(PIO_PULSE_BASE, 0) == 0)
   {
           IOWR(PIO_RESPONSE_BASE, 0, 1);
           flag++;
   }
   //IOWR(PIO_RESPONSE_BASE, 0, 1);
   if (IORD(PIO_PULSE_BASE, 0) == 1)
   {
           IOWR(PIO_RESPONSE_BASE, 0, 0);
           flag++;
   }
   // clear interrupt
   //IOWR(PIO_PULSE_BASE, 0, 0);
   IOWR(PIO_PULSE_BASE, 3, 0x0);
}
开发者ID:eric9913,项目名称:uwaterloo_ece224,代码行数:17,代码来源:lab1_phase2.c

示例15: SD_Ncc

// Send dummy clock pulse
void SD_Ncc()
{
    IOWR(AVSDC_0_BASE, 0, AV_SDC_SEND_DUMMY);
    /*for (int i = 0; i < 8; i++)
    {
        SD_ClockPulse();
    }*/
}
开发者ID:14dannie,项目名称:gbfpga,代码行数:9,代码来源:sdc.c


注:本文中的IOWR函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。