source: svn/newcon3bcm2_21bu/dst/dhl/src/DHL_OSAL.c @ 76

Last change on this file since 76 was 76, checked in by megakiss, 10 years ago

1W 대기전력을 만족시키기 위하여 POWEROFF시 튜너를 Standby 상태로 함

  • Property svn:executable set to *
File size: 14.3 KB
Line 
1/*
2        DHL_OSAL.c
3       
4        OS Abstraction Layer Implementation
5
6        Description:
7                OS Heap/.. implementation
8
9        Copyright 2006~2010 Digital STREAM Technology, Inc.
10        All Rights Reserved
11*/
12
13#include "DHL_OSAL.h"
14#include "DHL_OSAL_Priv.h"
15#include "DHL_DBG.h"
16#include "DHL_OSAL_Impl.h"
17#include "bcmmemmgr.h"
18
19
20/*
21        ¸ðµç Çì´õ ÆÄÀÏÀ» Æ÷ÇÔÇÏÁö´Â ¾ÊÀ¸¸ç, compile timeÀ» ÁÙÀ̱â À§ÇØ
22        °¢ ¸ðµâÀº ÇÊ¿äÇÑ ¸¸Å­ÀÇ Çì´õ¸¦ ¼±¾ðÇϵµ·Ï ÇÔ.
23*/
24
25
26
27/*
28        DHL µð¹ö±× ¸ðµâ À̸§ Á¤ÀÇ ·ê Âü°í:
29
30        DHL ¸ðµâµéÀº ¸ðµÎ * ·Î ½ÃÀÛ.
31        API´Â ´ë¹®ÀÚ, Platform ¹× ±âŸ´Â ¼Ò¹®ÀÚ »ç¿ë.
32
33        µðÆúÆ® ·¹º§Àº 0À¸·Î ¼³Á¤ÇÑ´Ù. (0: ¿¡·¯ ¸Þ½ÃÁö¸¸ Ãâ·Â)
34       
35       
36*/
37
38//DHL_MODULE("*osal", 0);
39
40
41#if COMMENT
42____Config____(){}
43#endif
44
45/*
46        ÀÌ ¸ðµâ ³»ºÎ¿¡¼­ »ç¿ëµÇ´Â °¢Á¾ configuration Á¤ÀÇ.
47*/
48
49
50/* #define SUPPORT_FAST_SWITCHING_OPTIMIZATION 1 */
51/* #define FUNC_MONITOR_TIMER_ID TIMER_ID_FUNC_MONITOR */
52
53/*
54        1·Î ¼³Á¤Çϸé malloc ¹öÆÛ ¾Õ µÚ·Î guard ¿µ¿ªÀ» Ãß°¡ È®º¸Çϰí,
55        memory overrun µîÀÇ ¿¡·¯ üũ ¼öÇà.
56
57        heap debug ¿É¼ÇÀ» »ç¿ëÇϰí ÀÖ´Ù¸é buf headerÀÇ memCheck°¡ ÀÌ ¿ªÇÒÀ» ´ë½ÅÇϰí ÀÖÀ¸¹Ç·Î
58        guard ¿É¼ÇÀÌ ÇÊ¿äÇÏÁö ¾ÊÀ½.
59*/
60#if DHL_OS_USE_HEAP_DEBUG
61        #define USE_MEMORY_GUARD 0
62#else
63        #define USE_MEMORY_GUARD 1
64#endif
65
66
67#if DHL_OS_USE_HEAP_DEBUG
68#define USE_MEM_FOOTER 1
69        // 1À̸é HEADER »Ó¸¸ ¾Æ´Ï¶ó FOOTER±îÁöµµ Ãß°¡ÇÑ´Ù.
70        // Ãß°¡ÀÇ ¸Þ¸ð¸®°¡ ¼Ò¿äµÇ³ª
71        // memory corruption ±îÁö üũÇÏ·Á¸é ÀÌ ¿É¼ÇÀ» »ç¿ëÇÑ´Ù.
72
73#define CHECK_MEM_CORRUPTION 1
74        // memory corruption (overrun) check¸¦ ¼öÇàÇÑ´Ù.
75        // »ç¿ëµÇÁö ¾Ê´Â ºó °ø°£¿¡ check patternÀ» ±â·ÏÇϱ⠶§¹®¿¡ ¾à°£ÀÇ ¼º´É °¨¼Ò ¿¹»ó.
76
77#define CHECK_MEM_LEAK 1
78        // memory ´©¼ö¸¦ È®ÀÎÇϱâ À§ÇØ ÀÏÁ¤ ÀÌ»ó memory°¡ »ç¿ëµÇ¸é
79        // heap »óŸ¦ Ãâ·ÂÇϵµ·Ï ÇÑ´Ù.
80
81#endif
82
83static DHL_OS_SEMA_ID semTask; // store BSS storage.
84
85/*
86        osi_takemutexsemaphore api´Â Ç¥ÁØ api°¡ ¾Æ´Ï¶ó¼­ Á¦°Å.
87        ¸ðµç sem¿¡¼­ °ø¿ëÀ¸·Î »ç¿ëÇÏ´Â api »ç¿ëÇÏ¸é µÊ.
88*/
89#define osi_takemutexsemaphore(s) osi_takesemaphore(s)
90
91
92extern int printf(const char *format, ...);
93
94#if COMMENT
95____Types____(){}
96#endif
97
98
99
100
101
102
103#if COMMENT
104____Variables____(){}
105#endif
106
107/*
108        global·Î Àû¿ëµÇ´Â variable Á¤ÀÇ.
109        °¢ function º°·Î Ư¼öÇÑ ¿ëµµÀÇ variableÀº °¢ functionX block ¿¡¼­ Á¤ÀÇ °¡´É.
110*/
111
112
113#if COMMENT
114____Task____(){}
115#endif
116
117
118
119//BKNOTE: ¹Ýµå½Ã task Á¾·á½Ã¿¡ DHL_OS_SelfDeleteTask() È£ÃâÇØÁà¾ß ÇÔ. (uCOS-II Á¦¾à)
120DHL_OS_TASK_ID DHL_OS_CreateTask(DHL_OS_TASKFUNCTION func, const char *name, 
121                                 int priority, int stackSize, UINT32 arg1)
122{
123//      UINT32 i;
124        DHL_OS_TASK_ID tid;
125       
126        osi_takemutexsemaphore(semTask);
127        tid = osi_spawntask(func, name, priority, stackSize, arg1);
128        osi_givemutexsemaphore(semTask);
129
130        if(tid==0)
131        {
132                DHL_OS_Printf("|%s| fail to add task(name:%s).\n", __FUNCTION__, name);
133                return DHL_INVALID_TASK_ID;
134
135        }
136       
137        DHL_OS_Printf("|%s| func = %x, arg1 = %d(%x), stk_size = %d\n",
138                      __FUNCTION__, func, arg1, arg1, stackSize);
139
140        return (DHL_OS_TASK_ID)tid;
141
142}
143
144void DHL_OS_SelfDeleteTask(void)
145{
146        DHL_OS_Printf("|%s| delete Task\n", __FUNCTION__);
147        osi_selfdeletetask();
148}
149
150void DHL_OS_SetTaskPriority(DHL_OS_TASK_ID tid, UINT32 newPrio, UINT32 *pOldPrio)
151{
152        if (pOldPrio == NULL)
153        {
154                return;
155        }
156       
157        osi_changetaskpriority(tid, newPrio, pOldPrio);
158//      void osi_changetaskpriority(os_task_id tid, UINT32 newPrio, UINT32 *oldPrioPtr)
159
160       
161        DHL_OS_Printf("|%s| change priority %d -> %d \n", __FUNCTION__, *pOldPrio, newPrio );
162}
163
164DHL_RESULT DHL_OS_FindTaskByName(const char *name, DHL_OS_TASK_ID *returnTid)
165{
166        if(!name || strlen(name)==0) {
167                printf("bad task name !!\n");
168                *returnTid=0;
169                return DHL_FAIL_INVALID_PARAM;
170        }
171       
172        osi_takemutexsemaphore(semTask);
173        *returnTid=osi_taskidfromname((char *)name);
174        osi_givemutexsemaphore(semTask);
175        return DHL_OK;
176}
177
178DHL_OS_TASK_ID DHL_OS_GetTaskID(void)
179{
180        DHL_OS_TASK_ID tid; 
181        tid = osi_taskid();
182        return tid;
183}
184
185DHL_RESULT DHL_OS_GetTaskInfo(DHL_OS_TASK_ID tid, DHL_OS_TASK_INFO *pTaskInfo)
186{
187       
188        b_task_stats *stat;
189        if (pTaskInfo == NULL)
190        {
191                DHL_OS_Printf("|%s| null arg(pTaskInfo).\n", __FUNCTION__);
192               
193                return DHL_FAIL_NULL_POINTER;
194        }
195
196        stat=bos_get_task_info((b_task_t)tid);
197        if(stat)
198        {
199                pTaskInfo->tid = tid;
200                pTaskInfo->name = stat->name;
201                pTaskInfo->priority= tid;
202        }else
203        {
204                DHL_OS_Printf("|%s| fail to find task(tid:0x%x).\n", __FUNCTION__, tid);
205                return DHL_FAIL_INVALID_HANDLE;
206        }
207
208        return DHL_OK;
209}
210
211char *DHL_OS_TaskName(DHL_OS_TASK_ID tid)
212{
213       
214        if(tid==(DHL_OS_TASK_ID)0) {
215                tid=osi_taskid();
216        }
217       
218        return osi_taskname(tid);
219}
220
221
222int DHL_OS_TaskPriority()
223{
224        return osi_taskpriority();
225}
226
227
228#if COMMENT
229____Semaphore____(){}
230#endif
231
232
233DHL_OS_SEMA_ID DHL_OS_CreateCountingSemaphore(const char *name, UINT32 options,
234                                              UINT32 count)
235{
236        return osi_createcountingsemaphore(name, options, count);
237
238}
239
240DHL_OS_SEMA_ID DHL_OS_CreateBinarySemaphore(const char *name, UINT32 options,
241                                            BOOL flag)
242{
243        return osi_createbinarysemaphore(name, options, flag);
244}
245
246DHL_OS_SEMA_ID DHL_OS_CreateMutexSemaphore(const char *name)
247{
248        return osi_createmutexsemaphore(name);
249}
250
251void DHL_OS_DeleteSemaphore(DHL_OS_SEMA_ID sem)
252{
253        printf("delete sem %x\n", sem);
254        osi_deletesemaphore(sem);
255}
256
257DHL_RESULT DHL_OS_TakeSemaphore(DHL_OS_SEMA_ID sem, UINT32 millisec)
258{
259        int ticks;
260
261        if (millisec == DHL_TIMEOUT_FOREVER)
262        {
263                if (osi_in_interrupt() || osi_in_tasklock()) {
264//                      osi_dbgprint("\a !! take sem in isr or tasklock\n");
265                        return DHL_FAIL_INVALID_STATE;
266                }
267
268                return osi_takesemaphore(sem);
269        }
270        else if(millisec == 0)
271        {
272                return osi_takesemaphore_nowait(sem);
273        }else
274        {
275                if (osi_in_interrupt() || osi_in_tasklock())
276                {
277//                      osi_dbgprint("\a !! take sem in isr\n");
278                        return DHL_FAIL_INVALID_STATE;
279                }
280                ticks = MS_TO_TICKS(millisec);
281
282                return osi_takesemaphore_wait(sem, ticks);
283        }
284        return DHL_OK;
285}
286
287DHL_RESULT DHL_OS_GiveSemaphore(DHL_OS_SEMA_ID sem)
288{
289        return osi_givesemaphore(sem);
290}
291
292
293#if COMMENT
294____OS_MessageQ____(){}
295#endif
296
297
298void _msg_api_test(void)
299{
300#if 0
301        typedef struct
302        {
303                unsigned char f;
304                unsigned int a;
305                unsigned short int b;
306                unsigned short int c;
307                unsigned int d;
308        } TEST_MSG;
309       
310        MS_S32 qid;
311        TEST_MSG smsg, rmsg;
312        MS_U32 rmsg_size;
313        MS_BOOL ret;
314        int i;
315       
316        // create
317        qid = MsOS_CreateQueue(NULL,
318                               96,
319                               E_MSG_FIXED_SIZE,
320                               sizeof(TEST_MSG),
321                               E_MSOS_FIFO,
322                               "Test");
323        printf("qid=%x\n", qid);
324       
325        // send
326        for (i = 0; i < 100; i++)
327        {
328                printf("<%5d>snd %3d:", DHL_OS_GetMsCount(), i + 1);
329               
330                smsg.f = i;
331                smsg.a = 0x82600628 + (0x08 * i);
332                smsg.b = 0x25099052 + (0x04 * i);
333                smsg.c = 0xcafeefac + (0x10 * i);
334                smsg.d = 0xbeeffeeb + (0x02 * i);
335                ret = MsOS_SendToQueue(qid,
336                                       (MS_U8 *)&smsg,
337                                       sizeof(TEST_MSG),
338                                       100);
339               
340                printf("ret=%x, f=%x, a=%x, b=%x, c=%x, d=%x\n", ret,
341                       smsg.f, smsg.a, smsg.b, smsg.c, smsg.d);
342        }
343       
344        // receive
345        for (i = 0; i < 150; i++)
346        {
347                printf("<%5d>rcv %3d:", DHL_OS_GetMsCount(), i + 1);
348               
349                ret = MsOS_RecvFromQueue(qid,
350                                         (MS_U8 *)&rmsg,
351                                         sizeof(TEST_MSG),
352                                         &rmsg_size,
353                                         100);
354               
355                printf("ret=%x, size=%x, f=%x, a=%x, b=%x, c=%x, d=%x\n", ret,
356                       rmsg_size, rmsg.f, rmsg.a, rmsg.b, rmsg.c, rmsg.d);
357        }
358#endif
359}
360
361DHL_OS_MSGQ_ID DHL_OS_CreateMessageQueue(const char *name, UINT32 options, 
362                                         UINT32 maxMessages,
363                                         UINT32 maxMessageLength)
364{
365        return osi_createmessagequeue(name, options, maxMessages, maxMessageLength);
366}
367
368void DHL_OS_DeleteMessageQueue(DHL_OS_MSGQ_ID qid)
369{
370        osi_deletemessagequeue(qid);
371}
372
373DHL_RESULT DHL_OS_SendMessage(DHL_OS_MSGQ_ID qid, void *buffer, int bytes)
374{
375        return osi_sendmessage(qid, buffer, bytes);
376}
377
378DHL_RESULT DHL_OS_ReceiveMessage(DHL_OS_MSGQ_ID qid, void *msgBuf,
379                                 UINT32 millisec)
380{
381
382        if (millisec == DHL_TIMEOUT_FOREVER)
383        {
384                if (osi_in_interrupt() || osi_in_tasklock()) {
385                        osi_dbgprint("\a !! rcv msg in isr or tasklock\n");
386                        return DHL_FAIL_INVALID_STATE;
387                }
388                return osi_receivemessage(qid, msgBuf);
389        }
390        else if(millisec == 0)
391        {
392                return osi_receivemessage_wait(qid, msgBuf, NO_WAIT);
393
394        }else
395        {
396                if (osi_in_interrupt() || osi_in_tasklock())
397                {
398                        osi_dbgprint("\a !! rcv msg in isr\n");
399                        return DHL_FAIL_INVALID_STATE;
400                }
401                return osi_receivemessage_wait(qid, msgBuf, MS_TO_TICKS(millisec));
402        }
403
404        return DHL_OK;
405}
406
407
408#if COMMENT
409____OS_Heap____(){}
410#endif
411
412
413void *DHL_OS_Malloc(int size)
414{
415        return OS_Malloc(size);
416}
417
418void DHL_OS_Free(void **pptr)
419{
420        return OS_Free(pptr);
421}
422
423extern bcm_heap_t *g_p_sdram_heap;
424void DHL_OS_GetHeapStatus(DHL_OS_HEAP_STATUS *pHeapStatus)
425{
426#ifdef BCM_DEBUG
427
428        struct bcm_heap_status bhs;
429        memset(pHeapStatus, 0, sizeof(dhl_heap_status));
430       
431        if (mem_status(g_p_sdram_heap, &bhs) == 0) {
432                pHeapStatus->size_heap = bhs.size_heap;
433                pHeapStatus->num_alloc_chunk = bhs.num_alloc_chunk;
434                pHeapStatus->size_alloc = bhs.size_alloc;
435                pHeapStatus->num_free_chunk = bhs.num_free_chunk;
436                pHeapStatus->size_free = bhs.size_free;
437        }
438#endif
439}
440
441
442#if COMMENT
443____OS_Tick____(){}
444#endif
445
446
447void DHL_OS_Delay(UINT32 millisec)
448{
449        if (osi_in_interrupt() || osi_in_tasklock()) {
450                osi_dbgprint("\a !! delay in isr or tasklock\n");
451                return;;
452        }
453        osi_delay(millisec);
454
455}
456
457UINT32 DHL_OS_GetMsCount(void)
458{
459        return TICKS_TO_MS(osi_gettickcount());
460}
461
462
463UINT32 DHL_OS_GetTickCount(void)
464{
465        return osi_gettickcount();
466}
467
468
469UINT32 DHL_OS_GetTicksPerSecond(void)
470{
471        return osi_gettickspersecond();
472}
473
474
475#if COMMENT
476____OS_Interrupt____(){}
477#endif
478
479
480BOOL DHL_OS_GetIntState()
481{
482        return osi_in_interrupt();
483
484}
485
486UINT32 DHL_OS_DisableInterrupts()
487{
488        return osi_disableint();
489
490}
491
492void DHL_OS_RestoreInterrupts(UINT32 mask)
493{
494        osi_enableint(mask);
495
496}
497
498
499#if COMMENT
500___Task_Enum___(){}
501#endif
502
503
504void DHL_OS_ShowTaskInfo(int level)
505{
506}
507
508
509#if COMMENT
510___Task_Priority___(){}
511#endif
512
513
514/*
515        OS º°·Î highest, lowest priority°¡ ´Ù¸£¹Ç·Î
516        inversion ÀÛ¾÷À» ´ë½ÅÇØ ÁÖ´Â ¸ÅÅ©·Î¸¦ »ç¿ë.
517
518        ¾Æ·¡ Å×ÀÌºí¿¡¼­´Â °¢ taskÀÇ »ó´ëÀûÀÎ ¼ø¼­¸¸ Àâ¾ÆÁÖ¸é µÇµµ·Ï ÇÔ.
519*/
520#define PRIO(x) (64-(x))
521
522struct 
523{
524        const char *signiture;
525        int prio;
526
527} p_prio_tbl[] =
528{
529#if 1//Newcon3 DST
530{ "APP_INIT",   14, },
531
532{ "DRV_GPB",    15, },  //x
533{ "DRV_IR",     30, },  //uio_task (x-1)        //16->30
534{ "DRV_GPIO",   18, },
535{ "DRV_UART",   20, },
536
537{ "DRV_TIMER",  21, },
538{ "DRV_FE",     23, }, 
539{ "DRV_BASE",   24, },
540
541{ "DHL_PSIPRX", 29, },  //26->29
542{ "DHL_EVENT",  27, },
543{ "DHL_AV_EVT", 28, },
544
545//{ "DMW_TUNER",        29, },
546
547// UI °ü·Ã
548{ "DIGIT_KEY",  32, },
549{ "MENU",               22, },  //19 -> 22
550{ "COMM",               31, },  //22->31
551
552// Caption °ü·Ã
553{ "DCC_AUX",    34, },
554{ "AUX_CC",     35, },
555{ "DCC_DCD",    36, },
556{ "DCC_DMX",    37, },
557{ "VBI_DEC",    38, },
558{ "CC_TIMER",   39, },
559
560{ "EA",                 44, },
561
562{ "DMC_TASK",   45, }, // old channel mw
563{ "DMW_CHM",    46, }, // new channel mw, channel tuning control
564
565{ "DMW_PSI",    47, }, // new psi mw, psi/psip scan task
566{ "DMW_EPGSCN", 48, }, // old epg mw
567{ "DMW_EPGEVT", 49, }, // old epg mw
568
569{ "DMW_TIMER",  51, }, // General purpose timer
570{ "APP_TIMER",  53, }, // Sleep timer ¿ëÀ¸·Î »ç¿ëµÇ´Â °ÍÀ¸·Î º¸ÀÓ.
571
572{ "SIGMON",     54, }, // signal monitor task
573
574{ "DHL_SHELL",  56, }, // µð¹ö±× ½©
575{ "DHL_SHELLX", 57, }, // µð¹ö±× ½© background ½ÇÇà
576
577{ "DHL_PRINTF", 58, }, // console printf task
578{ "DMW_FLASH",  59, }, // Flash worker task (for NVM)
579
580#else
581        { "APP_INIT",   PRIO(50), },
582
583        { "DRV_GPB",    PRIO(49), },
584        { "DRV_IR",     PRIO(48), },
585        { "DRV_GPIO",   PRIO(46), },
586        { "DRV_UART",   PRIO(44), },
587
588        { "DRV_TIMER",  PRIO(43), },
589        { "DRV_FE",     PRIO(41), }, 
590        { "DRV_BASE",   PRIO(40), },
591
592        { "DHL_PSIPRX", PRIO(38), },
593        { "DHL_EVENT",  PRIO(37), },
594        { "DHL_AV_EVT", PRIO(36), },
595
596        { "DMW_TUNER",  PRIO(35), },
597
598        // UI °ü·Ã
599        { "DIGIT_KEY",  PRIO(32), },
600        { "MENU",       PRIO(45), },
601        { "COMM",       PRIO(42), },
602
603        // Caption °ü·Ã
604        { "DCC_AUX",    PRIO(30), },
605        { "AUX_CC",     PRIO(29), },
606        { "DCC_DCD",    PRIO(28), },
607        { "DCC_DMX",    PRIO(27), },
608        { "VBI_DEC",    PRIO(26), },
609        { "CC_TIMER",   PRIO(25), },
610       
611        { "EA",         PRIO(20), },
612
613        { "DMC_TASK",   PRIO(19), }, // old channel mw
614        { "DMW_CHM",    PRIO(18), }, // new channel mw, channel tuning control
615
616        { "DMW_PSI",    PRIO(17), }, // new psi mw, psi/psip scan task
617        { "DMW_EPGSCN", PRIO(16), }, // old epg mw
618        { "DMW_EPGEVT", PRIO(15), }, // old epg mw
619
620        //{ "SCTESI_RX",  PRIO(17), }, // scte oob si scan task
621
622        { "DMW_TIMER",  PRIO(13), }, // General purpose timer
623        { "APP_TIMER",  PRIO(11), }, // Sleep timer ¿ëÀ¸·Î »ç¿ëµÇ´Â °ÍÀ¸·Î º¸ÀÓ.
624
625        { "SIGMON",     PRIO(10), }, // signal monitor task
626
627        { "DHL_SHELL",  PRIO(8), }, // µð¹ö±× ½©
628        { "DHL_SHELLX", PRIO(7), }, // µð¹ö±× ½© background ½ÇÇà
629
630        { "DHL_PRINTF", PRIO(6), }, // console printf task
631        { "DMW_FLASH",  PRIO(5), }, // Flash worker task (for NVM)
632#endif
633};
634
635/*
636        task signiture¸¦ task priority·Î º¯È¯ÇÏ¿© ÁÖ´Â util ÇÔ¼ö.
637*/
638int os_sig2taskprio(const char *signiture)
639{
640        int i;
641        for (i=0;(unsigned int)i<sizeof(p_prio_tbl)/sizeof(p_prio_tbl[0]); i++)
642                if (strcmp(signiture, p_prio_tbl[i].signiture)==0)
643                        return p_prio_tbl[i].prio;
644
645        DHL_OS_Printf("!! unknown task signiture '%s'\n", signiture);
646        //DHL_ASSERT(FALSE, "");
647        return 1;
648}
649
650
651#if COMMENT
652____Symbol____(){}
653#endif
654
655
656#if DHL_REGISTER_DEUBG_SYMBOLS
657        // OSAL ÀÌ ¸Ç ¸ÕÀú ÃʱâÈ­ µÇ¹Ç·Î DBG ¸ðµâÀº ¾ÆÁ÷ ÃʱâÈ­ ¾ÈµÇ¾úÀ½.
658        // µû¶ó¼­ OSAL¿¡¼­´Â alias symbol »ç¿ë ºÒ°¡´ÉÇÔ.
659#endif  /* DHL_REGISTER_DEUBG_SYMBOLS */
660
661
662#if COMMENT
663____Init____(){}
664#endif
665
666
667void DHL_OS_Init(void)
668{
669        // add entry task info
670        OS_TCB tcb;
671        OSTaskQuery( OS_PRIO_SELF, &tcb );      /* use our priority as a task id */
672
673        if (semTask) {
674                printf("\nDHL_OS_Init() already initialized. \n");
675                return; // already initialized.
676        }
677
678        semTask = osi_createmutexsemaphore("sem task");
679
680}
681
682void print_heap_status(void)
683{
684        DHL_OS_HEAP_STATUS status;
685       
686        DHL_OS_GetHeapStatus(&status);
687        DHL_OS_Printf("total_size = %x, size_free = %x, size_alloc = %x\n",
688                      status.size_heap, status.size_free,
689                      status.size_alloc);
690}
691
692
693/* end of file */
Note: See TracBrowser for help on using the repository browser.