Skip to content

Incorrect version of USBCore.cpp in package registry? #147

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
apanagar opened this issue Nov 17, 2024 · 0 comments
Open

Incorrect version of USBCore.cpp in package registry? #147

apanagar opened this issue Nov 17, 2024 · 0 comments

Comments

@apanagar
Copy link

I recently installed PlatformIO for development on an Arduino Due. When going through the basic environmental setups, I built and deployed the Blink sketch. During compile, I got the following warnings:

Compiling .pio/build/due/FrameworkArduino/cortex_handlers.c.o
Compiling .pio/build/due/FrameworkArduino/hooks.c.o
Indexing .pio/build/due/libFrameworkArduinoVariant.a
Compiling .pio/build/due/FrameworkArduino/iar_calls_sam3.c.o
/Users/ajay/.platformio/packages/framework-arduino-sam/cores/arduino/USB/USBCore.cpp: In function 'void USB_ISR()':
/Users/ajay/.platformio/packages/framework-arduino-sam/cores/arduino/USB/USBCore.cpp:688:21: warning: this 'else' clause does not guard... [-Wmisleading-indentation]
                     else
                     ^~~~
/Users/ajay/.platformio/packages/framework-arduino-sam/cores/arduino/USB/USBCore.cpp:690:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'else'
         UDD_Send8(EP0, 0);
         ^~~~~~~~~
Compiling .pio/build/due/FrameworkArduino/itoa.c.o
Compiling .pio/build/due/FrameworkArduino/main.cpp.o
Compiling .pio/build/due/FrameworkArduino/new.cpp.o
Compiling .pio/build/due/FrameworkArduino/syscalls_sam3.c.o
Compiling .pio/build/due/FrameworkArduino/watchdog.cpp.o

On inspection of USBCore.cpp, I see the following:
image

however, the latest code in the ArduinoCore-sam repo has the following commits, which seem to be more recent than my screenshot, and also resolves the warning above 790ff2c.

I'm new to PlatformIO and don't quite know my way around, so apologies if I am looking in the wrong place, but it seems to be that this is where the package is installed from https://github.com/platformio/platform-atmelsam/blob/1c15f3aa8595fa707f510221611ee051ab928efa/platform.json#L46, which does appear to be the latest version the repository. Also, here is what I get when list my packages:

[9:33] ajay@AJAYs-MBP ~/Documents/PlatformIO/Projects/tugboat01 $ pio pkg list
Resolving due dependencies...
Platform atmelsam @ 8.3.0 (required: atmelsam)
├── framework-arduino-sam @ 1.6.12 (required: platformio/framework-arduino-sam @ ~1.6.12)
├── framework-cmsis @ 1.40500.0 (required: platformio/framework-cmsis @ ~1.40500.0)
├── framework-cmsis-atmel @ 1.2.2 (required: platformio/framework-cmsis-atmel @ ~1.2.2)
├── tool-bossac @ 1.10700.190624 (required: platformio/tool-bossac @ ~1.10700.0)
└── toolchain-gccarmnoneeabi @ 1.70201.0 (required: platformio/toolchain-gccarmnoneeabi @ ~1.70201.0)

My guess is the package registry has older version of the code in it, but I'm not entirely sure how to download the actual package/file/tar.gz described here: https://registry.platformio.org/tools/platformio/framework-arduino-sam/versions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant