12.07.2015 Views

CooCox CoOS 用户手册

CooCox CoOS 用户手册

CooCox CoOS 用户手册

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>CooCox</strong> <strong>CoOS</strong> E_INVALID_PARAMETERE_OK buf #include "CCRTOS.h"OS_MMID mmc;void TaskN (void *pdata){int *ptr;.../* Get a memory block from memory partition *//* mmc: Created by other task */ptr = (int* )CoGetMemoryBuffer(mmc);if (ptr == NULL){printf("Assign buffer fail !\n");}else{.../* Process assigned buffer here */.../* Free assigned buffer to memory partition */CoFreeMemoryBuffer(mmc, (void* )ptr);}...}1buf CoGetMemoryBuffer6.5.7 CoGetFreeBlockNum()U32 CoGetFreeBlockNum(OS_MMID mmID,StatusType* perr)mmID ID perrE_INVALID_IDE_OK ID:71

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!