This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Advantage of memory pool?

Hi.

I'm currently trying to buffer data from beacon interrupt.

So, I choose to use circular buffer.

Before implementing it myself, I could find that there's already implemented circular queue in SDK library.

But, there're two form of library.

One is memory pool and the other is app_fifo.

I understand app_fifo is what I was trying to implement and it seems simple & easy to use.

But, I couldn't understand what memory pool is supposed to do.

As I understand it's just same as app_fifo, but there's not much explanation for usage of it.

What is the advantage of using memory pool over app_fifo library?

What is the intended use case of memory pool?

Thanks.

Parents
  • As you pointed out, its two libraries implementing the same functionality a circular FIFO buffer.

    The only difference is that the Memory Pool library allocates its buffer from static storage, with the app_fifo library you can chose if you want the buffer to be allocated from static memory or heap.

    The Memory Pool Library is used by our DFU libraries to buffer received data packets.

    I recommend using the app_fifo library since it is well documented and the Memory Pool library is not.

Reply
  • As you pointed out, its two libraries implementing the same functionality a circular FIFO buffer.

    The only difference is that the Memory Pool library allocates its buffer from static storage, with the app_fifo library you can chose if you want the buffer to be allocated from static memory or heap.

    The Memory Pool Library is used by our DFU libraries to buffer received data packets.

    I recommend using the app_fifo library since it is well documented and the Memory Pool library is not.

Children
No Data
Related