Questions tagged [softwareserial]

A library for emulating UART functionality in software on any available digital IO pins. Use this tag for questions regarding SoftwareSerial.

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

How to write a library that support both HW and SW Serial communication and allow user to chose which one to use?

I'm working on a library for Arduino/ESP8266/Teensy that use serial to send AT commands. I want to make it as customizable as possible, so I avoided to hardcode the serial and I ask for a reference in ...
1
vote
3answers
106 views

SoftwareSerial runs out of “text” space on ATtiny

I have an ATtiny and am trying to send a very large byte array stored in a separate .h file over SoftwareSerial: for (int i=0; i<numElements; i++) { softSerial.println(myList[i]); } I imagine ...
1
vote
1answer
221 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 '...
1
vote
1answer
272 views

How to chose softserial library use on Arduino project?

I want to do a project that has multiple Arduino communication through UART, that project project one of limit is using Arduino Nano (small and cheap). I need to set 4 serial port instance on Nano to ...
1
vote
1answer
862 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 ...
1
vote
2answers
182 views

How can I reduce the redundancy of this code, so one function can perform the task of printing on Serial and Softserial?

void Multi_print (String str) { Serial.print(str); mySerial.print(str); } void Multi_println (String str) { Serial.println(str); mySerial.println(str); } void Multi_parse_int (int value) { ...
1
vote
3answers
2k views

Synchronization and Implementing hamming code on Software Serial

I want to learn and use Hamming Code. Would it be wise to alter the Software serial library to do this or just change the data being transmitted in the actual Arduino sketch? Also, for means of ...
1
vote
5answers
8k views

SoftwareSerial with ESP8266

I am communicating with ESP8266 using SoftwareSerial of Arduino UNO. I can successfully send AT commands and get response when communicating through the terminal. But if i programmatically send ...
1
vote
2answers
544 views

Arduino Uno Rx/Tx + Arduino Serial

I was wondering if I can use the Rx and Tx Hardware on the Arduino Uno and also add another Rx/Tx pins using SoftwareSerial at the same time ? cause I need two to communicate with two motor ...
1
vote
3answers
2k views

Interfacing an ATtiny85 with MIDI via Software Serial

In order to finish a synth project that I'm working on I built a MIDI interface. To test it, I drew up some code which (is supposed to) light up an LED when any key is pressed. The light turns off ...
1
vote
2answers
4k views

What do symbols like UCSR0C, UMSEL01, etc. means?

I have a code with a connection to serial port: // Set baud rate UBRR0H = UBRRH_VALUE; UBRR0L = UBRRL_VALUE; // Disable USART rate doubler (arduino bootloader leaves it enabled...) UCSR0A &= ~(1 &...
1
vote
3answers
179 views

Read one value from continuous data stream at a lower frequency

I am working on a university final project and have run into a problem with programming Arduino, after a 3 year hiatus. I have a pressure transducer that is sending pressure data at 10Hz. I have ...
1
vote
3answers
10k views

SIM808 module GSM working fine, GPS not working (No GPS ready message on power on)

I powered on my SIM808 module. It showed me following output: RDY +CFUN: 1 +CPIN: READY Call Ready SMS Ready It supposed to show GPS ready also. I sent AT command and return ok. However ...
1
vote
2answers
194 views

Trying to pass a char to software serial with a button press

Good day everyone, I'm returning to the Arduino world after my a 3 year hiatus following the birth of my son. I'm trying to push a button connected to pin 2 and have that send a 'd' to SoftwareSerial ...
1
vote
2answers
5k views

2 way communication between Arduino with XBee and Computer

I have an Arduino Uno with a Wireless SD Shield and XBee S1 and a PC with another XBee S1 connected to it. What I'm after is for me to be able to send a message from my computer and receive a message ...
1
vote
1answer
1k views

Send array of Infrared codes

I'm having a bit of a problem when sending IR Codes stored in variables. I swear I had this convered up already. I don't actually know the reason why I can't use variables in the first place. I ...
1
vote
1answer
53 views

Reading from EEPROM and combining

I'm trying to read from the EEPROM and combine the information and send it out over SoftwareSerial using write() function but i'm getting the following error error: invalid operands of types 'const ...
1
vote
2answers
248 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
2k views

Alternative Rx/Tx Pins for Arduino Uno and Pro Mini

Do they have specific pins that is best to be use as Rx/Tx pins (aside from D0 and D1)? If so, what makes them special? edit: What pin feature i should look out for when choosing the rx/tx pin? Is ...
1
vote
3answers
3k views

Serial.read() always returns 255

So I'm trying to learn basic Android app dev. My master plan was to make an app using MIT App Inventor that would turn on an LED over Bluetooth using an Arduino. Once I verified that everything worked,...
1
vote
2answers
6k views

Setup arduino uno with ESP8266 ESP-1

Iam trying to set up the arduino uno with the wifi module ESP8266. I use this schematic setup: I have followed this tutorial: Tutorial ESP8266 Thereby I removed the Mega328P Chip like it says above, ...
1
vote
3answers
473 views

Garbled serial from GPS device

I'm using an Arduino Uno. "Regular" serial is plugged into my computer, and I can receive just fine. I'm using AltSoftSerial (tried SoftwareSerial, same results) with RX and TX on pins 8 and 9 to ...
1
vote
1answer
189 views

On UNO, when serial.print to UART pin 11, nothing comes out of pin 11

The problem: Message prints only to the Arduino IDE's Tools > Serial Monitor, not coming out of TX pin 11. Question, please how to get Arduino Uno or Mega to send data out of pin 11? #include <...
1
vote
1answer
111 views

Extra characters remain in Serial

I have spent the whole day trying to deal with this problem connecting Arduinos together using UART (Serial). But the problem is that it always behaves weirdly. For now the problem is that if previous ...
1
vote
2answers
6k views

SoftwareSerial together with AltSoftSerial and HardwareSerial

The title says it all. Angone with experience here on this subject? I want to use all Hardware serial, SoftwareSerial and AltSoftSerial on Arduino Duemilanove with At328. Is it possible?
1
vote
2answers
29 views

Converting each digit in an integer to its respective ASCII characters

For example what would be the process of converting the integer 1023 into ascii characters of 0x31 (1) 0x30 (0) 0x32 (2) 0x33 (3) Not looking for any library functions (I know of Serial.print() and ...
1
vote
1answer
166 views

HLW8032 UART sends random data ( Registers Overflow often)

I designed my own version of smart socket just like the Sonoff with power metering chip HLW8032. And when I read the data in ESP-12F the data doesn't have a fixed format. To troubleshoot the issue, I ...
1
vote
2answers
8k views

SIM800L not registering to network

I am using SIM800L module. I am new to GSM modules. I have searched in many web sites about SIM800L, every where they mentioned baud rate 9600 for SoftwareSerial but it is not working at all in my ...
1
vote
2answers
2k views

Using SoftwareSerial along with FastLED library to control WS2812 LEDs

I am controlling WS2812 LEDs with Arduino nano using FastLED library. I want the LED patterns to change on receiving a command from another Arduino Nano over software serial, I don't have the option ...
1
vote
3answers
2k views

How to change the baud rate of ESP8266 (12E) using an Arduino Uno?

I have with me an Arduino UNO and an ESP8266 (12E) WiFi Module. I need to make a webserver using the two. I read that the default baud rate for ESP8266 is 115200, and that the software serial pins can'...
1
vote
1answer
4k views

Use an Arduino to “intercept” transparently serial communication to Grbl?

I need to have an Arduino "spying" on communications between the PC and another Arduino with GRBL. The goal is to intercept a couple of GCode commands and act on them instead of Grbl. My first step ...
1
vote
3answers
4k views

Problem with Software Serial: no response

I am using an Arduino Uno board with IDE 1.6.7. I have tried to implement a tweaked version of the basic example (SoftwareSerial example) from the Software Serial library. The code is attached. It ...
1
vote
2answers
4k views

Arduino-Pyserial communication on Python 3, Windows machine: Pyserial.write() doesn't seem to do anything

I've recently gotten my hands on an Arduino (or rather a Genuino, but the overall architecture should be the same) UNO. I'm now using that Arduino to test how data is transmitted from a USB to Serial ...
1
vote
2answers
2k views

Using two software serial - two UART

I have ATMega328p chip, and I have HC-06 on pin A5, A4 (RX, TX) and I have another device on pin 10, 9 (RX,TX). I want to be able to send some command on BT via Bluetooth Terminal and pass raw (...
1
vote
2answers
553 views

Using only Rx pin to receive data from HC 05 and attiny85 (Arduino IDE)

I was building a Bluetooth car with attiny85 (Arduino IDE) and HC05 bluetooth module. I need 4 IO pins to control the car. Since attiny have only 5vIO's, I am left with only 1 pin to connect to HC05. ...
1
vote
1answer
234 views

Is it possible to run 2 functions, that communicate with 2 different serial devices, in parallel using FreeRtos library?

This might seem like a very broad question but that's what i want it to be for multiple ways of implementation. I've an Arduino UNO communicating with 2 Serial devices interfaced using SoftwareSerial ...
1
vote
1answer
9k views

Send JSON via POST on SIM900 shield with AT commands

I'm trying to send a JSON POST in SIM900 shield with AT commands. After I call the AT+HTTPACTION=1 command, it returns a 601 error: +HTTPACTION:1,601,0. I saw here that the error was 601 Network ...
1
vote
1answer
3k views

SoftwareSerial.h alternative with AVR (Two Serial/UART ports in atmega328p)

Arduino pins can be used as UART using the SoftwareSerial.h library. Is there any alternative for AVR? I need more than one serial port on a ATmega328P, but i don't use Arduino. SoftwareSerial.h is ...
1
vote
2answers
832 views

SoftwareSerial problems

Hi we are using an Arduino Micro and working with a Bluetooth device and a Rfid Scanner from Sparkfun(ID-20 LA). For that we implemented 2 SoftwareSerial objects and the Serial port for the Serial ...
1
vote
2answers
13k views

Arduino SoftwareSerial library basic example doesn't work

I come to you again because I have a problem with the Arduino SoftwareSerial library. With a basic example I fail to see results in the serial monitor. The basic code example: #include <...
1
vote
1answer
1k views

Wired serial connection between two Arduinos - do they need a common Ground (GND)?

I would like to connect two Arduinos by a serial connection. Is it sufficient to connect TX1<-->RX2 and RX1<-->TX2 or do I also need to connect the GND of the two Arduinos?
1
vote
1answer
1k views

SoftwareSerial error

I have arduino , upon arduino I have Arduino GSM shield (Tx-2, Rx-3, Modem reset-7) and upon it, I have the Adafruit GPS Logger shield. I am trying to send sms of Latitude from the GPS Logger shield ...
1
vote
1answer
67 views

Using software Serial for Adafruit Thermal library and more general cpp question

I'm working on a proof of concept for using the Adafruit_Thermal printer library with an ATTiny85. The ATTiny85 does not come with hardware serial capability, so I started looking into using ...
1
vote
1answer
314 views

Using SoftwareSerial.h in .cpp file

I am trying to modularize the different components in my arduino build by using objects, but am having trouble with the one controlling a wireless transceiver, which uses SoftwareSerial.h I believe I ...
1
vote
1answer
68 views

Is it possible to have two serialEvent() in Arduino code?

I am developing a code on Arduino and need to implement a condition that if data is available form "serial2" then only get the input for "Serial" terminal of Arduino. I have tried with below code, ...
1
vote
1answer
65 views

Measure Sofware Serial write() time

As you probably know, SoftwareSerial uses Interrupts to do some of the timing stuff of the Serial communication. What I am trying to accomplish is to measure the time that it takes SoftwareSerial....
1
vote
1answer
53 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 ...
1
vote
1answer
468 views

ESP8266 Software serial to ATmega 328 is not properly working

Thanks in advance.. We are having esp8266-12E chip and Atmega328 connected as follows, ESP 12 pin as Tx,13 pin as Rx && Atmega328 13pin as Rx, 12pin as Tx. Everything works fine, but while ...
1
vote
1answer
2k views

Sending PUBX commands to GPS Board (Ublox NEO-6M) through SoftwareSerial

I am having trouble parsing NMEA sentences coming from a GY-NEO6MV2 board (https://www.cytron.io/p-gps-neo6mv2), using the TinyGPS (https://github.com/mikalhart/TinyGPS) library. The GPS board itself ...
1
vote
3answers
70 views

Bluetooth Modules not communicating correctly

I plug in BT rx to digital 11, BT tx to digital 10 and then 5v and ground from the HC-05 to the arduino. I then upload this code to the HC-05 that is set as a master. #include <SoftwareSerial.h>...