-
-
Notifications
You must be signed in to change notification settings - Fork 107
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
Building project with MegaCore no longer works #251
Comments
Here is my [env]
platform = atmelavr
framework = arduino
monitor_speed = 115200
board_build.f_cpu = 16000000L ; 16MHz CPU frequency
board_hardware.uart = uart0 ; For Bootloader
board_hardware.oscillator = external ; External 16MHz crystal
upload_flags = -Pusb
build_flags =
-Wunused-parameter ; Turn on compiler warning when functions have unused parameters
[env:megaatmega2561]
board = ATmega2561
board_build.mcu = atmega2561
[env:megaatmega2560]
board = ATmega2560
board_build.mcu = atmega2560 |
I can reproduce the problem:
|
If I revert line 78 here 5077ecb#diff-0184adedc292a93218525209d37dabe7330a013e6ff8fa46fd6328c5eb4598faR78 it works. Maybe something was missing when MegaCore was updated? |
Ok I looked more into the Github pipeline. There is one MegaCore MCU there and compiles fine. I installed Python 3.7.9 (pipeline uses 3.7.10) and I reinstalled PlatformIO... then the build worked fine. I had Python 3.9.1 before. Now I've reinstalled 3.9.1 and I am getting this VS Code or SCons error: But then when I try to reproduce this more by reinstalling PIO again without changing the Python installation I get no error. I'm so confused 😅 Will close this for now and reopen if I learn more. |
Have you tried to explicitly specify the |
Yes I get the same results. You can see the Library Manager trying to install For reference I did it like this: lib_deps =
SPI
; ... more libraries below |
Could you please put together a simple project to reproduce the issue? |
@valeros here: https://github.com/GunZi200/MegaCore-ATmega2560-err I get this result on my end. I created an Arduino Mega project and only changed the If you can't reproduce this try one thing I did:
I seem to be able to bypass this error when my machine has Python 3.7.9 installed. |
It's strange, but I cannot reproduce the issue, tried your project with Python 3.9.1 and everything works just fine. Could you please run |
That's super weird. Let's focus on machines where it doesn't work. Do you see the |
Apparently, the |
I get it to work sometimes but sometimes not. I found one way to trigger the issue when it was working.
This issue is really slowing things down to test this hehe platformio/platformio-vscode-ide#2506 Edit: The |
Do you have an antivirus by any chance? |
No only Windows Defender, its never been a problem for me. |
Something is messing with the PlatformIO packages on your machines and I'm guessing it's |
@valeros I noticed that PlatformIO plugins installs |
I'm not sure if it's relevant or not, but I was not able to get the example project @GunZi200 provided when platformio.ini looked like this. Identical error to this one: #251 (comment) [env:ATmega2560]
platform = atmelavr
board = ATmega2560
framework = arduino
; Libraries
lib_deps =
Wire
https://github.com/adafruit/RTClib ; Real-time clock library
lib_ignore = TinyWireM However, if I changed the library dependent to this, it worked: [env:ATmega2560]
platform = atmelavr
board = ATmega2560
framework = arduino
; Libraries
lib_deps =
Wire
adafruit/RTClib @ 1.13.0
lib_ignore = TinyWireM |
@GunZi200 I believe it has nothing to do with this issue because your system contains broken framework package. |
I think I have a solution... Reproduction steps to make it work:
Build from this point works for me on all machines. If I for some reason reload VScode in step 6 the issue appears and the package is broken. I can consistently reproduce this. |
@GunZi200
If you do that, you will kill the |
I have tried with both ATmega2560 and ATmega2561.
This has never been a problem before.
The text was updated successfully, but these errors were encountered: