在线时间0 小时
UID2021091
注册时间2013-6-25
NXP金币0
该用户从未签到
新手上路

- 积分
- 36
- 最后登录
- 1970-1-1
|
LDD_TDeviceData* PWM1_Init(LDD_TUserData *UserDataPtr)
{
/* Allocate device structure */
PWM1_TDeviceData *DeviceDataPrv;
/* {MQXLite RTOS Adapter} Driver memory allocation: Dynamic allocation is simulated by a pointer to the static object */
DeviceDataPrv = &DeviceDataPrv__DEFAULT_RTOS_ALLOC;
DeviceDataPrv->UserDataPtr = UserDataPtr; /* Store the RTOS device structure */
DeviceDataPrv->EnUser = TRUE; /* Set the flag "device enabled" */
DeviceDataPrv->RatioStore = 0x01U; /* Ratio after initialization */
DeviceDataPrv->LinkedDeviceDataPtr = TU1_Init((LDD_TUserData *)NULL);
if (DeviceDataPrv->LinkedDeviceDataPtr == NULL) { /* Is initialization of TimerUnit unsuccessful? */
/* Deallocation of the device structure */
/* {MQXLite RTOS Adapter} Driver memory deallocation: Dynamic allocation is simulated, no deallocation code is generated */
return NULL; /* If so, then the PWM initialization is also unsuccessful */
}
/* Registration of the device structure */
PE_LDD_RegisterDeviceStructure(PE_LDD_COMPONENT_PWM1_ID,DeviceDataPrv);
return ((LDD_TDeviceData *)DeviceDataPrv); /* Return pointer to the device data structure */
}
这个参数传什么呢?我传的是NULL;但是没现象
各位大神看哪里有问题,下面附件是我的工程
|
|