Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Serial.readbytesuntil()

Status
Not open for further replies.

Bhuvanesh123

Advanced Member level 4
Full Member level 1
Joined
Aug 29, 2013
Messages
113
Helped
0
Reputation
0
Reaction score
0
Trophy points
16
Location
Singrauli, India, India
Visit site
Activity points
814
Code:
void setup()
{
  Serial.begin(9600);
}
void loop()
{char a[10];

  if(Serial.available())
  {
    byte b=Serial.readBytesUntil(b,a,10  );
    Serial.println(b);
  }
}
this is an arduino code

here terminator string is b
input:adb
actuall output:3

but expected out put is 2.how could it include terminator character as it made to terminate..help me
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top