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
0
votes
0answers
17 views

Issues with BluetoothSerial.h library and string comparison

I spent 5 hours searching on stack overflow, reading through documentation, and asking people I know for help with this issue. Basically my code reads an input string, character by character, from a ...
-3
votes
0answers
28 views

Serial comunication beetwen Arduino and STM32 F401RE with Arduino ide

How can I pass through the serial ports an arduino number to the STM32 F401RE? Using the Arduino IDE? For now I have done this: Code Arduino (TX) void setup(){ Serial.begin(9600); } void loop(){ ...
1
vote
0answers
25 views

Serial communication between Python & Arduino: [duplicate]

I need to transfer information between pyton script and arduino. Data is always built like this "wheelbase:1000" wheelbase can be another word and 1000 can be another value, : is always the ...
1
vote
1answer
43 views

Arduino native USB port and Simulink [closed]

I am trying to communicate through the native USB port of the Arduino Due with a PC. The native port itself works, I have tested this. The problem is, that every time I upload my Simulink model via ...
0
votes
1answer
36 views

Optimised random alphanumeric string generator

I'm trying to build arduino nonce generator, but the only thing I found is this question on arduino forum but I can't find out how to make it work for me. I checked and Serial.available() is always 0 ...
0
votes
0answers
10 views

Attempting to multiplex a UART interface [migrated]

This is in general more broad than just specific to the arduino but don't really know a more appropriate place to ask. If someone knows feel free to point me in the right direction. I'm working on a ...
1
vote
0answers
50 views

SoftwareSerial fails to receive on Nano but works with Uno [duplicate]

I have built a circuit board that includes a BLE module and an oxygen sensor that has a UART. Writing arbitrary data to the BLE works fine, but for some reason every configuration of SoftwareSerial I ...
0
votes
1answer
49 views

On-device logging of all Serial.print calls? [closed]

My Arduino program produces debug/error output using methods like Serial.printf. I can see all this output when it's connected to the computer, but I want to also log all this same output to my board'...
1
vote
1answer
54 views

Peculiar behaviour of arduino pro micro

I am working with an arduino pro micro and I am facing a peculiar problem. The project I am working with includes arduino MKR NB 1500 as well. I am transferring data from MKR NB 1500 to arduino pro ...
1
vote
1answer
173 views

How to send multiple data over serial in one byte?

I'm currently reading 3 limit switches and sending those data over Serial.write using the following code. #include <SPI.h> #include <Wire.h> #include <arduino-timer.h> //Define ...
1
vote
2answers
38 views

Serial.write - sedd ascii characters with hex value in the same line [closed]

Working on making a controller for a haunted house prop. Trying to get it to interface with a device. Was able to use a serial analyzer to see what commands and values are being sent. the hex codes ...
2
votes
0answers
40 views

Simulink resets arduino

I am working on servo motors control through serial communication protocol, I am sending data from Simulink to arduino and vice versa, The problem I am getting is that once I open Simulink Servo ...
0
votes
1answer
65 views

Serial comm UART1 works on Arduino but makes ESP32 continuously reboot

This comm sketch simply read incoming bytes from the UART 1 where a device is attached. It works normally on a real Arduino device. But on ESP32, it makes it continuously reboot with the following ...
2
votes
1answer
218 views

Fail upload sketches to ESP8266 only on Ubunto 20.04.3

I installed a fresh copy of Ubuntu 20.04, and Arduino IDE1.8.16. At the beginning adding user to dialout group enabled uploading sketch to Aruino AVR family, and ESP32, but still ESP8266 gives this ...
1
vote
1answer
63 views

Serial Monitor in Arduino works, but other Serial Terminal work only one way

I have a Arduino code working on a Adafruit Feather STM32F405 Express, and as long as I test it with Arduino serial Monitor, everything works perfect. As I want to use a serial terminal (a C# ...
0
votes
3answers
58 views

Where are these junk characters (from serial) coming from?

I currently have 2 Arduinos both hooked up to HC-12s and have successfully got them communicating. But I am now trying to be able to process the data sent across and store it as a variable so as to ...
2
votes
1answer
65 views

So many missed bytes with serial comm

I have a setup with serial comm from Raspberry Pi to Arduino. It's communicating at baud 9600 on both devices, and from Raspberry Pi 3b+ GPIO-14,UART0,TX0 to Arduino Nano RX0. There's a level shifter ...
3
votes
4answers
728 views

Bi-directional UART communication on single data wire, possible?

The nano is inside of the house, and the pro mini is outside of the house. I want to send/receive text between them. The communication will be always nano sending text to mini, and then mini sending ...
1
vote
2answers
126 views

which is the best way to declare Serial while creating Arduino library?

Well, I am trying make a library for HMI display. display and Arduino comminicate with Serial. So I will so many times Serial port. Generally I will use Serial.write commend. if I examine other ...
0
votes
1answer
71 views

No response from instrument via serial communication

I am using a Teensy 3.6 to communicate with an external instrument via a serial connection. However, I am not able to get the instrument to respond to my commands. The idea is to send a command from ...
2
votes
1answer
86 views

Swap Serial pins of ESP8266?

I have designed and manufactured a PCB which contains an ESP8266 (ESP-WROOM-02D) chip with the serial uart pins connected to a 30pin connector. I made a mistake on the layout (first time designing a ...
2
votes
1answer
62 views

Getting constant PWM value based on user input from serial monitor

I am trying to get a constant PWM value from the PWM pin based on the user input. For example: the user hits 1, the output PWM value is 100, if it is 2 the output would be 200. This will continue till ...
1
vote
0answers
82 views

Serial monitor constantly reads input with unknown characters

I am trying to read input from the serial monitor on my Arduino UNO using the new Arduino IDE 2.0 and send a specific infrared signal depending on the command. I do this using the following code: #...
0
votes
1answer
124 views

Serial to USD (HID keyboard device) converter

I am working on a project to collect data from a barcode scanner using an arduino which in turn is connected to a POS/laptop. So far i am able to collect the data from the barcode scanner by using the ...
1
vote
1answer
37 views

What is the overhead of a saturated serial connection at 256k baud?

I have am putting together multiple arduinos on a RS485 network (connected to Rx/Tx on the arduino and using Serial - connection via one of these https://www.ebay.co.uk/itm/272929871278) - RS485 ...
2
votes
2answers
398 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
334 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....
0
votes
1answer
223 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 ...
1
vote
1answer
67 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(); ...
2
votes
2answers
102 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
52 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 ...
1
vote
0answers
46 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 ...
2
votes
2answers
86 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
54 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
37 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. ...
1
vote
1answer
181 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 ...
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
73 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; ...
1
vote
0answers
110 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 ...
0
votes
2answers
57 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!"); } ...
1
vote
1answer
61 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
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
1answer
78 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
37 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
vote
1answer
46 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
30 views

Trying to use Serial to communicate between two D1 Mini's

I'm trying to connect two D1 Mini's together as a POC. There is a switch on one and a 7 segment display on the other I have the pins setup from TX>RX and RX>TX First ESP8266: int SWITCH_PIN = D5;...
1
vote
0answers
83 views

ESP32 sending data of type uint16_t(or anything except for uint8_t and char*) over bluetooth(classic) serial

I'm making a custom gamepad with an ESP32 and the joystick output is read by an ADC using uint16_t analogRead(uint8_t pin);. Now that I want to send the data and receive and parse it, I ran into a ...
1
vote
0answers
48 views

Parse the data incoming from the buffer of Serial.readBytes()

I want to parse the data of the incoming buffer from the serial read bytes, but I don't really know how to get the data out of the array and save it to different variables. This is my code: void setup(...
1
vote
1answer
51 views

Can Arduino Due be programmed with both USB ports connected?

It seems, due SAM-BA (SAM Boot Assistant) inside ATSAM3X8E being listening to both Native USB and UART USB ports after a Reset for programming, allowing talking with SAM-BA, this time from your PC, ...
1
vote
1answer
82 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
2 3 4 5
40