Serial Communication

So what does reply #68 mean?
If your responses were less monosyllabic and more forthcoming with useful, relevant information, I'd be more inclined to be more forthcoming with useful replies.

Have you contacted user jeet_jawi?
S/he is in the same part of the world as you, and has astonishingly similar software and problems to you.

Well now it means nothing Reply #68

Reply #68 was one of your replies, so if you don't understand it, we're pretty well buggered, aren't we?

Shall I just delete this thread now, and we can restart on some more sensible footing?

no but my issue remains the same its not transmitting from one board to other its just communicating with the PC and board, and i want to do work on Board to Board communication

my issue remains the same its not transmitting from one board to other

Please show your evidence for this assertion.

Please understand that you have a very large credibility gap in this thread, starting as it did with an assertion that code that could not possibly even compile, did, according to you, compile.

Great camera work.*
How about posting some code?

*Not

#include <LiquidCrystal.h>
#include <NewSoftSerial.h>

LiquidCrystal myLCD = LiquidCrystal(12, 11, 5, 4, 3, 2);


// khali pin 6
void setup() {
  Serial.begin(9600);
  myLCD.begin(16,2);
  //pinMode(13, OUTPUT);  // diagnostic led on Wiring-board
  //pinMode(6, OUTPUT);
  myLCD.print("Arduino");
  delay(1000);
  myLCD.clear();
  myLCD.home();

}
void loop() {
  
  if (Serial.available()>0){
  char ch=Serial.read();
  if(ch=='A')
  {
     myLCD.setCursor(0,1);
    myLCD.print("Cutebuddy6");
  }
  }
  
  
  if (Serial.available())   {
    float z= Serial.read();
    myLCD.setCursor(0,0);
    myLCD.print(z);


  }
}
float z= Serial.read();

You really aren't listening, are you?

Why don't you enter the following into the search box, up there on the right:
"PaulS SOP EOP"
and watch the magic unfold.

i am sorry actually i have not saved the code sorry

I'm sorry that you are sucking in some top technical experts on this forum to try to answer your questions when you are not paying the slightest bit of attention to what they are saying. Five or six pages of wasted time, when you haven't attempted to answer a question on page 1 of this thread. It isn't that you don't understand. The problem is that other people, who need answers to their questions, and who are prepared to listen, might be overlooked.

I pointed out a page or so ago that you can't read a float like that, but you persist in doing so.

Sir its requested that i am paying 100% on you Questions which type of DATA variable should i use

You're not paying us anything.
Money or attention.

Now, the question of reading ASCII representations of numbers comes up here on the forum at least once a week.
There is plenty of code and advice posted on the subject, so go look for it using the search terms I've already posted.
When you've got some actual questions and results, come back and post them.
If they work, we'll be happy for you, because you'll have learned a valuable lesson.
If they don't work, we'll help you fix them, but, as Mike pointed out in the very first reply to this thread WE WON'T WRITE IT FOR YOU.

cutebuddy6:
which type of DATA variable should i use

What does Serial.read() return? For a clue, read the reference page for it.

AWOL:
Why don't you enter the following into the search box, up there on the right:
"PaulS SOP EOP"
and watch the magic unfold.

Have you done this? It's very important that you do, which is why I mentioned Paul's username as a place to start in reply #29 (good grief, that was 60 replies ago, and no further forward).

What does Serial.read() return? For a clue, read the reference page for it.

done

dxw00d:

AWOL:
Why don't you enter the following into the search box, up there on the right:
"PaulS SOP EOP"
and watch the magic unfold.

Have you done this? It's very important that you do, which is why I mentioned Paul's username as a place to start in reply #29 (good grief, that was 60 replies ago, and no further forward).

And this bit?

@OP: It may seem to you that we're being cruel or obtuse, but this really is quite fundamental to programming - if you don't build on solid foundations, your future learning is going to be quite shaky.

Not doing this for yourself is a bit like getting a driving licence by turning up at the test centre with a car and a bribe for the examiner - you'll get the document, but you have no idea what the three pedals are for, and what does the stick thingy between you and the passenger seat do?

here is the receiver but its not compiling

#include <LiquidCrystal.h>
#include <NewSoftSerial.h>
#define SOP '<'
#define EOP '>'
bool started = false;
bool ended = false;
char inData[80];
byte index;
LiquidCrystal myLCD = LiquidCrystal(12, 11, 5, 4, 3, 2);
void setup()
{
  Serial.begin(57600);
  myLCD.begin(16,2);
  myLCD.print("CAR");
  delay(1000);
  myLCD.clear();
  myLCD.home();
  // Other stuff...
}

void loop()
{
  // Read all serial data available, as fast as possible
  while(Serial.available() > 0)
  {
    char inChar = Serial.read();
    if(inChar == SOP)
    {
    
      index = 0;
      inData[index] = '\0';
      started = true;
     
      ended = false;
    }
    else if(inChar == EOP)
    {
      ended = true;
      break;
    }
    else
    {
      if(index < 79)
      {
        inData[index] = inChar;
        index++;
        inData[index] = '\0';
      }
    }
  }

  // We are here either because all pending serial
  // data has been read OR because an end of
  // packet marker arrived. Which is it?
  if(started && ended)
  {
    // The end of packet marker arrived. Process the packet
     myLCD.setCursor(0,0);
      myLCD.print(inChar);

    // Reset for the next packet
    started = false;
    ended = false;
    index = 0;
    inData[index] = '\0';
  }
}

but it gives me error

example_2.cpp: In function 'void loop()':
example_2:58: error: 'inChar' was not declared in this scope

but when i modify it to this it works

#include <LiquidCrystal.h>
#include <NewSoftSerial.h>
#define SOP '<'
#define EOP '>'
bool started = false;
bool ended = false;
char inData[80];
byte index;
LiquidCrystal myLCD = LiquidCrystal(12, 11, 5, 4, 3, 2);
void setup()
{
  Serial.begin(57600);
  myLCD.begin(16,2);
  myLCD.print("CAR");
  delay(1000);
  myLCD.clear();
  myLCD.home();
  // Other stuff...
}

void loop()
{
  // Read all serial data available, as fast as possible
  while(Serial.available() > 0)
  {
    char inChar = Serial.read();
    if(inChar == SOP)
    {
    
      index = 0;
      inData[index] = '\0';
      started = true;
     
      ended = false;
    }
    else if(inChar == EOP)
    {
      ended = true;
      break;
    }
    else
    {
      if(index < 79)
      {
        inData[index] = inChar;
        index++;
        inData[index] = '\0';
      }
    }
  }

  // We are here either because all pending serial
  // data has been read OR because an end of
  // packet marker arrived. Which is it?
  if(started && ended)
  {
    // The end of packet marker arrived. Process the packet
     char inChar;
     myLCD.setCursor(0,0);
      myLCD.print(inChar);

    // Reset for the next packet
    started = false;
    ended = false;
    index = 0;
    inData[index] = '\0';
  }
}

it works

Hurrah!

Can we close this thread now then?

Later edit:

 // The end of packet marker arrived. Process the packet
     char inChar;
     myLCD.setCursor(0,0);
      myLCD.print(inChar);

Uh-oh.