println() question

Hi everyone I have a question about the println() command. I'm trying to to send data from one pc to another via two connected Arduino Megas. I know the data transfer works properly but this is the issue. I want to send a word from one pc to another for debugging purposes so "serial.println("worked") is sent from one pc but ascii is displayed on the second pc. How can I display "worked" on the second pc's serial monitor.

Thanks in advance!! Great forum, Learning alot!

How can I display "worked" on the second pc's serial monitor.

With the proper code. We can't see your code, but, since you are complaining about it, it must be wrong.

serial.println("worked") is sent from one pc but ascii is displayed on the second pc.

Isn't that what you want to happen?

Here's the code on the 1st pc:

int id1=0;
int id2=0;
int rsv=0;
int act[6];
int cr=1;
boolean test1=false;
boolean test2=false;
boolean test3=false;

void setup()
{
Serial.begin(9600);
Serial1.begin(9600);
}

void loop()
{
if (Serial.available()>0)
{
id1=Serial.read();
id2=Serial.read();
rsv=Serial.read();
if (id1=='A')
{
test1=true;
}
if (id2=='B')
{
test2=true;
}
if (rsv=='1')
{
test3=true;
}
//if (id1==true && id2==true && rsv==true)
//{
Serial1.println("worked");
id1, id2, rsv=false;
//}
}
}

Here's the code on the 2nd pc:

int c=1;
void setup() {
Serial.begin(9600);
Serial1.begin(9600);

}

void loop()
{
do
{
if (Serial1.available() > 0)
{
int inByte = Serial1.read();
Serial.println(inByte);
c++;
}
}while(c<100);
delay(600000);

}

if (Serial.available()>0)
  {
    id1=Serial.read();
    id2=Serial.read();
    rsv=Serial.read();

If there is one byte available, it is NOT OK to read three.

      id1, id2, rsv=false;

What do you think this is doing? It isn't, but the only way to fix it is to know what you were thinking. If you were.

    if (id1=='A')
    {
      test1=true;
    }

And, if id1 isn't 'A'?

Simpler would be

test1 = (id1 == 'A');
      int inByte = Serial1.read();
      Serial.println(inByte);

int? Did you SEND ints?