Discussion Forum

Rtx51-tiny and Multiple call to segment warning

Next Thread | Thread List | Previous Thread Start a Thread | Settings

DetailsMessage
Read-Only
Author
YongLiang He
Posted
21-Jul-2004 03:29 GMT
Toolset
C51
New! Rtx51-tiny and Multiple call to segment warning
When I build the following program,I get a warning.

*** WARNING L15: MULTIPLE CALL TO SEGMENT
SEGMENT: ?PR?FUNC?H
CALLER1: ?PR?TASK1?H
CALLER2: ?PR?TASK2?H

The configuration of RTX51-Tiny is,

; Define Round-Robin Timeout in Hardware-Timer ticks.
TIMESHARING EQU 0 ; default is 5 Hardware-Timer ticks.
; ; 0 disables Round-Robin Task Switching
;

Will my program run correctly? How can I remove the warning?
Thanks.

hylnew@tom.com

////////////////////////////////////////////////////////////
//filename: h.c
#include <rtx51tny.h>

//
unsigned char func(bit d)
{

 if(d)return (0);
 else return (1);
}

//
void init(void) _task_ 0
{
 os_create_task(1);
 os_create_task(2);
 os_delete_task(0);
}

//
void task1(void) _task_ 1
{
 while(1){
   os_wait(K_TMO,10,0);
   func(0);
 }
}

//
void task2(void) _task_ 2
{
 while(1){
   os_wait(K_TMO,10,0);
   func(1);
 }
}
////////////////////////////////////////////////////////////
Read-Only
Author
Keil Support, Intl.
Posted
10-Aug-2004 06:40 GMT
Toolset
C51
New! RE: Rtx51-tiny and Multiple call to segment warning
Review the following answers in the Support Knowledgebase:
http://www.keil.com/support/docs/805.htm
http://www.keil.com/support/docs/2042.htm

They also contain links to other related answers that provide detailed explaination about this programming problem.

Another answer that may help is:
http://www.keil.com/support/docs/690.htm
Read-Only
Author
haha @
Posted
13-Aug-2004 04:18 GMT
Toolset
C51
New! RE: Rtx51-tiny and Multiple call to segment warning
懂中文的为什么不到c51bbs.com去看一看~

Next Thread | Thread List | Previous Thread Start a Thread | Settings