-
Notifications
You must be signed in to change notification settings - Fork 2
Victor Carreño edited this page Jan 27, 2015
·
2 revisions
This section contains 3 sliders to send data between 0 and 255. Every slider sends data when its value has changed. Every slider has its own Arduino method.
Functions
int getRedValue()
int getGreenValue()
int getBlueValue()
Syntax
myiShield.getRedValue()
myiShield.getGreenValue()
myiShield.getBlueValue()
Returns
int value between 0 and 255.
Parameters
None
Example
#include <boards.h>
#include <SPI.h>
#include <RBL_nRF8001.h>
#include "iShield.h"
iShield myiShield;
void setup()
{
// Init. and start BLE library.
ble_begin();
Serial.begin(9600);
}
void loop()
{
myiShield.getInbox();
Serial.print("Red Value:");
Serial.println(myiShield.getRedValue());
Serial.print("Green Value:");
Serial.println(myiShield.getGreenValue());
Serial.print("Blue Value:");
Serial.println(myiShield.getBlueValue());
}