We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hello,there: I have met a tough quesiton, how to program with C and Assembly in the project using KEIL(verison 3.0), for example, I wana program the frame with C, and the functions with assembly, especially for RTC conditions, hope someone to give some advice, great thanks advance!
From your post I assume that you are not too familiar with C51 assembly. If this is true then it will be far better for you to stay in the C language. The Keil Compiler/Linker can build better code than you can write in assembly.
If you are more familiar with the C51 assembly language then look into the Keil PK51 User's Guide for instructions how to output C code in assembly language. By selecting the SRC options, Keil will convert your C code to assembly with all the hooks already built. You can then mess up the good C code as you wish.
Bradford
Look for the section titled, "Interfacing C to Assembler" in the C51 Manual...
Great thanks. As you mention there, I get more familiar with C programming, yet I have get some basic knowledge of the assembly using core 8051 instructions. Great interest forces me to get deeper understanding to perform C code to assembly and make my C code more efficient, if getting more clear about the interface of C code with assembly, I could write some more assembly or control the compiler do some efficent work as I wish. Do you have any books illustrate this? e-books comes first, great thanks advance!