FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
processing-docs/content/api_en/LIB_serial/Serial_last.xml at master · processing/processing-docs · GitHub
processing
processing-docs
Repository navigation
Code
Issues
3
(3)
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
processing-docs
/
content
/
api_en
/
LIB_serial
/
Serial_last.xml
Copy path
More file actions
More file actions
Latest commit
History
History
History
executable file
·
43 lines (30 loc) · 760 Bytes
Breadcrumbs
processing-docs
/
content
/
api_en
/
LIB_serial
/
Serial_last.xml
Copy path
File metadata and controls
executable file
·
43 lines (30 loc) · 760 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<?
xml
version
=
"
1.0
"
encoding
=
"
UTF-8
"
standalone
=
"
yes
"
?>
<
root
>
<
name
>last()</
name
>
<
category
>Serial</
category
>
<
subcategory
>Serial</
subcategory
>
<
usage
>Web
&
Application</
usage
>
<
example
>
<
image
></
image
>
<
code
>
<![CDATA[
// Example by Tom Igoe
import processing.serial.*;
Serial myPort; // The serial port:
void setup() {
// List all the available serial ports:
printArray(Serial.list());
// Open the port you are using at the rate you want:
myPort = new Serial(this, Serial.list()[0], 9600);
}
void draw() {
while (myPort.available() > 0) {
int lastIn = myPort.last();
println(lastIn);
}
}
]]>
</
code
>
</
example
>
<
description
>
<![CDATA[
Returns last byte received or -1 if there is none available.
]]>
</
description
>
</
root
>
Back
|
FazBrowse Home
|
New Git URL