2014-12-24 16:01:59 +01:00
|
|
|
mxboard
|
|
|
|
=======
|
|
|
|
|
|
|
|
Cherry MX breakout board for Arduino, RaspberryPi and other boards.
|
2014-12-24 16:35:28 +01:00
|
|
|
|
|
|
|
![front](/images/v01_front.png)
|
|
|
|
![back](/images/v01_back.png)
|
|
|
|
|
|
|
|
Order here: https://oshpark.com/shared_projects/PogDjaIS
|
2014-12-24 16:42:04 +01:00
|
|
|
|
2014-12-24 16:42:47 +01:00
|
|
|
|
|
|
|
Arduino Sample
|
|
|
|
==============
|
|
|
|
|
2014-12-24 16:42:04 +01:00
|
|
|
```arduino
|
|
|
|
const int buttonPin = 10;
|
|
|
|
const int ledPin = 11;
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
pinMode(buttonPin, INPUT);
|
|
|
|
pinMode(ledPin, OUTPUT);
|
|
|
|
}
|
|
|
|
|
|
|
|
void loop() {
|
|
|
|
// The switches are equiped with pull-down resistors. So if the
|
|
|
|
// button is pressed, you read a HIGH, if the button is released
|
|
|
|
// you read a LOW.
|
|
|
|
digitalWrite(ledPin, digitalRead(buttonPin));
|
|
|
|
}
|
|
|
|
```
|