/* Initialises the memory management block. This function need to be called when the system starts up. */
pn532_error_t pn532_mem_init(uint32_t *mem_pool, uint16_t pool_size)
/* Initialises the memory management block. This function need to be called when the system starts up. */
pn532_error_t pn532_mem_init(uint32_t *mem_pool, uint16_t pool_size)
{
  if ((!mem_pool)||(pool_size==0))
  {
    return PN532_ERROR_MEM_INVALID_PARAM;
  }
  bpool((void*)mem_pool, (bufsize)pool_size);
  _pn532_mem_initialised = TRUE;
  return PN532_ERROR_NONE;
}