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.
Hi all,
I have a small starter problem with my LPC2138
I'm using Flash Magic to make the hex file and program it to the arm controller.
I managed to make a serial connection with the terminal on Flash magic, so I can send characters to it.
What I want to do is to print a sentence to the terminal.
this is how I print a character:
void outchar0(char k) { unsigned long a; //local variable U0THR=k; //ascii code to buffer transmitter while((a=U0LSR&0x41)!=0) { } }
It actually sounds like you don't have much (any?) prior programming experience with any tools for any target - is that right?
If so, then you really need to start from scratch by learning the 'C' programming language; it is a very widely used language, so there is a vast library of books - both real and "virtual" - to help you.
You could start here: http://www.keil.com/books/genbooks.asp Or here: publications.gbdirect.co.uk/.../
but just asking random questions in a forum is probably not a very effective way to learn the basics of the language.
Having learned the 'C' language, you could then move on to applying it to ARM microcontrollers: http://www.keil.com/books/armbooks.asp
"I extracted it from a democode found on the internet."
"demo code" on the internet (and elsewhere) does tend to assume that you know the programming language in which it's written...
Once you have learned the basics of the 'C' programming language, yes - there is.
The not-so-easy part, of course, is the learning of the language that is needed in order to make the solution "easy"!
It's a bit like saying, "is it easy to drive to London?" As driving goes, it's not particularly difficult - but it would be hard if you didn't already know how to drive!