1 Reply Latest reply on May 3, 2015 7:34 PM by Alen——Chen

    How does Arduino Serial work in Intel?

    schwannden Community Member

      In Arduino Serial example, we can use Serial.print() and Serial.read() to implement a simple echo-reply application in tool/serial monitor

      For clarity, by serial monitor below, I mean The GUI serial monitor we get by clicking tool/serial monitor.

       

      I have few questions:

      1. When I type in serial monitor, and press return (send), what is happening? Is the bytes transmitting to Galileo in order as I type? Or is the message being buffered on my PC (where I run Arduino IDE), and is being sent to Galileo upon pressing return (send)? Or is it tcp like, buffered, and sent in chunks (not necessarily one byte at a time, and not necessarily a message a time).

       

      2. Serial.send() is sending message from which buffer to which buffer? The Arduino reference says its reading from serial port, but what does it mean?

       

      3. Serial.print() is sending message from which buffer to which buffer?

       

      When I was trying to figure out the same questions for C printf or Linux system call read/write, there are lots of well-writtened document. But I was not able to find these detail about Arduino easily, and is hoping if anyone could help, thanks!

        • Re: How does Arduino Serial work in Intel?
          Alen——Chen Community Member

          Hi schwannden,

           

          I think the Serial class is the intellectual property of Arduino software. It's not an open source software .  I don't think it's a easy thing to figure out the workflow without source code.

          If you are interested in the workflow of functions or the operating principle of Arduino software, it's better to consult the Arduino official.

          For the serial port of Arduino IDE ,I think this page can explain it , Arduino - Serial.

           

          At last, I think you post the thread in a wrong place. You should post this question here: Forum: Galileo | Intel Communitiese .  There are more experts can help you to handle your question about Galileo.

           

           

          Regards,

          Alen