Arduino Mega 2560 auto resetting !!!

Hello everyone :slight_smile: !

I’m a newbie to arduino and I’m working on my project which contains a dozen bitmaps and few graphical effects as a part of gui . mega is interfaced with keypad(4*3), Glcd(ks108) and a high torque stepper motor.

during the course of this project we encountered auto reset of arduino which is quite uncommon !! and is not at all desirable in our project :confused:

i have ensured that the reset is not due to the physical hardware switch on board and is mostly due to software reset.
is there anything in specific to check for, to correct this ??

bitmaps.h (41.9 KB)

_200116_01.ino (13.3 KB)

Why not include a schematic?

But my guess:

anirudh95: high torque stepper motor.

High torque => high current => no stable voltage

i have ensured that the reset is not due to the physical hardware

How? In a project with a motor in it, remove the motor and see if it still happens. In 99% of cases a reset is caused by interference form the motor.

How much memory ( SRAM ) does the compiler say you have left when you compile that?

@papakel, your Post has nothing to do with the other Posts in this Thread and I have suggested to the Moderator to move it to its own Thread,

Then post the program you are using and a photo of a drawing showing all the connections to your Mega.

...R