Thank you for your reply,
I create a partition into ram for Vector table and isr handler for adc and timer like
ram_isr (NOLOAD) :
{
KEEP(*(.Vector_ram))
KEEP(*(.ISR_ram))
KEEP(*(ADC_ISR))
} > SRAM_8
Declare them like
__attribute__((section(".ISR_ram"))) void Custom_ADC16_IRQ_HANDLER_FUNC(void)
{
g_Adc16ConversionDoneFlag = true;
/* Read conversion result to clear the conversion completed flag. */
g_Adc16ConversionValue = ADC16_GetChannelConversionValue(DEMO_ADC16_BASE, DEMO_ADC16_CHANNEL_GROUP);
ADC16_SetChannelConfig(DEMO_ADC16_BASE, DEMO_ADC16_CHANNEL_GROUP, &adc16ChannelConfigStruct);
g_Adc16InterruptCounter++;
SDK_ISR_EXIT_BARRIER;
}
__attribute__((section(".ISR_ram"))) void Custom_TMR1_IRQHandler(void)
{
/* Clear interrupt flag.*/
QTMR_ClearStatusFlags(TMR1, kQTMR_CompareFlag);
tmr_count++;
// PRINTF("\r\n Timer interrupt has occurred !");
// qtmrIsrFlag = true;
SDK_ISR_EXIT_BARRIER;
}
for vector table
unsigned int __attribute__((section(".Vector_ram"))) g_vectorTable[49];
__disable_irq();
DisableGlobalIRQ();
memcpy(g_vectorTable, (unsigned int *)SCB->VTOR, sizeof(uint32_t) * 48);
SCB->VTOR = &g_vectorTable;
__enable_irq();
the main thing for my project is i don't want to disable the interrupt while flash operation i need them. and i also move the isr handler into ram but still not write/read on particular address of the ram. please provide any suggestion or solutiond.
Thank you