Skip to content

Commit d720ee5

Browse files
committed
CLang fix
1 parent ba4f9b9 commit d720ee5

1 file changed

Lines changed: 22 additions & 19 deletions

File tree

src/board_controller/ant_neuro/ant_neuro.cpp

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
#include <unistd.h>
1212
#endif
1313

14-
#include <sstream>
1514
#include <iterator>
15+
#include <sstream>
1616

1717
#include <algorithm>
1818
#include <chrono>
@@ -490,8 +490,8 @@ int AntNeuroBoard::config_board (std::string config, std::string &response)
490490
}
491491
else if (config == get_firmware_version)
492492
{
493-
int version = amp->getFirmwareVersion();
494-
response = std::to_string(version);
493+
int version = amp->getFirmwareVersion ();
494+
response = std::to_string (version);
495495
return (int)BrainFlowExitCodes::STATUS_OK;
496496
}
497497
else if (config == get_serial_number)
@@ -501,38 +501,41 @@ int AntNeuroBoard::config_board (std::string config, std::string &response)
501501
}
502502
else if (config == get_sampling_rates_available)
503503
{
504-
std::vector<int> sampling_rates = amp->getSamplingRatesAvailable();
504+
std::vector<int> sampling_rates = amp->getSamplingRatesAvailable ();
505505
std::ostringstream result;
506-
if (!sampling_rates.empty())
506+
if (!sampling_rates.empty ())
507507
{
508-
std::copy(sampling_rates.begin(), sampling_rates.end() - 1, std::ostream_iterator<int>(result, ","));
509-
result << sampling_rates.back(); // no trailing comma
508+
std::copy (sampling_rates.begin (), sampling_rates.end () - 1,
509+
std::ostream_iterator<int> (result, ","));
510+
result << sampling_rates.back (); // no trailing comma
510511
}
511-
response = result.str();
512+
response = result.str ();
512513
return (int)BrainFlowExitCodes::STATUS_OK;
513514
}
514515
else if (config == get_reference_ranges_available)
515516
{
516-
std::vector<double> reference_ranges = amp->getReferenceRangesAvailable();
517+
std::vector<double> reference_ranges = amp->getReferenceRangesAvailable ();
517518
std::ostringstream result;
518-
if (!reference_ranges.empty())
519+
if (!reference_ranges.empty ())
519520
{
520-
std::copy(reference_ranges.begin(), reference_ranges.end() - 1, std::ostream_iterator<double>(result, ","));
521-
result << reference_ranges.back(); // no trailing comma
521+
std::copy (reference_ranges.begin (), reference_ranges.end () - 1,
522+
std::ostream_iterator<double> (result, ","));
523+
result << reference_ranges.back (); // no trailing comma
522524
}
523-
response = result.str();
525+
response = result.str ();
524526
return (int)BrainFlowExitCodes::STATUS_OK;
525527
}
526528
else if (config == get_bipolar_ranges_available)
527529
{
528-
std::vector<double> bipolar_ranges = amp->getBipolarRangesAvailable();
530+
std::vector<double> bipolar_ranges = amp->getBipolarRangesAvailable ();
529531
std::ostringstream result;
530-
if (!bipolar_ranges.empty())
532+
if (!bipolar_ranges.empty ())
531533
{
532-
std::copy(bipolar_ranges.begin(), bipolar_ranges.end() - 1, std::ostream_iterator<double>(result, ","));
533-
result << bipolar_ranges.back(); // no trailing comma
534+
std::copy (bipolar_ranges.begin (), bipolar_ranges.end () - 1,
535+
std::ostream_iterator<double> (result, ","));
536+
result << bipolar_ranges.back (); // no trailing comma
534537
}
535-
response = result.str();
538+
response = result.str ();
536539
return (int)BrainFlowExitCodes::STATUS_OK;
537540
}
538541
else if (config == get_power_state)
@@ -542,7 +545,7 @@ int AntNeuroBoard::config_board (std::string config, std::string &response)
542545
oss << "is_powered: " << power_state.is_powered
543546
<< ", is_charging: " << power_state.is_charging
544547
<< ", charging_level: " << power_state.charging_level;
545-
response = oss.str();
548+
response = oss.str ();
546549

547550
return (int)BrainFlowExitCodes::STATUS_OK;
548551
}

0 commit comments

Comments
 (0)