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.

learn more… | top users | synonyms (1)

0
votes
1answer
19 views

Serial3.available loop issue

I am trying to read information coming from an Atlas Scientific FLO30 chip. The following code works fine in an individual sketch: String inputstring = ""; ...
0
votes
3answers
53 views

How to reset arduino Mega 2560 code automatically?

I am working on the temperature project using arduino to collect temperature. But sometimes arduino hang there so I have to unplug cord and plug it back in to restart the arduino. I do not when it is ...
0
votes
0answers
23 views

Error compiling code (tv-b gone)

I have been getting started with the arduino and found a great project online called tv-b gone. It includes some code which I cannot compile. Yes I have included main.h and worldcodes.cpp. /* ...
0
votes
0answers
10 views

Receive response from the mosquitto broker

Im working on mqtt in arduino using sim900 gsm/gprs modem. I made a connection to the mosquitto broker by sending the connect packet, broker receives the connect packet. Broker send the connect ...
0
votes
2answers
45 views

Increment in switch statement not working

No matter how I rearrange this, the increment compare always returns false.... I have even taken it out of the if, and put it in its own if: int buttonFSM(button *ptrButton) { int i; i = ...
-1
votes
1answer
64 views

Serial communication not working between two Arduinos unless connected to computer

I have a robot with an Arduino Mega that gets data from a bluetooth module and sends it to an Arduino Leonardo to activate some functions. It all works amazing but only if the boards are connected to ...
1
vote
1answer
27 views

Assembling a float from an array of bytes

I would like to convert an array of bytes, received from serial, to a float. Let's consider this exemple. I'm sending 0.12 byte-wise from an Android application. The conversion from float to array of ...
1
vote
3answers
84 views

Can do I make an Arduino program that can decipher telephone touch tones?

I have an old land line phone that I want to connect to my Arduino. Then I would like to write a program that can decipher the touch-tone button presses (which are a combination of two tones) so that ...
-1
votes
0answers
24 views

How can I parse JSon string in Arduino? [duplicate]

I have this JSon string and i want to parse it. I don't want to use arduino string to char array. Do you have an idea? { "x": "3", "y": "5", "type": "data" }
0
votes
2answers
39 views

How can I create a power rail on my Arduino shield?

I have an Ardunio that has 4 devices within an enclosure. Each of the 4 devices needs 5v and GND. I have a shield with lots of unused pins (see photo). I'd like to "bridge" one row of the pins to ...
0
votes
0answers
60 views

RESTful API with ESP8266 and arduino mega

Anybody had worked with ESP8266 to post data to RESTful web service? I was trying but it's not posting anything. Tried with a test server : http://www.posttestserver.com/ Serial.println("\nSetting ...
-1
votes
0answers
25 views

Counter variable won't be at 0

I am feeling a bit dumb to be honest. This is my code: for ( int i=0 ; i < 2 ; i++ ) { // First loop for ( int ii=0 ; ii < 16 ; ii++ ) { // Second ...
-1
votes
0answers
36 views

Second “if statement” doesn't work , and the first one work sometimes ? what is the best way to code this? [closed]

int analogPin_0=0; int analogPin_1=1; int analogPin_2=2; int analogPin_3=3; int analogPin_4=4; int pin_0,pin_1,pin_2,pin_3,pin_4; void setup() { //pinMode(analogPin_A,INPUT); Serial.begin(9600); ...
0
votes
0answers
34 views

Hot regulator 7.7V Vin @ 135mA

Sorry folks, I understand this question has been asked quite few times, but I wasn't able to find a definitive answer: my Mega 2560 R3 is powered by 7.7V from Vin, and runs at a steady 135mA (in ...
0
votes
1answer
22 views

How do I know when the connections is ready between Arduino and QSerialPort

I am trying to send data from QSerialPort to Arduino Mega 2560. The proccess always takes some time to establish the connection. How do I know with QSerialPort is the connections is ready to send ...
0
votes
2answers
31 views

PYM-1 PIR sensor current concerns

I am busy toying with some PIR sensors to detect movement etc for a nightlight for my kids. One of the sensors I ordered is the PYM-1 PIR sensor. The data sheet states the following: Operating ...
-1
votes
1answer
40 views

What is the diffrence between following arduino boards and which should i buy? [closed]

Arduino UNO R3 Compatible Board ATmega328P ATmega16U2 ...
1
vote
2answers
51 views

How to count the number of times a changing variable reaches a peak value

I am recording a varying distance with an Ultrasonic sensor and Arduino but my problem is I want to display the number of times this variable reaches peak (at an instance the value will be increasing ...
0
votes
2answers
40 views

Arduino Ethernet Shield 2 stuck on EthernetServer::begin()

I am currently trying to get the Ethernet Shield working on my Mega. I was trying to run the Webserver example but the program seems to stuck at one point, so I tried to start from scratch. This is ...
0
votes
0answers
23 views

Arduino EEPROMex library problem

I am trying to write a float value to the EEPROM on an Arduino MEGA2560. According to some research I should use Arduino EEPROMex library. I added the library to Arduino, but I get the message "EEPROM ...
0
votes
1answer
42 views

How do I know how many memory that Arduino is use after my code is running for a few time [duplicate]

When I upload my program to Arduino it says the memory that the program is used. But what if I use a bad management of dynamic memory, or any object is created several times in use a lot of memory and ...
0
votes
0answers
17 views

Serial Communication with two bluetooth modules on Arduino Mega

I'm trying to communicate with two bluetooth module (RN-42) on the Arduino Mega. I studied about Serial communication in Arduino, and I used Serial1, Serial2 to get information at the same time from ...
0
votes
2answers
41 views

Arduino raise the error: `does not name a type` when an Object is used outside of the main two blocks setup and loop

I have this: class Person{ public: int age; }; Person p; p.age; void setup() { ... } void loop() { ... } And I got this error: Compiling 'MyProgram' for 'Arduino Mega w/ ATmega2560 (Mega ...
0
votes
3answers
63 views

Testing Arduino with Visual Studio Community 2013 raise LNK error

I have two projects in my Visual Studio Community 2013 solution. I created a project for Arduino, and create another project for Test. When I run the project tests without adding the Arduino project ...
1
vote
1answer
99 views

Arduino 1.6.4 not showing any /tty/ options in Serial ports

hej guys, recently I upgraded to Arduino's 1.6.4 IDE just to find out, that I can't seem to upload anything to my board. More specifically: The 1.6.4 IDE is not giving me the option to select the ...
0
votes
1answer
21 views

Arduino resets when I call network.begin()

I have included the RF24Network library in my project. I tried to use the Simple Transmit/Receive example from here but when it calls the network.begin() my arduino restarts. I placed some ...
0
votes
1answer
85 views

DC Motor not behaving reliably

Using an Arduino Mega. I have a motor hooked up exactly like the picture below. Using a BC548B transistor, 1N4001 diode, 220 ohm resistor and a 9V battery. I'm driving the motor in code by using PWM ...
1
vote
2answers
121 views

How can I play audio from an SD card?

What is the best / simplest way to play audio files from an SD card? I'm currently working on a sound board, where each button plays a different sound. But I have yet to find the right combination of ...
-3
votes
1answer
35 views

I guess, pull-up/down resistors fried. What can i do? [closed]

Arduino Mega ADK is working well but it is not working circuit in which pull-up/down resistors. It is generating wrong results. I guess, pull-up/down resistors fried. What can i do?
3
votes
1answer
55 views

How can I indicate that I am using ATmega2560 so that Arduino libraries understand it?

I am developing AVR microcontollers in Atmle Studio and sometimes I am using Arduino libraries(such as LiquidCrystal). When I initialize LiquidCrystal lcd(12, 11, 5, 4, 3, 2); I don't think Arduino ...
0
votes
1answer
56 views

Not detecting arduino Mega 2560. It worked before but now not detecting

I am using windows 8.1: 64 bit. I have Arduino Mega 2560. I configured and installed it with merlin firmware before. I had a system format in between. Tried to connect arduino again. Following ...
0
votes
1answer
92 views

How to draw a bitmap on a tft display?

I'd like to print a bitmap on my TFT. I setup my screen with this library: http://forum.arduino.cc/index.php?topic=292777.0 It is like the Adafruit_GFX library (only a little bit changed). ...
2
votes
1answer
40 views

How to avoid pulling the RX0 pin to reset sketch

My project requires reading 5 serial devices (RFID readers) at the same time. I chose an Arduino Mega 2560 as it comes with 4 serial RX ports. For the fifth port I am using the SoftwareSerial library. ...
0
votes
1answer
45 views

Do multiple ultrasonic sensors need an external power source?

So maybe it's a very low class form of question, but please bear with me. I'm working on a project with 7 HC-SR04 ultrasonic sensors connected to one Arduino. I tried to unify the trigger and echo ...
1
vote
1answer
19 views

Serial device file no longer shows up in /dev/ after working fine for months

I am using an Arduino MEGA connected to my Linux workstation via USB. I have been using this setup for several months with no issues. A few days ago, the usual serial device file (/dev/ttyACM0) ...
0
votes
0answers
30 views

LCD display intensity. Mega2560

I've looked it on the forum and I haven't found it!. I am trying to control an aquarium with an Arduino. But, when I connect everything, the LCD doesn't show correctly the data on the 2nd line. It is ...
0
votes
2answers
32 views

Improve sampling speed while using a multiplexer

I currently connected 5 sensor via a multiplexer (I must connect them to a multiplexer because they are I2C devices but they cannot been allocate more then 2 addresses so I use a multiplexer to solve ...
0
votes
2answers
57 views

Relay feedback control

I have a two-relay system set up to a DC motor. So, if I close one relay, the motor moves on one way and if I close the second relay (and open the first) the motor goes on the other direction. I ...
0
votes
1answer
85 views

Arduino selection for RTOS

I am brand new to Arduino and am having a difficult time understanding the "lay of the land". I'm looking for the beefiest, fastest, most compute-centric Arduino available to the market that will run ...
0
votes
0answers
67 views

Can't get LCD(1602A v2) to communicate with AVR ATMEGA2560

I have written the following code to communicate with an LCD display yet I can not get data to appear on the screen. All I get is white boxes on the display. I am properly controlling the RW, RS and ...
0
votes
1answer
127 views

How to call URL with Arduino Ethernet shield?

I'm working on Arduino and Ethernet shield. I need to call a URL. How can do it? (This URL is HTTP API to send an SMS to my phone). url: ...
0
votes
2answers
70 views

Arduino R/C compatible transmitter and reciever

I want to make a RC buggy or something down those lines (using Legos of course) and I'm confused while looking what transmitter/receiver to use. Would like a simple classic remote and any compatible ...
0
votes
0answers
93 views

Ethernet shield and sd card not working togather on arduino mega

I am making a web-client with an Arduino mega and Ethernet Shield. I am trying to receive data from a web-server running a php script and saving that data to the SD card located in the Arduino ...
1
vote
1answer
28 views

How I could make a bus connection in a prototype shield?

I am a programmer but pretty new to electronics , I recently bought a prototyping shield like the picture : In my view there is no bus connections here . I have lots components need connect to ...
0
votes
0answers
41 views

Problem with the GY-85s accelerator (ADXL345). Not sure if hardware or software

I have a GY-85 IMU (ITG3205 + ADXL345 + HMC5883L) hooked up to an arduino mega. When using the razor AHRS headtracking code, I have a problem where the accelerators z-axis doesn't change from 511. ...
0
votes
0answers
31 views

Trying to play audio files on arduino via Usb Host Shield

I want to build a program that will seek audio file inside a USB DOK (DisK On Key/Pen Drive) when it is inserted to the Circuits@Home USB Host shield. After a specified file will be found i want it to ...
1
vote
2answers
309 views

How to clear FIFO buffer on MPU6050?

my MPU6050 works very unstable , the problem is unable clear excessed FIFO buffer on MPU6050, I am using Jeff Rowberg's MPU library and according to his DMP example but without using ...
0
votes
2answers
55 views

Multiple interrupt lines connection

in my project need to connect more then 10 I2C sensors(MPU 6050) to Arduino Mega and each sensor an interrupt line is essential. Since in Arduino it only got several interrupt slot(digital 2, 3, ...
2
votes
1answer
76 views

Why does the pin 2 of arduino Mega stay always HIGH?

Without declaring the pin 2 as INPUT or OUTPUT, it remains constantly HIGH. Can anyone explain why is it so?
0
votes
0answers
67 views

cc3000 WiFi distrupting DS18b20 temp measurements

I am trying to post temperature measurements from DS18b20 thermal sensors to an online repository using a cc3000 WiFi shield on an Arduino Mega. It works great, once. All the temperatures get read ...