Пример #1
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            disable_tool = "tool-micronucleus"
            if "digispark" in board['build']['core']:
                disable_tool = "tool-avrdude"
            del self.PACKAGES[disable_tool]['alias']

        return BasePlatform.configure_default_packages(self, envoptions,
                                                       targets)
Пример #2
0
    def configure_default_packages(self, envoptions, targets):
        if (envoptions.get("framework") == "wiringpi"
                and "linux_arm" not in util.get_systype()):
            raise exception.PlatformioException(
                "PlatformIO does not support temporary cross-compilation "
                "for WiringPi framework. Please run PlatformIO directly on "
                "Raspberry Pi")

        return BasePlatform.configure_default_packages(self, envoptions,
                                                       targets)
Пример #3
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            if "digispark" in board['build']['core']:
                self.PACKAGES['tool-micronucleus']['alias'] = "uploader"
            else:
                self.PACKAGES['tool-avrdude']['alias'] = "uploader"

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #4
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            disable_tool = "tool-micronucleus"
            if "digispark" in board['build']['core']:
                disable_tool = "tool-avrdude"
            del self.PACKAGES[disable_tool]['alias']

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #5
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            if "digispark" in board['build']['core']:
                self.PACKAGES['tool-micronucleus']['alias'] = "uploader"
            else:
                self.PACKAGES['tool-avrdude']['alias'] = "uploader"

        return BasePlatform.configure_default_packages(self, envoptions,
                                                       targets)
Пример #6
0
    def configure_default_packages(self, envoptions, targets):
        if (envoptions.get("framework") == "wiringpi" and
                "linux_arm" not in util.get_systype()):
            raise exception.PlatformioException(
                "PlatformIO does not support temporary cross-compilation "
                "for WiringPi framework. Please run PlatformIO directly on "
                "Raspberry Pi"
            )

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #7
0
 def run(self, variables, targets, verbose):
     for v in variables:
         if "BOARD=" not in v:
             continue
         disable_tool = "tool-micronucleus"
         _, board = v.split("=")
         bdata = get_boards(board)
         if "digispark" in bdata['build']['core']:
             disable_tool = "tool-avrdude"
         del self.PACKAGES[disable_tool]['alias']
         break
     return BasePlatform.run(self, variables, targets, verbose)
Пример #8
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            if board['build']['core'] == "teensy":
                name = "toolchain-atmelavr"
            else:
                name = "toolchain-gccarmnoneeabi"
            self.PACKAGES[name]['alias'] = "toolchain"
            self.PACKAGES[name]['default'] = True

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #9
0
 def run(self, variables, targets, verbose):
     for v in variables:
         if "BOARD=" not in v:
             continue
         disable_tool = "tool-micronucleus"
         _, board = v.split("=")
         bdata = get_boards(board)
         if "digispark" in bdata['build']['core']:
             disable_tool = "tool-avrdude"
         del self.PACKAGES[disable_tool]['alias']
         break
     return BasePlatform.run(self, variables, targets, verbose)
Пример #10
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            if board['build']['core'] == "teensy":
                name = "toolchain-atmelavr"
            else:
                name = "toolchain-gccarmnoneeabi"
            self.PACKAGES[name]['alias'] = "toolchain"
            self.PACKAGES[name]['default'] = True

        return BasePlatform.configure_default_packages(self, envoptions,
                                                       targets)
Пример #11
0
 def run(self, variables, targets):
     for v in variables:
         if "BOARD=" not in v:
             continue
         tuploader = "tool-avrdude"
         _, board = v.split("=")
         bdata = get_boards(board)
         if "digispark" in bdata['build']['core']:
             tuploader = "tool-micronucleus"
         self.PACKAGES[tuploader]['alias'] = "uploader"
         break
     return BasePlatform.run(self, variables, targets)
Пример #12
0
 def run(self, variables, targets, verbose):
     for v in variables:
         if "BOARD=" not in v:
             continue
         _, board = v.split("=")
         bdata = get_boards(board)
         if bdata['build']['core'] == "teensy":
             tpackage = "toolchain-atmelavr"
         else:
             tpackage = "toolchain-gccarmnoneeabi"
         self.PACKAGES[tpackage]['alias'] = "toolchain"
         break
     return BasePlatform.run(self, variables, targets, verbose)
Пример #13
0
 def run(self, variables, targets):
     for v in variables:
         if "BOARD=" not in v:
             continue
         _, board = v.split("=")
         bdata = get_boards(board)
         if bdata['build']['core'] == "teensy":
             tpackage = "toolchain-atmelavr"
         else:
             tpackage = "toolchain-gccarmnoneeabi"
         self.PACKAGES[tpackage]['alias'] = "toolchain"
         break
     return BasePlatform.run(self, variables, targets)
Пример #14
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            upload_protocol = board.get("upload", {}).get("protocol", None)
            upload_tool = None
            if upload_protocol == "openocd":
                upload_tool = "tool-openocd"
            elif upload_protocol == "sam-ba":
                upload_tool = "tool-bossac"
            elif upload_protocol == "stk500v2":
                upload_tool = "tool-avrdude"

            if upload_tool:
                self.PACKAGES[upload_tool]['alias'] = "uploader"

        return BasePlatform.configure_default_packages(self, envoptions,
                                                       targets)
Пример #15
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("board"):
            board = get_boards(envoptions.get("board"))
            upload_protocol = board.get("upload", {}).get("protocol", None)
            upload_tool = None
            if upload_protocol == "openocd":
                upload_tool = "tool-openocd"
            elif upload_protocol == "sam-ba":
                upload_tool = "tool-bossac"
            elif upload_protocol == "stk500v2":
                upload_tool = "tool-avrdude"

            if upload_tool:
                self.PACKAGES[upload_tool]['alias'] = "uploader"

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #16
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("framework") == "cmsis":
            self.PACKAGES['framework-mbed']['default'] = True

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #17
0
 def on_run_err(self, line):  # pylint: disable=R0201
     # fix STDERR "flash written" for avrdude
     if "avrdude" in line:
         self.on_run_out(line)
     else:
         BasePlatform.on_run_err(self, line)
Пример #18
0
    def configure_default_packages(self, envoptions, targets):
        if not envoptions.get("framework"):
            self.PACKAGES['sdk-esp8266']['default'] = True

        return BasePlatform.configure_default_packages(
            self, envoptions, targets)
Пример #19
0
    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)
Пример #20
0
 def __init__(self):
     if get_systype() == "linux_x86_64":
         del self.PACKAGES['toolchain-gcclinux64']
     BasePlatform.__init__(self)
Пример #21
0
    def configure_default_packages(self, envoptions, targets):
        if envoptions.get("framework") == "cmsis":
            self.PACKAGES['framework-mbed']['default'] = True

        return BasePlatform.configure_default_packages(self, envoptions,
                                                       targets)
Пример #22
0
 def on_run_err(self, line):  # pylint: disable=R0201
     # fix STDERR "flash written" for avrdude
     if "avrdude" in line:
         self.on_run_out(line)
     else:
         BasePlatform.on_run_err(self, line)
    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)
Пример #24
0
 def __init__(self):
     if "linux_arm" in util.get_systype():
         del self.PACKAGES['toolchain-gccarmlinuxgnueabi']
     BasePlatform.__init__(self)
Пример #25
0
 def __init__(self):
     if get_systype() == "linux_x86_64":
         del self.PACKAGES['toolchain-gcclinux64']
     BasePlatform.__init__(self)
Пример #26
0
 def __init__(self):
     if "linux_arm" in util.get_systype():
         del self.PACKAGES['toolchain-gccarmlinuxgnueabi']
     BasePlatform.__init__(self)
Пример #27
0
 def __init__(self):
     if get_systype() == "linux_i686":
         del self.PACKAGES['toolchain-gcclinux32']
     BasePlatform.__init__(self)
Пример #28
0
 def __init__(self):
     if get_systype() == "linux_i686":
         del self.PACKAGES['toolchain-gcclinux32']
     BasePlatform.__init__(self)