So i have a Wemos D1 R2 & mini and a arduino nano. The arduino nano bassicly just has a 4 digit screen attached and i want to send a number from the wemos to the nano so that it can display that number.
If you are using a serial connection between the Wemos and the nano then have a look at the examples in Serial Input Basics - simple reliable ways to receive data. There is also a parse example to illustrate how to extract numbers from the received text.
The technique in the 3rd example will be the most reliable. It is what I use for Arduino to Arduino and Arduino to PC communication.
You can send data in a compatible format with code like this (or the equivalent in any other programming language)
simgamer3:
So i have a Wemos D1 R2 & mini and a arduino nano. The arduino nano basically just has a 4 digit screen attached and i want to send a number from the wemos to the nano so that it can display that number.
Why are you using an Arduino Nano?
It makes much more sense and easier to code to have the WeMOS control the display directly.
Robin2:
If you are using a serial connection between the Wemos and the nano then have a look at the examples in Serial Input Basics - simple reliable ways to receive data. There is also a parse example to illustrate how to extract numbers from the received text.
The technique in the 3rd example will be the most reliable. It is what I use for Arduino to Arduino and Arduino to PC communication.
You can send data in a compatible format with code like this (or the equivalent in any other programming language)
Serial.print('<'); // start marker
Serial.print(value1);
Serial.print(','); // comma separator
Serial.print(value2);
Serial.println('>'); // end marker
simgamer3:
i don't have a i2c display i have a basic 4 digit display which needs 12 pins
A 4 digit display requires two data pins.
Stop mucking about. Get the right parts to do the job.
Your suggestion of using an Arduino Nano to drive a display poorly (because you have to code for the multiplexing yourself and argue over how choose resistors to limit the current to within the Arduino's safe limits - a frequent topic here) will prove a lot more tedious than using a display module designed for the purpose.