Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

calling c routine in assembley in keil 8051

Status
Not open for further replies.

satish.ghariya

Member level 1
Joined
Jun 25, 2006
Messages
32
Helped
4
Reputation
8
Reaction score
4
Trophy points
1,288
Location
Noida/Indore
Activity points
1,602
hi..
i want to write C code for my project.. But my project already written in Assembley, and i only want to call some routine which will be written in C..
How can i do that.. can anybody explain me with example..
Satish Ghariya
 

This is impossible. Main project has to be written in C and added to him procedures in asm. On side of www.keil.com are example.

Code:
//deklare funcion in ASM
extern  LCD (unsigned char *ptr);
extern unsigned int Delay(unsigned int k);
...
....
...
...
void (main) void
{
...
...
...
{while(1)
 {
   Delay(0x231);
   LCD("Hello world");
   ...
   ....
 }

}
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top