Custom Board Not Found

I have created a boards directory in %HOMEPATH%.platformio and created a custom board JSON file in it. When I run platformio boards it is not shown and, of course, doing a build results in a “Unknown board ID” error. I have tried placing the file in the platforms/teensy directory but it is not found here either. I’ve searched for a solution to this problem and implemented everything that was relevant but the custom board is not seen by platofrmio. I also would like to know where to put the ldscript file I reference in the JSON file.

PlatformIO version is: 3.5.3b1 running on Win7 Pro

I also have an Arduino style boards.txt file in .platformio\packages\framework-arduinoteensy that works when I use this board in the Arduino/TeensyDuino IDE

I would appreciate some help on getting this custom board installed and working in PlatformIO.

Here is the JSON file (sorry… I don’t know how to put code in a post or to upload the file as only images are allowed):

“teensy3x”: {
“build”: {
“core”: “teensy3”,
“cpu”: “cortex-m4”,
“extra_flags”: “-D__MK20DX256__ -DTEENSY31”,
“f_cpu”: “96000000L”,
“ldscript”: “mk20dx128.ld”,
“mcu”: “mk20dx128”
“debug”: {
“jlink_device”: “MK20DX128xxx7”
“frameworks”: [
“name”: “teensy3x”,
“upload”: {
“maximum_ram_size”: 16384,
“maximum_size”: 131072,
“protocols”: [
“protocol”: “teensy-gui”
“url”: “PJRC Store”,
“vendor”: “Teensy”

Here is my platformio.ini:

platform = teensy
framework = arduino
board = teensy3x
board_f_cpu = 96000000L
extra_scripts =
debug_tool = custom
debug_server =

and here is


env.VerboseAction(" “.join([
“sed”, “-i.bak”,
]), “Fixing $BUILD_DIR/firmware.hex secure flash flags”))
env.VerboseAction(” ".join([
“‘h\nloadfile $BUILD_DIR/firmware.hex\nr\nq\n’”,
]), “Creating auxiliary files”))

‘C:\JLINK\jlink.exe -device MK20DX128xxx7 -speed 4000 -if swd -autoconnect 1 -CommanderScript $BUILD_DIR/aux.jlink’