0
\$\begingroup\$

Is it possible to view the serial monitor of the ATMega328P (with the Arduino Nano Bootloader) while the arduino is powered by an external power supply?

I'm trying to troubleshoot my program, and it will be a lot easier if I'm able to view what is going on with the code while the batteries are plugged in. My circuit is powered by two 3.7V Lithium Ion batteries in series. Right now, I'm trying to debug the charging circuit part of my program. It will be easier to do so if I can use the serial monitor to view the data registers on the I2C bus while the Lithium Ion batteries are charging.

For this project, I'm not using the arduino board, but the actual ATMega328P microcontroller. To upload the program, I have been using the FT232RL USB to Serial converter module. I did a test to see if it was possible to view the serial monitor with my Arduino Pro Mini, and it was successful. I powered the Pro Mini via the batteries, and connected the TX and RX serial pins on the FT232 and to the Arduino Board. Now when I try the same thing with the standalone ATMega, the Serial Monitor isn't responding. I am still able to upload a sketch and view the Serial Monitor normally if I remove the batteries, so what am I doing wrong? I'm asking on here so I don't accidentally damage my microcontroller in the process.

Here is the ATMega328P portion of my schematic:

enter image description here

\$\endgroup\$
  • \$\begingroup\$ Are you hooking up DTR as well? Shared ground? How is it powered if you remove the battery? \$\endgroup\$ – Ron Beyer May 4 at 23:39
  • \$\begingroup\$ On Header P1, I am connecting the DTR, TX, RX, +5V, and GND pins from the FT Module if the battery is removed. When it is inplace, only the TX and RX pins are connected. So DTR needs to be connected as well along with a shared GND? \$\endgroup\$ – Jay May 4 at 23:45
  • 2
    \$\begingroup\$ I'd try it without DTR or 5V hooked up, just TX, RX, and ground. \$\endgroup\$ – Ron Beyer May 4 at 23:46
  • \$\begingroup\$ Oh wow! A very simple fix! Thank you, I got it working now. If you would like, leave an answer and I'll formally accept it. \$\endgroup\$ – Jay May 4 at 23:54
1
\$\begingroup\$

If you want to just use it as a serial port, remove the DTR so it doesn't interfere with the processor reset signal. You also don't need +5V there, just TX, RX, and GND.

| improve this answer | |
\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.