How to chose softserial library use on Arduino project?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP












1















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 connect other nano to receive and write, I searched about serial port of nano that only have one hardware serial port, so after I found the many softserial library such as pre-bulite softserial and altsoftserial NeoSWSerial and NeoHWSerial and NeoICSerial.
Because library too libraries i don't know which one can help complete my project.










share|improve this question
























  • what's wrong with the arduino softwareserial library? in what way does it not work for you?

    – Jaromanda X
    Mar 1 at 9:41











  • Is using UART a hard requirement? If not, consider using an I2C connection which uses a single connection and addresses to communicate with many devices.

    – Nefrin
    Mar 1 at 16:18















1















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 connect other nano to receive and write, I searched about serial port of nano that only have one hardware serial port, so after I found the many softserial library such as pre-bulite softserial and altsoftserial NeoSWSerial and NeoHWSerial and NeoICSerial.
Because library too libraries i don't know which one can help complete my project.










share|improve this question
























  • what's wrong with the arduino softwareserial library? in what way does it not work for you?

    – Jaromanda X
    Mar 1 at 9:41











  • Is using UART a hard requirement? If not, consider using an I2C connection which uses a single connection and addresses to communicate with many devices.

    – Nefrin
    Mar 1 at 16:18













1












1








1


1






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 connect other nano to receive and write, I searched about serial port of nano that only have one hardware serial port, so after I found the many softserial library such as pre-bulite softserial and altsoftserial NeoSWSerial and NeoHWSerial and NeoICSerial.
Because library too libraries i don't know which one can help complete my project.










share|improve this question
















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 connect other nano to receive and write, I searched about serial port of nano that only have one hardware serial port, so after I found the many softserial library such as pre-bulite softserial and altsoftserial NeoSWSerial and NeoHWSerial and NeoICSerial.
Because library too libraries i don't know which one can help complete my project.







arduino-nano softwareserial uart






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 1 at 13:47









Michel Keijzers

6,88951939




6,88951939










asked Mar 1 at 9:21









HaseoHaseo

62




62












  • what's wrong with the arduino softwareserial library? in what way does it not work for you?

    – Jaromanda X
    Mar 1 at 9:41











  • Is using UART a hard requirement? If not, consider using an I2C connection which uses a single connection and addresses to communicate with many devices.

    – Nefrin
    Mar 1 at 16:18

















  • what's wrong with the arduino softwareserial library? in what way does it not work for you?

    – Jaromanda X
    Mar 1 at 9:41











  • Is using UART a hard requirement? If not, consider using an I2C connection which uses a single connection and addresses to communicate with many devices.

    – Nefrin
    Mar 1 at 16:18
















what's wrong with the arduino softwareserial library? in what way does it not work for you?

– Jaromanda X
Mar 1 at 9:41





what's wrong with the arduino softwareserial library? in what way does it not work for you?

– Jaromanda X
Mar 1 at 9:41













Is using UART a hard requirement? If not, consider using an I2C connection which uses a single connection and addresses to communicate with many devices.

– Nefrin
Mar 1 at 16:18





Is using UART a hard requirement? If not, consider using an I2C connection which uses a single connection and addresses to communicate with many devices.

– Nefrin
Mar 1 at 16:18










1 Answer
1






active

oldest

votes


















5














I think your problem is that you need 4 serial ports.



With software serial that's just not going to happen:



  • SoftwareSerial can only receive on one serial port at any given time.

  • AltSoftSerial is limited to specific pins, and only one instance because there is only one set of pins

  • NeoSWSerial is kind of between the two. More efficient than SoftwareSerial, but still (as far as I can tell) limited to one instance (it uses a timer interrupt to drive the communication, so can use any pins)

If you need communication between lots of devices over serial then you will either need devices with more hardware serial ports (Arduino Mega, for example), or implement a multi-drop bus system (like RS-485) which only needs one serial port to communicate with many devices. Extra external hardware is required though.






share|improve this answer























  • Good answer. Another hardware option is a SPI to UART expander.

    – caligari
    Mar 1 at 12:07











Your Answer






StackExchange.ifUsing("editor", function ()
return StackExchange.using("schematics", function ()
StackExchange.schematics.init();
);
, "cicuitlab");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "540"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2farduino.stackexchange.com%2fquestions%2f62091%2fhow-to-chose-softserial-library-use-on-arduino-project%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









5














I think your problem is that you need 4 serial ports.



With software serial that's just not going to happen:



  • SoftwareSerial can only receive on one serial port at any given time.

  • AltSoftSerial is limited to specific pins, and only one instance because there is only one set of pins

  • NeoSWSerial is kind of between the two. More efficient than SoftwareSerial, but still (as far as I can tell) limited to one instance (it uses a timer interrupt to drive the communication, so can use any pins)

If you need communication between lots of devices over serial then you will either need devices with more hardware serial ports (Arduino Mega, for example), or implement a multi-drop bus system (like RS-485) which only needs one serial port to communicate with many devices. Extra external hardware is required though.






share|improve this answer























  • Good answer. Another hardware option is a SPI to UART expander.

    – caligari
    Mar 1 at 12:07















5














I think your problem is that you need 4 serial ports.



With software serial that's just not going to happen:



  • SoftwareSerial can only receive on one serial port at any given time.

  • AltSoftSerial is limited to specific pins, and only one instance because there is only one set of pins

  • NeoSWSerial is kind of between the two. More efficient than SoftwareSerial, but still (as far as I can tell) limited to one instance (it uses a timer interrupt to drive the communication, so can use any pins)

If you need communication between lots of devices over serial then you will either need devices with more hardware serial ports (Arduino Mega, for example), or implement a multi-drop bus system (like RS-485) which only needs one serial port to communicate with many devices. Extra external hardware is required though.






share|improve this answer























  • Good answer. Another hardware option is a SPI to UART expander.

    – caligari
    Mar 1 at 12:07













5












5








5







I think your problem is that you need 4 serial ports.



With software serial that's just not going to happen:



  • SoftwareSerial can only receive on one serial port at any given time.

  • AltSoftSerial is limited to specific pins, and only one instance because there is only one set of pins

  • NeoSWSerial is kind of between the two. More efficient than SoftwareSerial, but still (as far as I can tell) limited to one instance (it uses a timer interrupt to drive the communication, so can use any pins)

If you need communication between lots of devices over serial then you will either need devices with more hardware serial ports (Arduino Mega, for example), or implement a multi-drop bus system (like RS-485) which only needs one serial port to communicate with many devices. Extra external hardware is required though.






share|improve this answer













I think your problem is that you need 4 serial ports.



With software serial that's just not going to happen:



  • SoftwareSerial can only receive on one serial port at any given time.

  • AltSoftSerial is limited to specific pins, and only one instance because there is only one set of pins

  • NeoSWSerial is kind of between the two. More efficient than SoftwareSerial, but still (as far as I can tell) limited to one instance (it uses a timer interrupt to drive the communication, so can use any pins)

If you need communication between lots of devices over serial then you will either need devices with more hardware serial ports (Arduino Mega, for example), or implement a multi-drop bus system (like RS-485) which only needs one serial port to communicate with many devices. Extra external hardware is required though.







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 1 at 10:04









MajenkoMajenko

69k43277




69k43277












  • Good answer. Another hardware option is a SPI to UART expander.

    – caligari
    Mar 1 at 12:07

















  • Good answer. Another hardware option is a SPI to UART expander.

    – caligari
    Mar 1 at 12:07
















Good answer. Another hardware option is a SPI to UART expander.

– caligari
Mar 1 at 12:07





Good answer. Another hardware option is a SPI to UART expander.

– caligari
Mar 1 at 12:07

















draft saved

draft discarded
















































Thanks for contributing an answer to Arduino Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2farduino.stackexchange.com%2fquestions%2f62091%2fhow-to-chose-softserial-library-use-on-arduino-project%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown






Popular posts from this blog

How to check contact read email or not when send email to Individual?

Displaying single band from multi-band raster using QGIS

How many registers does an x86_64 CPU actually have?