zephyr/samples/portability/cmsis_rtos_v1/timer_synchronization
Andy Ross f288d1e4a7 tests: samples: Apps shouldn't set tick rate
Tick rate is becoming a platform tunable in the tickless world.  Some
apps were setting it due to requirements of drivers or subsystems (or
sometimes for reasons that don't make much sense), but the dependency
goes the other way around now: board/soc/arch level code is
responsible for setting tick rates that work with their devices.

A few tests still use hard-configured tick rates, as they have
baked-in assumptions (like e.g. "a tick will be longer than a
millisecond") that need to be addressed first.

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2019-07-02 22:52:29 -04:00
..
src
CMakeLists.txt
README.rst
prj.conf tests: samples: Apps shouldn't set tick rate 2019-07-02 22:52:29 -04:00
sample.yaml docs: fix misspelling across the tree 2019-06-19 15:34:13 -05:00

README.rst

.. _cmsis_rtos_v1-sync_sample:

Synchronization using CMSI RTOS V1 APIs
#######################################

Overview
********
The sample project illustrates usage of timers and message queues using
CMSIS RTOS V1 APIs.

The main thread creates a preemptive thread which writes message to message queue
and on timer expiry, message is read by main thread.


Building and Running Project
****************************
This project outputs to the console.  It can be built and executed
on QEMU as follows:

.. zephyr-app-commands::
   :zephyr-app: samples/philosophers
   :host-os: unix
   :board: qemu_x86
   :goals: run
   :compact:

Sample Output
=============

.. code-block:: console

    Wrote to message queue: 5
    Read from message queue: 5

    Wrote to message queue: 6
    Read from message queue: 6

    Wrote to message queue: 7
    Read from message queue: 7

    Wrote to message queue: 8
    Read from message queue: 8

    Wrote to message queue: 9
    Read from message queue: 9

    Wrote to message queue: 10
    Read from message queue: 10

    Wrote to message queue: 11
    Read from message queue: 11

    Wrote to message queue: 12
    Read from message queue: 12

    Wrote to message queue: 13
    Read from message queue: 13

    Wrote to message queue: 14
    Read from message queue: 14

    Wrote to message queue: 15
    Read from message queue: 15

    Sample execution successful