Go Down

Topic: Board not found error (Read 1 time) previous topic - next topic

BillBigge

I'm using a fork of Adafruits SAMD core for Arduino, and I've been using the D21G18 microcontroller for some project development. Now the project is almost complete I've swapped out the MCO for a D21G17 - it has half the memory and costs a little less - (my code was only using 30% fash on the g18).

I've created a new board definition for this MCU variant and as far as I know I've edited every part of the  variants files to reference the d21g17 instead of the g18, but every time I try and upload is tells me it can't find a board on that port.

I'm after some pointers as to where I might be going wrong here.

More details: I'm using bootloaders from MattairTech who have an entire suite of pre-compiled bootloaders for every version of the D21. Their D21G18 bootloader plays fine with the Adafruit Arduino distribution, and I can upload code if I select my own D21G18 variant, or an Adafruit M0 board.

The problems occur now that I'm using the D21G17, and the matching bootloader from Mattairtech.

If I use Mattairtechs Arduino distribution to upload a test sketch then it will upload fine - but my project needs some pins not definined in the Mattairtech boards, and don't want to have to have to construct an entire set of board definition files for the Mattairtech distribution just to complete the last step of the project - except as the last resort!

DrAzzy

#1
Nov 23, 2019, 12:01 am Last Edit: Nov 23, 2019, 12:11 am by DrAzzy
Post the exact text of the error message, and a link to the fork of the core that you're using.

You should always post the full text of any and all error messages whenever asking for help with a technical problem, not your paraphrasing of the error. Small differences in the phrasing of the error can make a world of difference regarding it's cause; programmers are usually pretty lousy at writing good error messages (and besides, sometimes there's more than one error, and people only post one of them - despite the fact that they're asking for help, which in and of itself demonstrates that they are not qualified to interpret the error message(s))
ATTinyCore for x4/x5/x61/x7/x8/x41/1634/828/x313 megaTinyCore for the megaavr ATtinies - Board Manager:
http://drazzy.com/package_drazzy.com_index.json
ATtiny breakouts, mosfets, awesome prototyping board in my store http://tindie.com/stores/DrAzzy

BillBigge

Yes, quite right.
Quote
An error occurred while uploading the sketch
No device found on COM24
Mattairtech arduino dist:
https://github.com/mattairtech/ArduinoCore-samd

Adafruits:
https://github.com/adafruit/ArduinoCore-samd

My own branch of adafruits is not online, but here is the section from the hacked boards.txt file - both for the board variant that works (samd21G18) and the version that doesn't (samd21G17).

I wish I understood how this all worked better than I do, but I'm hoping I'll learn enough to fix my problem.

If I upload a sketch using the Mattairtech core then when I next try and upload using my own core it will disconnect the USB as it usually does, but when the bootloader starts it doesn't seem to recognise it as something it can communicate with.

Code: [Select]
# HabIntroExtro
# ------------------------------
habIntroExtro.name=habIntroExtro
habIntroExtro.vid.0=0x16D0
habIntroExtro.pid.0=0x0557
habIntroExtro.vid.1=0x16D0
habIntroExtro.pid.1=0x0856
habIntroExtro.vid.2=0x16D0
habIntroExtro.pid.2=0x0B41
habIntroExtro.vid.3=0x16D0
habIntroExtro.pid.3=0x0B40
habIntroExtro.vid.4=0x16D0
habIntroExtro.pid.4=0x0A0C
habIntroExtro.vid.5=0x16D0
habIntroExtro.pid.5=0x0856
habIntroExtro.upload.tool=bossac
habIntroExtro.upload.protocol=sam-ba
habIntroExtro.upload.maximum_size=262144
habIntroExtro.upload.offset=0x2000
habIntroExtro.upload.use_1200bps_touch=true
habIntroExtro.upload.wait_for_upload_port=true
habIntroExtro.upload.native_usb=true
habIntroExtro.build.mcu=cortex-m0plus
habIntroExtro.build.f_cpu=48000000L
habIntroExtro.build.usb_product="HabIntroExtro"
habIntroExtro.build.usb_manufacturer="Hbd"
habIntroExtro.build.board=SAMD_ZERO
habIntroExtro.build.core=arduino
habIntroExtro.build.extra_flags=-DCRYSTALLESS -DADAFRUIT_ITSYBITSY_M0 -D__SAMD21G18A__ -DARM_MATH_CM0PLUS {build.usb_flags}
habIntroExtro.build.ldscript=linker_scripts/gcc/flash_with_bootloader.ld
habIntroExtro.build.openocdscript=openocd_scripts/SAMD21G18A.cfg
habIntroExtro.build.variant=habIntroExtro
habIntroExtro.build.variant_system_lib=
habIntroExtro.build.vid=0x16D0
habIntroExtro.build.pid=0x0557
habIntroExtro.bootloader.tool=arduino:openocd
habIntroExtro.bootloader.file=zero/binaries/sam_ba_Generic_x21G_SAMD21G18A.bin
habIntroExtro.menu.usbstack.arduino=Arduino
habIntroExtro.menu.usbstack.tinyusb=TinyUSB
habIntroExtro.menu.usbstack.tinyusb.build.flags.usbstack=-DUSE_TINYUSB
habIntroExtro.menu.debug.off=Off
habIntroExtro.menu.debug.on=On
habIntroExtro.menu.debug.on.build.flags.debug=-g


# HabIntroExtroPro
# ------------------------------
habIntroExtroPro.name=habIntroExtroPro
habIntroExtroPro.vid.0=0x16D0
habIntroExtroPro.pid.0=0x0557
habIntroExtroPro.vid.1=0x16D0
habIntroExtroPro.pid.1=0x0856
habIntroExtroPro.vid.2=0x16D0
habIntroExtroPro.pid.2=0x0B41
habIntroExtroPro.vid.3=0x16D0
habIntroExtroPro.pid.3=0x0B40
habIntroExtroPro.vid.4=0x16D0
habIntroExtroPro.pid.4=0x0A0C
habIntroExtroPro.vid.5=0x16D0
habIntroExtroPro.pid.5=0x0856
habIntroExtroPro.upload.tool=bossac
habIntroExtroPro.upload.protocol=sam-ba
habIntroExtroPro.upload.maximum_size=131072
habIntroExtroPro.upload.offset=0x2000
habIntroExtroPro.upload.use_1200bps_touch=true
habIntroExtroPro.upload.wait_for_upload_port=true
habIntroExtroPro.upload.native_usb=true
habIntroExtroPro.build.mcu=cortex-m0plus
habIntroExtroPro.build.f_cpu=48000000L
habIntroExtroPro.build.usb_product="HabIntroExtroPro"
habIntroExtroPro.build.usb_manufacturer="Hbd"
habIntroExtroPro.build.board=SAMD_ZERO
habIntroExtroPro.build.core=arduino
habIntroExtroPro.build.extra_flags=-DCRYSTALLESS -D__SAMD21G17A__ -DARM_MATH_CM0PLUS {build.usb_flags}
habIntroExtroPro.build.ldscript=linker_scripts/gcc/flash_with_bootloader.ld
habIntroExtroPro.build.openocdscript=openocd_scripts/SAMD21G17A.cfg
habIntroExtroPro.build.variant=habIntroExtroPro
habIntroExtroPro.build.variant_system_lib=
habIntroExtroPro.build.vid=0x16D0
habIntroExtroPro.build.pid=0x0557
habIntroExtroPro.bootloader.tool=arduino:openocd
habIntroExtroPro.bootloader.file=zero/binaries/sam_ba_Generic_x21G_SAMD21G17A.bin
habIntroExtroPro.menu.usbstack.arduino=Arduino
habIntroExtroPro.menu.usbstack.tinyusb=TinyUSB
habIntroExtroPro.menu.usbstack.tinyusb.build.flags.usbstack=-DUSE_TINYUSB
habIntroExtroPro.menu.debug.off=Off
habIntroExtroPro.menu.debug.on=On
habIntroExtroPro.menu.debug.on.build.flags.debug=-g

Go Up