Where does the Arduino IDE save the binaries on Mac OS X?
问题:
回答1:
In the Arduino software: go to File -> Preferences and then select Show verbose output during -> compilation.
Finally, when you are compiling, the program will show you lots of data. At the last lines, you will find the path1 to the .hex
file.
1Every time the path changes!
回答2:
Arduino 1.6.5 has a new command: Under the Sketch
menu, select Export compiled Binary
, then Show Sketch Folder
. There it is.
回答3:
Arduino IDE uses the mktemp command to create the temp directory on Mac and Linux. However, on Mac the default $TMPDIR env var is not /tmp/ as it is on Linux. On Mac it's under /var/folders and it is randomly generated on boot. That complicates things a little, but here are tricks you can add to your toolkit (as aliases, functions, shell scripts, etc.) to help you find what you need.
To find the hex files
find $TMPDIR -name \*.hex -exec ls -lrt {} \; #<-- you need that backslash before and space after the semicolon
To find build directories
ls -ldrt $TMPDIR/build*
NOTE: The ls
flags of r
and t
cause the listing to be "reverse" sorted by "time" respectively. This means that the newest will be on the bottom.
回答4:
What UDalillu said. The trick also works on Windows. On XP it ended up in C:\Documents and Settings\Your_User_Name\Local Settings\Temp\buildxxxxx\ (the xxx number changes for each build, pick the most recent).
回答5:
The arduino web page http://arduino.cc/en/Hacking/BuildProcess described
During a "Verify" the .hex file is written to /tmp (on Mac and Linux) or \Documents and Settings\\Local Settings\Temp (on Windows)
I am using fedora19 64bit, and when i check my /tmp the build directory created is /tmp/build8102....tmp/
回答6:
I made a simple tutorial here with images
回答7:
It is very beautifully explained in the following blog Where to find Arduino Hex files or Output Binaries I hope this helps :)