I programmed and successfully tested my project initially on the Uno and then transferred the 328 chip to a circuit board where it was working fine from a 5V power supply.
Now I want to edit the sketch, preferably using my 'USB-SERlAL CH340, ('USB to UART TTL Serial Adapter) rather than removing the chip from its 28-pin socket and doing it in a UNO or on a breadboard.
I'm pretty sure I've added the five necessary header pins on my 328 circuit and that they are connected correctly to the CH340 adapter.
Device Mgr shows 'USB-SERlAL CH340 (COM4)' and that's the port I've set.
But I cannot find a winning combination of Board, Programmer and Processor. Tried many in vain so far.
When I did this before a month or so ago on breadboard, programming a Pro Mini, I had to use 'Arduino NG or Older', not 'Arduino Pro or Pro Mini', which had me baffled (and still does). So that tells me the choice is not intuitive.
BTW, when using Tools > Get Board Info, how do I interpret this obscure message?
This message returns the ID Vendor (0x1A86) and the ID Product(0x7523) from the USB Device connected to the USB Host. These informations are retrieved by the USB Host from the USB Device during enumeration process (one of the first steps of a USB communication).
If you enter these ID Vendor and ID Product into this database:
You'll "learn" that the USB Device seen by the USB Host is a HL-340 USB-Serial adapter from wch-ic.com and the Host will use the right driver.
Get Board Info only returns info on boards with the 16u2 as the serial adapter (like official Uno/Mega and faithful clones) or native USB (like Micro/Leo/Due). With a general purpose serial adapter (like Nano, and most clone Uno/Megas, or any time you use an external serial adapter, you'll always see that kind of output. Frankly, I wish they would remove the "get board info" from the menu, because new users try to use it when using clones or boards with external serial adapter (like pro mini) and think that the message you saw is a useful debugging tool (it's not).
What error are you getting?
If you're getting a COM port, and when you select that port and try to upload, you get a sync error, not something weird, the problem is probably not related to drivers.
Do you have the 10k resistor between RST and VCC? You need that for the DTR autoreset, which it needs to upload.
Do you have an LED+resistor on arduino pin 13 (not physical pin 13)? I can't tell from the picture. If you do, a quick debugging step is to briefly connect RST to ground - you should see the LED blink three times quickly (this means the '328p has the bootloader on it and the bootloader runs on reset). Assuming that works (which doesn't tell us anything we don't already know from the fact that you can upload to it if you put it back into the socket on an Uno) - open the serial monitor - do you see that same triple-blink pattern? If not, autoreset isn't working, and that's why you can't upload.
Assuming the chip was bootloaded as an Uno, you should have Uno as the selected board.
The tools -> programmer option does not matter when doing a normal upload to a board with a bootloader - it is only used when using an external ISP programmer for "burn bootloader" or "upload using programmer", which you're not trying to do (if using a third party board package where there isn't a bootloader, for example, the most common configurations for an ATtiny, this option is used for normal uploads - but you're not doing that either)
The OFFICIAL clone driver is Chinese and there is only that link given.
Other copies exist but beware there are also some non official sites that offer some pretty nasty drivers.
ballscrewbob:
The OFFICIAL clone driver is Chinese and there is only that link given.
Other copies exist but beware there are also some non official sites that offer some pretty nasty drivers.
Bob.
Thanks, understood.
But on reflection I don't think there can be a missing CH340G driver. As mentioned, I have used that adapter successfully before.