1987cuimeng

    1. F28027采集数字传感器的信号 4/4158 DSP 与 ARM 处理器 2012-02-16
      用F28027把基本的程序写出来了,按着时序一步步,但是有个问题就是,设置定时器有点问题, 请各位高手帮忙看一下。 #include "DSP28x_Project.h"     // Device Headerfile and Examples Include File #define unchar  unsigned char /// Select the example to compile in.  Only one example should be set as 1 // the rest should be set as 0. void Gpio_select1(void); void Gpio_select2(void); void RH(void); unchar COM(void); //interrupt void cpu_timer0_isr(void); typedef unsigned char  U8;       /* defined for unsigned 8-bits integer variable           无符号8位整型变量  */ U8  U8temp; U8  flag; U8  U8T_data_H,U8T_data_L,U8RH_data_H,U8RH_data_L,U8checkdata; U8  U8T_data_H_temp,U8T_data_L_temp,U8RH_data_H_temp,U8RH_data_L_temp,U8checkdata_temp; U8  U8comdata; void main(void) { // Step 1. Initialize System Control: // PLL, WatchDog, enable Peripheral Clocks // This example function is found in the DSP2802x_SysCtrl.c file.    InitSysCtrl(); // Step 2. Initalize GPIO: // This example function is found in the DSP2802x_Gpio.c file and // illustrates how to set the GPIO to it's default state. // InitGpio();  // Skipped for this example // For this example use the following configuration: //   Gpio_select(); // Step 3. Clear all interrupts and initialize PIE vector table: // Disable CPU interrupts    DINT; // Initialize PIE control registers to their default state. // The default state is all PIE interrupts disabled and flags // are cleared. // This function is found in the DSP2802x_PieCtrl.c file.    InitPieCtrl(); // Disable CPU interrupts and clear all CPU interrupt flags:    IER = 0x0000;    IFR = 0x0000; // Initialize the PIE vector table with pointers to the shell Interrupt // Service Routines (ISR). // This will populate the entire table, even if the interrupt // is not used in this example.  This is useful for debug purposes. // The shell ISR routines are found in DSP2802x_DefaultIsr.c. // This function is found in DSP2802x_PieVect.c.    InitPieVectTable(); // Step 4. Initialize all the Device Peripherals: // This function is found in DSP2802x_InitPeripherals.c // InitPeripherals(); // Not required for this example    EALLOW;  // This is needed to write to EALLOW protected registers        PieVectTable.TINT0 = &cpu_timer0_isr;    EDIS;    // This is needed to disable write to EALLOW protected registers    InitCpuTimers();     // 100MHz CPU Freq, 1 second Period (in uSeconds)    ConfigCpuTimer(&CpuTimer0, 60, 1000000);//100    StartCpuTimer0();        // Enable CPU INT1 which is connected to CPU-Timer 0:    IER |= M_INT1;    // Enable TINT0 in the PIE: Group 1 interrupt 7    PieCtrlRegs.PIEIER1.bit.INTx7 = 1;    // Enable global Interrupts and higher priority real-time debug events:    EINT;   // Enable Global interrupt INTM    ERTM;   // Enable Global realtime interrupt DBGM        for(;;); } void delay_loop0()  //执行每条指令 225ns {     unsigned int   i,j;     for (i = 0; i
    2. F28027采集数字传感器的信号 4/4158 DSP 与 ARM 处理器 2012-02-11
      我要用的是单总线的DHT11,时序图看着也还可以,TI提供了AD的例程,找好久都没有看到采集数字传感器信号的程序,表示很无奈,C51的也看了,看懂了,只是不知道怎样用DSP来编
    3. 求高人指点,这块板子可以用ADS这个编译工具,写完并且编译好下载到开发板中吗,我是刚刚接触ARM的,应该怎么办

最近访客

< 1/1 >

统计信息

已有70人来访过

  • 芯积分:--
  • 好友:--
  • 主题:2
  • 回复:3

留言

你需要登录后才可以留言 登录 | 注册


现在还没有留言