Comments (27)
Related topic https://community.platformio.org/t/support-for-atmega328pb/314
from platform-atmelavr.
1.6.12 finally updates avrdude to 6.3.
from platform-atmelavr.
Is there any news on why this havent been done ? I want to use the Atmega328PB which alledgedly is supported by updating this.
from platform-atmelavr.
Could someone help us with new packages? We will replace old that are located here
https://bintray.com/platformio/dl-packages/toolchain-atmelavr#files
from platform-atmelavr.
What do you mean by help you ? Download the packages from Atmel for you ?
from platform-atmelavr.
Download the packages from Atmel for you ?
Good joke!
I mean that multiple developers migrate from Arduino IDE to PlatformIO IDE. We should be confident that new users will not have problems with projects that work with Arduino IDE and don't work with PlatformIO IDE because we use different toolchains, etc.
The question: does Arduino IDE uses Atmel AVR 3.5.3 toolchain?
from platform-atmelavr.
Q then, is it possible to maybe define a custom toolchain for a particulat project or similar since I have the atmega328 ?
from platform-atmelavr.
Yes, it is. You can clone existing Atmel Avr development platform and specify own toolchain version.
In any case, I am ready to update generic GCC-AVR toolchain but need to be confident that we will not break thousands of PlatformIO projects over the world.
Could someone check this information? Which version of gcc-avr is used in Arduino IDE? Then, we will decide together here which we should use in PlatformIO.
from platform-atmelavr.
The newest Arduino uses 4.9.2
ekarlso@ekarlso-tpad:/Downloads/arduino-1.6.12$ ./hardware/tools/avr/bin/avr-g++/Downloads/arduino-1.6.12$ ./hardware/tools/avr/bin/avr-g++ -v
avr-g++: fatal error: no input files
compilation terminated.
ekarlso@ekarlso-tpad:
Using built-in specs.
Reading specs from /home/ekarlso/Downloads/arduino-1.6.12/hardware/tools/avr/bin/../lib/gcc/avr/4.9.2/device-specs/specs-avr2
COLLECT_GCC=./hardware/tools/avr/bin/avr-g++
COLLECT_LTO_WRAPPER=/home/ekarlso/Downloads/arduino-1.6.12/hardware/tools/avr/bin/../libexec/gcc/avr/4.9.2/lto-wrapper
Target: avr
Configured with: ../gcc/configure --enable-fixed-point --enable-languages=c,c++ --prefix=/home/jenkins/workspace/avr-gcc/label/debian7-x86_64/objdir --enable-long-long --disable-nls --disable-checking --disable-libssp --disable-libada --disable-shared --enable-lto --with-avrlibc=yes --with-dwarf2 --disable-doc --target=avr
Thread model: single
gcc version 4.9.2 (GCC)
from platform-atmelavr.
@ekarlso thanks! Is this toolchain the same that we can downloads from Atmel site?
from platform-atmelavr.
That is the bundled version of Arduino 1.6.12.
This is the avr toolchain 3.5.4
Using built-in specs.
Reading specs from /home/ekarlso/Downloads/avr8-gnu-toolchain-linux_x86_64/bin/../lib/gcc/avr/4.9.2/device-specs/specs-avr2
COLLECT_GCC=./bin/avr-g++
COLLECT_LTO_WRAPPER=/home/ekarlso/Downloads/avr8-gnu-toolchain-linux_x86_64/bin/../libexec/gcc/avr/4.9.2/lto-wrapper
Target: avr
Configured with: /home/toolsbuild/workspace/avr8-gnu-toolchain/src/gcc/configure LDFLAGS=-L/home/toolsbuild/workspace/avr8-gnu-toolchain/avr8-gnu-toolchain-linux_x86_64-hostlibs/lib CPPFLAGS= --target=avr --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/home/toolsbuild/workspace/avr8-gnu-toolchain/avr8-gnu-toolchain-linux_x86_64 --libdir=/home/toolsbuild/workspace/avr8-gnu-toolchain/avr8-gnu-toolchain-linux_x86_64/lib --enable-languages=c,c++ --with-dwarf2 --enable-doc --disable-shared --disable-libada --disable-libssp --disable-nls --with-avrlibc=yes --with-mpfr=/home/toolsbuild/workspace/avr8-gnu-toolchain/avr8-gnu-toolchain-linux_x86_64-hostlibs --with-gmp=/home/toolsbuild/workspace/avr8-gnu-toolchain/avr8-gnu-toolchain-linux_x86_64-hostlibs --with-mpc=/home/toolsbuild/workspace/avr8-gnu-toolchain/avr8-gnu-toolchain-linux_x86_64-hostlibs --with-pkgversion=AVR_8_bit_GNU_Toolchain_3.5.4_1709 --with-bugurl=http://www.atmel.com
Thread model: single
gcc version 4.9.2 (AVR_8_bit_GNU_Toolchain_3.5.4_1709)
from platform-atmelavr.
[Mon Oct 31 14:31:34 2016] Processing controller (upload_protocol: usbasp, framework: arduino, lib_install: 13,135, upload_flags: -Pusb -B5, platform: atmelavr, board: gatekeeper-controller)
Verbose mode can be enabled via -v, --verbose
option
Collected 30 compatible libraries
Looking for dependencies...
Library Dependency Graph
|--
Compiling .pioenvs/controller/src/main.o
In file included from /home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/pgmspace.h:90:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/Arduino.h:28,
from src/main.cpp:1:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/io.h:623:6: warning: #warning "device type not defined" [-Wcpp]
warning "device type not defined"
^
Compiling .pioenvs/controller/FrameworkArduino/CDC.o
In file included from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/USBAPI.h:25:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/Arduino.h:225,
from src/main.cpp:1:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/eeprom.h:41:3: warning: #warning "Device does not have EEPROM available." [-Wcpp]
warning "Device does not have EEPROM available."
^
Compiling .pioenvs/controller/FrameworkArduino/HardwareSerial.o
In file included from /home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/pgmspace.h:90:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/USBAPI.h:24,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/CDC.cpp:19:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/io.h:623:6: warning: #warning "device type not defined" [-Wcpp]
warning "device type not defined"
^
In file included from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/USBAPI.h:25:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/CDC.cpp:19:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/eeprom.h:41:3: warning: #warning "Device does not have EEPROM available." [-Wcpp]
warning "Device does not have EEPROM available."
^
Compiling .pioenvs/controller/FrameworkArduino/HardwareSerial0.o
src/main.cpp:6:27: error: 'Serial' was not declared in this scope
RS485Controller rs485ctrl(Serial, RS485_RE, RS485_WE);
^
src/main.cpp: In function 'void setup()':
src/main.cpp:18:3: error: 'Serial' was not declared in this scope
Serial.begin(9600);
^
src/main.cpp: In function 'void loop()':
src/main.cpp:33:7: error: 'Serial' was not declared in this scope
Serial.println("RX: IDLE");
^
*** [.pioenvs/controller/src/main.o] Error 1
In file included from /home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/pgmspace.h:90:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/Arduino.h:28,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/HardwareSerial.cpp:29:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/io.h:623:6: warning: #warning "device type not defined" [-Wcpp]
warning "device type not defined"
^
In file included from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/USBAPI.h:25:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/Arduino.h:225,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/HardwareSerial.cpp:29:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/eeprom.h:41:3: warning: #warning "Device does not have EEPROM available." [-Wcpp]
warning "Device does not have EEPROM available."
^
In file included from /home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/pgmspace.h:90:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/Arduino.h:28,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/HardwareSerial0.cpp:25:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/io.h:623:6: warning: #warning "device type not defined" [-Wcpp]
warning "device type not defined"
^
In file included from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/USBAPI.h:25:0,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/Arduino.h:225,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/HardwareSerial0.cpp:25:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/eeprom.h:41:3: warning: #warning "Device does not have EEPROM available." [-Wcpp]
warning "Device does not have EEPROM available."
^
In file included from /home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/io.h:99:0,
from /home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/pgmspace.h:90,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/USBAPI.h:24,
from /home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/CDC.cpp:19:
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h: In function 'void wdt_enable(uint8_t)':
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:454:21: error: 'WDT' was not declared in this scope
if (_SFR_IO_REG_P (_WD_CONTROL_REG))
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:465:24: error: 'WDCE' was not declared in this scope
"r" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE))),
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:465:42: error: 'WDE' was not declared in this scope
"r" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE))),
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:482:24: error: 'WDCE' was not declared in this scope
"r" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE))),
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:482:42: error: 'WDE' was not declared in this scope
"r" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE))),
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h: In function 'void wdt_disable()':
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:494:21: error: 'WDT' was not declared in this scope
if (_SFR_IO_REG_P (_WD_CONTROL_REG))
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:508:37: error: 'WDCE' was not declared in this scope
[WDCE_WDE] "n" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE)))
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:508:55: error: 'WDE' was not declared in this scope
[WDCE_WDE] "n" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE)))
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:526:37: error: 'WDCE' was not declared in this scope
[WDCE_WDE] "n" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE)))
^
/home/ekarlso/.platformio/packages/toolchain-atmelavr/avr/include/avr/wdt.h:526:55: error: 'WDE' was not declared in this scope
[WDCE_WDE] "n" ((uint8_t)(_BV(_WD_CHANGE_BIT) | _BV(WDE)))
^
*** [.pioenvs/controller/FrameworkArduino/CDC.o] Error 1
========================================================================================================= [ERROR] Took 0.64 seconds =========================================================================================================
from platform-atmelavr.
What is it? New toolchain?
from platform-atmelavr.
That is the Atmel 3.5.4 toolchain (I just swapped toolchain-atmelavr with this one)
from platform-atmelavr.
Could you try Arduino IDE's toolchain?
Also, check that new toolchain structure is the same as previous and all symbolic links are resolved.
from platform-atmelavr.
So I did the following:
cp -R /home/ekarlso/arduino-1.6.12/hardware/arduino/avr/ framework-arduinoavr
cp -R /home/ekarlso/arduino-1.6.12/hardware/tools/avr/ toolchain-atmelavr
copied package.json from the old versions to the "copy" and then tried to run "pio run" in my project but it fails giving
*** Multiple ways to build the same target were specified for: /home/ekarlso/projects/gatekeeper/gatekeeper-rs485-reader/.pioenvs/reader/FrameworkArduino/wiring_pulse.o (from ['/home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/wiring_pulse.S'] and from ['/home/ekarlso/.platformio/packages/framework-arduinoavr/cores/arduino/wiring_pulse.c'])
File "/usr/local/lib/python2.7/dist-packages/platformio/builder/tools/platformio.py", line 263, in BuildLibrary
So I checked the "old" version and I see you have renamed the file to _file.S there and that fixed it and my project compiles.
arduino_1.6.12.txt
arduino-old.txt
Attached you will find "tree -al" of both of the directories.
from platform-atmelavr.
Stop... We talk here about toolchain but not about new Arduino Framework.
Need to check Arduino IDE's toolchain-atmelavr
from platform-atmelavr.
cp -R /home/ekarlso/arduino-1.6.12/hardware/tools/avr/ toolchain-atmelavr
Please sorry, I see it.
Does it work with Atmega328PB ?
from platform-atmelavr.
You need to add support for it by the looks by copying the files in before pio run is done.
I have updated the project so you can see what is being done
https://gitlab.com/creator-makerspace/gatekeeper-rs485-controller/blob/develop/bootstrap.sh
basically it's a very hacky solution atm to get it going.
- "pio run" to get the toolchain etc installed
- replace the packages/toolchain-avr with the toolchain from arduino 1.6.12
- bootstrap.sh to install support for the atmega328pb
- run platformio run to compile..
And after all that there's still no support in the current avrdude.conf that is with platformio for it.
from platform-atmelavr.
Any idea @ivankravets ?
from platform-atmelavr.
I'll update all toolchains and add support for atmega328pb in PlatformIO 3.2.
from platform-atmelavr.
The boards_dir
is already implemented platformio/platformio-core@7b4d94c
from platform-atmelavr.
If you want me to test dev version I can do that once you update ;)
from platform-atmelavr.
Sure, I'll ask here. I'm working on the first public beta of PlatformIO 3.2 and after it will take a look at the new packages, boards, etc.
Would you like to try out PIO Remote? http://docs.platformio.org/en/latest/plus/pio-remote.html
Would be thankful for any feedback!
from platform-atmelavr.
Avrdude has been updated to 6.3. Also , added support for ATmega328PB
from platform-atmelavr.
@ekarlso Could you help us to resolve this issue? https://ci.appveyor.com/project/ivankravets/platform-atmelavr/build/1.0.101/job/8m3his6x75rs9bo8#L2284
I patched all toolchains with https://github.com/watterott/ATmega328PB-Testing but it doesn't work with Windows toolchain.
from platform-atmelavr.
Fixed toolchain for Windows
from platform-atmelavr.
Related Issues (20)
- Update all MCUdude Arduino cores to the latest version HOT 5
- Update MCUdude cores (yet again, sorry) HOT 1
- tool-micronucleus package (Digispark support) needs update to fix "flash erase error" -71, -32, etc. on Linux
- [Feature Request] HOT 1
- Updated PIO, build now fails with "KeyError: 'tool-avrdude," but I'm not even using avrdude HOT 2
- relocation truncated to fit: R_AVR_13_PCREL against `no symbol'
- Update MCUdude cores the the latest version HOT 1
- debugging with simavr: avr-gdb depends on libncurses.so.5 and libtinfo.so.5 HOT 1
- avr-gdb in toolchain atmelavr is obsolete and depends on libncurses5 HOT 1
- framework-arduino-avr package incredibly outdated HOT 7
- DOCS: Invalid Parameters. HOT 1
- Addding a custom board to your boards list (CRODUINO_ATMEGA328P_LoRA) HOT 1
- PlatformIO passes the wrong -mmcu flag for the assembler (ATmega328PB) HOT 4
- Upload to attiny85 using optiboot (serial)
- Support for Urboot and Mighty/Mini/Mega/MajorCore v3.0.0 HOT 2
- error: 'fabs' was not declared in this scope HOT 2
- Add support for ATX2 HOT 3
- toolchain-atmelavr source code and build scripts? HOT 12
- Custom board pull request. (STF Labs B107AA)
- please consider to add upload.mcu HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from platform-atmelavr.