Help for C++

Hey all, i have arduino conected with FSR sensor, and send any Pressure via bluetooth. i write code via C++ language to connect the sensor with arduino . but i need to send the information (Pressure ) via bluetooth how can i write code to do this . can any one help me to write it this is the code :

int fsrAnalogPin = 0; // FSR is connected to analog 0
int LEDpin = 13;      // connect Red LED to pin 11 (PWM pin)
int fsrReading;      // the analog reading from the FSR resistor divider
int LEDbrightness;

void setup(void) {
  Serial.begin(9600);   // We'll send debugging information via the Serial monitor
  pinMode(LEDpin, OUTPUT);
}

void loop(void) {
  fsrReading = analogRead(fsrAnalogPin);
  Serial.print("Analog reading = ");
  Serial.println(fsrReading);

  // we'll need to change the range from the analog reading (0-1023) down to the range
  // used by analogWrite (0-255) with map!
  LEDbrightness = map(fsrReading, 0, 1023, 0, 255);
  // LED gets brighter the harder you press
  analogWrite(LEDpin, LEDbrightness);

  delay(100);
}

|500x334

thanks

You would just use the serial class from the library that supports your Bluetooth interface. Any decent library has examples you can look at.

aarg: You would just use the serial class from the library that supports your Bluetooth interface. Any decent library has examples you can look at.

aarg: You would just use the serial class from the library that supports your Bluetooth interface. Any decent library has examples you can look at.

sorry i'm beginner in C++ can you explain more

thanks

I don't see a bluetooth device in your diagram. What is your plan?

aarg: I don't see a bluetooth device in your diagram. What is your plan?

yes not in diagram because this pic from internet i don't know how to draw it . for hardware it's done

i need complete the code if you can help me

There are many bluetooth modules. Which one do you have? Can't you get any information about it online? Download software for it?

aarg:
There are many bluetooth modules. Which one do you have? Can’t you get any information about it online? Download software for it?

my friend the problem not in connection
i need to write code in c++ to send any press on sensor to app via bluetooth

i need to write code in c++ to send any press on sensor to app via bluetooth

We understand that but which bluetooth module are you using ?

UKHeliBob: We understand that but which bluetooth module are you using ?

http://www.ebay.com/itm/HC-05-Wireless-Bluetooth-RF-Transceiver-Module-serial-RS232-TTL-for-arduino-/281641074833?pt=LH_DefaultDomain_0&hash=item41931dc091

HC-05 Wireless Bluetooth RF Transceiver Module serial RS232 TTL for arduino

up