Re: ChibiOS OS Library Test Suite
Posted: Mon Jan 25, 2021 11:54 am
I will look into this.
Giovanni
Giovanni
ChibiOS Web Boards
https://forum.chibios.org/
Code: Select all
dyn_buffer_t *chFactoryCreateBuffer(const char *name, size_t size) {
dyn_buffer_t *dbp;
F_LOCK();
dbp = (dyn_buffer_t *)dyn_create_object_heap(name,
&ch_factory.buf_list,
sizeof (dyn_buffer_t) + size,
CH_HEAP_ALIGNMENT);
if (dbp != NULL) {
/* Initializing buffer object data.*/
memset((void *)(dbp + 1), 0, size);
}
F_UNLOCK();
return dbp;
}
00:00:38.314 DEBUG main.c::print_mem:51 - core free memory : 56216 bytes
00:00:38.342 DEBUG main.c::print_mem:52 - heap fragments : 2
00:00:38.367 DEBUG main.c::print_mem:53 - heap free total : 552 bytes
00:00:38.395 DEBUG main.c::print_mem:54 - heap free largest: 408 bytes
00:00:38.423 DEBUG main.c::main:194 - Iteration: 1 Errors: 0
...
00:37:40.363 DEBUG main.c::print_mem:51 - core free memory : 56216 bytes
00:37:40.391 DEBUG main.c::print_mem:52 - heap fragments : 2
00:37:40.417 DEBUG main.c::print_mem:53 - heap free total : 552 bytes
00:37:40.445 DEBUG main.c::print_mem:54 - heap free largest: 408 bytes
00:37:40.472 DEBUG main.c::main:194 - Iteration: 56 Errors: 0