@Nik: As a general rule, if the ST HAL API has a timeout, then it is blocking. For example, if I look at: https://github.com/STMicroelectronics/stm32l4xx-hal-driver/blob/f8e66b7f8db10809f91a4360c154b6304fab06ba/Inc/stm32l4xx_hal_i2c.h We see that the methods/functions are grouped by "Blocking mode: Polling" or "Non-Blocking mode: Interrupt" or "Non-Blocking mode: DMA". You should be able to search for those comments in the above example. When using QP/C or QP/C++, avoid the blocking methods, as noted...
8.1.1 qpcpp build errors with -Wsign-conversion
Hello, This is a common issue with many non-volatile memory access patterns in the embedded space. Most third party NVM related APIs or libraries assume locking and synchronous access patterns. Since the associated device is already a single point of communications (and failure), I nearly always isolate all NVM access into a single active object (thread). Any other AO that needs to write data to the NVM device, must publish or post an event to the associated NVM AO. If it must wait for a success...
Hello, This is a common issue with many non-volatile memory access patterns in the embedded space. Most third party NVM related APIs or libraries assume locking and synchronous access patterns. Since the associated device is already a single point of communications (and failure), I nearly always isolate all NVM access into a single active object (thread). Any other AO that needs to write data to the NVM device, must publish or post an event to the associated NVM AO. If it must wait for a success...
Welcome to QP world. It is great. After reading Samek's book, check out a post I wrote on this topic, here: https://covemountainsoftware.com/2020/03/08/uml-statechart-handling-errors-when-entering-a-state/ Good luck, Matthew
I think it is reasonable for the framework to assume that the underlying system has performed per the required C++ standards. However, here is one idea: https://godbolt.org/z/e8rjrfxh6 #include <cstdint> #include <cstdio> class ConstructorsCalled { public: ConstructorsCalled() : value(MAGIC) {} bool IsConstructorCalled() { return value == MAGIC; } private: static constexpr uint32_t MAGIC = 0x12AB56FE; uint32_t value; }; static ConstructorsCalled called = {}; int main() { printf("Constructors called...
This is one of my checklist items as a consultant to firmware teams: are they storing separately all tools, packages, materials, source code, etc, required, directly or indirectly, to create or recreate their project ? Most projects do not. Especially shorter lived consumer electronics based projects -- fire and forget!
This is one of my checklist items as a consultant to a firmware team: are they storing separately all tools, packages, materials, source code, etc, required, directly or indirectly, to create or recreate their project ? Most projects do not. Especially shorter lived consumer electronics based projects -- fire and forget!