I'm trying to merge two sketches together, One that blinks Led's, Another that controls a lift system that uses buttons to control motors that run until a limit switch is pressed and then stops.
The first sketch that I wrote alternates a number of Led's and runs an led matrix that is set to blink all Led's Randomly and quickly.
The Second Sketch that I did not, is for a "lift System" that is designed for a life-size R2-D2 and its functions are better detailed in THIS Post.
(Tho, my problem has nothing to do with the question in the above link)
BOTH systems have been built and Are working PERFECTLY on their own.
I'm trying to combine them onto ONE Arduino Mega, and when I do, the "lift" portion of the sketch still works, However, the Led section Is showing some problems with the Lights Not working exactly (tho close) as scripted, AND the bigger problem is that the Led matrix is now only flashing one light every loop and not acting like the very quick random sequence I am looking for.
I had a problem with this same sketch (just the LED sketch) and the matrix, when I had written the code using DELAY(s), and I think what is happening, is something in the "Lift" Sketch is acting as a delay OR perhaps it is the Length of the sketch is "delaying" the "logic lights" portion of the Sketch and acting as if I had used delays.
Can anyone Let me know if I'm on the right track in my thinking? and where I may have gone wrong? Or maybe suggest a better way to run the Max7219 matrix to achieve the same effect and NOT be effected by the second "lift" sketch.
Thank you in advance!
I'll post the 2 sketches in another Post (went over 9000)
Dome_lift_system_changes.ino (28.3 KB)
DomeLightsNormal.ino (9.21 KB)