This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Idle Task Overrun!

Hi,

I am getting a Idle Task overrun in the following code:

uint32_t parser_get_tlv(uint32_t tlvAddress, TLV_t * tlv)
{
	M25PExx_read(tlvAddress,(uint8_t *)&tlv->tag,sizeof(tlv->tag)); // WORKS FINE!
	tlvAddress += sizeof(tlv->tag);

	M25PExx_read(tlvAddress,(uint8_t *)&tlv->length,sizeof(tlv->length)); // WORKS FINE!
	tlvAddress += sizeof(tlv->length);

	M25PExx_read(tlvAddress,tlv->value,tlv->length); // IDLE TASK OVERRUN!
	tlvAddress += tlv->length;
}

/* Read a block of data */
M25PExx_return_t M25PExx_read(unsigned long address, unsigned char * data, unsigned long size)
{
	unsigned long i;
	
	/* Validate address */
	if(!(address < M25PExx_SIZE))
		return addressInvalid;
	
	/* Validate size */
	if(!((address + size) <= M25PExx_SIZE))
		return sizeInvalid;
	
	M25PExx_SPI_CS_LOW;
	spi_send_receive(CMD_READ);
	
	send_address(address);
	
	for(i=0;i<size;i++)
	{
		data[i] = spi_send_receive(0);
	}
	
	M25PExx_SPI_CS_HIGH;
	
	return success;
}

/* Send one byte through SPI and return the received byte */
uint8_t spi_send_receive(uint8_t aByte)
{
	uint8_t rxByte;
	uint8_t txByte;

	txByte = aByte;

	spiTransaction.count = 1;
	spiTransaction.rxBuf = &rxByte;
	spiTransaction.txBuf = &txByte;

	SPI_transfer(spiHandle,&spiTransaction);

	return rxByte;
}

I am calling parser_get_tlv() from sign_task, not the Idle task. What is the relation between my task and the Idle task?

Best regards,