5
\$\begingroup\$

I have a OSEPP MEga 2560 R3 Plus. It's connected to a 7.2V200mA solar panel SC20072. I don't know fully what I'm doing, but the power light on the board lights up. However, the USB TX and RX lights blink like it's trying to boot and then the Link light just keeps blinking. The Arduino never actually seems to finish the boot and start running my program. It works just fine via USB and the USB light pattern is the same while using USB, but the link light eventually stops blinking. This makes me think it's waiting on the USB link, but I don't know.

What's the problem? Am I not properly powering my device? Do I need to circumvent USB boot-up somehow? Thank you.

\$\endgroup\$
5
  • 1
    \$\begingroup\$ An immediate issue to suspect would be that the panel does not meet the power needs of the board, at least not consistently. Solar panels tend to be rated at least for sale) for something close to their best case - often in realistic conditions their output will be drastically lower. It would be worth trying your arduino-style board on a good power supply (or USB power) to verify that it is otherwise functional. \$\endgroup\$ Commented May 3, 2013 at 19:06
  • \$\begingroup\$ It works just fine with USB. Do you know of a link with error messages for this board? I'm assuming there would be error messages similar to a PC motherboard, but I can't find any. This is my first micro-controller so I'm pretty noob. \$\endgroup\$
    – EhevuTov
    Commented May 3, 2013 at 19:28
  • 1
    \$\begingroup\$ No, there really are no error messages, unless you implement some. But you won't get a chance to send error messages unless the boards works long enough to get through the bootloader, into your code, and send / play / flash /whatever your message. If the power supply is iffy, that may well not be the case. Note that you can run an ATMEGA328p well down into the 3v range at an appropriate clock speed, but the input of the Arduino's 5v regulator has a minimum voltage spec that is (from memory) about what your panel would give under ideal conditions. \$\endgroup\$ Commented May 3, 2013 at 19:56
  • \$\begingroup\$ Ah, I see now you have a MEGA2560 board rather than a MEGA328p based one, still I suspect that the processor used there can also run at much lower voltages than the board is currently set up to run it at. \$\endgroup\$ Commented May 3, 2013 at 20:16
  • 1
    \$\begingroup\$ It was underpowered. I put it in more light and it worked. \$\endgroup\$
    – EhevuTov
    Commented May 26, 2013 at 13:14

2 Answers 2

5
\$\begingroup\$

The OSEPP Mega 2560 board requires between 100 and 400 mA of current for normal operation, not including any LEDs or other peripherals that are on and need power. Presumably the R3 Plus board needs as much, or more.

This power requirement hits the higher end when the USB-to-serial IC (the one near the USB socket) is transmitting / receiving, or attempting to.

When operated from the USB port, the board has up to 500 mA available to it from the computer it is connected to, so power is not a problem.

The OSEPP solar cell generates its full capacity of 7.2 V at 200 mA only under bright daylight. When used indoors, especially with normal room level artificial lighting, the voltage may fall below the 6 Volts minimum required by the Mega 2560 board.

The problem described appears to be of insufficient power delivered by the solar cells to the board. The USB TX/RX lights blink because the bootloader attempts to check for any communication from the Arduino IDE, and this will drive up the board's current draw. In this situation, the solar cell simply cannot supply sufficient power, and the board resets due to a brown-out i.e. insufficient voltage / current reaching the voltage regulators on board.

Resolution:

Power the board by a 9 Volt battery to check this hypothesis. If it behaves normally under battery power, then you may need to connect two or more identical solar panels in parallel to supply sufficient power. This is described in the solar panel datasheet linked above.

\$\endgroup\$
1
  • \$\begingroup\$ I have that SC20072 power cell \$\endgroup\$
    – EhevuTov
    Commented May 3, 2013 at 21:12
4
\$\begingroup\$

It seems like your Arduino is resetting itself. The exact cause of the last known reset is stored in a register MCUSR:

  • bit3: WDRF => Watchdog Reset Flag (a program loop takes too long)
  • bit2: BORF => Brown-Out Reset Flag (low voltage threshold)
  • bit1: EXTRF => External Reset Flag (reset pin)
  • bit0: PORF => Power-on Reset Flag

You can check these flags at the start of your program [setup()] and send a message over serial to your PC or make a indicator LED light up. I suspect you are seeing PORF or BORF. If you see PORF I would investigate the use of brown out detection as that makes your program return to a known state when the power supply gets too low.

Check the datasheet to the ATmega2560 for details.

\$\endgroup\$
1
  • 1
    \$\begingroup\$ Yes... you can if the processor runs long enough to get through the bootloader and output the discovered value. And these values are not preserved across true power loss - they might last through a brownout that caused a reset, but if the power dipped far enough, long enough, it will just be a power-on case again. \$\endgroup\$ Commented May 3, 2013 at 20:14

Your Answer

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

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