Need help

Today i finaly got a new Denguino kit .
But im pretty new to the whole thing i only used Dwengo in the past.
And there are 2x SRT Ultrasoon HC SR04.
But i just can't find where to connect my Echo output and my trigger input.
Sorry if i sound like a noob.
But im just here to learn! :slight_smile:

yo man, heres a code I used with 4 of those sensors for an instrument I made a few months ago, just change your baud rate ect ect

/*
CODE HERE
Array of HC-SR04 ultrasonic sensors
*/


//Sonar 1
int echoPin1 =3;
int initPin1 =2;
int distance1 =0;
int ledPin1 =11;

//Sonar 2
int echoPin2 =6;
int initPin2 =7;
int distance2 =0;
int ledPin2 =10;

//Sonar 3
int echoPin3 =8;
int initPin3 =9;
int distance3 =0;
int ledPin3 =5;

//Sonar 4
int echoPin4 =12;
int initPin4 =13;
int distance4 =0;
int ledPin4 =4;

void setup() {
  
  pinMode(initPin1, OUTPUT);
  pinMode(echoPin1, INPUT);
  pinMode(initPin2, OUTPUT);
  pinMode(echoPin2, INPUT);
  pinMode(initPin3, OUTPUT);
  pinMode(echoPin3, INPUT);
  pinMode(initPin4, OUTPUT);
  pinMode(echoPin4, INPUT);
  pinMode(ledPin1, OUTPUT);
  pinMode(ledPin2, OUTPUT);
  pinMode(ledPin3, OUTPUT);
  pinMode(ledPin4, OUTPUT);
  Serial.begin(9600);
  
}

void firstsensor(){ // This function is for first sensor.
  int duration1, distance1;
  digitalWrite (initPin1, HIGH);
  delayMicroseconds (10);
  digitalWrite (initPin1, LOW);
  duration1 = pulseIn (echoPin1, HIGH);
  distance1 = (duration1/2) / 29.1;

      Serial.print(" ");
      Serial.print(distance1);  
      Serial.print(" ");

  if (distance1 < 50) {  // Change the number for long or short distances.
    digitalWrite (ledPin1, HIGH);
  } else {
    digitalWrite (ledPin1, LOW);
  }    
   
}
  
void secondsensor(){ // This function is for second sensor.
    int duration2, distance2;
    digitalWrite (initPin2, HIGH);
    delayMicroseconds (10);
    digitalWrite (initPin2, LOW);
    duration2 = pulseIn (echoPin2, HIGH);
    distance2 = (duration2/2) / 29.1;
  
      Serial.print(" "); 
      Serial.print(distance2);  
      Serial.print(" ");
 
 if (distance2 < 50) {  // Change the number for long or short distances.
    digitalWrite (ledPin2, HIGH);
  } else {
    digitalWrite (ledPin2, LOW);
  }
}     
      
void thirdsensor(){ // This function is for third sensor.
    int duration3, distance3;
    digitalWrite (initPin3, HIGH);
    delayMicroseconds (10);
    digitalWrite (initPin3, LOW);
    duration3 = pulseIn (echoPin3, HIGH);
    distance3 = (duration3/2) / 29.1;

      Serial.print(" ");   
      Serial.print(distance3);  
      Serial.print("");
 
 if (distance3 < 50) {  // Change the number for long or short distances.
    digitalWrite (ledPin3, HIGH);
  } else {
    digitalWrite (ledPin3, LOW);
  }    
}  
      

void fourthsensor(){ // This function is for third sensor.
    int duration4, distance4;
    digitalWrite (initPin4, HIGH);
    delayMicroseconds (10);
    digitalWrite (initPin4, LOW);
    duration4 = pulseIn (echoPin4, HIGH);
    distance4 = (duration4/2) / 29.1;

      Serial.print(" ");   
      Serial.print(distance4);  
      Serial.print("");
   
 if (distance4 < 50) {  // Change the number for long or short distances.
    digitalWrite (ledPin4, HIGH);
  } else {
    digitalWrite (ledPin4, LOW);
  }    
}    

void loop() {
Serial.println("\n");
firstsensor();
secondsensor();
thirdsensor();
fourthsensor();
delay(50);
}