aboutsummaryrefslogtreecommitdiffstats
path: root/wirish
diff options
context:
space:
mode:
authorMarti Bolivar <mbolivar@leaflabs.com>2012-06-05 18:44:58 -0400
committerMarti Bolivar <mbolivar@leaflabs.com>2012-06-07 03:38:30 -0400
commit645f2217d5a318312132655324ddfc3464bf4d0f (patch)
tree4149b38023d109743b228319f2bc954928b36f3d /wirish
parentda4403052cf884c501f27f3b7be0252fa89d5d7a (diff)
downloadlibrambutan-645f2217d5a318312132655324ddfc3464bf4d0f.tar.gz
librambutan-645f2217d5a318312132655324ddfc3464bf4d0f.zip
board_private.h: Add PMAP_ROW() convenience macro.
Signed-off-by: Marti Bolivar <mbolivar@leaflabs.com>
Diffstat (limited to 'wirish')
-rw-r--r--wirish/boards_private.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/wirish/boards_private.h b/wirish/boards_private.h
index 4607913..49867ca 100644
--- a/wirish/boards_private.h
+++ b/wirish/boards_private.h
@@ -40,6 +40,10 @@
#include <libmaple/rcc.h>
#include <libmaple/adc.h>
+/* Makes the PIN_MAP rows more human-readable. */
+#define PMAP_ROW(gpio_dev, gpio_bit, timer_dev, timer_ch, adc_dev, adc_ch) \
+ { gpio_dev, timer_dev, adc_dev, gpio_bit, timer_ch, adc_ch }
+
namespace wirish {
namespace priv {