Parent epic: #268
Scope
Wire the meta SD-ELEMENT (sequenceId + sysUpTime + language) into Example/FreeRtos/SingleTask/main.c and untag structured_data.feature from the FreeRTOS BDD sweep.
Slice 7 (#308) wired the first SD-ELEMENT — Origin — landing 4 of 5 origin scenarios. Slice 8 adds the meta SD's three callbacks; slice 9 will follow with the timeQuality SD which untags time_quality.feature and the remaining origin.feature::All standard structured data present scenario.
Deliverables
- New
Platform/FreeRtos/Interface/SolidSyslogFreeRtosSysUpTime.h + Platform/FreeRtos/Source/SolidSyslogFreeRtosSysUpTime.c mirroring the Posix/Windows shape: SolidSyslogFreeRtosSysUpTime_Get returns uint32_t hundredths-since-boot, wraps per RFC 3418 TimeTicks. Backed by xTaskGetTickCount() × 100 / configTICK_RATE_HZ.
- Switch
Example/FreeRtos/SingleTask/FreeRTOSConfig.h to configTICK_TYPE_WIDTH_IN_BITS = TICK_TYPE_WIDTH_64_BITS so the multiplication cannot intermediate-overflow at any sane tick rate. (Existing tick consumers in main.c already cast to uint32_t explicitly — transparent.)
- Host-TDD: new
Tests/Platform/FreeRtos/SolidSyslogFreeRtosSysUpTimeTest.cpp against a stubbable xTaskGetTickCount seam, mirroring the slice-4 datagram test layout.
- Wire
SolidSyslogStdAtomicOps_Create → SolidSyslogAtomicCounter_Create → SolidSyslogMetaSd_Create into InteractiveTask alongside the slice-7 originSd. Reuse Example/Common/ExampleLanguage.c (ExampleLanguage_Get callback emitting en-GB, matching the Linux/Windows examples).
- Add
Example/Common/ExampleLanguage.c to the FreeRTOS source list (one CMakeLists line).
- Update CLAUDE.md "Public header audiences" with a new row for
SolidSyslogFreeRtosSysUpTime.h.
Atomic ops choice — StdAtomicOps
The cross toolchain already compiles SolidSyslogStdAtomicOps.c for Cortex-M3 (build/freertos-cross/.../SolidSyslogStdAtomicOps.c.obj). On Cortex-M3 + Thumb-2, _Atomic uint32_t lowers to inline LDREX/STREX with no libatomic runtime needed, and the SolidSyslog counter is incremented only inside SolidSyslog_Log — task context only on this single-task example, never from an ISR. The ARM exclusive monitor is sufficient. No new platform adapter needed; if linkage fails (unlikely) we fall back to a SolidSyslogFreeRtosAtomicOps wrapping taskENTER_CRITICAL / taskEXIT_CRITICAL.
Acceptance — BDD untag scope
time_quality.feature stays tagged: both scenarios assert tzKnown (timeQuality SD — slice 9). origin.feature::All standard structured data present stays tagged: needs sequenceId + tzKnown together.
Expected after slice 8: FreeRTOS BDD sweep at 6 features / 17 scenarios (slice-7 baseline 5 / 14).
Local pre-PR
cmake --build --preset freertos-cross --target SolidSyslogFreeRtosSingleTask clean
behave --tags='not @wip and not @freertoswip and @udp' Bdd/features/structured_data.feature Bdd/features/origin.feature Bdd/features/time_quality.feature
- Linux unit tests including the new
SolidSyslogFreeRtosSysUpTimeTest
clang-format --dry-run --Werror on touched C files
- cppcheck / tidy / iwyu / sanitize / coverage: CI's responsibility per established precedent
Out of scope
- timeQuality SD (separate slice).
- The
udp_mtu.feature::Oversize scenario — UDP path-MTU EMSGSIZE on FreeRTOS-Plus-TCP, its own slice.
- CMake-driven memory scaling for the interactive-task stack (already deferred).
- Real-IP enumeration via
FreeRTOS_GetEndPoints (deferred to S08.03 close — see DEVLOG slice 7).
Parent epic: #268
Scope
Wire the meta SD-ELEMENT (sequenceId + sysUpTime + language) into
Example/FreeRtos/SingleTask/main.cand untagstructured_data.featurefrom the FreeRTOS BDD sweep.Slice 7 (#308) wired the first SD-ELEMENT — Origin — landing 4 of 5 origin scenarios. Slice 8 adds the meta SD's three callbacks; slice 9 will follow with the timeQuality SD which untags
time_quality.featureand the remainingorigin.feature::All standard structured data presentscenario.Deliverables
Platform/FreeRtos/Interface/SolidSyslogFreeRtosSysUpTime.h+Platform/FreeRtos/Source/SolidSyslogFreeRtosSysUpTime.cmirroring the Posix/Windows shape:SolidSyslogFreeRtosSysUpTime_Getreturnsuint32_thundredths-since-boot, wraps per RFC 3418TimeTicks. Backed byxTaskGetTickCount()×100 / configTICK_RATE_HZ.Example/FreeRtos/SingleTask/FreeRTOSConfig.htoconfigTICK_TYPE_WIDTH_IN_BITS = TICK_TYPE_WIDTH_64_BITSso the multiplication cannot intermediate-overflow at any sane tick rate. (Existing tick consumers inmain.calready cast touint32_texplicitly — transparent.)Tests/Platform/FreeRtos/SolidSyslogFreeRtosSysUpTimeTest.cppagainst a stubbablexTaskGetTickCountseam, mirroring the slice-4 datagram test layout.SolidSyslogStdAtomicOps_Create→SolidSyslogAtomicCounter_Create→SolidSyslogMetaSd_CreateintoInteractiveTaskalongside the slice-7 originSd. ReuseExample/Common/ExampleLanguage.c(ExampleLanguage_Getcallback emittingen-GB, matching the Linux/Windows examples).Example/Common/ExampleLanguage.cto the FreeRTOS source list (one CMakeLists line).SolidSyslogFreeRtosSysUpTime.h.Atomic ops choice — StdAtomicOps
The cross toolchain already compiles
SolidSyslogStdAtomicOps.cfor Cortex-M3 (build/freertos-cross/.../SolidSyslogStdAtomicOps.c.obj). On Cortex-M3 + Thumb-2,_Atomic uint32_tlowers to inline LDREX/STREX with no libatomic runtime needed, and the SolidSyslog counter is incremented only insideSolidSyslog_Log— task context only on this single-task example, never from an ISR. The ARM exclusive monitor is sufficient. No new platform adapter needed; if linkage fails (unlikely) we fall back to aSolidSyslogFreeRtosAtomicOpswrappingtaskENTER_CRITICAL/taskEXIT_CRITICAL.Acceptance — BDD untag scope
structured_data.feature— untag at feature level. All 3 scenarios (sequenceId 1, sequential sequenceId, sysUpTime + language) pass.time_quality.featurestays tagged: both scenarios asserttzKnown(timeQuality SD — slice 9).origin.feature::All standard structured data presentstays tagged: needs sequenceId + tzKnown together.Expected after slice 8: FreeRTOS BDD sweep at 6 features / 17 scenarios (slice-7 baseline 5 / 14).
Local pre-PR
cmake --build --preset freertos-cross --target SolidSyslogFreeRtosSingleTaskcleanbehave --tags='not @wip and not @freertoswip and @udp' Bdd/features/structured_data.feature Bdd/features/origin.feature Bdd/features/time_quality.featureSolidSyslogFreeRtosSysUpTimeTestclang-format --dry-run --Werroron touched C filesOut of scope
udp_mtu.feature::Oversizescenario — UDP path-MTU EMSGSIZE on FreeRTOS-Plus-TCP, its own slice.FreeRTOS_GetEndPoints(deferred to S08.03 close — see DEVLOG slice 7).