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 [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
votes
1answer
23 views

Can I operate an arduino that has a file uploaded on it, without having the file myself?

I've been a massive idiot and accidentally deleted the sketch I need for a project at university, and I didn't create any backups. The sketch is already uploaded into the arduino, which operates using ...
0
votes
1answer
29 views

Optocoupler on Tinkercad acting weird

So, maybe it's my understanding that is at fault or maybe it's tinkercad. It's probably the former. But anyway here's my problem I've connected it according to picture https://imgur.com/a/h2HYgUE ...
0
votes
0answers
29 views

How to make Arduino + CAN-BUS as Adapter

Is it possible to make Arduino + CAN-BUS shield as adapter to PC ? Example: I have software "A", which needs CAN data (software gets data itself, and do everything itself). I connect CAN-HIGH, CAN-LOW ...
0
votes
1answer
37 views

Receiving junk values in Arduino serial monitor console

I want to send a character from a Zigbee transmitter to an Arduino Mega 2560. After the character is received, Arduino should send some data back to Zigbee. But Arduino is always receiving junk values ...
0
votes
1answer
41 views

Random characters generated by LCD during serial.read()

I am using the following codes to print characters on LCD display.... #include <LiquidCrystal.h> const int rs = 8, en = 9, d0 = 4, d1 = 5, d2 = 6, d3 = 7; LiquidCrystal lcd(rs, en, d0, d1, d2, ...
0
votes
2answers
53 views

Serial Communication between 2 Arduinos for analogRead value

I have an optical sensor connected to A0 on Arduino #1 (Nano) giving me values from 200 to 1010. I need to receive these values in Arduino #2 (Nano) through serial communication. I have used a simple ...
0
votes
0answers
35 views

UART communication

I'm working on a NUCLEO-F401RE board from STMicroelectronics which is based on STM32 microcontroller and an xbee module from Digi for Zigbee communication. This board is programmable via Arduino IDE, ...
-1
votes
1answer
18 views

Is it possible to simultaneously acquire 2 values from the Arduino? [duplicate]

I am currently making a project using a resistive touch screen and an Arduino Uno. The resistive touch screen outputs an X and Y coordinate pair, which I then want to be able to read and output on an ...
0
votes
1answer
39 views

Multiple sensors connected to Arduino MEGA 2560 Serial ports

I am using Arduino MEGA 2560 to read values from two sensors. Sensor 1 is providing us two values separated by a comma and a space followed by a newline character. e.g.: 2.277, 7.942 2.269, 7.897 2....
0
votes
1answer
33 views

Arduino losing connection to Serial port after running function

For some reason when I loop my code through a separate function the serial port hangs up. The serial connection appears fine when I call cases within the loop but not when I call outside. I tried to ...
1
vote
1answer
116 views

getting error 'Serial' was not declared in this scope

I am adding Dust Sensor to my particle photon project at home, I got this GitHub project that I want to test before implementing a final code. I am not an expert in cpp, I wanted to modularise the ...
0
votes
1answer
38 views

Why my light meter's values are blank on Arduino Serial Monitor?

I tried to represent the values of TSL 2591 Adafruit light sensor on my Arduino Serial Monitor, but for some reason, I could not do that. The Arduino Serial Monitor just enters some blank values and ...
0
votes
2answers
42 views

Problem with modbus communication between two arduinos when writing more than 27 registers

I have the following problem: I want send 200 registers from a modbus master to a slave. Both are arduinos. I can't send more than 27 registers. When I send more i get the Errorcode 255 which means ...
0
votes
2answers
43 views

Serial.write is synchronous

I have a good experience of the real(/critical)time world, but I'm new with Arduino. I noticed that Serial.write is synchronous. If the buffer size is >64 (the USART size) it lasts the time of the ...
0
votes
5answers
56 views

Can I have two separated serial monitor for the same arduino board connected to PC?

I'd like to split serial communication into the two channels: 1) debug info, 2) application data. There's only one Serial object to use. However, maybe, there is an alternative way to print data ...
0
votes
2answers
22 views

What is the best serial communication method between an Arduino and a spectral sensor?

I have an Adafruit AS7262 visible spectral sensor. I want to receive the data of the sensor with an Arduino. The sensor has two serial communication options: UART(asynchronous) or I2C(synchronous). I ...
0
votes
1answer
30 views

Does SoftwareSerial and the servo library produce interrupt conflicts?

I'm planning a project that will involve multiple serial ports and the Arduino servo library. I have heard that this may cause interrupt conflicts. Are there any simple solutions to this
0
votes
1answer
44 views

How to send an integer through pyserial with Python to an Arduino and get back the same result?

There has been similar questions all over the internet but none of them seem to answer my question, so can anybody tell me what is wrong with this code and how I can fix it? Python code: import ...
0
votes
1answer
38 views

Serial monitor doesn't work with piezo buzzer

So I can't see the distance of the proximity sensor anymore as soon as I type the code for the piezo buzzer. I've tried many things but it doesn't work.. Can anybody help me fixing this? int trigPin =...
0
votes
0answers
11 views

GSM Module sim900a fails network registration

I interfaced the Arduino uno with gsm module sim900a through communication. But when the AT commands are sent by arduino there is no response from gsm module. I watched the data sent by arduino in ...
0
votes
1answer
49 views

elechouse Voice recognition v3 module not responding when i send command using Access port serial tool

I have this challenge of receiving data when I send a command to voice recognition v3 module. the uart connections are okay, but when I send a command I don't receive a response on the terminal. the ...
0
votes
3answers
93 views

Unexpected accident of my board, CH341 issue for Linux or Dead ESP?

I have early midnight accident of my Lolin/Wemos boards. I tried uploads my sketch with a assembly VIN to GND as my reset button, when i uploads my sketch at more one hundred times, i get my boards ...
0
votes
0answers
49 views

MPU-6050 data over I2C freezing/stopping

Thanks in advance for everyone on this forum always being so helpful. This is the first time that I've had to post a question, because I've always found my answers easily after a quick search - either ...
1
vote
0answers
51 views

Keypad prints just 1 [closed]

I used this example code: #include <Keypad.h> const byte ROWS = 4; //four rows const byte COLS = 4; //four columns char keys[ROWS][COLS] = { {'1','2','3','A'}, {'4','5','6','B'}, {'7','8'...
0
votes
1answer
50 views

Serial Moniter is repeating output

I do apologize for the constant posts on here. However I ran into an issue and I cannot seem to find any solution to it. The goal is to enter a username, through the Serial.read function, and if the ...
0
votes
0answers
23 views

How can I read the serial output of STM32F103C8T6 from USB to Serial TTL?

I recently bought a STM32F103C8T6 board (blue pill) I programming to it using the USB to Serial TTL I bought (CP2102). I'm still taking very first steps and trying to figure out how to operate the ...
0
votes
1answer
36 views

LDC paired with Arduino locks up and freezes. Out of SPRAM?

I am making an alarm clock using a 4x20 lcd display, rtc, and Arduino Pro Mini 3.3v. I have implemented a menu system for setting the time/date that blinks the text on the lcd display to indicate that ...
1
vote
2answers
61 views

Serial monitor returns “48” when I enter “0”

I am going through an Arduino Learning Book(978-1-59327-448-1) and I've run into the same issue twice now. When I enter data into the serial monitor, the number that it reads and displays(when asked ...
0
votes
0answers
38 views

Connecting serial ESP8266 ESP-07S - not working

I'm trying to access EPS8266 ESP-07S serial connection on PC using CP2102 and PL2303HX - both supporting 3.3V connection. I'm using diagram like this or this, and trying with and without connected RST,...
0
votes
1answer
86 views

No data sent over serial port in linux c++

TL;DR - I am attempting serial communication with Arduino with code that I found here and nothing gets sent over (Arduino programmed to respond, and I checked that it does with its serial monitor) Hi ...
0
votes
1answer
46 views

Using Arduino UNO for uploading a sketch to the Espresso Lite v2

I am trying to use my Arduino UNO as a programming interface to load sketches on the Espresso Lite v2. I followed the instructions to setup the Wifi network (long press gpio13 and the AP thing), but ...
0
votes
1answer
48 views

If/Else Statements on Arduino not executing

I have a bit of code below, the problem is only the first 'if' statement will execute when called on. When I call on u, q, or any of the other if statements it will go straight to the else and not ...
0
votes
1answer
31 views

Why does my Esplora only send serial data when the serial monitor is on?

I've noticed that when I'm sending serial data to my computer's serial monitor, the tx light only lights up when the serial monitor is open. When I close the monitor, it seems to stop sending data. ...
0
votes
0answers
42 views

CH340G and CP2102 devices not recognized with Thinkpad L380

I have three different devices, none of them gets recognized on my new Thinkpad L380 running Windows 10: Arduino Nano Clone with CH340G chip (USB2Serial) NodeMCU (Lolin V3) with CH 340G chip (...
0
votes
1answer
31 views

Serial communication between an Uno and an Esplora by connecting their usb ports together

I’m trying to send a character message from an arduino uno to an esplora by connecting their usb ports together. The esplora has a micro usb port, while the uno uses a usb B port. To hooked them up, ...
1
vote
2answers
42 views

Two floating point values do not get added and printed on ESP-WROOM-32

I have a Olimex ESP32-PoE board which has a ESP-WROOM-32. I just found out a strange behaviour for printing floating point numbers on the board. Sketch void setup() { // put your setup code here,...
0
votes
2answers
81 views

Arduino Hello World in Serial monitor

Hi we were asked to program something which when i enter something in the serial monitor it prints Hello world but the catch is it only prints hello world under the conditions that your input in the ...
0
votes
3answers
72 views

formatting strings in Arduino for output

I wander what is the best option for formatting strings in Arduino for output. I mean what's a preferable way in the point of view of performance, memory usage – things like that. I see, people ...
0
votes
0answers
28 views

How to make arduino as a client and send the data collected by the arduino to a web server via ESP8266 [duplicate]

I am working on an IOT project where Arduino as a client and send the data collected by the Arduino using Current Sensor ACS712 to a server which is hosted over the internet. Where I can store and ...
0
votes
1answer
157 views

Serial communication mac to Digispark ATtiny85

I want to use the Arduino IDE serial monitor with my Digispark ATtiny85 over USB. I can without problems upload this code(Digispark CDC example): #include <DigiCDC.h> void setup() { ...
0
votes
1answer
294 views

Arduino Convert std:string to String

I'm working on BLE project with espressif library. And It returns me founded BLE device. std::string getManufacturerData(); std::string getName(); int getRSSI(); BLEScan* getScan(); When ...
2
votes
1answer
205 views

“char inChar = (char)Serial.read();” why is the “char” in brackets? and what is it called

I am sure this is a very simple answer, but I don't know to look it up on google In the example "SerialEvent" in the arduino IDE (v1.8.7), there is the following function void serialEvent() { ...
0
votes
1answer
22 views

SIM808 return the same AT command

I am using atmega 2560 and SIM808. When I send an AT command to SIM808 it returns correctly. But sometimes I have seen that SIM808 returns the same AT command. Sometimes it occurs due to lack of power ...
0
votes
1answer
52 views

Can't write to serial immediately from PC to Arduino nano via pl2303 usb to ttl converter

Goal: I am trying to send some characters to Arduino through serial from PC via a Prolific PL2303 USB to TTL converter(Chinese clone). I have wrote a simple sketch(attached bellow) which should ...
1
vote
1answer
58 views

Writing and reading an ID to/from an Arduino reliably

I need a way to both ID (a sketch/compiled hex) and later on, identify based on this ID the project that got uploaded to my Arduino microcontroller. As of right now, I have explored multiple options ...
1
vote
2answers
57 views

Arduino serial question [closed]

just a quick question on an oddity I noticed while playing with serial on my Arduino. I'm using the serial monitor to test an interface I plan to adapt to Bluetooth later. Except I'm noticing if I ...
0
votes
1answer
23 views

Unable to receive data when using multiple SoftSerial on Arduino Nano

I am trying to use several (four) software-based serial ports to talk to different peripheral hardware. However, I am unable to receive data through the SoftSerial when using more than one software ...
0
votes
0answers
22 views

Arduino Pro Micro and RFID-reader

I've written some code for reading RFID-tags that works perfectly with my UNO. No issues at all. Problem is, the UNO is 1) too large, and 2) lacking USB interface, which I want in order to transfer ...
0
votes
0answers
18 views

USB OTG to arduino using another power source [duplicate]

First off: I know some similar questions have been asked, but I think my question has not been answered yet. I am working on a way to controll my LEDs via my Android phone, which works, by connecting ...
0
votes
1answer
27 views

How to Create a reference to an External Print object

Right now I have an object: class Dog { public: Dog(uint8_t I2c, Stream& feedback); void Speak(); private: uint8_t _I2c; Stream& _output; }; Dog::Dog(uint8_t I2c, Stream&...