Rename tune_control_s strength to volume to match Nuttx and Linux standard nomenclature for audio (loudness) control.

This commit is contained in:
mcsauder
2019-02-19 10:07:53 +01:00
committed by Beat Küng
parent 57dd1b7b45
commit 31f23c1e76
7 changed files with 47 additions and 46 deletions
+3 -3
View File
@@ -56,7 +56,7 @@ int test_tone(int argc, char *argv[])
if (argc == 1) {
PX4_INFO("Volume silenced for testing predefined tunes 0-20.");
tune_control.strength = 0;
tune_control.volume = tune_control_s::VOLUME_LEVEL_MIN;
for (size_t i = 0; i <= 20; i++) {
tune_control.tune_id = i;
@@ -80,13 +80,13 @@ int test_tone(int argc, char *argv[])
}
if (argc == 3) {
int volume = 40;
int volume = tune_control_s::VOLUME_LEVEL_DEFAULT;
Tunes tunes{};
tunes.set_string(argv[2], volume);
PX4_INFO("Custom tune.");
}
tune_control.strength = 40;
tune_control.volume = tune_control_s::VOLUME_LEVEL_DEFAULT;
result = orb_publish(ORB_ID(tune_control), tune_control_pub, &tune_control);
orb_unadvertise(tune_control_pub);