NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.
Microcontroller Programming » I can write to my MCU but it won't work
May 31, 2011 by thatguy |
Hey guys, I don't know what has happened, but I am using the printf function to write to the computer, my program WAS working 2 days ago, (i didn't tamper with code) and now it's not working, Today i was initially trying out some new code on it, when that didn't work I reverted back to my old (unchanged) code, now I am able to write to the chip however, I expect to see lines printed in hyperterminal and there is nothing coming up, the chip isn't lighting any LED's which would have been on the board for testing purposes either.... Is there a way to fully flash the chip or any tests I can do to see if the chip is damaged? Thanks in advance ! |
---|---|
May 31, 2011 by 6ofhalfdozen |
Heya Thatguy, A couple quick suggestions..
|
June 01, 2011 by thatguy |
I've tried putting on the temperature sensor code and still nothing, Something i've noticed, when i am not in programming mode, the pin PB0 is giving out 5 volts, it's very strange :( |
June 01, 2011 by hevans (NerdKits Staff) |
Hi thatguy, Just to make sure I understand the symptoms. You can flash the chip with any new programs, and the command line shows no errors, but when you do flash a program the chip does not seem to respond? Have you tried flashing a very simple program like blinking an LED just to make sure there is nothing in the LCD wiring that is tripping you up. Humberto |
June 01, 2011 by thatguy |
I've done what you said Humberto, and it seems to only...... work when it wants to, I wrote the program twice to the chip before attempting anything and I got it to work once (turning on an LED), It just seems a bit bizarre, It could be just my machine or something small, I was just wondering was it a common problem, I was afraid I did damage to the chip because I was using pin 14 and I thought I might done something to damage the chip. Hopefully I will have a better day tomorrow with it, thanks guys ! |
June 03, 2011 by BobaMosfet |
First rule of debugging- don't assume because your code seemed to work the first time and now isn't, that it was right. Either it or something else about your setup was different than it is now. Assume nothing, check everything. BM |
June 03, 2011 by BobaMosfet |
Don't fixate on pin 14 being +5-- that may just be due to a pullup. BM |
Please log in to post a reply.
Did you know that interrupts can cause problems if you're not careful about timing and memory access? Learn more...
|