diff options
author | Archit Aggarwal <architag@amazon.com> | 2020-11-24 17:13:11 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-24 17:13:11 -0800 |
commit | 152b7db2c1f146a181d75798d10e3840281c9fa5 (patch) | |
tree | e5a50e0e28ddf19f16d32c663316222c219c250b /FreeRTOS-Plus/Demo/AWS | |
parent | e2652a87112493e9a95e8ccbe0d3c2626b7be1f7 (diff) | |
download | freertos-git-152b7db2c1f146a181d75798d10e3840281c9fa5.tar.gz |
Add "Demo completed successfully" log in Jobs demo (#421)
Diffstat (limited to 'FreeRTOS-Plus/Demo/AWS')
-rwxr-xr-x | FreeRTOS-Plus/Demo/AWS/Jobs_Windows_Simulator/Jobs_Demo/DemoTasks/JobsDemoExample.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/FreeRTOS-Plus/Demo/AWS/Jobs_Windows_Simulator/Jobs_Demo/DemoTasks/JobsDemoExample.c b/FreeRTOS-Plus/Demo/AWS/Jobs_Windows_Simulator/Jobs_Demo/DemoTasks/JobsDemoExample.c index 055398dff..b7e3f97e0 100755 --- a/FreeRTOS-Plus/Demo/AWS/Jobs_Windows_Simulator/Jobs_Demo/DemoTasks/JobsDemoExample.c +++ b/FreeRTOS-Plus/Demo/AWS/Jobs_Windows_Simulator/Jobs_Demo/DemoTasks/JobsDemoExample.c @@ -1,5 +1,5 @@ /* - * FreeRTOS Kernel V10.3.0 + * FreeRTOS V202011.00 * Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Permission is hereby granted, free of charge, to any person obtaining a copy of @@ -19,8 +19,8 @@ * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. * - * http://www.FreeRTOS.org - * http://aws.amazon.com/freertos + * https://www.FreeRTOS.org + * https://github.com/FreeRTOS * */ @@ -828,6 +828,7 @@ void prvJobsDemoTask( void * pvParameters ) NEXT_JOB_EXECUTION_CHANGED_TOPIC( democonfigTHING_NAME ), sizeof( NEXT_JOB_EXECUTION_CHANGED_TOPIC( democonfigTHING_NAME ) ) - 1 ) != pdPASS ) { + xDemoStatus == pdFAIL; LogError( ( "Failed to subscribe unsubscribe from the NextJobExecutionChanged API of AWS IoT Jobs service: " "Topic=%s", NEXT_JOB_EXECUTION_CHANGED_TOPIC( democonfigTHING_NAME ) ) ); } @@ -835,9 +836,15 @@ void prvJobsDemoTask( void * pvParameters ) /* Disconnect the MQTT and network connections with AWS IoT. */ if( xDisconnectMqttSession( &xMqttContext, &xNetworkContext ) != pdPASS ) { + xDemoStatus == pdFAIL; LogError( ( "Disconnection from AWS Iot failed..." ) ); } + if( ( xDemoEncounteredError == pdFALSE ) && ( xDemoStatus == pdPASS ) ) + { + LogInfo( ( "Demo completed successfully." ) ); + } + /* Delete this demo task. */ LogInfo( ( "Deleting Jobs Demo task." ) ); vTaskDelete( NULL ); |