forked from Elron_dev/elbear_arduino_bsp
добавлена поддержка еще одного прерывания и еще двух выводов для ШИМ для
платы Elbear. добавлены флаги компиляции, необходимые для работы в ArduinoIDE v1.8.19
This commit is contained in:
1 parent
f06650400b
commit
a32d749c60
19 files changed
+172
-116
No files matched your search
@@ -4,8 +4,8 @@
|
||||
#include "Arduino.h"
|
||||
|
||||
// --------------------- init --------------------- //
|
||||
// called before setup()
|
||||
void pre_init(void)
|
||||
// called from crt0.S before constructors initialization
|
||||
extern "C" void SystemInit(void)
|
||||
{
|
||||
// set irq vector to ram region
|
||||
write_csr(mtvec, 0x02000000);
|
||||
@@ -25,8 +25,8 @@ void pre_init(void)
|
||||
// called after setup()
|
||||
void post_init(void)
|
||||
{
|
||||
// enable global interrupts by default
|
||||
interrupts();
|
||||
if(isInterruptsEnabled()) // if user has called noInterrupts() in setup(), this value is false
|
||||
interrupts(); // enable global interrupts
|
||||
}
|
||||
|
||||
// --------------------- other --------------------- //
|
||||
|
||||
Reference in new issue
Block a user