forked from bakercp/ofxSerial
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clean up examples, move OSC examples to ofxOscSerial.
- Loading branch information
Showing
43 changed files
with
134 additions
and
1,059 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Echo | ||
|
||
## Description | ||
|
||
This example sets up a simple echo connection with an Arduino. | ||
|
||
## Instructions | ||
|
||
1. Upload the `Echo.ino` sketch (in this example's `Arduino/` folder) to an Arduino-compatible board. | ||
|
||
2. Check the "listDevices" call in the `ofApp::setup()` function to make sure the correct serial device is connected. | ||
|
||
3. Run this app. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
ofxIO | ||
ofxPoco | ||
ofxSerial | ||
ofxPoco |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Echo | ||
|
||
## Description | ||
|
||
This example shows how to list all connected serial devices. | ||
|
||
## Instructions | ||
|
||
1. Run this app. |
58 changes: 0 additions & 58 deletions
58
examples/intermediate/buffered_serial_device/basic/Arduino/HaikuGenerator/HaikuGenerator.ino
This file was deleted.
Oops, something went wrong.
40 changes: 40 additions & 0 deletions
40
...intermediate/buffered_serial_device/line_buffer/Arduino/HaikuGenerator/HaikuGenerator.ino
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
// | ||
// Copyright (c) 2014 Christopher Baker <https://christopherbaker.net> | ||
// | ||
// SPDX-License-Identifier: MIT | ||
// | ||
|
||
|
||
const int numLines = 3; | ||
|
||
String haiku[] = { | ||
"at the age old pond", | ||
"a frog leaps into water", | ||
"a deep resonance" | ||
}; | ||
|
||
byte currentLine = 0; | ||
byte currentChar = 0; | ||
|
||
void setup() | ||
{ | ||
Serial.begin(115200); | ||
} | ||
|
||
|
||
void loop() | ||
{ | ||
if (currentChar < haiku[currentLine].length()) | ||
{ | ||
Serial.print(haiku[currentLine][currentChar]); | ||
currentChar++; | ||
} | ||
else | ||
{ | ||
Serial.println(""); | ||
currentChar = 0; | ||
currentLine = random(0, numLines); | ||
} | ||
|
||
delay(random(250)); | ||
} |
13 changes: 13 additions & 0 deletions
13
examples/intermediate/buffered_serial_device/line_buffer/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Buffered Serial Device / Basic | ||
|
||
## Description | ||
|
||
This example sets up a simple echo connection with an Arduino using a buffered serial device. | ||
|
||
## Instructions | ||
|
||
1. Upload the `HaikuGenerator.ino` sketch (in this example's `Arduino/` folder) to an Arduino-compatible board. | ||
|
||
2. Check the "listDevices" call in the `ofApp::setup()` function to make sure the correct serial device is connected. | ||
|
||
3. Run this app. |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ | |
// SPDX-License-Identifier: MIT | ||
// | ||
|
||
|
||
#include "ofApp.h" | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ | |
// SPDX-License-Identifier: MIT | ||
// | ||
|
||
|
||
#pragma once | ||
|
||
|
||
|
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Packet Serial Device / Basic | ||
|
||
## Description | ||
|
||
This example sets up a simple connection with an Arduino using a packet serial device. | ||
|
||
## Instructions | ||
|
||
1. Upload the `PacketSerialReverseEcho.ino` sketch to an Arduino board. This sketch requires the Arduino [PacketSerial library](https://github.com/bakercp/PacketSerial) and the example Arduino code can be found in that package. | ||
2. Check the "listDevices" call below to make sure the correct serial device is connected. | ||
3. Run this app. |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
3 changes: 0 additions & 3 deletions
3
examples/intermediate/packet_serial_device/osc/Arduino/README.md
This file was deleted.
Oops, something went wrong.
56 changes: 0 additions & 56 deletions
56
examples/intermediate/packet_serial_device/osc/Arduino/SLIP-OSC/SLIP-OSC.ino
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Please see the [ofxOscSerial](https://github.com/bakercp/ofxOscSerial) addon for communicating via OSC over SLIP. |
This file was deleted.
Oops, something went wrong.
15 changes: 0 additions & 15 deletions
15
examples/intermediate/packet_serial_device/osc/src/main.cpp
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.