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.

Filter by
Sorted by
Tagged with
1
vote
2answers
22 views

Printing the array using print and serial write function in Arduino Uno

I have, one program with only using printing array and other with serial write and print function for the array, while using serial write and print function I get these extra characters between the ...
1
vote
1answer
1k views

Can't read from / write to EEPROM

I'm currently trying to write to and read from an 25LC256-E EEPROM with my Arduino Uno via SPI. I've made a program which is supposed to do this, but I only get weird answers. I'm sending in a Serial-...
1
vote
1answer
115 views

How to convert a String to Hex array

I am trying use a HMI display. If I want to send a data, for example I want to write "TOPWAY" to 0x00000080 address it should like that: Serial.write(0xaa); // packet head Serial....
11
votes
4answers
46k views

How to retrieve the data type of a variable?

I am using Arduino and I would like to know if there is a function that returns the data type of a variable. That is, I would like to run something as like the following: // Note: 'typeof' is a ...
0
votes
1answer
49 views

Using index of to search for multiple characters

In my Arduino project, a string will be received. I understand using .indexof to find the placement of a certain character in the string. My problem is that I need to find the first occurrence of any ...
0
votes
1answer
49 views

Find OK or ERROR in serial string

I am trying to figure out how to capture the OK or the ERROR from a SIM800l. I have tried mySerial.println("AT"); while (mySerial.available() > 0 ) { String str = mySerial.readString(); ...
0
votes
1answer
286 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 ...
2
votes
2answers
86 views

how can I accurately recieve potentiometer values over the USB port?

I want to read the analog values of my ardunio uno into a separate c++ program. On the Arduino I have a serial port initialized for 9600 baud: int sensorPin = A0; // select the input pin for the ...
1
vote
1answer
148 views

How to send 2 data to processing from Arduino

I am new to Arduino and processing so sorry for any mistakes. I have a problem with sending multiple data to processing from Arduino. I can send 1 data easily ut I can't send more than 2 data can ...
1
vote
1answer
100 views

Dragino lg01-p problem with serial monitor

i have a dragino lg01-p lora gateway to which i successfully communivate through lora with an arduino and i can program it through network as expected and seen in its manual with the demo client-...
0
votes
0answers
102 views

I need all these codes in one single code 1) Relay 2) Motorised ball valve 3) Ultrasonic sensor [duplicate]

I have three separate codes for relay, motorized ball valve and for ultrasonic sensor. I am unable to run all the three codes at once in same serial monitor. I am pasting all the three codes below. MY ...
0
votes
1answer
2k views

Serial communication from Arduino to ESP8266 NodeMCU works, but from NodeMCU to Arduino isn't working

My circuit connection is like: (I am following this tutorial) Code uploaded to Arduino: #include <SoftwareSerial.h> #include <ArduinoJson.h> SoftwareSerial s(5,6); void setup() { s....
2
votes
1answer
103 views

RS-485 Serial communication problem with arduino

I use 485 modules to transmit data serially from one arduino uno to another uno. If I connect the 2 arduino boards directly without using the rs485 module, the data is sent and received without a ...
1
vote
1answer
30 views

ESP8266-01 module “AT” command testing not responding

Firstly I have connected the Arduino UNo to Esp8266-01 Module and uploaded the Simple Blink Sketch using Arduino Uno and It responded correctly as in the Blue Led Light on Esp8266-01 was blinking ...
1
vote
1answer
62 views

Dealing with USB Unplugging?

The following code, debugs SerialUSB Native Port, plugged to a PC, and connected through a Terminal Monitor (such as Termite, with any bps, 8N1, RTS/CTS). At start, the ports seeks for communication, ...
1
vote
1answer
49 views

Serial baud rate is less than specified

I want to read values of arduino pins and send it to PC via USB cable. The problem is that byte writing/reading happens at a rate which is ~10 times smaller than specifies baud rate of a serial port. ...
2
votes
2answers
135 views

Bluetooth module(HC 05) issues

I am trying to make a Bluetooth controlled 4WD robot. i was following a tutorial i found online (https://howtomechatronics.com/tutorials/arduino/arduino-robot-car-wireless-control-using-hc-05-...
1
vote
1answer
20 views

Arduino Nano not recognized by Mabook Pro M1

I am new to Arduino and I have ran into an issue. When I first tried to plug the arduino nano (after market, from ebay) into my computer (Macbook pro M1), nothing happened. Then I downloaded the ...
41
votes
4answers
44k views

Why does starting the serial monitor restart the sketch?

If I upload any sketch that sends serial data, I immediately see the TX/RX LEDs flash once the sketch is uploaded. If I then start the serial monitor, the sketch appears to restart. A bare minimum ...
1
vote
1answer
255 views

Random characters transmitted from ESP8266 to Arduino

Below is the code for getting a value from Firebase and sending the received data to arduino for performing necessary action. The code here here sends a string "o" to arduino once //uploaded to ...
2
votes
2answers
80 views

Stuck In While Loop

So I'm a beginner at Arduino and I have to light up an LED grid to show digits from 0-9. I wrote a bit of code (with the help of some people) and it's like 90% done but there's this ONE problem. I ...
1
vote
0answers
38 views

Program a mega2560 from a different Serial port

I want to be able to use my HC-05, currently on Serial3 to download code to on my 2560 from a connected android tablet. I'm currently running MegaCore, which has optiboot on it. I've looked for ...
3
votes
1answer
47 views

Is it possible to gather data while the Arduino is being powered with a battery, connect to comp, and then read off the values in Serial Monitor?

I want to do a project where I gather data such as sunlight hours per day, as well as temperature highs/lows. Once I have gathered 24 hours worth of data, I want to hook it up to the computer to read ...
2
votes
1answer
462 views

Arduino Pro Mini ATmega 328P: garbage output on serial console

Arduino Pro Mini ATmega 328P 3.3V 8MHz, connected to USB port via USB to Serial breakout board built around the FT232RL FTDI chip. JTAGenum project code uploaded to the Arduino. I opened terminal and ...
2
votes
2answers
1k views

FastLed (WS2812B) and IRRemote problem

I am trying to control my WS2812B with a remote control. To archive this, I am using IRRemote library. The problem is that this two libraries doesn't work together. I did some research and found out ...
1
vote
3answers
866 views

Is there any way to use the serial port as an interruption source?

I have an sketch made for reading a temp/hum sensor once every ten seconds aprox. However, I want to introduce an interruption source to send from my keyboard a magic word to make the sensor be read ...
1
vote
0answers
48 views

Serial communication problems

When I run this script serial communication just stops after a random period of time. There is no error it just stops outputting data and does not respond to inputs in IDE. Does anyone know a fix for ...
1
vote
1answer
52 views

Arduino NANO clone not detected by computer

I recently purchased 5 Arduino Nano clones and on my Windows PC they were all working fine. I then gave one to a friend and after installing the CH34OC driver on his Mac he was able to program a ...
1
vote
1answer
31 views

Arduino randomly stops sending data to python over serial

I want to send commands to Arduino over USB Serial from my python program and Arduino should send back received command to make sure data wasn't lost. However Arduino randomly stops sending data back. ...
3
votes
1answer
2k views

Reading three signals sent serially on Simulink from Arduino

I am sending three signals from one Arduino mega to another using xbees. On the receiving end I am using these signals in a Simulink code to control servo motors. Currently it is set up to read from ...
0
votes
1answer
456 views

Why can't I use Jeelib Sleepy on the Teensy 2 along with Serial

I have been using the Jeelib Sleepy functionality for several years now to achieve low power states on the Arduino ATmega328/1280/2560 boards, specifically the LoseSomeTime functionality. I want to ...
2
votes
1answer
154 views

Trouble obtaining values from Nextion screen to Arduino

Currently I have a setup running an Arduino BME 280 sensor and a 4.3" Nextion screen. What my program does is sent all the calculated values from the BME to numbers and progress bars in my ...
0
votes
1answer
84 views

Listening Serial Ports

guys. I need your help. I have 6 Serial Channels and I need to listen this channel and be sure which channel is working? How can I do that? Can I listen this channel by using digital inputs? Or Do I ...
1
vote
1answer
61 views

Sending Data Between Arduino Nano and D1 Mini

I am sending data from Arduino Nano to D1 Mini, Transmitter is Arduino Nano Transmitter Code: #include <DES.h> #include <SoftwareSerial.h> SoftwareSerial link(2, 3); // Rx, Tx DES des; ...
0
votes
2answers
51 views

Arduino Serial Monitor Input 3DES Encryption

I am trying to 3DES encryption using Serial Read, Found this 3DES Sample code in Github, #include <DES.h> DES des; void setup() { Serial.begin(9600); Serial.println("Hello!"); } ...
0
votes
0answers
42 views

Serial communication transfer data btw 2 arduino

i want to transfer 3 data from master to slave and turn on / off led in slave. HOW COULD I TRANSFER 3 DATA IN SERIAL COMMUNICATION BTW 2 ARDUINO UNO? if data1 = 0 in master , led 1 = LOW in slave, if ...
1
vote
0answers
18 views

Writing multiple inputs to serial port using a while loop

I am trying to get the serial monitor to prompt me to input two settings - the PWM level and the Resonance level. I am being prompted to input the PWM level, but before I can input the Resonance level ...
1
vote
1answer
32 views

How do I control a servo with python through an Arduino

I'm trying to make it so I can control 2 servos with data that I get from a python script that tracks my face. I have found 2 libraries that do this:pySerial and pyfirmata. Is one superior to the ...
5
votes
3answers
6k views

Arduino serial port reset in Serial monitor & Python

So am I using an Arduino with a shield to gain some voltage values for an ECG. I am then plotting that data in Python. However whenever I "observe" the serial port, be that through the Arduino serial ...
5
votes
1answer
1k views

Serial monitor can't display float and double values with absolute greater than 4294967040=2^32-2^8

I have the following sketch: void setup() {} void loop() { float af = 4294967040.0; float bf = 4294967240.0; double ad = 4294967040.0; double bd = 4294967040.00001; Serial.println(af); ...
0
votes
2answers
231 views

Print when echo is read by HR-S04 sensor

I'm trying to see when an echo is received by my HR-S04 sensor. I have a Serial.println within my while loop to read the signal and see once a change happens to break the loop. The issue is my serial ...
1
vote
1answer
131 views

Storing data in Arduino Portenta H7's SDRAM

I am working on storing data from Portenta H7's ADC through a high sample rate (>100kSa/sec) per channel. I am using 2 ADC channel for my work. Through the forum, I learned that the serial. print ...
0
votes
1answer
976 views

Unable to read the Serial Port through Arduino the way Serial Port Monitor softwares read it

I have a device feeding Rx Tx data every minute. I connected it to the computer. I downloaded a Serial Port Monitor Software, and here is the data I captured using that software. Now when I try to ...
1
vote
1answer
195 views

Can SoftwareSerial be used in an ESP01

I am using ESP01 as a microcontroller that retrieves information from Firebase and sends them over serial to an Arduino Uno for other uses. I am not using NODEMcu since it has few analog pins and ...
1
vote
1answer
398 views

Flow control between ESP32 and RS323 device

I'm trying to communicate an RS232 device with an ESP32 (Heltec Wifi/LoRa 32 v2) my problem is that I don't receive any response from the device, doing some research, I'm thinking that the trouble can ...
1
vote
1answer
62 views

16x2LCD Display serial read extra character

I get extra character (frowning face) when sending a text over the serial monitor(see attached image) When empty string is sent over the serial monitor, the LCD display still shows the extra ...
0
votes
1answer
37 views

Arduino nano BLE sense Serial port Suddenly stopped working

Last week I got my new Arduino nanao ble sense. Today I was executing a code on it which reads every sensor data on it and print it on serial monitor. I changed some parameters in my code and upload ...
1
vote
0answers
33 views

I am interfacing relay, signal isolator and a ultrasonic sensor using one Arduino UNO. How can I control using one serial monitor and one code? [closed]

char a; // Using Pin 3 const byte numChars = 32; char receivedChars[numChars]; // an array to store the received data boolean newData = false; int dataNumber = 0; // new for this version ...
2
votes
4answers
1k views

What is the function of the XBee / USB switch on an XBee shield?

I recently bought an XBee shield (this). The shield has a switch that seems to switch between USB/XBee. However, there is no USB port. What exactly is the switch supposed to do?
1
vote
0answers
35 views

Serial communication detect

guys. I am workin on a project. I have two channel for Serial RS232 communication. Main and Stand-By channel. If Main channel has some problem and, cannot communicate for 15 seconds then I want to ...

1
2 3 4 5
42