Hello everyone,
After waste a few hours without any progress, I decided to register in the forum and ask for help.
My problem is my board is not working properly. So far it is clear that the board is no capable of execute properly the if statements. Sometimes the if condition is ignored. I guess it has no sense to share the code, I have done a lot of tests, and it fails in a wide variety of cases. When I did some examples, it looks ok, but once you start to work in your own projects with if statements, the most stupid if for example if(a < b) {... is failing. Problems with int variables, and also with float variables. And that is quite frustrating, because I work for many years with Siemens PLC's without any issue.
Hardware data:
Board Mega 2560 - may be is a bad board? And I should buy a better one.
In this project I have connected 2 devices:
Accelerometer module MPU-6050
OLED display interface SSD1325
Software:
In my PC Arduino 1.8.19 (Windows Store 1.8.57.0)
Libraries:
for the accelerometer:
Wire.h
for the display I am using adafruit libraries:
SPI.h
Adafruit_GFX.h
Adafruit_SSD1325.h
Any one has experience problems with any of the items listed?
Thank you very much,
Rafael Martínez