2023-04-22 08:21 AM
Hi
In main.c I have got these lines:
osMailQDef (object_pool_q, 10, MEM_memberTypeDef); // Declare mail queue
osMailQId (object_pool_q_id);
object_pool_q_id = osMailCreate(osMailQ(object_pool_q), NULL);
in another file in my therad I want to access object_pool_q_id,
extern osMailQId (object_pool_q_id);
extern osMailQId (object_pool_q_id);
void Start_Mem_Task(void const * argument)
{
while (1) {
osEvent event = osMailGet(object_pool_q_id , osWaitForever);
...
}
}
The linked complains:
undefined reference to `object_pool_q_id'
What is going wrong?
Thx