Questions tagged [gcc]
Users invoke a language-specific driver program (gcc for C, g++ for C++, etc.), which interprets command arguments, calls the actual compiler, runs the assembler on the output, and then optionally runs the linker to produce a complete executable binary.
21 questions
1
vote
0
answers
141
views
Trying to show g++ (linter-gcc for Atom) where to find Arduino libs
I'm trying to use Atom as an IDE for arduino and arduino-based boards.
I'm using arduino-cli for compilation and avrdude for upload, and now I'm trying to use linter-gcc for linting.
g++ is running ...
1
vote
2
answers
1k
views
How do I make Arduino IDE use a specific version of GCC in Debian?
Using Raspbian Stretch.
I installed gcc-4.9 with specified version. Then I installed arduino (2.1.0.5) which in turn pulled gcc 4.6. When I try to compile Marlin in it, it says
Marlin requires C++...
7
votes
1
answer
2k
views
Accessing a C++ static variable from gcc inline asm
For some reason I want to mix a bit of assembly with C++ (not C).
To allow the code to be compilable using the standard Arduino IDE, I don't want to use direct assembly source.
I don't want to use a ...
0
votes
3
answers
14k
views
Does int array[100] = {0} construct work on Arduino?
I'm compiling my code in Arduino IDE. I have an array that I want to 0-initialize. I know memset works on Arduino, but I'm used to this way from my desktop C++ programming practice:
int array[100] = {...
0
votes
2
answers
19k
views
GCC msg "note: in definition of macro 'max'" error message
I'm using the ATtiny x5 series board, compiling my project (.cpp.ino file). Whenever I use the max(a,b) macro, I receive this message:
"C:\Documents and Settings\<user>\Local Settings\...
2
votes
0
answers
942
views
Error with libraries after setting up Code::blocks to work as an arduino IDE
I followed this guide: http://arduinodev.com/guide-to-arduino-development-environment-codeblocks/
Everything seemed to work until I compiled the example code:
#include <Arduino.h>
/*
Turns ...
0
votes
2
answers
557
views
detecting presence inside - PIR or ultrasound?
(I am professionally a software guy working in the GCC compiler with MELT, so I am fluent in software, but much less in hardware - I did use a solder for a 74LS00 nand gate based stuff in the 1990s. ...
0
votes
1
answer
292
views
Running Arduino code for Bluefruit LE on bare ATMega328
I need to hook up Bluefruit LE Breakout (nRF8001-based) to ATMega328 chip (to use it as wireless UART), and it seems like the library provided is for Arduino.
What I have is just bare ATMega328 (note ...
3
votes
1
answer
2k
views
Using an Arduino board to program an AVR
I think the arduino board is awesome.
Though I'm not interested in the library and IDE at all...
Is there a way, to use an AVR 328p, as you normally would, on an arduino board?
I like how arduino's ...
0
votes
1
answer
861
views
Add -D option via boards.txt
I'm trying to find a way to set a -D compiler option from within the boards.txt file. Basically set a #define for use in code. There are already some special ones like board.vid but is there a generic ...
15
votes
1
answer
386
views
Is there a preprocessor constant for memory size
I would like my compiles to exclude some code depending upon the flash/program space available. To be used in the demo code of a library I support. Whereas my current solution is to use a #ifdef of ...