aboutsummaryrefslogtreecommitdiff
path: root/libraries/Bridge/Bridge.cpp
diff options
context:
space:
mode:
authorFederico Fissore <f.fissore@arduino.cc>2013-06-20 16:32:12 +0200
committerFederico Fissore <f.fissore@arduino.cc>2013-06-20 16:32:47 +0200
commit4ec08ef6cc8189f49f45966c05d9283a81c4977a (patch)
tree98737da55b517f70630270055084f43a48d8a4f8 /libraries/Bridge/Bridge.cpp
parented672deb7447e8c229fa5bfef54189dceb0841a8 (diff)
reviewed bridge example
added BridgeClass::writeMessage(const String& str)
Diffstat (limited to 'libraries/Bridge/Bridge.cpp')
-rw-r--r--libraries/Bridge/Bridge.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/libraries/Bridge/Bridge.cpp b/libraries/Bridge/Bridge.cpp
index 5802156..2485852 100644
--- a/libraries/Bridge/Bridge.cpp
+++ b/libraries/Bridge/Bridge.cpp
@@ -68,6 +68,10 @@ void BridgeClass::writeMessage(const uint8_t *buff, unsigned int size) {
transfer(cmd, 1, buff, size, NULL, 0);
}
+void BridgeClass::writeMessage(const String& str) {
+ writeMessage((uint8_t*) str.c_str(), str.length());
+}
+
unsigned int BridgeClass::messageAvailable() {
uint8_t tmp[] = {'n'};
uint8_t res[2];