Quick question.
Does anyone know why the DTR (Data Terminal Ready) pin on the FT232 i often shown a connected to the reset net on the Atmega 328 ?
Thanks
Quick question.
Does anyone know why the DTR (Data Terminal Ready) pin on the FT232 i often shown a connected to the reset net on the Atmega 328 ?
Thanks
The reset signal makes the 328 start its bootloader.
But you don't use the ft232 to bootload. You would use spi 4 wire. You can use the usb but it would take nearly 24 hours. So why is the DTR connected to reset?
If you don't need to force a reset you don't need to connect DTR to the reset pin.
...R
pedro_delmonde:
But you don't use the ft232 to bootload.
You don't use it to burn the bootloader but you can indeed use it to upload programs to the ATmega328 via the bootloader.
pedro_delmonde:
You would use spi 4 wire.
You can do that too, though it's less common in the Arduino world.
pedro_delmonde:
You can use the usb but it would take nearly 24 hours.
You might need to check your math:
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: reading input file "C:\Users\per\AppData\Local\Temp\arduino_build_993130/sketch_oct31b.ino.hex"
avrdude: writing flash (32256 bytes):
Writing | ################################################## | 100% 4.73s
avrdude: 32256 bytes of flash written
avrdude: verifying flash memory against C:\Users\per\AppData\Local\Temp\arduino_build_993130/sketch_oct31b.ino.hex:
avrdude: load data flash data from input file C:\Users\per\AppData\Local\Temp\arduino_build_993130/sketch_oct31b.ino.hex:
avrdude: input file C:\Users\per\AppData\Local\Temp\arduino_build_993130/sketch_oct31b.ino.hex contains 32256 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 3.44s
avrdude: verifying ...
avrdude: 32256 bytes of flash verified
That's right. It took 8.17 seconds to upload and verify the largest possible program to an ATmega328P with Optiboot bootloader via USB
pedro_delmonde:
So why is the DTR connected to reset?
Just what knut_ny told you already. The bootloader runs on every hard reset. In the old days you had to actually hit the reset button before uploading but now that is automatically done via the DTR pin at just the right time for the upload to occur with the minimum bootloader delay.
SPI 4-wire is indeed Needed to put a bootloader on the board. It holds Reset low and accesses memory locations & fuses using SCK, MISO, MOSI pins.