I have connected a Maxbotix EZ4 analog sonar to the Orange Cube of my Rover via the ADC connector (ROVER firmware 4.1.2) but it is not taken into account.
When RNGFND1_TYPE = 0, I have 0 which is displayed in “sonarrange” and “sonarvoltage”
When I have filled in all the necessary parameters:
RNGFND1_TYPE = 1
RNGFND1_PIN = 14
RNGFND1_MAX = 700
RNGFND1_SCALING = 2.04
There are numbers that appear in “sonarrange” and “sonarvoltage”, regardless of whether the sonar is connected or not.
I tested the sonar signal (sonar connected to the Cube) with a multimeter and there is indeed a voltage variation when you vary the distance to the sonar.
I had read this post, I tested on pin 15, but it didn’t change anything:
I think I’m missing something, but I haven’t found it.
Do you have an idea ?