Merge pull request #59 from petejohanson/sensors/en11-encoder-sensor

Initial low level EC11 sensor driver
This commit is contained in:
Pete Johanson
2020-07-21 14:38:32 -04:00
committed by GitHub
9 changed files with 484 additions and 0 deletions

View File

@@ -58,6 +58,24 @@ RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9)
};
left_encoder: encoder_left {
compatible = "alps,ec11";
label = "LEFT_ENCODER";
a-gpios = <&pro_micro_d 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
resolution = <4>;
status = "disabled";
};
right_encoder: encoder_right {
compatible = "alps,ec11";
label = "RIGHT_ENCODER";
a-gpios = <&pro_micro_d 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro_d 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
resolution = <4>;
status = "disabled";
};
// TODO: Encoder node(s)
// TODO: OLED node
// TODO: RGB node(s)

View File

@@ -19,3 +19,6 @@
;
};
&left_encoder {
status = "okay";
};

View File

@@ -23,3 +23,7 @@
;
};
&right_encoder {
status = "okay";
};