66//
77
88#include < app/led/app_led.h>
9+ #include < mcal_benchmark.h>
910#include < mcal/mcal.h>
1011#include < os/os_task.h>
1112
1516
1617ATTRIBUTE (used,noinline) auto main() -> int;
1718
18- auto manip_container () -> bool;
19-
20- constexpr auto sram_start_address = static_cast <mcal_sram_uintptr_t >(UINT8_C(0 ));
21-
22- using sram_container_type =
23- mcal::memory::sram::array<std::uint32_t ,
24- std::uint32_t { UINT32_C (1024 ) * UINT32_C (1024 ) },
25- sram_start_address>;
26-
27- sram_container_type container { };
28-
2919auto main () -> int
3020{
3121 // Initialize the microcontroller abstraction layer.
3222 mcal::init ();
3323
24+ using benchmark_port_type = ::mcal::benchmark::benchmark_port_type;
25+
26+ benchmark_port_type::set_direction_output ();
27+
3428 mcal::spi::sram::mcal_spi_sram_type::init ();
3529
3630 // Configure and create the OS tasks. These macros
3731 // also setup the task static resources including the
3832 // task control block structures and task stacks.
3933
40- OS_TASK_CREATE (app_led_task_background, nullptr , 1U , 64U );
41- OS_TASK_CREATE (app_led_task_toggle_led0, nullptr , 3U , 64U );
34+ OS_TASK_CREATE (app_led_task_background, nullptr , 1U , 512U );
35+ OS_TASK_CREATE (app_led_task_toggle_led0, nullptr , 3U , 32U );
4236
4337 // Start the OS scheduler (and never return).
4438 OS_TASK_START_SCHEDULER ();
4539}
46-
47- auto manip_container () -> bool
48- {
49- static sram_container_type::pointer my_sram_ptr { container.data () };
50- static std::uint32_t my_sram_value { };
51-
52- *my_sram_ptr = my_sram_value;
53-
54- const bool result_sram_is_ok { (*my_sram_ptr == my_sram_value) };
55-
56- ++my_sram_ptr;
57- ++my_sram_value;
58-
59- if (my_sram_ptr == container.data () + container.size ())
60- {
61- my_sram_ptr = container.data ();
62- }
63-
64- return result_sram_is_ok;
65- }
0 commit comments