diff options
author | Diego Barrios Romero <eldruin@gmail.com> | 2018-11-10 10:00:43 +0100 |
---|---|---|
committer | Diego Barrios Romero <eldruin@gmail.com> | 2018-11-10 10:00:43 +0100 |
commit | e7532aef9723a4078874d42ccb9a616628f1b3e6 (patch) | |
tree | 9d4889656c6d01afd7daac32dae074bf435fecf9 | |
parent | 56cce55ab344c83c1bcf9bfbe393b9c9fe5a82e9 (diff) | |
download | ads1x1x-async-e7532aef9723a4078874d42ccb9a616628f1b3e6.tar.gz ads1x1x-async-e7532aef9723a4078874d42ccb9a616628f1b3e6.tar.xz ads1x1x-async-e7532aef9723a4078874d42ccb9a616628f1b3e6.zip |
Make enums comparable
-rw-r--r-- | src/lib.rs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -130,7 +130,7 @@ pub mod mode { } /// Data rate -#[derive(Debug, Clone)] +#[derive(Debug, Clone, PartialEq)] pub enum DataRate { /// 128 SPS Sps128, @@ -149,7 +149,7 @@ pub enum DataRate { } /// Comparator mode (only for ADS1x14, ADS1x15) -#[derive(Debug, Clone)] +#[derive(Debug, Clone, PartialEq)] pub enum ComparatorMode { /// Traditional comparator (default) /// @@ -167,7 +167,7 @@ pub enum ComparatorMode { } /// Comparator polarity (only for ADS1x14, ADS1x15) -#[derive(Debug, Clone)] +#[derive(Debug, Clone, PartialEq)] pub enum ComparatorPolarity { /// Active low (default) ActiveLow, |