Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to FreeRTOS LTS libraries 202406-LTS #103

Merged
merged 4 commits into from
Jan 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ extern void vLoggingPrintf( const char * pcFormatString,

/* Include support for TCP keep-alive messages. */
#define ipconfigTCP_KEEP_ALIVE ( 1 )
#define ipconfigTCP_KEEP_ALIVE_INTERVAL ( 20 ) /* in seconds */
#define ipconfigTCP_KEEP_ALIVE_INTERVAL ( 300 ) /* in seconds */

/* Include all API's and code that is needed for the IPv4 protocol.
* When defined as zero, the application should uses IPv6. */
Expand Down
3 changes: 3 additions & 0 deletions applications/helpers/ota_orchestrator/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ else()
)

target_link_libraries(ota-update
PUBLIC
jobs-for-aws-iot-embedded-sdk
aws-iot-core-mqtt-file-streams-embedded-c
freertos_kernel
Expand All @@ -29,5 +30,7 @@ else()
helpers-events
backoff-algorithm
crt-helpers
PRIVATE
helpers-logging
)
endif()
12 changes: 12 additions & 0 deletions applications/helpers/ota_orchestrator/src/mqtt_helpers.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,18 @@
#include "ota_register_callback.h"
#include "ota_types_definitions.h"

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "OTA"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

/* Provides external linkage only when running unit test */
#ifdef UNIT_TESTING
#define STATIC /* as nothing */
Expand Down
12 changes: 12 additions & 0 deletions applications/helpers/ota_orchestrator/src/ota_orchestrator.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,18 @@
#include "ota_register_callback.h"
#include "ota_types_definitions.h"

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "OTA"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

#define NUM_OF_BLOCKS_REQUESTED 1U
#define START_JOB_MSG_LENGTH 147U
#define MAX_JOB_ID_LENGTH 64U
Expand Down
12 changes: 12 additions & 0 deletions applications/helpers/ota_orchestrator/src/ota_os_freertos.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,18 @@

#include "ota_types_definitions.h"

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "OTA"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

/* OTA Event queue attributes.*/
#define MAX_MESSAGES 20
#define MAX_MSG_SIZE sizeof( OtaEventMsg_t )
Expand Down
4 changes: 3 additions & 1 deletion applications/helpers/sntp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,13 @@ else()
)

target_link_libraries(helpers-sntp
PUBLIC
backoff-algorithm
connectivity-stack
corepkcs11
coresntp
helpers-logging
mbedtls
PRIVATE
helpers-logging
)
endif()
1 change: 1 addition & 0 deletions applications/keyword_detection/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ target_link_libraries(keyword-detection
fri-bsp
helpers-device-advisor
helpers-events
helpers-logging
mbedtls
ota-update
provisioning-lib
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ target_include_directories(coremqtt-config
.
)

target_link_libraries(coremqtt-config
INTERFACE
helpers-logging
)

target_compile_definitions(coremqtt-agent-config
INTERFACE
MQTT_AGENT_DO_NOT_USE_CUSTOM_CONFIG
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,6 @@
#ifndef CORE_MQTT_CONFIG_H
#define CORE_MQTT_CONFIG_H

#include "logging_levels.h"

/* Logging configuration for the MQTT library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "MQTT"
#endif

#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif

#include "logging_stack.h"

/**
* @brief The maximum number of MQTT PUBLISH messages that may be pending
* acknowledgment at any time.
Expand Down
24 changes: 0 additions & 24 deletions applications/keyword_detection/configs/aws_configs/ota_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,30 +28,6 @@
#ifndef OTA_CONFIG_H_
#define OTA_CONFIG_H_

/**************************************************/
/******* DO NOT CHANGE the following order ********/
/**************************************************/

/* Logging related header files are required to be included in the following order:
* 1. Include the header file "logging_levels.h".
* 2. Define LIBRARY_LOG_NAME and LIBRARY_LOG_LEVEL.
* 3. Include the header file "logging_stack.h".
*/

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "OTA"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

/************ End of logging configuration ****************/

/* Include config file used for testing the OTA PAL. This config file defines
* the otapalconfigCODE_SIGNING_CERTIFICATE macro. */
#include "ota_demo_config.h"
Expand Down
12 changes: 12 additions & 0 deletions applications/keyword_detection/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,18 @@

#include "FreeRTOSConfig.h"

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "main"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

#ifdef AUDIO_VSI
#include "Driver_SAI.h"
#endif
Expand Down
1 change: 1 addition & 0 deletions applications/object_detection/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ target_link_libraries(object-detection
toolchain-override
object_detection_api
object_detection_model
helpers-logging
)

include(${IOT_REFERENCE_ARM_CORSTONE3XX_SOURCE_DIR}/bsp/cmake/SetLinkerOptions.cmake)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ target_include_directories(coremqtt-config
.
)

target_link_libraries(coremqtt-config
INTERFACE
helpers-logging
)

target_compile_definitions(coremqtt-agent-config
INTERFACE
MQTT_AGENT_DO_NOT_USE_CUSTOM_CONFIG
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,6 @@
#ifndef CORE_MQTT_CONFIG_H
#define CORE_MQTT_CONFIG_H

#include "logging_levels.h"

/* Logging configuration for the MQTT library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "MQTT"
#endif

#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif

#include "logging_stack.h"

/**
* @brief The maximum number of MQTT PUBLISH messages that may be pending
* acknowledgment at any time.
Expand Down
1 change: 0 additions & 1 deletion applications/object_detection/isp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,4 @@ target_sources(isp-config
target_link_libraries(isp-config
INTERFACE
isp_control
helpers-logging
)
16 changes: 16 additions & 0 deletions applications/object_detection/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,22 @@

#include "FreeRTOSConfig.h"

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "main"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

#ifdef AUDIO_VSI
#include "Driver_SAI.h"
#endif

#ifdef AUDIO_VSI
#include "Driver_SAI.h"
#endif
Expand Down
1 change: 1 addition & 0 deletions applications/speech_recognition/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ target_link_libraries(speech-recognition
toolchain-override
asr_api
asr_model
helpers-logging
)

include(${IOT_REFERENCE_ARM_CORSTONE3XX_SOURCE_DIR}/bsp/cmake/SetLinkerOptions.cmake)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ target_include_directories(coremqtt-config
.
)

target_link_libraries(coremqtt-config
INTERFACE
helpers-logging
)

target_compile_definitions(coremqtt-agent-config
INTERFACE
MQTT_AGENT_DO_NOT_USE_CUSTOM_CONFIG
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,6 @@
#ifndef CORE_MQTT_CONFIG_H
#define CORE_MQTT_CONFIG_H

#include "logging_levels.h"

/* Logging configuration for the MQTT library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "MQTT"
#endif

#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif

#include "logging_stack.h"

/**
* @brief The maximum number of MQTT PUBLISH messages that may be pending
* acknowledgment at any time.
Expand Down
12 changes: 12 additions & 0 deletions applications/speech_recognition/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,18 @@

#include "FreeRTOSConfig.h"

/* Include header that defines log levels. */
#include "logging_levels.h"

/* Configure name and log level for the OTA library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "main"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
#include "logging_stack.h"

#ifdef AUDIO_VSI
#include "Driver_SAI.h"
#endif
Expand Down
2 changes: 1 addition & 1 deletion components/aws_iot/corejson/library
Submodule library updated 118 files
2 changes: 1 addition & 1 deletion components/aws_iot/coremqtt/library
Submodule library updated 67 files
+47 −0 .github/.cSpellWords.txt
+21 −0 .github/pull_request_template.md
+104 −27 .github/workflows/ci.yml
+23 −0 .github/workflows/formatting.yml
+136 −22 .github/workflows/release.yml
+29 −2 CHANGELOG.md
+130 −58 README.md
+31 −0 cspell.config.yaml
+182 −84 docs/doxygen/config.doxyfile
+2 −2 docs/doxygen/include/size_table.md
+0 −439 lexicon.txt
+1 −1 manifest.yml
+18 −16 sbom.spdx
+132 −55 source/core_mqtt.c
+1 −5 source/core_mqtt_serializer.c
+1 −3 source/core_mqtt_state.c
+13 −2 source/include/core_mqtt.h
+81 −1 source/include/core_mqtt_config_defaults.h
+0 −132 source/include/core_mqtt_default_logging.h
+1 −13 source/include/core_mqtt_serializer.h
+1 −1 source/include/core_mqtt_state.h
+6 −9 source/interface/transport_interface.h
+60 −48 test/CMakeLists.txt
+1 −7 test/cbmc/include/core_mqtt_config.h
+1 −1 test/cbmc/include/event_callback_stub.h
+1 −1 test/cbmc/include/get_time_stub.h
+1 −1 test/cbmc/include/mqtt_cbmc_state.h
+1 −1 test/cbmc/include/network_interface_stubs.h
+2 −1 test/cbmc/proofs/MQTT_Connect/MQTT_Connect_harness.c
+1 −1 test/cbmc/proofs/MQTT_DeserializeAck/MQTT_DeserializeAck_harness.c
+1 −1 test/cbmc/proofs/MQTT_DeserializePublish/MQTT_DeserializePublish_harness.c
+1 −1 test/cbmc/proofs/MQTT_Disconnect/MQTT_Disconnect_harness.c
+6 −1 test/cbmc/proofs/MQTT_GetIncomingPacketTypeAndLength/MQTT_GetIncomingPacketTypeAndLength_harness.c
+1 −1 test/cbmc/proofs/MQTT_GetPacketId/MQTT_GetPacketId_harness.c
+1 −1 test/cbmc/proofs/MQTT_GetSubAckStatusCodes/MQTT_GetSubAckStatusCodes_harness.c
+1 −1 test/cbmc/proofs/MQTT_Init/MQTT_Init_harness.c
+1 −1 test/cbmc/proofs/MQTT_MatchTopic/MQTT_MatchTopic_harness.c
+1 −1 test/cbmc/proofs/MQTT_Ping/MQTT_Ping_harness.c
+1 −1 test/cbmc/proofs/MQTT_ProcessLoop/MQTT_ProcessLoop_harness.c
+2 −1 test/cbmc/proofs/MQTT_Publish/MQTT_Publish_harness.c
+1 −1 test/cbmc/proofs/MQTT_ReceiveLoop/MQTT_ReceiveLoop_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializeAck/MQTT_SerializeAck_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializeConnect/MQTT_SerializeConnect_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializeDisconnect/MQTT_SerializeDisconnect_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializePingreq/MQTT_SerializePingreq_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializePublish/MQTT_SerializePublish_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializePublishHeader/MQTT_SerializePublishHeader_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializeSubscribe/MQTT_SerializeSubscribe_harness.c
+1 −1 test/cbmc/proofs/MQTT_SerializeUnsubscribe/MQTT_SerializeUnsubscribe_harness.c
+2 −1 test/cbmc/proofs/MQTT_Subscribe/MQTT_Subscribe_harness.c
+2 −1 test/cbmc/proofs/MQTT_Unsubscribe/MQTT_Unsubscribe_harness.c
+74 −0 test/cbmc/proofs/lib/print_tool_versions.py
+57 −6 test/cbmc/proofs/lib/summarize.py
+1 −1 test/cbmc/sources/mqtt_cbmc_state.c
+1 −1 test/cbmc/stubs/event_callback_stub.c
+1 −1 test/cbmc/stubs/get_time_stub.c
+1 −1 test/cbmc/stubs/memmove.c
+1 −1 test/cbmc/stubs/network_interface_stubs.c
+36 −0 test/unit-test/cmock_opaque_types.h
+3 −7 test/unit-test/core_mqtt_config.h
+13 −6 test/unit-test/core_mqtt_serializer_utest.c
+6 −6 test/unit-test/core_mqtt_state_utest.c
+132 −2 test/unit-test/core_mqtt_utest.c
+1 −1 test/unit-test/logging/logging_levels.h
+1 −1 test/unit-test/logging/logging_stack.h
+2 −0 tools/cmock/project.yml
+22 −25 tools/coverity/misra.config
2 changes: 1 addition & 1 deletion components/aws_iot/coresntp/library
Submodule library updated 45 files
+31 −0 .github/.cSpellWords.txt
+37 −0 .github/CODEOWNERS
+20 −0 .github/pull_request_template.md
+73 −27 .github/workflows/ci.yml
+23 −0 .github/workflows/formatting.yml
+6 −5 .github/workflows/release.yml
+12 −0 CHANGELOG.md
+82 −33 README.md
+31 −0 cspell.config.yaml
+1 −1 docs/doxygen/code_examples/example_sntp_client_posix.c
+182 −84 docs/doxygen/config.doxyfile
+4 −4 docs/doxygen/include/size_table.md
+0 −262 lexicon.txt
+10 −1 manifest.yml
+15 −13 sbom.spdx
+72 −27 source/core_sntp_client.c
+11 −9 source/core_sntp_serializer.c
+1 −1 source/include/core_sntp_client.h
+1 −1 source/include/core_sntp_config_defaults.h
+5 −5 source/include/core_sntp_serializer.h
+36 −19 test/CMakeLists.txt
+1 −1 test/cbmc/include/core_sntp_cbmc_state.h
+1 −1 test/cbmc/include/core_sntp_config.h
+5 −2 test/cbmc/include/core_sntp_stubs.h
+1 −1 test/cbmc/proofs/Sntp_CalculatePollInterval/README.md
+1 −1 test/cbmc/proofs/Sntp_CalculatePollInterval/Sntp_CalculatePollInterval_harness.c
+1 −1 test/cbmc/proofs/Sntp_ConvertToUnixTime/README.md
+1 −1 test/cbmc/proofs/Sntp_ConvertToUnixTime/Sntp_ConvertToUnixTime_harness.c
+1 −1 test/cbmc/proofs/Sntp_DeserializeResponse/README.md
+1 −1 test/cbmc/proofs/Sntp_DeserializeResponse/Sntp_DeserializeResponse_harness.c
+1 −1 test/cbmc/proofs/Sntp_Init/Sntp_Init_harness.c
+1 −1 test/cbmc/proofs/Sntp_ReceiveTimeResponse/README.md
+1 −1 test/cbmc/proofs/Sntp_ReceiveTimeResponse/Sntp_ReceiveTimeResponse_harness.c
+1 −1 test/cbmc/proofs/Sntp_SendTimeRequest/Sntp_SendTimeRequest_harness.c
+1 −1 test/cbmc/proofs/Sntp_SerializeRequest/README.md
+1 −1 test/cbmc/proofs/Sntp_SerializeRequest/Sntp_SerializeRequest_harness.c
+74 −0 test/cbmc/proofs/lib/print_tool_versions.py
+57 −6 test/cbmc/proofs/lib/summarize.py
+1 −1 test/cbmc/sources/core_sntp_cbmc_state.c
+3 −2 test/cbmc/stubs/core_sntp_stubs.c
+1 −1 test/unit-test/CMock
+7 −1 test/unit-test/core_sntp_client_utest.c
+1 −1 test/unit-test/core_sntp_config.h
+4 −1 test/unit-test/core_sntp_serializer_utest.c
+15 −18 tools/coverity/misra.config
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ else ()
PRIVATE
coremqtt
helpers-events
helpers-logging
iot-tls
)

Expand Down
2 changes: 1 addition & 1 deletion components/connectivity/freertos_plus_tcp/library
Submodule library updated 339 files
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ else()
PRIVATE
coremqtt
helpers-events
helpers-logging
fri-bsp
iot-socket-api
iot-tls
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ target_link_libraries(freertos-libraries-integration-tests-mqtt
# reset request when the device is busy.
target_compile_definitions(freertos-libraries-integration-tests-mqtt
PRIVATE
MQTT_KEEP_ALIVE_INTERVAL_SECONDS=60
MQTT_KEEP_ALIVE_INTERVAL_SECONDS=300
)

add_library(freertos-libraries-integration-tests-pkcs11
Expand Down
10 changes: 5 additions & 5 deletions manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ dependencies:
license: "MIT"
tpip-category: "category-2"
security-risk: "low"
version: "v2.1.1"
version: "v2.3.1"
repository:
type: "git"
url: "https://github.com/FreeRTOS/coreMQTT.git"
Expand All @@ -97,7 +97,7 @@ dependencies:
license: "MIT"
tpip-category: "category-2"
security-risk: "low"
version: "v3.2.0"
version: "v3.3.0"
repository:
type: "git"
url: "https://github.com/FreeRTOS/coreJSON.git"
Expand All @@ -115,7 +115,7 @@ dependencies:
license: "MIT"
tpip-category: "category-2"
security-risk: "low"
version: "v1.2.0"
version: "v1.3.1"
repository:
type: "git"
url: "https://github.com/FreeRTOS/coreSNTP.git"
Expand All @@ -124,7 +124,7 @@ dependencies:
license: "MIT"
tpip-category: "category-2"
security-risk: "low"
version: "v1.3.0"
version: "v1.4.1"
repository:
type: "git"
url: "https://github.com/FreeRTOS/backoffAlgorithm.git"
Expand Down Expand Up @@ -169,7 +169,7 @@ dependencies:
license: "MIT"
tpip-category: "category-2"
security-risk: "low"
version: "ba4e25c350020abcb787a3a319fdf991bef70538"
version: "V4.2.2"
repository:
type: "git"
url: "https://github.com/FreeRTOS/FreeRTOS-Plus-TCP.git"
Expand Down
Loading
Loading