Need an Arduino/Linux assistance

91 views
Skip to first unread message

The_Digital_Dentist

unread,
Aug 11, 2012, 12:12:07 PM8/11/12
to milwaukee...@googlegroups.com
What should be the easiest part of building my printer is turning out to be the biggest PITA.

I've been trying to set up the Arduino IDE so I can flash the firmware on the MegaMax 3D printer, which should be really simple, but I'm running into one problem after another.  First newer versions of the IDE don't work with the Mega4560 board even though it appears to be a couple years old, so I had to track down and install an older version of the IDE.  Then I find that I'm having compile problems because the older IDE isn't compatible with latest C compiler I installed.  Then, after I track down the older, compatible C compiler I find it is dependent on older GMP and other modules and won't work with current versions.  It's like pulling potatoes except that the string of dependencies on outdated software never seems to end.

So eventually I get what I think is all the out-dated software packages and dependencies together, configure it, make it, and then install fails.  What little documentation for all this that exists (except how to actually make it work) is spread out in a 100 posts on 20 internet forums.

3 questions:

1)  Are there any one-stop-shopping sites anywhere with DLs for all the necessary software and dependencies for any given Arduino board like the Mega2560?

2)  Is all this because I'm using linux or is the situation the same for all OSes?  

3) How the hell does anyone get ANYTHING working on an Arduino board? 

Ron Bean

unread,
Aug 11, 2012, 12:25:50 PM8/11/12
to milwaukee...@googlegroups.com
>1) Are there any one-stop-shopping sites anywhere with DLs for all the
>necessary software and dependencies for any given Arduino board like the
>Mega2560?
>
>2) Is all this because I'm using linux or is the situation the same for
>all OSes?
>
>3) How the hell does anyone get ANYTHING working on an Arduino board?

I'm running Ubuntu 12.04 (current version), and the version of the
Arduino IDE in their repository (1.0, slightly behind the current
release) supports the Mega 2560. What version of Linux are you running?

It might be worth setting up a spare machine (maybe at the space) with
Ubuntu just to try it out.

The IDE seems to work fine for the boards it supports. There's a config
file you can edit (and support files you can add) to support other
boards, but it doesn't always work, and I haven't found any
documentation for it.

BTW it's also possible to set up the Eclipse IDE to work with Arduino.
It's on my to-do list, but it does take some research to make sure
you're doing it right (Royce has it working). There are a few web pages
about it, some of which seem to be slightly out of date. Things to seem
to be improving, though.

The_Digital_Dentist

unread,
Aug 11, 2012, 12:41:53 PM8/11/12
to milwaukee...@googlegroups.com, Ron Bean
The Marlin page at GitHub says that you have to use version 0022 (and someone on a forum said 0023 works) of the Arduino IDE to compile the Marlin code because of some incompatibilities with more recent versions of the IDE (I tested that idea and it's true- Marlin won't compile on Arduino 1.0.0 or 1.0.1).  What they don't tell you is that in order to get one of those older versions of the IDE to work you also have to hunt down and install a bunch of other out-dated software.

I'm running Ubuntu 12.04.

Ron Bean

unread,
Aug 11, 2012, 1:31:18 PM8/11/12
to milwaukee...@googlegroups.com
>The Marlin page at GitHub says that you have to use version 0022 (and
>someone on a forum said 0023 works) of the Arduino IDE to compile the
>Marlin code because of some incompatibilities with more recent versions of
>the IDE (I tested that idea and it's true- Marlin won't compile on Arduino
>1.0.0 or 1.0.1).

What specifically doesn't work? It might be easier to try to fix the
code.


Pete Prodoehl

unread,
Aug 11, 2012, 2:58:15 PM8/11/12
to milwaukee...@googlegroups.com

There are known issues with the RepRap firmware(s) and the latest Arduino IDE, so 0022 or 0023 is recommended.

(On Mac OS X all I had to do was download and run the older version, there was no other mucking about.)

Did you try Sprinter as well as Marlin?

I'm hoping we can figure it out at the Meetup tomorrow.


Pete

Ron Bean

unread,
Aug 11, 2012, 3:20:58 PM8/11/12
to milwaukee...@googlegroups.com
>There are known issues with the RepRap firmware(s) and the latest Arduino
>IDE, so 0022 or 0023 is recommended.

Do you know what the issues are?
I wonder if anyone has tried compiling it under Eclipse.


Ron Bean

unread,
Aug 11, 2012, 3:32:20 PM8/11/12
to milwaukee...@googlegroups.com
Interesting note from a year ago:
https://github.com/ErikZalm/Marlin/pull/36

It says the errors are all in the SDcard and LCD sections, due to
changes in the libraries. What happens if you comment out those
sections?

It might also be possible to compile with the old libraries.


Royce Pipkins

unread,
Aug 11, 2012, 3:36:52 PM8/11/12
to milwaukee...@googlegroups.com
How big is the code base? I had to change a few things in the 1.0 on
my code, but it wasn't that hard. Perhaps we can just change it match
the new libraries.

I can show you how to download a hex file without the IDE. But you do
have to be able to compile successfully before you'll get that hex
file.
> --
>
>
>



--
The real problem is not whether machines think but whether men do.
B. F. Skinner

Jerry [HM]

unread,
Aug 11, 2012, 5:49:19 PM8/11/12
to milwaukee...@googlegroups.com
Usually libs that are NOT 1.0 compatible (or vise versa) need a few simple lines of code.. as the Arduino IDE has changed the names of some of the core files.
 
 
 
--



Jerry [HM]

unread,
Aug 11, 2012, 5:50:37 PM8/11/12
to milwaukee...@googlegroups.com
maybe try updating those library that are older? (like the SDFAT lib (or whatever it is using)...same with the LCD libs..)
----- Original Message -----
From: Ron Bean
--



The_Digital_Dentist

unread,
Aug 11, 2012, 6:15:16 PM8/11/12
to milwaukee...@googlegroups.com
I found this:


which some might find useful.  You select options and it will build the Marlin hex file on-line and give you a hex file to DL and burn to your controller board.
It only modifies the config.h file and not the pins.h file where you define LCD connections, emergency stops, etc.

Gary Kramlich

unread,
Aug 12, 2012, 2:29:57 AM8/12/12
to milwaukee...@googlegroups.com
if you're on a debian based distro, "apt-get build-depends arduino" should get you everything to build an old version (hopefully)

--
 
 
 

Jim Rawson

unread,
Aug 12, 2012, 6:59:48 AM8/12/12
to milwaukee...@googlegroups.com
Nothing really to contribute here,except I noticed that Dentists don't use the common idiom  " It's like pulling teeth", but instead use  "It's like pulling potatoes".

Ed Hagopian

unread,
Aug 12, 2012, 8:22:09 PM8/12/12
to milwaukee...@googlegroups.com
I'm rolling Marlin on mine with Arduino 022 on an Ardy Mega with Ramps 1.4 and it's been good. At least on a pc with windows.

The_Digital_Dentist

unread,
Aug 12, 2012, 10:10:43 PM8/12/12
to milwaukee...@googlegroups.com
OK!  Now it's really ALIVE!  Special thanks to Gary for helping out at the 3D printing meetup at bucketworks.

For anyone interested, the compile problem was traced to a macro in the Arduino IDE that defined a math rounding function.  It seems that the C compiler also had a "round" function defined (maybe a recent addition?) and the two were in conflict.  Gary commented out the Arduino macro and it compiled just fine after that.

I have tweaked Marlin for the specifics of my machine and it seems to be working now.  I can position all three axes, the endstops (min and max) work fine, the LCD, encoder, and beeper all work.  SD card is detected, but I haven't tested it further.  The kill switch doesn't seem to work.  

I loaded the calibration cube file from pronterface and hit print and the machine took off and ran with it.

Time to mount the electronics in a box, wire the machine and dress the cables and get it ready for the extruder.

Ron Bean

unread,
Aug 12, 2012, 10:20:23 PM8/12/12
to milwaukee...@googlegroups.com
>The kill switch doesn't seem to work.

I'd suggest having it kill the power to the stepper drivers.
IMHO there shouldn't be any software in the loop.

The_Digital_Dentist

unread,
Aug 12, 2012, 11:31:58 PM8/12/12
to milwaukee...@googlegroups.com, Ron Bean
I think it's just finding the right place in the firmware to put the pin definition.  As far as I know it drives a hardware interrupt that kills motors, extruders, hot ends and heated bed.  I'll let you know when I have it working.

I'll post some video of it running shortly.

The_Digital_Dentist

unread,
Aug 12, 2012, 11:33:34 PM8/12/12
to milwaukee...@googlegroups.com
That's because pulling teeth is easier than debugging software (for me, anyway).

Random Conxstructs

unread,
Mar 11, 2015, 1:41:12 AM3/11/15
to milwaukee...@googlegroups.com
link is dead

Random Conxstructs

unread,
Mar 11, 2015, 1:43:18 AM3/11/15
to milwaukee...@googlegroups.com
Im currently having issues converting to the hex file.... can i get one of yall to do it for me? im having issues with linux...( just switched from windows)
Reply all
Reply to author
Forward
0 new messages