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,
I'm trying to create an application using ONLY assembly language. The program I create assembles dine. The problem is with the linker. Every time, no matter what other files I inlude in the source group, I always get some or the other error. The most common error is L6320W. If you want specifics, I'll let you know. But I've got loads of errors, so not posting all of them.(Please ask if you want to know the others)
Please can anyone guide me on this??? Just tell me the correct procedure to follow. Any help will be appreciated as I'm getting pretty desperate now. I'm using MDK-Lite Version 4.21
I already tried. I couldn't find any specific answer to my question. Most(all) of the threads are discussing invoking assembly code in C or C++ programs.
@Per Westermak If you know of any such thread, please post the link.
I couldn't find any specific answer to my question.
And from that you concluded that you should best not ask any specific question, did you?
Perhaps you should find a project for your board/chip, insert your assembler code into startup.s and get that working. Once you understand how that is constructed, and builds, you'll be in a better place to figure out why your current project fails to build. With all the unspecified errors it contains. Current problems at a guess are with vectors, reset handler, and MicroLIB.
I have seen a number of threads where the linker have issued warning messages because there haven't been any main() available in the project - because the linker have assumed it to be a C project while the poster have wanted to have a strict assembler project.
So the threads exists.
So should I search for linker issues then? I have searched mainly for error l6320w. There are 3 threads including mine, regarding that particular error. Only 1 has any usable info(that too provided by the asker).
We don't know what processor you are using, the code you're attempting to compile/assemble/link, and the exact text associated with the error. Heck may be even a demonstration project.
Do you think this is solvable without some more pertinent details of your specific situation?
@Westonsupermare Pier- Thanks for asking.
It was a very simple program, just for learning the ropes of ARM(I'm just beginning to learn how to use ARM) I think I got the solution. By properly adding source file data(copy pasted) into my assembly file, the relevant file is assembled and linked properly. I checked on the debugger, and proper opcodes are being generated as per my program.
However I have just one more question. In 8051 we used ORG directive to specify the absolute address of CODE or DATA. Any idea how to do this in ARM? Is there a directive for this, or do I have to use linker functions, like scatter loading file( got this from the KEIL uVision HELP).
In the above post I mentioned source file. I meant the startup file (.s) as mentioned by Westonsupermare Pier.
Sorry for so many posts. But thanks to Per Westermark also for suggesting the absence of main() as a cause of error.