Commit Graph

7 Commits (371f183a6a5d915617861c23cedcdbf0354a9072)

Author SHA1 Message Date
Christopher Haster c39ce94b09 equeue: Removed RTOS dependencies when RTOS not present 2018-02-15 10:20:12 -06:00
Russ Butler b2384b1629 Remove use of internal RTX types
Make calls to cmsis-os to get thread state, stack size, and max stack
usage rather than accessing internal RTX data directly. Wrap RTX5
specific code in OS_BACKEND_RTX5.

Also refactor the code to use mbed types rather than RTX types:
os_timer_t -> mbed_rtos_storage_timer_t
os_event_flags_t -> mbed_rtos_storage_event_flags_t
osRtxMutex_t -> mbed_rtos_storage_thread_t
2017-09-04 11:26:38 -05:00
Christopher Haster 3934b30b58 events: Adopt osEventFlags from RTX 5
This provides the correct binary semaphore behaviour that was expected
by the equeue layer, removes concerns around semaphore overflow, and
reduces the number of spurious wakeups which may save a bit of power.

This also fixes some issues we were seeing around the RTX 5 changes
to semaphore behaviour.
2017-06-15 15:47:15 -05:00
Bartek Szatkowski b793a3fb89 Update codebase for CMSIS5/RTX5
Update all of mbed-os to use RTX5.
2017-05-30 18:55:52 +01:00
Christopher Haster 2bcb09560b events: Fixed zero wait condition in non-rtos semaphore
Before, if the semaphore recieved a wait of zero, the semaphore
would erronously drop the ticker event to wake up the device,
causing the device to go to sleep without any mechanism to wake
itself up.

During a dispatch operation, the event queue dispatches all events
that have expired, so the call to equeue_sema_wait very rarely
has a wait of zero. But this can happen when an event is posted
just after a dispatch has occured.
2017-04-05 17:21:51 -05:00
Jimmy Brisson f1a78027d3 Add tags to our code 2016-10-04 15:02:44 -05:00
Bogdan Marinescu e7abc11f59 Added mbed-events library
Added mbed-events from https://github.com/ARMMbed/mbed-events. Changes
from upstream:

- the whole code is licensed under the Apache license. Sources and
  headers were updates with this information.
- removed the porting layers for Windows and FreeRTOS and the references
  to these porting layers in equeue_platform.h.
- moved the TESTS directory in mbed-events to the TESTS directory of
  mbed-os.
2016-09-29 18:44:09 +03:00