[riot-notifications] [RIOT-OS/RIOT] sys/arduino: Using Arduino libraries (#12180)

Kees Bakker notifications at github.com
Wed Sep 11 21:36:24 CEST 2019


keestux commented on this pull request.



> + * @}
+ */
+
+#include <stdint.h>
+#include <TalkingLED.h>
+
+#include "board.h"
+
+TalkingLED tled;
+
+uint16_t sequence1[] = {500, 500, 500, 500, 0};
+uint16_t Sequence2[] = {250, 250, 250, 250, 0};
+
+int main(void)
+{
+    tled.begin(LED0_PIN);

This must be an Arduino pin number, not a RIOT pin. On my Sodaq One `LED0_PIN` is defined as `GPIO_PIN(PA, 15)`. This evaluates into a 32 bit number. `tled.begin()` wants to have a `uint8_t` pin number. That will be also the case for the other SAM boards.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/12180#pullrequestreview-287025109
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190911/db2856d6/attachment.htm>


More information about the notifications mailing list