Quantcast
Channel: MSP low-power microcontrollers
Viewing all articles
Browse latest Browse all 62309

Forum Post: How to continuous blink the LED and do not effect the operation of original code ?

$
0
0
Hi , I am developing in MSP430F5335 + CC2564 with IAR SPPLEDemo_Lite project. When the device is power on , I want the LED will continuous blink when the BT or BLE has not been connected. And the LED will turn on after the BT or BLE has been connected. I try to use the following code to blink the LED. void toggleLED( void ) { P6OUT ^= BIT6; } When the BT or BLE has not been connected , I use the following code to blink the LED. while( connectMode == 0 ){ toggleLED(); BTPS_Delay(500); } The connectMode is set to 0 at the begin before the BT or BLE has been connected. When the BT or BLE has been connected , set the connectMode to the 1. But it seems can not out of the while function , when I try to connect to the device via BLE. How to blink the LED via thread or Timer and do not effect the operation of original code ? But it will not break

Viewing all articles
Browse latest Browse all 62309

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>