#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 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)
{
SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOB);//使能B模块
GPIODirModeSet(GPIO_PORTB_BASE,PINS,GPIO_DIR_MODE_OUT);//设置为输出
GPIOPinWrite(GPIO_PORTB_BASE,PINS,~PINS);//拉高
GPIOPinWrite(GPIO_PORTB_BASE,PINS,PINS);//拉低
while(1);
}
用CCSV5查看GPIOB寄存器的数据不发生变化,这个问题弄了好几天了不知道什么问题~~按理说能拉高拉低 |