From c5e9cfd84f4905394492566152587c434b74f540 Mon Sep 17 00:00:00 2001 From: Cristian Maglie <c.maglie@arduino.cc> Date: Sat, 13 Jun 2015 16:16:50 +0200 Subject: [PATCH] Added initVariant() hook as in the other Arduino cores --- cores/arduino/main.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/cores/arduino/main.cpp b/cores/arduino/main.cpp index 55eef9e9..8af01b57 100644 --- a/cores/arduino/main.cpp +++ b/cores/arduino/main.cpp @@ -1,5 +1,5 @@ /* - Copyright (c) 2014 Arduino. All right reserved. + Copyright (c) 2015 Arduino LLC. All right reserved. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -19,6 +19,11 @@ #define ARDUINO_MAIN #include "Arduino.h" +// Weak empty variant initialization function. +// May be redefined by variant files. +void initVariant() __attribute__((weak)); +void initVariant() { } + /* * \brief Main entry point of Arduino application */ @@ -26,6 +31,8 @@ int main( void ) { init(); + initVariant(); + delay(1); #if defined(USBCON) USBDevice.init(); -- GitLab