0

I just bought an Arduino Mega2560 R3 and it doesn't connect to my Laptop. The connection is somewhat random, sometimes it connects and sometimes it doesn't.

Can someone help me identify whats the problem?

When it gets connected I can upload sketches.

I would like to remove the Atmega 16U2 and replace it with ftdi USB to Serial, would it be possible?

asked Apr 8, 2015 at 10:59
7
  • Did you try another USB port / another PC? Commented Apr 8, 2015 at 11:14
  • Also, the cable might be the problem. Check for that. Commented Apr 8, 2015 at 11:29
  • Yes I did both. The connection was random, now it doesn't connect at all, only an error. I can get it into DFU mode but Atmel Flip says usb device cannot be connected. Commented Apr 8, 2015 at 12:06
  • Do you have an ISP programmer / another arduino Commented Apr 8, 2015 at 12:32
  • I have bought an I |SP programmer but it will take 3 weeks to reach and no I dont have another arduino, TBH I'm scared to buy another one. I am buying an FTDI USB to TTL/Serial, could that help? Commented Apr 8, 2015 at 12:43

1 Answer 1

1

You can use your USB/Serial adapter to program the 2560 as the Arduino uses the 16u2 as the same thing to program the mega. You shouldn't remove the 16u2, just wait till you get the programmers and reflash the 16u2 with its firmaware and it will work, I actually had the same problem where the DFU didn't work and the 16u2 stopped responding, after reflashing the firmware it worked. The firmaware can be found under(as of 1.6.0):

...\Arduino\hardware\arduino\avr\firmwares\atmegaxxu2\MEGA-dfu_and_usbserial_combined.hex

You need to connect the Serial pins on the FTDI and Mega in the below fashion:

 FTDI MEGA
 GND<----------->GND
 CTS<----------->GND
 VCC<----------->VCC
 TXD<----------->RX0
 RXD<----------->TX0
 RTS/DTR<---||-->RST

The Capacitor between the DTR pin and RST pin are needed this should be 100nF.

enter image description here

I have bought an I |SP programmer but it will take 3 weeks to reach and no I dont have another arduino, TBH I'm scared to buy another one... – echo_salik

If you are buying clones, those will more than likely give issues as they will be cutting back on costs in places, i.e. QC checks.

answered Apr 8, 2015 at 13:23
18
  • Actually the ISP is a normal one but the shipping takes time to my country. I'll try this out and let you know. How will I flash it, like what software will I use to flash it? Arduino Studio will work with it? Commented Apr 8, 2015 at 14:17
  • 1
    @echo_salik - you can use avrdude to flash the 16u2, there are a few tutorials on using it, I will add a link when I'm back at a PC Commented Apr 8, 2015 at 14:24
  • On my USB to Serial Module, it just have the following pins: 3V3 - TXD - RXD - GND - +5V Its a USB to TTL device. Could that work? Commented Apr 9, 2015 at 11:52
  • @echo_salik I think that should work, you will just be doing some fancy finger work, you will still connect serial lines as normal and the power, but on upload you will need to push reset on the board manually. Commented Apr 9, 2015 at 15:48
  • @echo_salik - brain fart, if your USB-serial chip is exposed, and you can get the pin put, see if you can solder a wire to the DTR pin? Just if the other way fails to upload. Commented Apr 9, 2015 at 16:31

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.