hi all.... This is Gaurav Kothari. I want a very small help from you. As i new to programming part, i started my new project of hello world. my lcd prints it perfectly But now i want my lcd to ask the name first and then to print hello and then the name entered. can anybody please me....
"Finding code like that can be very good at getting the reader to go through the data sheets and determine how the code is doing its job (and get a better understanding of it)."
But in reality, not many seem to bother to try to know about why or how something works. All focus is on the final result with the least amount of own time invested, and where the code represents magical formulas that must not be touched.
"Having well defined names can be as equally useless if the code does not work and can be misleading for a reader who then blindly believes that the code of each line is correct."
The blind will fail whatever the code looks like. But we don't spend our engineering skills for the people who don't care how things works, since we'll have to at least hope that anyone who will later maintain the code will be skilled in the craft. And we then don't want to be embarrased when they start reading the code.
"In an ideal world, yes. But there have been a surprisingly high number of occasions where I've found a bug in an incorrectly specified manifest. So there, the fact that it was pretty was a definite distraction and time waster."
Beginners has a tendancy to go one of two routes. Either zero comments. Or they spend their time to "completely" document what every single code line does in natural language - so the first time they modify the code their comments and their code will start to tell two completely different stories. All code should have meaningful symbol names - but the comments should concentrate on why something happens, instead of telling other developers that a = b+c is adding two numbers and assigning to a third variable. Comments are obviously of no use if they lie.
But a big problem here is that beginners are bad at figuring out what is well crafted code, and what isn't. It isn't until they have spent a significant amount of time working with other peoples code they will start to figure out how huge difference there might be in amount of time needed to modify the code if it's well crafted or not.
more and more 'coding' these days is "plug and play" and many come to the embedded world and expect to find just that. E. g. the ARM 'startup code' provided by manufacturers is wonderful, but, as opposed to manys belief, does not allow you not to think.
the ARM 'startup code' provided by manufacturers is wonderful, but, as opposed to manys belief, does not allow you not to think.
That is so true. Unfortunately, there does seem to be an increasing expectation for instant gratification. It's not unusual to hear "I shouldn't need to know that, I expect the compiler to know that I want to do XYZ".
The likes of Google don't help. Don't get me wrong. I think it's great and would hate to be without it now, but there are many people who either fail to understand how to make a good request or expect the first result to be the most informative.
The hardest thing for people to learn is that a couple of extra hours spent collecting information or planning at the start of the project will save many times over at the end of the project. People are in a hurry, so they jump-start the projects without first figuring out what the actual goal is. So when the do get a hit on Google, they decide it's "close enough" and most probably doesn't even read the full page.
The good thing is that lots of people will fail - and you can learn a lot from a failure. But it's so much smarter and productive to learn from someone elses failure instead of making own failures.
hi all.
Thanks for your help before. I still work on the project and it is nearly working properly. The problem is that it sometimes prints on the second line with a gap. can anybody please me....
this is my new code
unsigned char time[3]={"00"}; void main(void) { unsigned int i,k, j; lcdcmd(0x38); lcdcmd(0x0F); lcdcmd(0x06); lcdcmd(0x01); printstring("ENTER TIME:"); lcdcmd(); lcdcursor(7); i=0; do { time[i]=keypad(); lcddata(time[i]); i++; } while(i!=2); i=0; lcdclear(); lcdcursor(5); printstring("TIME SET", time); msdelay(200); }