Re: Can't connect SNAP to ATMega328P using MPLab X IPE v5.15
Thank you for your interest and replies.
Sorry for the delay in getting back to you, I was out of town.
I am powering the Nano through its USB port, tried both from a PC USB and a powered hub.
The connection from the SNAP to the micro is made via a ~ 6 inch jumper cable from an 8-inline male header to a 2x3 female connector to fit the classic AVR ISP Header.
Another individual on the AVRFreaks site noted that if one first selects a SAM device, then clicks Apply, then clicks Connect (knowing that it will fail without a SAM uC connected), then selects the AVR (M328P in this case), then clicks Apply, and then clicks Connect, it WILL connect to the AVR 8-bitter.
Using that work around the Win10 MPLab X IPE will connect to the AVR.
(So the initial USB connection to the SNAP error is resolved.)
BUT, when I then program a pre-compiled .Hex file the SNAP RESETS the Mega328P's "Fuses", (Configuration Bits), and changes the clock from the External 16 MHz Xtal the Nano was running on to the internal 8 MHz RC Osc with the Divide by 8 Fuse set, so the uC now runs at 1 MHz.
What in the world is that all about?
Although the IPE will let me see the Configuration Bits, and even do a pull down on the clock source, it won't let me change them back to how I had them set!
It also pops up a message to say that re-setting the AVR Configuration Bits is disabled in the IPE, but one can use the IDE.
That makes the IPE TOTALLY USELESS.
I can't have it reset my Clock and other Configuration Bits every time I download a file!!!
It did, however, download the .hex file, which then ran correctly, albeit 16 x slower than expected, so I know that the converter cable from the SNAP to the target AVR works fine.
I did then try the IDE. Understand I'm new to the IDE, but I found it a bit more complex to navigate then the IPE which I thought was straight forward and user friendly, (except for not working!).
I spent an hour trying to get the Win 10 MPLab X IDE to let me change the M328P's Configuration Bits back the way I wanted them, and never could make it work.
As the Nano has some additional circuitry on the Reset\ pin for the Arduino IDE, I also tried the MPLab X IPE and IDE on a custom M328PB board with just a 10K pull-up on the Reset\ line. Again, neither the IPE nor the IDE will let me re-configure the Configuration Bits, ("Fuses").
Know that I can program and configure the Config Bits on both the M328P and the M328PB using Studio 7.xxx and an AVR ISP mkII programmer without difficulty.
I purchased three SNAPs as I was looking for a simple, low cost AVR programmer.
The marketing pop ups on the web page said that MPLab now supports all AVRs.
I don't believe that to be the case, and with the IPE resetting the ConFig Bits and no tic-the-box option to tell it NOT to do that, it is totally worthless.
It would be nice if MC added TWO tic-the-box options to the IPE:
1) Turn On/Off the IPE touching the AVR's Configuration Bits.
(The default should be to NOT touch them!)
2) Turn On/Off the ability to the User to configure the Configuration Bits, ("Fuses").