summaryrefslogtreecommitdiff
path: root/irsndconfig.h
diff options
context:
space:
mode:
authorLeo C2017-04-30 12:43:56 +0200
committerLeo C2017-04-30 12:43:56 +0200
commit54cbcce61b31454cc76ad2a75d4d5e479d896345 (patch)
tree3fa240748ce2f8b0abfbda17da867c0a45f1a66b /irsndconfig.h
parenta8915151dc5ddd5342d4b8db48a563abf4369891 (diff)
downloadirmp-54cbcce61b31454cc76ad2a75d4d5e479d896345.zip
libopencm3 for IRSND
Diffstat (limited to 'irsndconfig.h')
-rw-r--r--irsndconfig.h25
1 files changed, 18 insertions, 7 deletions
diff --git a/irsndconfig.h b/irsndconfig.h
index 8ed36bf..4f58bda 100644
--- a/irsndconfig.h
+++ b/irsndconfig.h
@@ -152,19 +152,22 @@
# define IRSND_TIMER_CHANNEL_NUMBER 1 // only channel 1 can be used at the moment, others won't work
/*---------------------------------------------------------------------------------------------------------------------------------------------------
- * Teensy 3.x with teensyduino gcc compiler
+ * ARM STM32 with libopencm3 section:
*---------------------------------------------------------------------------------------------------------------------------------------------------
*/
-#elif defined (TEENSY_ARM_CORTEX_M4)
-# define IRSND_PIN 5 // choose an arduino pin with PWM function!
+#elif defined (LIBOPENCM3) // use B6 as IR output on STM32 whith libopencm3
+# define IRSND_PORT_LETTER B
+# define IRSND_BIT_NUMBER 9
+# define IRSND_TIMER_NUMBER 4
+# define IRSND_TIMER_CHANNEL_NUMBER 4
+# define F_CPU // KLUDGE: make irsnd.c happy (TODO:)
/*---------------------------------------------------------------------------------------------------------------------------------------------------
- * Other target systems
+ * Teensy 3.x with teensyduino gcc compiler
*---------------------------------------------------------------------------------------------------------------------------------------------------
*/
-#elif !defined (UNIX_OR_WINDOWS)
-# error target system not defined.
-#endif
+#elif defined (TEENSY_ARM_CORTEX_M4)
+# define IRSND_PIN 5 // choose an arduino pin with PWM function!
/*---------------------------------------------------------------------------------------------------------------------------------------------------
* ESP8266 (Arduino, see IRSEND.ino)
@@ -174,6 +177,14 @@
# define IRSND_PIN 0 // choose an arduino pin with PWM function!
/*---------------------------------------------------------------------------------------------------------------------------------------------------
+ * Other target systems
+ *---------------------------------------------------------------------------------------------------------------------------------------------------
+ */
+#elif !defined (UNIX_OR_WINDOWS)
+# error target system not defined.
+#endif
+
+/*---------------------------------------------------------------------------------------------------------------------------------------------------
* Use Callbacks to indicate output signal or something else
*---------------------------------------------------------------------------------------------------------------------------------------------------
*/