diff --git a/samples/bluetooth/iso_broadcast_benchmark/src/receiver.c b/samples/bluetooth/iso_broadcast_benchmark/src/receiver.c index 419c3f5d994..6080f31959e 100644 --- a/samples/bluetooth/iso_broadcast_benchmark/src/receiver.c +++ b/samples/bluetooth/iso_broadcast_benchmark/src/receiver.c @@ -171,7 +171,7 @@ static void print_stats(char *name, struct iso_recv_stats *stats) LOG_INF("%s: Received %u/%u (%.2f%%) - Total packets lost %u", name, stats->iso_recv_count, total_packets, - (float)stats->iso_recv_count * 100 / total_packets, + (double)((float)stats->iso_recv_count * 100 / total_packets), stats->iso_lost_count); } diff --git a/samples/bluetooth/iso_connected_benchmark/src/main.c b/samples/bluetooth/iso_connected_benchmark/src/main.c index 7eb5b05cbb9..99b308ccbb2 100644 --- a/samples/bluetooth/iso_connected_benchmark/src/main.c +++ b/samples/bluetooth/iso_connected_benchmark/src/main.c @@ -170,7 +170,7 @@ static void print_stats(char *name, struct iso_recv_stats *stats) LOG_INF("%s: Received %u/%u (%.2f%%) - Total packets lost %u", name, stats->iso_recv_count, total_packets, - (float)stats->iso_recv_count * 100 / total_packets, + (double)((float)stats->iso_recv_count * 100 / total_packets), stats->iso_lost_count); } diff --git a/samples/bluetooth/unicast_audio_client/src/main.c b/samples/bluetooth/unicast_audio_client/src/main.c index 435debdf056..0254852c895 100644 --- a/samples/bluetooth/unicast_audio_client/src/main.c +++ b/samples/bluetooth/unicast_audio_client/src/main.c @@ -117,7 +117,7 @@ static void fill_audio_buf_sin(int16_t *buf, int length_us, int frequency_hz, in { const int sine_period_samples = sample_rate_hz / frequency_hz; const unsigned int num_samples = (length_us * sample_rate_hz) / USEC_PER_SEC; - const float step = 2 * 3.1415 / sine_period_samples; + const float step = 2 * 3.1415f / sine_period_samples; for (unsigned int i = 0; i < num_samples; i++) { const float sample = sin(i * step);