Skip to content

Teensy 3.2 cannot be programmed after first time, unless press reset button #41

@424778940z

Description

@424778940z

I'm using latest stable version platformio ide

This issue may caused by I set it to usb uart mode, and download script doesn't reboot it before program.

i did following change in this file: .atom\packages\platformio-ide\penv\Lib\site-packages\platformio\builder\scripts\teensy.py
start at: Line 68

before:

env.Append(
        UPLOADER=join(
            "$PIOPACKAGES_DIR", "tool-teensy", "teensy_post_compile"),
        UPLOADERFLAGS=[
            "-file=firmware",
            '-path="$BUILD_DIR"',
            '-tools="%s"' % join("$PIOPACKAGES_DIR", "tool-teensy")
        ],
        UPLOADHEXCMD='"$UPLOADER" $UPLOADERFLAGS'
    )

after:

env.Append(
        REBOTTER=join(
            "$PIOPACKAGES_DIR", "tool-teensy", "teensy_reboot"),
        UPLOADER=join(
            "$PIOPACKAGES_DIR", "tool-teensy", "teensy_post_compile"),
        UPLOADERFLAGS=[
            "-file=firmware",
            '-path="$BUILD_DIR"',
            '-tools="%s"' % join("$PIOPACKAGES_DIR", "tool-teensy")
        ],
        UPLOADHEXCMD='"$REBOTTER" & "$UPLOADER" $UPLOADERFLAGS'
    )

it solve this issue for now but will have a error because delay between restart and program is not enough
error msg: "Teensy Loader is currently busy with another operation (p). Please try again in a few seconds, or restart Teensy Loader."

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions