This is tal_memory file
更多...
#include "tuya_cloud_types.h"
浏览源代码.
|
#define | Calloc(req_count, req_size) tal_calloc(req_count, req_size) |
|
#define | Free(ptr) tal_free(ptr) |
|
#define | Malloc(req_size) tal_malloc(req_size) |
|
This is tal_memory file
- 版本
- 1.0
- 日期
- 2021-08-24
- 版权所有
- Copyright 2021-2023 Tuya Inc. All Rights Reserved.
◆ tal_calloc()
VOID_T * tal_calloc |
( |
SIZE_T |
nitems, |
|
|
SIZE_T |
size |
|
) |
| |
Allocate and clear the memory
- 参数
-
[in] | nitems | the numbers of memory block |
[in] | size | the size of the memory block |
- 返回
- the memory address calloced
◆ tal_free()
VOID_T tal_free |
( |
VOID_T * |
ptr | ) |
|
This API is used to free memory of system.
- 参数
-
- 返回
- OPRT_OK on success. Others on error, please refer to tuya_error_code.h
◆ tal_malloc()
VOID_T * tal_malloc |
( |
SIZE_T |
size | ) |
|
This API is used to alloc memory of system.
- 参数
-
- 返回
- OPRT_OK on success. Others on error, please refer to tuya_error_code.h
◆ tal_realloc()
VOID_T * tal_realloc |
( |
VOID_T * |
ptr, |
|
|
SIZE_T |
size |
|
) |
| |
Re-allocate the memory
- 参数
-
[in] | nitems | source memory address |
[in] | size | the size after re-allocate |
- 返回
- VOID_T
◆ tal_system_get_free_heap_size()
INT32_T tal_system_get_free_heap_size |
( |
VOID_T |
| ) |
|
Get system free heap size
- 参数
-
- 返回
- OPRT_OK on success. Others on error, please refer to tuya_error_code.h