It is now possible to temporarily suspend PWM and safely preserve the duty
cycle set. This functionality is needed to allow a device to enter deep
sleep as a PWM instance prevents deep sleep in order for the timer it
relies on to run so its output can be modified. The duty cycle configuration
can be restored upon resuming from deep sleep.
Existing code may a dependency on the old behavior of "-1" to
mean "no instruction". Therefore, update the typedef, and the value
of QSPI_NO_INST, to avoid breaking those uses.
Encourage the usage of consistent types (there are currently
a mix of `int` and `unsigned int` used for qspi instructions)
QSPI commands are limited to 8 bits, to this is a typdef to char
It is possible to temporarily suspend USB and safely preserve its
configuration. This is needed to allow a device to enter deep
sleep as a USBDevice instance prevents deep sleep. USB operation can be
suspended with `deinit` and restored with `connect`.
The QSPI spec allows alt to be any size that is a multiple of the
number of data lines. For example, Micron's N25Q128A uses only a
single alt cycle for all read modes (1, 2, or 4 bits depending on
how many data lines are in use).
Unlinke other compilers supported, the IAR compiler requires the
pre-processor extension to force inline a method to be placed before
the keyword `template` if the method is declared with one.
When a Doxygen group has been defined (created), all its needed to add
documentation to that group is `\addtogroup`. Since all the information
about the group is preserved, it is not necessary to mention the group
hierarchy again with `\ingroup`. This PR removes unnecessary Doxygen lines
across the `drivers`, `events`, `platform` and `rtos` directories.
It also ensures that new groups are created with `\defgroup` once and
referenced with `\addtogroup` whenever documentation needs to be added to
an existing group.
Calls to Timer::attach() are inlined in order not to use floating-point
library functions calls given Timer::attach_us() expects an integer
for the callback interval.
* Create new `s_timestamp_t` type to specify timestamp is seconds
* Alter `attach()` API to expect `s_timestamp_t` for interval value
* Create helper macro to convert seconds to milliseconds and help code
readability
* Modify Greentea tests accordingly
* Modify Doxygen grouping of `drivers` Public/Internal APIs
* Correct classification of `mbed_events.h`
* Amend name of Doxygen group containing Device Key API
* Classify `CallChain.h` as public API and relocate file
* Remove Doxygen group from `equeue_platform.h` as it has no Doxygen compliant documentation
* Move USB target specific code back to `usb/device/targets`
* Fix rtos include path in NRFCordioHCIDriver
* Flatten USB driver directory structure
* Add missing include for us_ticker
* Add more missing includes for us_ticker
* Fix mbed_hal_fpga_ci_test_shield/uart test
* Fix bare-metal build
* Fix Watchdog UNITTEST
* Fix Mbed OS 2 build for Public/Internal headers relocating
* Change Doxygen groups structure, splitting first by Public/Internal
This commit also does the following:
* groups the documentation of related API
* moves `events/internal/equeue.h` to `events/equeue.h`
* merges `events/source/README.md` to `events/README.md`
The contents of the usb directory were moved to appropriate locations and the usb directory removed.
* Public USB headers moved under drivers/
* Internal USB headers moved under drivers/internal/
* USB Source code moved under drivers/source/usb/
* Moved usb/device/hal/ under hal/usb/
* Moved usb/device/USBPhy/ under hal/usb/
* Merged usb/device/targets/ into targets/
* Separated public and private USB API documentation under Doxygen groups drivers-public-api and drivers-internal-api.
Also includes:
* rename `mbed_sleep_manager.c` to `mbed_power_mgmt.c` to match its
header file
* create Doxygen groups for public and internal APIs
* use relative path to include header files where inconsistent
* update references to internal APIs throughout libraries
* update the copyright year for all modified files
Separate drivers, events, and rtos internal APIs from public APIs.
* Move source files to source subdirs
* Move internal headers to internal subdirs
* Add Doxygen comments for documenting internal and public APIs
* Remove source code from header files in order to remove include pre-processor directives
that included header files not directly used by said header files
* Explicitly include header files instead of implicit inclusions via third-party header files.
Release Notes
This will break user code that was using an internal API as the internal header files have been moved.
This will only break if the user was including the header file using a namespace (i.e #include "foo/bar.h" instead of #include "bar.h"
* Adjust definition to make the default constructor `constexpr`.
This permits use in classes that want lazy initialization and their
own `constexpr` constructor, such as `mstd::mutex`.
* Add `get_no_init()` method to allow an explicit optimisation for
paths that know they won be the first call (such as
`mstd::mutex::unlock`).
* Add `destroy()` method to permit destruction of the contained object.
(`SingletonPtr`'s destructor does not call its destructor - a cheat
to omit destructors of static objects). Needed if using in a class
that needs proper destruction.
We will provide documentation how to create your own VirtualWatchdog. It's simple,
create timeout and watchdog objects.
This class brought lot of discussion and questions. After our refactor we made this class
just a linked list of objects - something tickers can do as well (they already have linked list) and handling hw should be
done via Watchdog due to the limitations (timeout can be set only once per app!).