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

Compiler problem in Keil 5.24.2.0

Hi,

Please find following source code.

		if ( MotorDirection == 1 )
		{
			NRF_LOG_INFO(" Motor Forword");
			nrf_gpio_pin_write(MotorDirectionControl, 1);									// 馬達往前
		}
		else if ( MotorDirection == -1 )
		{
			NRF_LOG_INFO(" Motor Backword");
			nrf_gpio_pin_write(MotorDirectionControl, 0);									// 馬達往後
		}
		else
		{
			NRF_LOG_INFO(" Motor Stop");
			nrf_gpio_pin_write(MotorDirectionControl, 1);
		}

After compiler by Keil 5.24.2, some code will not compiled,

I can see the situation by "enter debug mode, please find following image.

Would you please tell me why?

Thank you

Related