Issues with FreeRTOS queue and changing "Queue Size" and "msg_size"
There are times where I would like a message queue of a single depth. In some similar OSes this is also how semaphores are created. I have hit a near brick wall in STM32CubeMX failing to create a queue with just one element.
In this case for the STM32F4 library, I get the following call where I set a "Queue Size" 1 in:
Middleware -> FreeROTS -> Tasks and Queues -> Queues -> Queue Size.
This creates a function:
I2CWriteQHandle = osMessageQueueNew (2, sizeof(i2c_data_type), &I2CWriteQ_attributes);
Note the "msg_count" argument is 2, despite all the I2CWriteQ_attributes being consistent with those being set in ST32CubeMX. If the queue is increased to say 16, msg_count remains at 2. Other queues with a osMessageQueueNew "msg_count" set at 16, remain at 16.
If I manually correct the "msg_count" argument, the new value is retained when (re)generating the code.
I presume this behaviour of unlinking "Queue Size" "msg_count" is unintened and not sure when this issue started. BTW I am using v6.7.1 and have applied the patch associated with this version.
