7 years ago.

I want to put an interrupt on hold. [ Wifi lib timing question for (ODIN-W2) in mbed os 3. ]

Hi All

I run thread with an interrupt of 1 ms by RTC as shown below. When linking the WiFi RUN time library, there is a period during which thread can not be started. Since the RTC interrupt itself has occurred, it seems that it seems that interrupts are disabled. Can we accept threads? In the case of ODIN, I do not know the contents of ublox-odin-w2-drivers.a, so I can not get it.

/media/uploads/Okoshi/sc.png

Excerpt the code below.

RTC_Alarm_IRQHandler is called every 1 ms. It calls thread of tickerInt01 from its RTC_Alarm_IRQHandler. WiFi connection is done. If you type Ping etc, you will see a period not accepting thread.

void tickerInt01(){
	gpio0->write(1);
	{
		// waste time
		volatile int i=1,j=1;
		for (i=0;i<100; i++){
			j=(j*i/0.3);
		}
	}
	gpio0->write(0);
	ticker01handle = 0;
}


void RTC_Alarm_IRQHandler(void)
{
	if(!ticker01handle) {
		ticker01handle = minar::Scheduler::postCallback(tickerInt01).tolerance(minar::milliseconds(1)).getHandle();
	}else{
		gpio1->write(!gpio1->read());
	}
}

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Hi All

It is a question about wifi lib (ODIN-W2) in mbed os 3. I am developing on mbed os 3 (yota) at ODIN-W2.

Although processing is done synchronously by RTC every 1sec, there is timing when processing does not shift to MINER of about 3 ms about once every few seconds. I do not know whether the communication library behind works or not. But I'd like to control the timing when this communication stops, but is there no way (I want to specify the timing to stop)?

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

I investigated this problem and got the following idea. The expected operation may be done by holding the interrupt of EXTI1_IRQn.

Therefore, I want to use the following function. What is the effect of these? If you disable / enable instead of holding it did not do the expected behavior.

NVIC_GetPendingIRQ(IRQn_Type IRQn ) NVIC_SetPendingIRQ(IRQn_Type IRQn ) NVIC_ClearPendingIRQ(IRQn_Type IRQn )

When NVIC_SetPendingIRQ was experimented, the interrupt was not put on hold. Is it being put on hold if used correctly, is not it implemented in ODIN (STM 32 F 439) in the first place?

What kind of behavior do these functions originally intend?

I saw the following but I did not understand well. https://developer.mbed.org/users/screamer/code/mbed/docs/aff670d0d510/group__CMSIS__Core__NVICFunctions.html#gafec8042db64c0f8ed432b6c8386a05d8

B/R All

Be the first to answer this question.