CONNECTING ULTRASONIC SENSOR AND BLUETOOTH MODULE HC05

Im working on a wireless intruder alert project

I used this code for my ultrasonic sensor

/*
 HC-SR04 Ping distance sensor]
 VCC to arduino 5v GND to arduino GND
 Echo to Arduino pin 13 Trig to Arduino pin 12
 Red POS to Arduino pin 11
 Green POS to Arduino pin 10
 560 ohm resistor to both LED NEG and GRD power rail
 More info at: http://goo.gl/kJ8Gl
 Original code improvements to the Ping sketch sourced from Trollmaker.com
 Some code and wiring inspired by http://en.wikiversity.org/wiki/User:Dstaub/robotcar
 */

#define trigPin 13
#define echoPin 12
#define led 11
#define led2 10

void setup() {
  Serial.begin (9600);
  pinMode(trigPin, OUTPUT);
  pinMode(echoPin, INPUT);
  pinMode(led, OUTPUT);
  pinMode(led2, OUTPUT);
}

void loop() {
  long duration, distance;
  digitalWrite(trigPin, LOW);  // Added this line
  delayMicroseconds(2); // Added this line
  digitalWrite(trigPin, HIGH);
//  delayMicroseconds(1000); - Removed this line
  delayMicroseconds(10); // Added this line
  digitalWrite(trigPin, LOW);
  duration = pulseIn(echoPin, HIGH);
  distance = (duration/2) / 29.1;
  if (distance < 4) {  // This is where the LED On/Off happens
    digitalWrite(led,HIGH); // When the Red condition is met, the Green LED should turn off
  digitalWrite(led2,LOW);
}
  else {
    digitalWrite(led,LOW);
    digitalWrite(led2,HIGH);
  }
  if (distance >= 200 || distance <= 0){
    Serial.println("Out of range");
  }
  else {
    Serial.print(distance);
    Serial.println(" cm");
  }
  delay(500);
}

I want to connect my ultrasonic sensor to my bluetooth module.

can someone help me?

I want to connect my ultrasonic sensor to my bluetooth module.

What makes you think that that is even possible? Especially without knowing which bluetooth module you are talking about?

You could connect both to the Arduino. But, what are you going to send the data to?

im using bluetooth hc 05 with the arduino nano and i connect the ultrasonic sensor there. that is my transmitter.

i want to send "1" (high) to the receiver if the ultrasonic sensor detects anything.
my receiver also has bluetooth hc 05 with arduino mega and a buzzer

all that's lacking is the code. heeeelp

and i connect the ultrasonic sensor there.

I can't see where you are pointing.

that is my transmitter.

I can't see where you are pointing.

i want to send "1" (high) to the receiver if the ultrasonic sensor detects anything.

8 miles away counts as anything?

all that's lacking is the code.

That's where you come in.

heeeelp

That word does not appear in my unabridged dictionary. Sounds like a cat got stepped on.

Assuming the code you show actually works, it appears that all you really need is the establishment of connection between two HC-05 modules.

This might be useful