Stack Exchange Network

Stack Exchange network consists of 175 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 [serial]

Serial communication is the standard USB connection between the Arduino and a computer with a standard USB A to B cable or through the TX/RX pins using a USB to serial converter. It can also refer to the serial library.

1
vote
1answer
29 views

attachInterrupt() corrupting Serial buffer requiring Serial restart

I am working on a proof-of-concept ADC to "explode" what's inside of an ADC chip for teaching purposes. Currently, I have a sketch that uses a push-button to act as a clock-pulse that counts up (1, ...
0
votes
1answer
27 views

Create New Serial Class Inheriting from Stream

How should I inherit from Stream, for creating a new class MySerial able to be initialized from a Stream0 instance?. The error so far is: "cannot declare variable 'mySerial' to be of abstract type '...
0
votes
1answer
11 views

Pipe serial dump to SD card file

I am using the RFID module to read mifare NFC chips and the library has only methods to send the data to the serial monitor. I need them to be saved to an SD card file. I have been adding custom ...
0
votes
1answer
218 views

Passing HardwareSerial and SoftwareSerial as a Class Property

I wish to know if there is a way to use a single property Serial0 to hold a HardwareSerial or a SoftwareSerial or other class instances supporting basic methods such as available(), read() and write(),...
-2
votes
1answer
43 views

Parsing data in arduino?

I just started working with Arduino and in my project I am trying to achieve the COMM between two Arduino using HC-05 in master and slave mode respectively, I configured it all successfully. Now I ...
0
votes
1answer
25 views

How to use 2 serial port when WifiEsp library uses one of both

I try without success to receive datas from DataPort and transmit them to my computer via WifiPort, using ESP8266 wifi module. Each second, serial datas income on DataPort from another device. ...
0
votes
1answer
28 views

Blinking 2 LED having input from serial monitor

Sir while entering the values on the serial monitor, I ask the user to enter the value for red led voltage(0-255) then again ask for yellow at the red voltage asking it produces the user to put the ...
0
votes
1answer
14 views

NeoICSerial and SPI on the Uno - pin 10

The NeoICSerial documentation contains a table that states for the Uno: Transmit: 9 Receive: 8 PWM Unusable: 10 Pin 8 and 9 are used for the serial connection. Pin 10 is part of the pins for the SPI ...
0
votes
1answer
29 views

Problems with serial communication from Arduino to ESP8266

I've been trying to get an Arduino and ESP8266 to communicate with each other over serial. The ESP8266 uses the Serial class for communications, while the Arduino uses SoftwareSerial. The problem is ...
0
votes
1answer
19 views

Arduino Due - Native/Programming Port [closed]

I am finalizing a project. I was using the programming port from the beginning and getting ready to change to the native port. I thought it would be as easy as changing my Serial.xxxx to SerialUSB....
0
votes
0answers
21 views

RS485 Arduino Communication Issue

Friends, I am trying to achieve half duplex communication between two Arduinos using RS485 Protocol. The hardware I am using is a MAX485 module and an Arduino Uno. I am using the SoftwareSerial ...
0
votes
0answers
597 views

Port not showing on Arduino IDE 1.8.5 on MacBook Pro

The port is not showing up on Arduino IDE. I have tried using a compatible Arduino Uno and I'm now trying to connect an Adafruit Flora board. The serial port is just not showing up. Arduino compatible ...
0
votes
2answers
26 views

Connecting Emotiv EPOC+ to HC-05 [closed]

How can I connect Emotiv Epoc+ headset to HC-05? The headset has its own Bluetooth USB dongle which you plug into the computer to acquire data, but is there anything I can do on the Arduino side to ...
0
votes
1answer
25 views

Sending data to UART using Atmel Studio with Attiny84

I want to send data to TFDI. It can be hello world or any value of variable. But I can't do. I haven't found example code on the internet. Some examples doesn't work. I am using Atmel Studio.
0
votes
0answers
20 views

library for both HardwareSerial and Serial_ [duplicate]

many Arduino boards use the HardwareSerial class, like the AVR based boards (UNO, MEGA), ESP* and the official STM32duino. Recently seems that Arduino made a new class called Serial_ which works on ...
0
votes
1answer
45 views

What is /dev/tty.usbserial-1420 [duplicate]

I'm a complete newbie with Arduino. I've bought a couple of Nano clones from China. According to supplier description, it is Arduino Nano V3.0 ATMEGA328P ATMEGA328 CH340. Not sure why they list both ...
1
vote
1answer
47 views

Printing elements of char array from PROGMEM

Given: const char* PROGMEM names[] = {"Foo","Bar"}; Serial.print(names[0]); I get garbage output. Is there some function that will print the string from PROGMEM? E.G.: Serial.print(<function ...
1
vote
0answers
31 views

Is it a rule of thumb to always use a buffer for realtime data acquisition from a microcontroller? [on hold]

I probably have a misunderstanding one way or another, so this may be a bad question, but whenever I see sketches of projects that are outputting realtime data or in general, I always see the use of ...
0
votes
0answers
21 views

Setting up two arduinos connected to separate serial ports with wires in-between

I intend to have both an Arduino Nano and an Uno connected to a PC via the on-board USB ports, but have them inter-connected with wires from one's GPIO pins to the other's (one reads the status of the ...
0
votes
1answer
42 views

Serial.read() doesnt work in IF statement

I am working with an XBee module, so naturally, I started my void loop with AT command testing. void loop() { digitalWrite(Sleep_Rq,LOW); A +++ with a guard time of 1 sec before and after it, ...
0
votes
0answers
23 views

Problem: char string not working with SoftwareSerial.h

I am creating a program to display text on an OLED display and then have it sent to a thermal printer. The issue is my second char string: word_buffer When I try to use word_buffer for any reason it ...
4
votes
4answers
18k views

Is it possible to connect many arduino uno in one pc?

We have many Arduinos and we will be putting each of them in a cubicle. All of them are connected to only one PC. The PC will stand as a server were you can control your Arduino there.
1
vote
2answers
46 views

How do you make a switch case run until another serial input is detected?

I am trying to create a Traffic Light Controller. There are three modes to the controller: Mode 1 - the traffic light operates RED-YELLOW-GREEN-YELLOW and should repeat * (The other modes are not ...
2
votes
1answer
21 views

Read from serial monitor and put it in a array of byte

I'm a new here and this is my first question. I would like to read from serial monitor and stock the information in a array of bytes. then I want to print this array in serial monitor. This is the ...
2
votes
1answer
32 views

STM32 Nucleo F401RE in Arduino IDE - how to enable more than 1 Serial?

I just received a Nucleo F401RE and can't get my sketch to work on it because the compiler says Serial1 is not defined. My sketch uses multiple serials because I need to use the usb serial monitor ...
1
vote
2answers
51 views

Unusual use of << operator… not a bit shift?

Poking through the example code of SDFS, I saw the following: static ArduinoOutStream cout(Serial); // F stores strings in flash to save RAM cout << F("\ntype any character to start\n"); What ...
0
votes
1answer
128 views

Badly formatted characters using JDY-30 bluetooth module

I have a JDY-30 bluetooth module and have it wired like this (except using an Arduino Uno): It is working, but I need to use it with a 115200 baud rate instead of the default one of 9600. I also got ...
0
votes
3answers
43 views

Is it possible to upload an arduino sketch through the serial port (RX) instead of USB

In another words, is it possible to develop a custom bootloader so sketches can be uploaded via serial connection made using the RX/TX pins and not via the USB connector (I am using Pro Micro boards)? ...
0
votes
0answers
27 views

Serial communication problem NodeMCU

this is my first post here. Before I ask you my problem, I'm sorry if I'm wrong to write but my English is bad. So, my problem is this: I'm developing a "client-server" system with serial ...
0
votes
1answer
28 views

Arduino Python to Serial command [duplicate]

I am trying to send commands via serial from Python to Arduino with the code below. If I save this code in a dedicated python file "Stepper.py" (Python2.7 on Mac OSX) , the code runs successfully ...
0
votes
1answer
66 views

Arduino Uno: external power supply +5V and serial communication with pc over USB

I have connected to my Arduino Uno outputs relay module. Relay module has 16 relays (5VDC) which are controlled by transoptors pins (HIGH from Arduino = specific relay is off). Link to relay module ...
0
votes
1answer
34 views

Display Wireless Temperature Sensor data to Web page by using Serial communication

I am reading from wireless temperature sensor with help of gateway receiver connected to Arduino UNO, using this code I need to display the data of the wireless sensor on the webpage. Any ...
0
votes
4answers
87 views

How to convert read characters to strings?

How can I append a string e.g. "AA 00 01 00 FF FF A2" to serial data using Arduino? The following code does not seem to be correct: String comdata; void loop() { while (Serial2.available() > 0)...
0
votes
1answer
84 views

Issues with I2C and Wire.Available()

I am working on a project which requires communication from an Arduino Due (Master) and an FDC2214Q1 C to D IC (Slave), but there is some variability as to whether the code works or not depending on ...
0
votes
0answers
11 views

Problem with uploading sketch [duplicate]

Arduino: 1.8.9 Hourly Build 2019/02/04 10:12 (Mac OS X), Board: "Arduino/Genuino Uno" Sketch uses 2078 bytes (6%) of program storage space. Maximum is 32256 bytes. Global variables use 189 bytes (9%) ...
0
votes
1answer
431 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
1answer
41 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
1answer
40 views

How to convert a delimited string of hex numbers to an int array

I am sending a string to the Arduino via serial, I made the program that sends the data, so I can change it to anything, but for now it sends a string of hex numbers delimited by ':', so for example ...
0
votes
0answers
24 views

Prints to the serial monitor are being overwritten

Using esp32, Arduino IDE 1.8.9 on OSX. My code is interspersed with Serial.println() writes to the serial monitor of various status messages. As far as I can tell, if a println is not fully written ...
0
votes
1answer
45 views

Voltage meter ADC + serial: Bytes lost during communication

I want to make a simple digital voltage monitor. So I have a sketch: void setup() { Serial.begin(115200); } void loop() { int val = analogRead(A4); // read the input pin val = 1; byte ...
0
votes
1answer
53 views

Oscillating Output from Arduino Pins when not in use, why? [duplicate]

I have A1 set to be an input, have the program read it, and then print to the serial monitor. My question is, when the circuit is not receiving power, but is grounded, and is still connected to A1, ...
0
votes
0answers
21 views

GPS only works when I click Reset on Arduino or Reopen Serial Monitor

I cannot work this out! My Ublox 7n GPS module will only print data in the serial monitor once when I either click reset on my Arduino Uno or reopen and close my Serial monitor. So whenever I have ...
0
votes
0answers
116 views

ESP8266 to send data to thingspeak while doing unblocked read on Serial.readString()

I have a requirement to get RFID data on Arduido UNO and send it to ESP8266 to be sent to ThingSpeak via the Wifi module. However, ESP8266 is also programmed to send Temperature and humidity data to ...
1
vote
0answers
46 views

Connecting Audio Jack to Arduino

So I started working on a project of mine that is mostly software based which I have no problems with, but it includes electronics too. Where I am still learning a lot. Anyways, I have been trying to ...
1
vote
2answers
48 views

Several Software Serial Ports

I am planning to use an Arduino (Nano ideally, or Other) to send and receive information from several software serial ports to other arduinos, over their available pins, ideally 8 ports. I could ...
1
vote
2answers
87 views

Two serials can't work on the same speed

I have a device which sits on pins 10/11 of Arduino UNO. I am trying to send commands from my PC using Arduino to relay my commands to the device via Serial. The problem is that if I use speed 9600 ...
1
vote
1answer
50 views

Why my serial message won't show on another when I try use 2 Arduino communication

I am trying to make a simple chatting program with my 2 arduino uno and 2 PC. But when I tried write a message using PC1 serial monitor the message won't show up on PC2 serial monitor. I can't see the ...
0
votes
1answer
69 views

Random number/sequence output

The program I'm trying to build is: Type in 1st name, hit enter, type in 2nd name and then hit enter again. Register those names from string input to char naming in student struct. Print out the ...
0
votes
1answer
28 views

Method to iterate over the bits in a byte sent over serial [closed]

In my current project which integrates Arduino/avr IC with Raspberry-Pi, and each communicating via serial, I'm looking to send a byte of data to the Arduino from the RPi, which then would be iterated ...
-1
votes
1answer
51 views

How to parse multi line serial data with an unknown number of lines? [closed]

Here's the example data I've read in H-Term: \r\n \r\n NO:0015\r\n G: 5.97kg\r\n T: 0.00kg\r\n N: 5.97kg\r\n \r\n \r\n How to save the number including "kg" to each variable (NO, G,...