-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added IPAddress.h SPI.h , WCharacter.h, sqrt and delayMicroseconds #18
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, thanks, this is great. I like how you fixed some style issues for consistency, e.g. trailing white spaces and changing boolean
to bool
.
A few requests before I merge this:
- Can you rebase your PR onto the latest commit on the
develop
branch? There should be no conflicts with anything that I committed since you branched. - Can you update the copyright note at the top to add your name, and a few lines to note that you changed a few things?
- An incorrect function signature on
delayMicroseconds()
, I'll point that out in the review.
Arduino.cpp
Outdated
@@ -21,6 +21,10 @@ | |||
// Arduino methods emulated in Unix | |||
// ----------------------------------------------------------------------- | |||
|
|||
void delayMicroseconds(unsigned long us) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be
void delayMicroSeconds(unsigned int us)
to be compatible with other cores.
Arduino.h
Outdated
@@ -81,6 +82,7 @@ | |||
|
|||
extern "C" { | |||
|
|||
void delayMicroseconds(unsigned long us); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto, change unsigned long
to unsigned int
/* | ||
IPAddress.cpp - Base class that provides IPAddress | ||
Copyright (c) 2011 Adrian McEwen. All right reserved. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add something like:
Copied from Arduino AVR core 1.8.3 by Erik Tideman. Removed
unnecessary 'friend' declarations.
* Copyright (c) 2014 by Paul Stoffregen <paul@pjrc.com> (Transaction API) | ||
* Copyright (c) 2014 by Matthijs Kooijman <matthijs@stdin.nl> (SPISettings AVR) | ||
* Copyright (c) 2014 by Andrew J. Kroll <xxxajk@gmail.com> (atomicity fixes) | ||
* SPI Master library for arduino. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add something like:
Copyright (c) 2021 by Erik Tideman (Replaced actual implementations with stubs.)
* Copyright (c) 2014 by Paul Stoffregen <paul@pjrc.com> (Transaction API) | ||
* Copyright (c) 2014 by Matthijs Kooijman <matthijs@stdin.nl> (SPISettings AVR) | ||
* Copyright (c) 2014 by Andrew J. Kroll <xxxajk@gmail.com> (atomicity fixes) | ||
* SPI Master library for arduino. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add something like:
Copyright (c) 2021 by Erik Tideman (Replaced actual implementations with stubs.)
/* | ||
WCharacter.h - Character utility functions for Wiring & Arduino | ||
Copyright (c) 2010 Hernando Barragan. All right reserved. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add something like:
Copyright (c) 2021 by Erik Tideman (Replaced 'boolean' with 'bool')
… including Arduino.h Same behavior as arduino
Hi again, Thanks for great work! |
This looks great, thanks for sending the PR. |
…ementation of transfer() (see #18)
…Arduino features, added in #18
Hi,
I'm using your linux port as a drop in replacement of the official Arduino core when compiling unit tests. I ran across some missing functions and added those that gave me compiler errors. Most is just copy and paste from the official core!