mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-20 10:08:33 -04:00
Continue work on SmartFusion demo.
This commit is contained in:
parent
5725c4b305
commit
3144ef3cc6
4 changed files with 28 additions and 51 deletions
|
@ -113,19 +113,25 @@ void vParTestSetLED( unsigned portBASE_TYPE uxLED, signed portBASE_TYPE xValue )
|
|||
|
||||
void vParTestSetLEDFromISR( unsigned portBASE_TYPE uxLED, signed portBASE_TYPE xValue )
|
||||
{
|
||||
if( uxLED < partstMAX_LEDS )
|
||||
{
|
||||
if( xValue == pdTRUE )
|
||||
{
|
||||
ulGPIOState &= ~( 1UL << uxLED );
|
||||
}
|
||||
else
|
||||
{
|
||||
ulGPIOState |= ( 1UL << uxLED );
|
||||
}
|
||||
unsigned portBASE_TYPE uxInterruptFlags;
|
||||
|
||||
MSS_GPIO_set_outputs( ulGPIOState );
|
||||
uxInterruptFlags = portSET_INTERRUPT_MASK_FROM_ISR();
|
||||
{
|
||||
if( uxLED < partstMAX_LEDS )
|
||||
{
|
||||
if( xValue == pdTRUE )
|
||||
{
|
||||
ulGPIOState &= ~( 1UL << uxLED );
|
||||
}
|
||||
else
|
||||
{
|
||||
ulGPIOState |= ( 1UL << uxLED );
|
||||
}
|
||||
|
||||
MSS_GPIO_set_outputs( ulGPIOState );
|
||||
}
|
||||
}
|
||||
portCLEAR_INTERRUPT_MASK_FROM_ISR( uxInterruptFlags );
|
||||
}
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue