Цитата(MALLOY2 @ Jun 6 2010, 12:15)

Не могу скомпилить FREERTOS в IAR ARM 5.50 если включаю "Multi-file Compilation"
А оно Вам надо? Там проблем при такой компиляции хватает, я тут на прошлой неделе с дуру AVR-овсий исходник так компильнул (правда с discard unused public

)- так он молча повыбрасывал одиночные записи в периферию. Ну зачем типа они, если вcе равно никто потом записанное не читает. Да и без этого у него сильная тяга, ели нафиг не запретить, к генерации кроссвызовов. Полное спагетти.
Ну а вообще никаких препятствий нет. Только что собрал свой тестик:
Код
###############################################################################
# #
# IAR ANSI C/C++ Compiler V5.50.0.51878/W32 for ARM 06/Jun/2010 13:48:57 #
# Copyright (C) 1999-2010 IAR Systems AB. #
# #
# Cpu mode = thumb #
# Endian = little #
# Source file = D:\ARM_WORK\CM3Test\EMAC\emac.c #
# Command line = D:\ARM_WORK\CM3Test\EMAC\emac.c -D IAR_ARMCM3_LM -D #
# PACK_STRUCT_END= -lcN D:\ARM_WORK\CM3Test\Works\List\ #
# --remarks --diag_suppress pa050,pe068 -o #
# D:\ARM_WORK\CM3Test\Works\Obj\ --debug --endian=little #
# --cpu=Cortex-M3 -e --fpu=None --dlib_config #
# "D:\IAR\Embedded Workbench 5\ARM\INC\DLib_Config_Normal. #
# h" -I D:\ARM_WORK\CM3Test\ -I #
# D:\ARM_WORK\CM3Test\INCLUDE\ -I #
# D:\ARM_WORK\CM3Test\LM3SLIB\ -I #
# D:\ARM_WORK\CM3Test\LM3SLIB\H\ -I #
# D:\ARM_WORK\CM3Test\..\COMMON\INCLUDE\ -I #
# D:\ARM_WORK\CM3Test\..\COMMON\RTOS\INCLUDE\ -I #
# "D:\IAR\Embedded Workbench 5\ARM\INC\" -Oh --mfc #
# D:\ARM_WORK\CM3Test\LM3SLIB\G\lcd.c #
# D:\ARM_WORK\CM3Test\LM3SLIB\G\rit128x96x4.c #
# D:\ARM_WORK\CM3Test\LM3SLIB\console.c #
# D:\ARM_WORK\CM3Test\LM3SLIB\cpu.c #
# D:\ARM_WORK\CM3Test\MAIN\command.c #
# D:\ARM_WORK\CM3Test\MAIN\main.c #
# D:\ARM_WORK\CM3Test\RESOURCE\cstartup.c #
# D:\ARM_WORK\CM3Test\RESOURCE\ll_init.c #
# D:\ARM_WORK\COMMON\RTOS\croutine.c #
# D:\ARM_WORK\COMMON\RTOS\list.c #
# D:\ARM_WORK\COMMON\RTOS\portable\ARM_CM3\IAR\port.c #
# D:\ARM_WORK\COMMON\RTOS\portable\MEMMANG\HEAP_Z.C #
# D:\ARM_WORK\COMMON\RTOS\queue.c #
# D:\ARM_WORK\COMMON\RTOS\tasks.c #
# List file = D:\ARM_WORK\CM3Test\Works\List\emac.lst #
# Object file = D:\ARM_WORK\CM3Test\Works\Obj\emac.o #
# #
# #
###############################################################################
Как и следовало ожидать без малейших замечаний. Не во FreeRTOS проблема.
Цитата(MALLOY2 @ Jun 6 2010, 12:44)

Вся беда в том что, в queue.h тип xQueueHandle обьявлен как void
Код
typedef void * xQueueHandle;
Во! Забыл я, что всякую такую мишуру давно у себя в своей ветка FreeRTOS поубирал

.
Цитата(MALLOY2 @ Jun 6 2010, 12:44)

Подключил queue.h в queue.c
Определение структуры xQUEUE вынес в queue.h сюдаже и определение типа xQueueHandle. Все собралось, еще не осознал чем это грозит, да и не красиво как то, может есть еще варианты ?
Да ничем, перестали быть скрытыми члены, ну и все.
Вот кусок совершенно аналогично, но по другим причинам, латанного мною:
Код
/*
FreeRTOS.org V5.0.4 - Copyright (C) 2003-2008 Richard Barry.
.....
*/
#ifndef QUEUE_H
#define QUEUE_H
// zlt[
#include "RTOS.h"
#include "task.h"
#include "croutine.h"
#ifdef __cplusplus
extern "C" {
#endif
// Moved from queue.c
// Definition of the queue used by the scheduler.
// Items are queued by copy, not reference.
//
typedef struct QueueDefinition
{
signed char *pcHead; // < Points to the beginning of the queue storage area.
signed char *pcTail; // < Points to the byte at the end of the queue storage area. Once more byte is allocated than necessary to store the queue items, this is used as a marker.
signed char *pcWriteTo; // < Points to the free next place in the storage area.
signed char *pcReadFrom; // < Points to the last place that a queued item was read from.
xList xTasksWaitingToSend; // < List of tasks that are blocked waiting to post onto this queue. Stored in priority order.
xList xTasksWaitingToReceive; // < List of tasks that are blocked waiting to read from this queue. Stored in priority order.
unsigned portBASE_TYPE uxMessagesWaiting; // < The number of items currently in the queue.
unsigned portBASE_TYPE uxLength; // < The length of the queue defined as the number of items it will hold, not the number of bytes.
unsigned portBASE_TYPE uxItemSize; // < The size of each items that the queue will hold.
signed portBASE_TYPE xRxLock; // < Stores the number of items received from the queue (removed from the queue) while the queue was locked. Set to queueUNLOCKED when the queue is not locked.
signed portBASE_TYPE xTxLock; // < Stores the number of items transmitted to the queue (added to the queue) while the queue was locked. Set to queueUNLOCKED when the queue is not locked.
} xQUEUE;
// typedef void * xQueueHandle;
typedef xQUEUE *xQueueHandle;
//]zlt
......