Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [arduino-mega]

A microcontroller board based on the ATmega2560 or 1280 chip. Use this tag for questions specifically regarding the Mega, and not just general Arduino usage.

0
votes
0answers
14 views

How to make Variable Frequency Drive (VFD) Inverter using Arduino

I have a VSI SPWM Inverter Project, but my supervisor ask me to upgrade it to a VFD Inverter. I've found a code about how to generate 3 phase SPWM in this article, and i've tried the code. The output ...
0
votes
1answer
19 views

RFID RC522 reads the previous tag serial with different tag

I hope someone can help me. I'm using a Mega with RC522, and this happens: I use a tag, it reads the right serial (e.g. AA:BB:CC:DD). Then I use a second tag and sometimes it gives me the correct ...
0
votes
0answers
28 views

Code not working

Basically, it's an Arduino project in which I am stuck. I using inputs as two sensors and LED as output, for further details and concept video had been attached. I did the wiring and everything ...
0
votes
0answers
18 views

How to generate 4 square signals using Arduino Mega 2560 below 30hz using timers

I would like to generate 4 square signals of different frequencies below 30 hz using timers of Arduino Mega. I was able to generate 30.6hz signals but I have no idea how to generate lower frequencies....
0
votes
0answers
13 views

NEO 6M GPS with COMPASS Module, Arduino Mega

I'm doing a 4-wheel robot project. My goal is to detect the location of the robot and go to the coordinate points I have entered. I'm using the TinyGPSPlus library. The problem is that it doesn't ...
0
votes
1answer
16 views

Issue with analog readings on Arduino atMega with YL-69 moisture sensors

I've connected four YL-69 sensors to my arduino at-mega2560 on analogs pins 0-3. This is combined with four DHT11 sensors that are in digital pins. The DHT work fine, and I can work one YL-69 ...
0
votes
2answers
22 views

Error compiling a sketch to class/library conversion

I'm trying to take a sketch and turn it into a class for a library I'm making, but I'm getting compile issues. This is not a duplicate as suggested. as i explain in the comment and my answer. Thank ...
0
votes
0answers
23 views

Arduino Mega and ADS1256 board

I found code for a Teensy board and now I added just digitalwriteFast library to code and changed port to SPI for Arduino Mega. And now I get just one number out: #include <SPI.h> #include <...
0
votes
1answer
38 views

Arduino hangs after some time

I am using Atmega328p with 5V power supply, My Arduino getting hangs [or auto restarts] after some times. I am using libraries: Wire.h CRC32.h EEPROM.h Arduino.h TimerOne.h RtcDS3231.h ...
0
votes
0answers
12 views

Is there software to make an interactive GUI for my TFT touch screen shield?

I was wondering this, because realized it takes quite time consuming due to all the lines of code I have to write.
0
votes
1answer
30 views

C: No communication to a connected serial port?

I'm trying to connect to an arduino Mega At2560 unit connected via usb serial port in my linux based PC. Using C code, I'm trying to send and receive simple text strings, just I'm able to send and ...
0
votes
0answers
4 views

ros_serial loses sync with Arduino only when motors are running

We have an Intel NUC communicating with an Arduino Mega using ros_serial. There are several motors attached to our bot. The motors are controlled using a BlueRobotics Basic ESC Rev 3 which takes a PWM ...
0
votes
1answer
44 views

Did not find fingerprint sensor :( Arduino Mega 2560 Adafruit Fingerprint Sensor

I'm getting the following error when I try to enroll fingerprints using the Arduino Mega 2560 microcontroller along with a Fingerprint Scanner: Did not find fingerprint sensor :( The exact devices ...
0
votes
0answers
22 views

SD card module not responding [duplicate]

I am trying to read an SD card info by Arduino and an SD card module. But the SD card is not responding. I connected the wires carefully several times but it is not working. I am using this module : ...
0
votes
0answers
21 views

Encoder code using interrupts design question

I have an Arduino Mega 2560, an Omron Optical encoder with an Index (360 steps), a 60 led NeoPixel ring (no Clk wire) and another Arduino Uno. Here is my question, I have some code written that works ...
0
votes
0answers
22 views

How to use ESP8266 with Google API for GPS as well as controlling Arduino pins

I am working on IoT based project and I want to control the device using mobile App. Everything works fine, I can switch the load and get the status back on mobile app, but I want to use my ESP8266 as ...
0
votes
1answer
15 views

Mega attachInterrupt on pins 18 or 19 require EIFR bit set first (to clear it)?

Experimenting with external interrupts on a Mega. Pins 2 and 3 work with standard attachInterrupt(digitalPinToInterrupt(iPin),ISR,FALLING); coding and call my ISR. With pins 18 and 19 I had to add ...
0
votes
1answer
47 views

Does UNO and Nano have the same pins?

Do Arduino Nano Atmega328p have the same pins as Arduino/Gizduino Uno Atmega328p?
0
votes
1answer
42 views

Arduino Uno: avrdude: stk500_recv(): programmer is not responding

I have an original Arduino Uno board purchased directly from the official arduino website. I have used it successfully with IDE v1.8.5 on my Windows 10 laptop for various projects in the last 6 months....
0
votes
1answer
28 views

How to check whether my arduino-mega ADC is sampling correctly?

I have a code which samples the given input signals with sampling rate 256hz. I plotted the graph of FFT and was able to see the peaks at the expected frequencies.But I would like to know whether my ...
0
votes
1answer
35 views

esp8266 esp-01 printing garbage values on serial monitor

I am trying to up an esp8266 esp-01. While monitoring the serial monitor it's printing garbage values. I am using arduino-mega to write the code to the esp8266. The sample code i'm trying to write is ...
0
votes
1answer
20 views

servo starts rotating whenever it is plugged

I am making a fish feeder using an Arduino Mega 2560, servo motor SG90 and RTC DS3231. I want to make it rotate twice a day, i.e. morning and 9 o'clock evening. Whenever I plug my Arduino board to ...
0
votes
0answers
38 views

problem data I2C to sensor GY955/BNO055 (China)

I want to ask, I have a problem when running the Arduino sensor, I can't output data, but it's detecting that the sensor address has been paired. Like I2C has a problem or locks it. Last night it ...
0
votes
1answer
31 views

What is the sizeof() Arduino's built in HIGH and LOW?

This might be a stupid question to ask but I'm curious. I decided to test this myself and I got a value of 2 for both HIGH and LOW, why would it output 2?
0
votes
1answer
25 views

Do the libraries of the Arduino Uno work with the Arduino Mega?

I did a project with the Arduino Due and the libraries for the VS1053 MP3 Shield were not compatable with the Due. Are the libraries that work with the Uno compatable with the Arduino Mega?
0
votes
3answers
26 views

Code getting stuck waiting for GPS Output

I'm basically trying to make a device that pulls the GPS information from a SIM808 and pushes it to a server online via GPRS. I am sorry as I am not good at programming so ive spent days trying to ...
0
votes
2answers
34 views

Which LCD Pins, if any, require PWM?

In the Arduino Tutorial Page named "Hello World" aimed to help people connect a 16x2 LCD Display compatible with Hitachi HD44780 driver to an Arduino Uno. The pins used to connect the Arduino Uno and ...
0
votes
0answers
15 views

Arduino TFT LCD buttons reappear after fillScreen(BLACK);

I am very new to TFT screens and I am developing some code to display on a little information board, however I have come across an issue. Once I call tft.fillScreen(BLACK);, it writes testing but ...
0
votes
0answers
28 views

Problem with potentiometer

I would like to make an RC controller with NRF24L01 and two dx6i clone joysticks. Problem Joystick potentiometer return shitty value. When I move it, the "middle point value change" as well "...
1
vote
1answer
30 views

Problem sending SMS from a GSM SIM900

I have a laser security system project with a GSM SIM900 and a few sensors. I'm using an Arduino Mega 2560, and everything is working normally, except the GSM is not sending an SMS to the phone and I ...
0
votes
1answer
42 views

Can't replace SoftwareSerial by Serial1 on Mega board

This sketch runs well with SoftwareSerial define and the monitor displays device modbus values. But now, i want to replace SoftwareSerial by Serial1 and i have no data. This is the sketch with ...
0
votes
1answer
101 views

Controlling output of 3 Phase SPWM Inverter

I am now on a 3 Phase SPWM inverter project, and i got this code from this article. It works perfectly on simulation. But the problem is, i can't make the output voltage variable. I intend to use it ...
0
votes
1answer
32 views

Can a push button be used for TFT LCD screens?

I am trying to link my TFT LCD touch screen to a few push buttons. May I enquire why my code is not working? I'm trying to link the screen and the button so I'm trying to make the image display a ...
-1
votes
0answers
13 views

Arduino Mega hangs/freezes on opening COM port

My Arduino mega 2560 is connected with NEO 7M GPS module. The data is received using RX0 and TX0 pins. If I open com port(serial monitor) more than twice when the code is running, the code hangs. On ...
0
votes
1answer
43 views

What should I use Arduino-Mega or Rasbeery pi? [closed]

I am doing a project on Vehicle tracking and security. In my project Micro controller will sense input from sensors and at the same time it has to sense signal from user for tracking purpose and ...
0
votes
0answers
27 views

WiFiEsp library TIMEOUT if do something after client in loop

i don't manage to find out a solution with my code using ESP8266 (esp-01) and WiFiEsp.h library. I can receive datas easily but when i add some code after client.stop(), the library stops run the code ...
3
votes
2answers
167 views

Testing Conditions on Port Bytes - ignoring certain bits?

Being new to testing byte and bit conditions, I feel like there has to be a better way to test for conditions/values on a byte (read from a port). For example, I'm reading 8 bits from PORTK. I need ...
-1
votes
0answers
37 views

Control 24 stepper motors in same time via arduino

I want to do myself this project https://vimeo.com/174226879. I refer to this question I2C Master-Slave Arduino system to control array of steppers. In this question are use just 6 stepper motors but ...
-3
votes
1answer
77 views

My Arduino Code but it will not compile, I cannot find what is wrong with it [closed]

I tried convining and LCD display, ultrasonic sensons, LEDs and an IR reciever code into one main code. Seperately they work fine, but when I put them toguether it gives me the following error: "Error ...
0
votes
1answer
23 views

Arduino MEGA with RTOS

I've been coding for FreeRTOS on the MEGA 2560, and was using some LEDs to determine activity per task by toggling each individual LED each time through the task, and monitoring the time using a scope ...
0
votes
0answers
41 views

Stepper Motor Not Running Code

I'm working with an Arduino Mega and I'm trying to run a stepper motor and servo from the same code. There are two buttons: one operates the stepper and the other operates the servo. I'm trying to ...
0
votes
1answer
29 views

How to add if condition with RFID Example

Using a Arduino Mega 2560 and PN532 NFC/RFID module, I want to be able to scan a card and see if it's value is (0xF0, 0x21, 0x5D, 0xA7). It should print "accepted" in the serial monitor. However ...
1
vote
2answers
53 views

Remotely uploading code to an Arduino board over the internet [closed]

I recently used Particle Photon that allows me to upload firmware (.bin file) remotely over the internet. I would like to use something like this for my Arduino but I cannot find anything like that. ...
0
votes
1answer
47 views

Arduino MEGA Timer Help

Nick Gammon posted some code to setup a counter on an Arduino UNO using timer2 to generate a 38KHZ signal, and I've used it on several IR projects. On my current project, I'm using FreeRTOS for the ...
0
votes
1answer
37 views

SD card initialization failed

i use the example sketch of SD card presented in Arduino IDE. It runs well, but when i reboot my Adruino Mega by the reset button, the SD card initialization fails. To fix it, i need to remove the SD ...
0
votes
1answer
41 views

FreeRTOS Timer Use

I use Timer1 on an UNO to generate a 38KHZ signal for IR communications. It all works as expected. BUT, I need to convert the code to run as a task under FreeRTOS, and can't seem to find any details ...
0
votes
2answers
43 views

ESP8266 library: 2 requests received instead of 1

I have a strange issue with my sketch using WiFiEsp.h library from https://github.com/bportaluri/WiFiEsp When i send 1 request to my ESP8266 from my browser as http://192.168.0.25 , it seems that my ...
0
votes
1answer
26 views

problem related to arduino

first of all, I am not very good at English. if I have done a mistake during describe the problem apologize me. I want to combine both ultrasonic sensor code and mpu6050 sensor. can anyone tell me how ...
0
votes
1answer
43 views

Look for Master and Slave code with error for a Arduino Mege

I am building a a-10c Sim. So I need lots of input and outputs. Each Arduino has 54 digital i/o and 16 analog inputs in each. As I need more I just add another arduino mega 2560. I want to thank in ...
-1
votes
0answers
68 views

Arduino Mega2560 + Sim808 + GPS + TCP HTTP GET

I'm trying to get some GPS data and temperature and send it over an HTTP GET request to a webserver (yeah I know, sending data over GET... no POST, it's boring). GPS is working, but TCP is not. ...