Join us in Chat. Click link in menu bar to join. Unofficial chat day is every Friday night (US time).
0 Members and 1 Guest are viewing this topic.
Could probably be a problem with soldering to one of the other pins. Check the wire that goes to the RESET pin of the mcu. If that looks ok then also look at the MOSI/MISO wires.
Just as a two-cents thing, when you start up AVRStudio and make a new project, you select the chip. Did you do that, or are you just writing code? Does your code build? It might be trying to connect to the wrong chip because you may have selected the wrong one when starting your project.MIKE
Try this:Open AVR Studio, but don't open any files. I assume you're using AVRStudio 4.something, because this is different (and horrifying) for AVRStudio 5 and 6.Click "New Project"Click "AVR GCC"Name the project whatever you want. We're just trying to connect here, so it doesn't matter.Click NEXTNow you get to choose a "Debug Platform". Choose "AVR Simulator". I have no idea what this does, but I've never used debug mode anyway :-PYou'll see that there is a list of chips to choose. Scroll down to the chip you have, which I guess is an ATMega8?Select it and hit finish.NOW try to connect and see if it works. You won't be able to download anything yet (you'll need to put code into the project...) but you're just testing to see if you can connect to the chip.MIKE
Quote from: mstacho on July 05, 2012, 08:28:44 AMTry this:Open AVR Studio, but don't open any files. I assume you're using AVRStudio 4.something, because this is different (and horrifying) for AVRStudio 5 and 6.Click "New Project"Click "AVR GCC"Name the project whatever you want. We're just trying to connect here, so it doesn't matter.Click NEXTNow you get to choose a "Debug Platform". Choose "AVR Simulator". I have no idea what this does, but I've never used debug mode anyway :-PYou'll see that there is a list of chips to choose. Scroll down to the chip you have, which I guess is an ATMega8?Select it and hit finish.NOW try to connect and see if it works. You won't be able to download anything yet (you'll need to put code into the project...) but you're just testing to see if you can connect to the chip.MIKEMike, I am going to try this when I get home tonight.I will let you know.Thx for your help! Much appreciated!
Erik,I had a similar problem, here's a list of things I tried:Double check you have the latest 4.x version of AVRStudioUpdate the firmware on the AVRISPMKII (Tools->AVRISP mkii Update)Check in Device Manager (Control Panel->System->Hardware->Device Manager) for the driver. You should have a Jungo driverCheck that the AVRISPMKII light goes green when the robot is connectedHopefully one of those will help solve the problem!Adrian
Erik,Only a couple of other suggestions then,a) if you haven't already try following this tutorial: http://www.societyofrobots.com/member_tutorials/book/export/html/290 (to make sure you have't missed a step and to see the debugging techniques mentioned)b) read through this post http://www.avrfreaks.net/index.php?name=PNphpBB2&file=printview&t=86205&start=20 not sure if it's fixed yet but at one stage apparently you had to run 'regsvr32 scomm.dll', probably worth a shot.Adrian
If your uC is not soldered in, you can check it fairly easily using a solderless breadboard. All you need to do is set up a power circuit and the SPI pins (the pins that are used to program it). Then try all the steps you otherwise went to in order to connect. If that doesn't work, the uC is broken somehow. Try it with another one (they're only like $1 aren't they?)MIKE
Hm, although it's not the clearest picture, it LOOKS like either MISO or MOSI has a solder connection to 5V, which will cause some problems. Do you know how to check continuity in a circuit using a multimeter?If not: take the multimeter, and you should have a setting that looks like a diode symbol (a triangle pointing into a bar). Set it to that, and when the leads aren't touching, you will get either "1" or "OVERLOAD" or something to that effect. When they touch, the reading should go down to 0, or it will beep or something.Put one lead on MISO and one on GND, and check if there is a connection. Do the same for MOSI, and then do both again for the 5V line, just to be sure.Check all of your connections for continuity. You should make sure not only that all of the pins are connected like they should be, but that none of the pins are connected to anything BUT what they should be connected to.I'm intrigued to know if that's the answer, since setting up the ISP with these chips isn't super hard, so it's got to be a circuit problem, or the uC is broken somehow.In order to breadboard it, you have to be a little...creative :-P The easiest way I had of doing it was to take a small piece of board that I can solder to, and make the 6 pin connector, then attach a whole bunch of solid wires to each of the pins. Plug in the wires into the associated uC pin and you're good to go.MIKE
Hm, yeah, sometimes it is a continuity problem. Especially with the SPI interface, it's hard to know when that happens. For example, if MISO is always +5V, then you can't receive any data from the slave, but how do you distinguish between "No data, accidental short" and "a really big string of 1's" :-PIF it is continuity due to soldering, don't scrap the board. It is possible to remove solder using solder wick, and it's a good learning experience. I'm away this weekend, but I'll check back in on Sunday. I'm interested in knowing if this was the issue.Cheers,MIKE
You need to do a second set of tests: there are pins that are supposed to be connected to each other, and they are. But are there any shorts? For example, is MISO also connected to GND accidentally?If THAT doesn't work, then yeah, try another uC.MIKE
Nope, that was it. Hm...try another uC in a solderless breadboard and see if you can get a connection to it, then. This REALLY shouldn't be hard, so probably it's an issue that isn't related to anything you did, but it's a hardware problem or something that's causing the issue.MIKE
Just checking; is the 5V regulator actually giving you 5V?
What is the voltage on pin 1 of the uC? It should be +5V. If it isn't (if it's too low) your uC is in a continuous reset mode. THAT is my last, best guess :-(MIKE