This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

GPIO问题

#include "inc/hw_ints.h"
#include "inc/hw_memmap.h"
#include "inc/hw_types.h"
#include "driverlib/gpio.h"
#include "driverlib/sysctl.h"
#define PINS GPIO_PIN_6
void delay(int d)
{
 for(;d;--d);
}
void SysCtlClockSet(unsigned long ulConfig)
{}

void   SysCtlPeripheralEnable (unsigned long ulPeripheral)
{}

void GPIODirModeSet(unsigned long ulPort,unsigned char ucPins,unsigned long ulPinIO)
{}

void GPIOPinWrite(unsigned long ulPort, unsigned char ucPins, unsigned char ucVal)
{}

int main(void)
{
 unsigned int i;

   SysCtlClockSet(SYSCTL_SYSDIV_1|SYSCTL_USE_OSC|SYSCTL_OSC_MAIN|SYSCTL_XTAL_16MHZ);//直接使用外部晶振
   SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOB);//使能GPIO的PB模块
   GPIODirModeSet(GPIO_PORTB_BASE,PINS,GPIO_DIR_MODE_OUT);//设置PB6输出
   for(i=0;i<10;i++)
   {
    GPIOPinWrite(GPIO_PORTB_BASE, GPIO_PIN_6,1);//置PB6低电平
    delay(20000);
    GPIOPinWrite(GPIO_PORTB_BASE, GPIO_PIN_6,0);//置PB6高电平
    delay(20000);
   }
   SysCtlClockSet(SYSCTL_SYSDIV_1|SYSCTL_USE_PLL|SYSCTL_OSC_MAIN|SYSCTL_XTAL_16MHZ);//使用PLL
   for(i=0;i<10;i++)
   {GPIOPinWrite(GPIO_PORTB_BASE,PINS,~PINS);
   delay(20000);
   GPIOPinWrite(GPIO_PORTB_BASE,PINS,PINS);
   delay(20000);
   }
   while(1);

  // return 0;

}

GPIOB相应的寄存器数据不改变,单步运行没反应。板子是LM3S9B92  开发环境CCSV5