You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 3, 2024. It is now read-only.
Hello I am a beginner in sifive board.I am using freedom-metal for ultrasonic ranging.
The following is its arduino code.How to achieve its function with freedom-metal ?
Function:
1.delayMicroseconds(2) //delay 2 us
2.pulseIn(7, HIGH) //Measuring pulse width (us)
float checkdistance_6_7() {
digitalWrite(6, LOW);
delayMicroseconds(2);
digitalWrite(6, HIGH);
delayMicroseconds(10);
digitalWrite(6, LOW);
float distance = pulseIn(7, HIGH) / 58.00;
delay(10);
return distance;
}
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hello I am a beginner in sifive board.I am using freedom-metal for ultrasonic ranging.
The following is its arduino code.How to achieve its function with freedom-metal ?
Function:
1.delayMicroseconds(2) //delay 2 us
2.pulseIn(7, HIGH) //Measuring pulse width (us)
float checkdistance_6_7() {
digitalWrite(6, LOW);
delayMicroseconds(2);
digitalWrite(6, HIGH);
delayMicroseconds(10);
digitalWrite(6, LOW);
float distance = pulseIn(7, HIGH) / 58.00;
delay(10);
return distance;
}
The text was updated successfully, but these errors were encountered: