Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
ArduinoCore-avr
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
ArduinoCore-avr
Commits
366b1b81
Unverified
Commit
366b1b81
authored
Sep 16, 2019
by
Alexander Entinger
Committed by
GitHub
Sep 16, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into patch-1
parents
0c5aa78f
742abcd9
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
40 additions
and
42 deletions
+40
-42
cores/arduino/Arduino.h
cores/arduino/Arduino.h
+9
-9
cores/arduino/Stream.cpp
cores/arduino/Stream.cpp
+0
-1
cores/arduino/USBAPI.h
cores/arduino/USBAPI.h
+2
-0
cores/arduino/USBCore.cpp
cores/arduino/USBCore.cpp
+7
-2
cores/arduino/WInterrupts.c
cores/arduino/WInterrupts.c
+0
-14
cores/arduino/new.cpp
cores/arduino/new.cpp
+5
-0
cores/arduino/new.h
cores/arduino/new.h
+1
-0
libraries/EEPROM/src/EEPROM.h
libraries/EEPROM/src/EEPROM.h
+3
-3
libraries/SoftwareSerial/src/SoftwareSerial.h
libraries/SoftwareSerial/src/SoftwareSerial.h
+0
-9
platform.txt
platform.txt
+2
-2
programmers.txt
programmers.txt
+11
-2
No files found.
cores/arduino/Arduino.h
View file @
366b1b81
...
...
@@ -112,7 +112,7 @@ void yield(void);
#define bitSet(value, bit) ((value) |= (1UL << (bit)))
#define bitClear(value, bit) ((value) &= ~(1UL << (bit)))
#define bitToggle(value, bit) ((value) ^= (1UL << (bit)))
#define bitWrite(value, bit, bitvalue) (
bitvalue
? bitSet(value, bit) : bitClear(value, bit))
#define bitWrite(value, bit, bitvalue) (
(bitvalue)
? bitSet(value, bit) : bitClear(value, bit))
// avr-libc defines _NOP() since 1.6.2
#ifndef _NOP
...
...
@@ -131,16 +131,16 @@ void initVariant(void);
int
atexit
(
void
(
*
func
)())
__attribute__
((
weak
));
void
pinMode
(
uint8_t
,
uint8_t
);
void
digitalWrite
(
uint8_t
,
uint8_t
);
int
digitalRead
(
uint8_t
);
int
analogRead
(
uint8_t
);
void
pinMode
(
uint8_t
pin
,
uint8_t
mode
);
void
digitalWrite
(
uint8_t
pin
,
uint8_t
val
);
int
digitalRead
(
uint8_t
pin
);
int
analogRead
(
uint8_t
pin
);
void
analogReference
(
uint8_t
mode
);
void
analogWrite
(
uint8_t
,
int
);
void
analogWrite
(
uint8_t
pin
,
int
val
);
unsigned
long
millis
(
void
);
unsigned
long
micros
(
void
);
void
delay
(
unsigned
long
);
void
delay
(
unsigned
long
ms
);
void
delayMicroseconds
(
unsigned
int
us
);
unsigned
long
pulseIn
(
uint8_t
pin
,
uint8_t
state
,
unsigned
long
timeout
);
unsigned
long
pulseInLong
(
uint8_t
pin
,
uint8_t
state
,
unsigned
long
timeout
);
...
...
@@ -148,8 +148,8 @@ unsigned long pulseInLong(uint8_t pin, uint8_t state, unsigned long timeout);
void
shiftOut
(
uint8_t
dataPin
,
uint8_t
clockPin
,
uint8_t
bitOrder
,
uint8_t
val
);
uint8_t
shiftIn
(
uint8_t
dataPin
,
uint8_t
clockPin
,
uint8_t
bitOrder
);
void
attachInterrupt
(
uint8_t
,
void
(
*
)(
void
),
int
mode
);
void
detachInterrupt
(
uint8_t
);
void
attachInterrupt
(
uint8_t
interruptNum
,
void
(
*
userFunc
)(
void
),
int
mode
);
void
detachInterrupt
(
uint8_t
interruptNum
);
void
setup
(
void
);
void
loop
(
void
);
...
...
cores/arduino/Stream.cpp
View file @
366b1b81
...
...
@@ -218,7 +218,6 @@ size_t Stream::readBytes(char *buffer, size_t length)
size_t
Stream
::
readBytesUntil
(
char
terminator
,
char
*
buffer
,
size_t
length
)
{
if
(
length
<
1
)
return
0
;
size_t
index
=
0
;
while
(
index
<
length
)
{
int
c
=
timedRead
();
...
...
cores/arduino/USBAPI.h
View file @
366b1b81
...
...
@@ -65,6 +65,8 @@ public:
void
detach
();
// Serial port goes down too...
void
poll
();
bool
wakeupHost
();
// returns false, when wakeup cannot be processed
bool
isSuspended
();
};
extern
USBDevice_
USBDevice
;
...
...
cores/arduino/USBCore.cpp
View file @
366b1b81
...
...
@@ -496,14 +496,13 @@ bool SendConfiguration(int maxlen)
static
bool
SendDescriptor
(
USBSetup
&
setup
)
{
int
ret
;
u8
t
=
setup
.
wValueH
;
if
(
USB_CONFIGURATION_DESCRIPTOR_TYPE
==
t
)
return
SendConfiguration
(
setup
.
wLength
);
InitControl
(
setup
.
wLength
);
#ifdef PLUGGABLE_USB_ENABLED
ret
=
PluggableUSB
().
getDescriptor
(
setup
);
int
ret
=
PluggableUSB
().
getDescriptor
(
setup
);
if
(
ret
!=
0
)
{
return
(
ret
>
0
?
true
:
false
);
}
...
...
@@ -855,4 +854,10 @@ bool USBDevice_::wakeupHost()
return
false
;
}
bool
USBDevice_
::
isSuspended
()
{
return
(
_usbSuspendState
&
(
1
<<
SUSPI
));
}
#endif
/* if defined(USBCON) */
cores/arduino/WInterrupts.c
View file @
366b1b81
...
...
@@ -65,7 +65,6 @@ static volatile voidFuncPtr intFunc[EXTERNAL_NUM_INTERRUPTS] = {
nothing
,
#endif
};
// volatile static voidFuncPtr twiIntFunc;
void
attachInterrupt
(
uint8_t
interruptNum
,
void
(
*
userFunc
)(
void
),
int
mode
)
{
if
(
interruptNum
<
EXTERNAL_NUM_INTERRUPTS
)
{
...
...
@@ -274,11 +273,6 @@ void detachInterrupt(uint8_t interruptNum) {
}
}
/*
void attachInterruptTwi(void (*userFunc)(void) ) {
twiIntFunc = userFunc;
}
*/
#define IMPLEMENT_ISR(vect, interrupt) \
ISR(vect) { \
...
...
@@ -314,11 +308,3 @@ IMPLEMENT_ISR(INT2_vect, EXTERNAL_INT_2)
#endif
#endif
/*
ISR(TWI_vect) {
if(twiIntFunc)
twiIntFunc();
}
*/
cores/arduino/new.cpp
View file @
366b1b81
...
...
@@ -26,6 +26,11 @@ void *operator new[](size_t size) {
return
malloc
(
size
);
}
void
*
operator
new
(
size_t
size
,
void
*
ptr
)
noexcept
{
(
void
)
size
;
return
ptr
;
}
void
operator
delete
(
void
*
ptr
)
{
free
(
ptr
);
}
...
...
cores/arduino/new.h
View file @
366b1b81
...
...
@@ -23,6 +23,7 @@
void
*
operator
new
(
size_t
size
);
void
*
operator
new
[](
size_t
size
);
void
*
operator
new
(
size_t
size
,
void
*
ptr
)
noexcept
;
void
operator
delete
(
void
*
ptr
);
void
operator
delete
[](
void
*
ptr
);
...
...
libraries/EEPROM/src/EEPROM.h
View file @
366b1b81
...
...
@@ -40,7 +40,7 @@ struct EERef{
//Access/read members.
uint8_t
operator
*
()
const
{
return
eeprom_read_byte
(
(
uint8_t
*
)
index
);
}
operator
const
uint8_t
()
const
{
return
**
this
;
}
operator
uint8_t
()
const
{
return
**
this
;
}
//Assignment/write members.
EERef
&
operator
=
(
const
EERef
&
ref
)
{
return
*
this
=
*
ref
;
}
...
...
@@ -89,7 +89,7 @@ struct EEPtr{
EEPtr
(
const
int
index
)
:
index
(
index
)
{}
operator
const
int
()
const
{
return
index
;
}
operator
int
()
const
{
return
index
;
}
EEPtr
&
operator
=
(
int
in
)
{
return
index
=
in
,
*
this
;
}
//Iterator functionality.
...
...
@@ -143,4 +143,4 @@ struct EEPROMClass{
};
static
EEPROMClass
EEPROM
;
#endif
\ No newline at end of file
#endif
libraries/SoftwareSerial/src/SoftwareSerial.h
View file @
366b1b81
...
...
@@ -111,13 +111,4 @@ public:
static
inline
void
handle_interrupt
()
__attribute__
((
__always_inline__
));
};
// Arduino 0012 workaround
#undef int
#undef char
#undef long
#undef byte
#undef float
#undef abs
#undef round
#endif
platform.txt
View file @
366b1b81
...
...
@@ -6,7 +6,7 @@
# https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5-3rd-party-Hardware-specification
name=Arduino AVR Boards
version=1.6.2
2
version=1.6.2
3
# AVR compile variables
# ---------------------
...
...
@@ -25,7 +25,7 @@ compiler.c.elf.flags={compiler.warning_flags} -Os -g -flto -fuse-linker-plugin -
compiler.c.elf.cmd=avr-gcc
compiler.S.flags=-c -g -x assembler-with-cpp -flto -MMD
compiler.cpp.cmd=avr-g++
compiler.cpp.flags=-c -g -Os {compiler.warning_flags} -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto
compiler.cpp.flags=-c -g -Os {compiler.warning_flags} -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -
Wno-error=narrowing -
MMD -flto
compiler.ar.cmd=avr-gcc-ar
compiler.ar.flags=rcs
compiler.objcopy.cmd=avr-objcopy
...
...
programmers.txt
View file @
366b1b81
...
...
@@ -43,13 +43,22 @@ parallel.program.extra_params=-F
arduinoasisp.name=Arduino as ISP
arduinoasisp.communication=serial
arduinoasisp.protocol=
arduino
arduinoasisp.protocol=
stk500v1
arduinoasisp.speed=19200
arduinoasisp.program.protocol=
arduino
arduinoasisp.program.protocol=
stk500v1
arduinoasisp.program.speed=19200
arduinoasisp.program.tool=avrdude
arduinoasisp.program.extra_params=-P{serial.port} -b{program.speed}
arduinoasispatmega32u4.name=Arduino as ISP (ATmega32U4)
arduinoasispatmega32u4.communication=serial
arduinoasispatmega32u4.protocol=arduino
arduinoasispatmega32u4.speed=19200
arduinoasispatmega32u4.program.protocol=arduino
arduinoasispatmega32u4.program.speed=19200
arduinoasispatmega32u4.program.tool=avrdude
arduinoasispatmega32u4.program.extra_params=-P{serial.port} -b{program.speed}
usbGemma.name=Arduino Gemma
usbGemma.protocol=arduinogemma
usbGemma.program.tool=avrdude
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment