mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-29 17:47:14 +02:00
Add support for RFDuino // Resolve #319
This commit is contained in:
@ -12,6 +12,8 @@ PlatformIO 2.0
|
||||
PlatformIO. ``pip install platformio`` rocks!
|
||||
* Added support for the new Adafruit boards Bluefruit Micro and Feather
|
||||
(`issue #403 <https://github.com/platformio/platformio/issues/403>`_)
|
||||
* Added support for RFDuino
|
||||
(`issue #319 <https://github.com/platformio/platformio/issues/319>`_)
|
||||
* Updated Arduino framework for Atmel AVR development platform to 1.6.7
|
||||
* Documented `firmware uploading for Atmel AVR development platform using
|
||||
Programmers <http://docs.platformio.org/en/latest/platforms/atmelavr.html#upload-using-programmer>`_:
|
||||
|
@ -36,6 +36,9 @@ Platforms
|
||||
* - :ref:`platform_espressif`
|
||||
- Espressif Systems is a privately held fabless semiconductor company. They provide wireless communications and Wi-Fi chips which are widely used in mobile devices and the Internet of Things applications.
|
||||
|
||||
* - :ref:`platform_nordicnrf51`
|
||||
- The Nordic nRF51 Series is a family of highly flexible, multi-protocol, system-on-chip (SoC) devices for ultra-low power wireless applications. nRF51 Series devices support a range of protocol stacks including Bluetooth Smart (previously called Bluetooth low energy), ANT and proprietary 2.4GHz protocols such as Gazell.
|
||||
|
||||
* - :ref:`platform_teensy`
|
||||
- Teensy is a complete USB-based microcontroller development system, in a very small footprint, capable of implementing many types of projects. All programming is done via the USB port. No special programmer is needed, only a standard "Mini-B" USB cable and a PC or Macintosh with a USB port.
|
||||
|
||||
@ -783,6 +786,26 @@ Quirkbot
|
||||
- 32 Kb
|
||||
- 2.5 Kb
|
||||
|
||||
RFduino
|
||||
~~~~~~~
|
||||
|
||||
.. list-table::
|
||||
:header-rows: 1
|
||||
|
||||
* - Type ``board``
|
||||
- Name
|
||||
- Microcontroller
|
||||
- Frequency
|
||||
- Flash
|
||||
- RAM
|
||||
|
||||
* - ``rfduino``
|
||||
- `RFduino <http://www.rfduino.com/product/rfd22102-rfduino-dip/index.html>`_
|
||||
- NRF51822
|
||||
- 16 MHz
|
||||
- 128 Kb
|
||||
- 8 Kb
|
||||
|
||||
RedBearLab
|
||||
~~~~~~~~~~
|
||||
|
||||
|
@ -62,6 +62,9 @@ Packages
|
||||
* - ``framework-arduinomsp430``
|
||||
- `Arduino Wiring-based Framework (MSP430 Core) <http://arduino.cc/en/Reference/HomePage>`_
|
||||
|
||||
* - ``framework-arduinonordicnrf51``
|
||||
- `Arduino Wiring-based Framework (RFDuino Core) <https://github.com/RFduino/RFduino>`_
|
||||
|
||||
* - ``framework-arduinosam``
|
||||
- `Arduino Wiring-based Framework (SAM Core, 1.6) <http://arduino.cc/en/Reference/HomePage>`_
|
||||
|
||||
@ -113,6 +116,9 @@ Packages
|
||||
* - ``tool-mspdebug``
|
||||
- `MSPDebug <http://mspdebug.sourceforge.net/>`_
|
||||
|
||||
* - ``tool-rfdloader``
|
||||
- `rfdloader <https://github.com/RFduino/RFduino>`_
|
||||
|
||||
* - ``tool-scons``
|
||||
- `SCons software construction tool <http://www.scons.org>`_
|
||||
|
||||
|
@ -31,9 +31,15 @@ Packages
|
||||
* - ``framework-mbed``
|
||||
- `mbed Framework <http://mbed.org>`_
|
||||
|
||||
* - ``tool-rfdloader``
|
||||
- `rfdloader <https://github.com/RFduino/RFduino>`_
|
||||
|
||||
* - ``toolchain-gccarmnoneeabi``
|
||||
- `gcc-arm-embedded <https://launchpad.net/gcc-arm-embedded>`_, `GDB <http://www.gnu.org/software/gdb/>`_
|
||||
|
||||
* - ``framework-arduinonordicnrf51``
|
||||
- `Arduino Wiring-based Framework (RFDuino Core) <https://github.com/RFduino/RFduino>`_
|
||||
|
||||
.. warning::
|
||||
**Linux Users:** Don't forget to install "udev" rules file
|
||||
`99-platformio-udev.rules <https://github.com/platformio/platformio/blob/develop/scripts/99-platformio-udev.rules>`_ (an instruction is located in the file).
|
||||
@ -51,6 +57,9 @@ Frameworks
|
||||
* - Name
|
||||
- Description
|
||||
|
||||
* - :ref:`framework_arduino`
|
||||
- Arduino Framework allows writing cross-platform software to control devices attached to a wide range of Arduino boards to create all kinds of creative coding, interactive objects, spaces or physical experiences.
|
||||
|
||||
* - :ref:`framework_mbed`
|
||||
- The mbed framework The mbed SDK has been designed to provide enough hardware abstraction to be intuitive and concise, yet powerful enough to build complex projects. It is built on the low-level ARM CMSIS APIs, allowing you to code down to the metal if needed. In addition to RTOS, USB and Networking libraries, a cookbook of hundreds of reusable peripheral and module libraries have been built on top of the SDK by the mbed Developer Community.
|
||||
|
||||
@ -137,6 +146,26 @@ Nordic
|
||||
- 128 Kb
|
||||
- 16 Kb
|
||||
|
||||
RFduino
|
||||
~~~~~~~
|
||||
|
||||
.. list-table::
|
||||
:header-rows: 1
|
||||
|
||||
* - Type ``board``
|
||||
- Name
|
||||
- Microcontroller
|
||||
- Frequency
|
||||
- Flash
|
||||
- RAM
|
||||
|
||||
* - ``rfduino``
|
||||
- `RFduino <http://www.rfduino.com/product/rfd22102-rfduino-dip/index.html>`_
|
||||
- NRF51822
|
||||
- 16 MHz
|
||||
- 128 Kb
|
||||
- 8 Kb
|
||||
|
||||
RedBearLab
|
||||
~~~~~~~~~~
|
||||
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
import sys
|
||||
|
||||
VERSION = (2, 7, "0.dev0")
|
||||
VERSION = (2, 7, "0.dev1")
|
||||
__version__ = ".".join([str(s) for s in VERSION])
|
||||
|
||||
__title__ = "platformio"
|
||||
|
@ -142,5 +142,25 @@
|
||||
},
|
||||
"url": "https://developer.mbed.org/platforms/Delta-DFCM-NNN40/",
|
||||
"vendor": "Delta"
|
||||
},
|
||||
"rfduino": {
|
||||
"build": {
|
||||
"core": "arduino",
|
||||
"extra_flags": "-D__RFduino__",
|
||||
"f_cpu": "16000000L",
|
||||
"ldscript": "RFduino.ld",
|
||||
"cpu": "cortex-m0",
|
||||
"mcu": "nrf51822",
|
||||
"variant": "rfduino"
|
||||
},
|
||||
"frameworks": ["arduino"],
|
||||
"name": "RFduino",
|
||||
"platform": "nordicnrf51",
|
||||
"upload": {
|
||||
"maximum_ram_size": 8192,
|
||||
"maximum_size": 131072
|
||||
},
|
||||
"url": "http://www.rfduino.com/product/rfd22102-rfduino-dip/index.html",
|
||||
"vendor": "RFduino"
|
||||
}
|
||||
}
|
||||
|
@ -111,12 +111,7 @@ if "BOARD" in env:
|
||||
UPLOAD_SPEED="${BOARD_OPTIONS['upload'].get('speed', None)}")
|
||||
if "ldscript" in env.get("BOARD_OPTIONS", {}).get("build", {}):
|
||||
env.Replace(
|
||||
LDSCRIPT_PATH=(
|
||||
env['BOARD_OPTIONS']['build']['ldscript']
|
||||
if isfile(env['BOARD_OPTIONS']['build']['ldscript'])
|
||||
else join("$PIOHOME_DIR", "packages", "ldscripts",
|
||||
"${BOARD_OPTIONS['build']['ldscript']}")
|
||||
)
|
||||
LDSCRIPT_PATH="${BOARD_OPTIONS['build']['ldscript']}"
|
||||
)
|
||||
|
||||
if env['PLATFORM'] != env.get("BOARD_OPTIONS", {}).get("platform"):
|
||||
|
@ -60,6 +60,34 @@ elif env.get("PLATFORM") == "espressif":
|
||||
LIBS=["smartconfig", "pp", "main", "wpa", "lwip",
|
||||
"net80211", "wps", "crypto", "phy", "hal", "axtls", "gcc", "m"]
|
||||
)
|
||||
elif env.get("PLATFORM") == "nordicnrf51":
|
||||
PLATFORMFW_DIR = join(
|
||||
"$PIOPACKAGES_DIR",
|
||||
"framework-arduinonordicnrf51"
|
||||
)
|
||||
env.Prepend(
|
||||
CPPPATH=[
|
||||
join("$PLATFORMFW_DIR", "system", "CMSIS", "CMSIS", "Include"),
|
||||
join("$PLATFORMFW_DIR", "system", "RFduino"),
|
||||
join("$PLATFORMFW_DIR", "system", "RFduino", "include")
|
||||
],
|
||||
LIBPATH=[
|
||||
join(
|
||||
"$PLATFORMFW_DIR",
|
||||
"variants",
|
||||
"${BOARD_OPTIONS['build']['variant']}"
|
||||
),
|
||||
join(
|
||||
"$PLATFORMFW_DIR",
|
||||
"variants",
|
||||
"${BOARD_OPTIONS['build']['variant']}",
|
||||
"linker_scripts",
|
||||
"gcc"
|
||||
),
|
||||
],
|
||||
LIBS=["RFduino", "RFduinoBLE", "RFduinoGZLL", "RFduinoSystem"]
|
||||
)
|
||||
|
||||
|
||||
env.Replace(PLATFORMFW_DIR=PLATFORMFW_DIR)
|
||||
|
||||
|
@ -25,6 +25,17 @@ env = DefaultEnvironment()
|
||||
|
||||
SConscript(env.subst(join("$PIOBUILDER_DIR", "scripts", "basearm.py")))
|
||||
|
||||
if env.subst("$BOARD") == "rfduino":
|
||||
env.Append(
|
||||
CPPFLAGS=["-fno-builtin"],
|
||||
LINKFLAGS=["--specs=nano.specs"]
|
||||
)
|
||||
env.Replace(
|
||||
UPLOADER=join("$PIOPACKAGES_DIR", "tool-rfdloader", "rfdloader"),
|
||||
UPLOADERFLAGS=["-q", "$UPLOAD_PORT", "$SOURCES"],
|
||||
UPLOADCMD='"$UPLOADER" $UPLOADERFLAGS"'
|
||||
)
|
||||
|
||||
#
|
||||
# Target: Build executable and linkable firmware
|
||||
#
|
||||
@ -51,7 +62,12 @@ AlwaysBuild(target_size)
|
||||
# Target: Upload by default .bin file
|
||||
#
|
||||
|
||||
upload = env.Alias(["upload", "uploadlazy"], target_firm, env.UploadToDisk)
|
||||
if env.subst("$BOARD") == "rfduino":
|
||||
upload = env.Alias(
|
||||
["upload", "uploadlazy"], target_firm,
|
||||
[lambda target, source, env: env.AutodetectUploadPort(), "$UPLOADCMD"])
|
||||
else:
|
||||
upload = env.Alias(["upload", "uploadlazy"], target_firm, env.UploadToDisk)
|
||||
AlwaysBuild(upload)
|
||||
|
||||
#
|
||||
|
@ -47,6 +47,10 @@ PLATFORM_PACKAGES = {
|
||||
("Arduino Wiring-based Framework (ESP8266 Core)",
|
||||
"https://github.com/esp8266/Arduino")
|
||||
],
|
||||
"framework-arduinonordicnrf51": [
|
||||
("Arduino Wiring-based Framework (RFDuino Core)",
|
||||
"https://github.com/RFduino/RFduino")
|
||||
],
|
||||
"framework-energiamsp430": [
|
||||
("Energia Wiring-based Framework (MSP430 Core)",
|
||||
"http://energia.nu/reference/")
|
||||
@ -139,6 +143,9 @@ PLATFORM_PACKAGES = {
|
||||
],
|
||||
"tool-esptool": [
|
||||
("esptool-ck", "https://github.com/igrr/esptool-ck")
|
||||
],
|
||||
"tool-rfdloader": [
|
||||
("rfdloader", "https://github.com/RFduino/RFduino")
|
||||
]
|
||||
}
|
||||
|
||||
|
@ -37,8 +37,22 @@ class Nordicnrf51Platform(BasePlatform):
|
||||
|
||||
"framework-mbed": {
|
||||
"alias": "framework"
|
||||
},
|
||||
|
||||
"framework-arduinonordicnrf51": {
|
||||
"alias": "framework"
|
||||
},
|
||||
|
||||
"tool-rfdloader": {
|
||||
}
|
||||
}
|
||||
|
||||
def get_name(self):
|
||||
return "Nordic nRF51"
|
||||
|
||||
def configure_default_packages(self, envoptions, targets):
|
||||
if envoptions.get("board") == "rfduino":
|
||||
self.PACKAGES['tool-rfdloader']['alias'] = "uploader"
|
||||
|
||||
return BasePlatform.configure_default_packages(
|
||||
self, envoptions, targets)
|
||||
|
Reference in New Issue
Block a user