View Full Version : [Question(s)] unable to compile ArbotiXBlink

10-24-2013, 06:23 AM
Hi all!

I just started from scratch and tried to load some Arbotix-Code into my Atmega644p.

The best way would be probable the arbotix-quick-start:

S (http://learn.trossenrobotics.com/arbotix/7-arbotix-quick-start-guide)o I did.

I installed the Arduino environment (version 1.0.5) and downloaded the Arbotix-M Hardware and Libs:

The content went into ~/sketchbook .

Then I started arduino, the libs were listed and also the hardware. I simply opened the ArbotiXBlink via File -> Sketchbook -> ArbotiX Sketches -> Test Sketches -> ArbotiXBlink .

Next I selected the hardware via Tools -> Board -> Arbotix .

Finally "Verify / Compile" which returns with:

/home/erazor/sketchbook/hardware/arbotix/cores/arbotix/Print.cpp: In member function ‘size_t Print::print(const __FlashStringHelper*)’:/home/erazor/sketchbook/hardware/arbotix/cores/arbotix/Print.cpp:44:9: error: ‘prog_char’ does not name a type
/home/erazor/sketchbook/hardware/arbotix/cores/arbotix/Print.cpp:47:23: error: ‘p’ was not declared in this scope

So I stated my vi and added the missing prog_char typedef in Print.cpp:

#include <avr/pgmspace.h>
typedef char PROGMEM prog_char;

That gives me a new compile error:

/home/erazor/sketchbook/hardware/arbotix/cores/arbotix/HardwareSerial.cpp:133:15: error: attempt to use poisoned "SIG_USART1_RECV"

So a second round for vi. It seems like the HardwareSerial.cpp will give an error whenever SIG_USART1_RECV is already defined.
Well, that's probably the point where I suppose something is pretty weird with my setup.

Did I download the wrong libs or why am I having this issues?

Thanks for your help!

10-24-2013, 09:12 AM
I did not redo everything on my machine, but I am running Arduino 1.0.5, I redownloaded the Arbotix stuff with the link you gave. I renamed my current version of the Hardware stuff to Save and copied in the current one from the zip file. Did not worry about any of the libraries as the test sketch does not use any. I double clicked on the INO file, which brought up the IDE, selected Arbotix and it compiled fine for me.

But I am using Windows. My guess is that you are using Linux, so may try on my Portable running Linux Mint and update.


Update: Also compiled on Linux Mint

10-24-2013, 09:38 AM
2nd update: for the fun of it, I then wondered about what version of Arduino would be installed if I used the apt-get route, so I did:
sudo apt-get install arduino

It downloaded lots of stuff including arduino 1.0.3. When I then simply type arduino at a command prompt it bring this version up. If I load the blink sketch, it errors like you mentioned. However if I go and doubleclick on my 1.0.5 executable text file and load in terminal, it runs the 1.0.5 version and compiles the sketch.

10-24-2013, 09:58 AM
Kurt thanks for testing!

I played a bit with the versions and my system (Gentoo) pulls in version 1.0.5.

I downloaded the latest one via git and now its working without any issues so seems like it's something with 1.0.5.

So, probably it's time for some pynuke now :-)

10-24-2013, 03:37 PM
So KurtE, it sounds like 1.0.3 and the ArbotiX don't get along?

Erazor, so you were running 1.0.5, but still got the error?

10-24-2013, 04:16 PM
Actually not sure if it is the version of Arduino that is the issue, but more how it is installed?
My 1.0.5 was installed by going to the Arduino website, and downloading the package, and extracting the stuff into a directory on my desktop where I run Arduino from.

My 1.0.3 was actually installed by using the command: sudo apt-get install Arduino, which install lots of stuff including the actual Arduino, plus gcc, ... It was with this one that I had the issues mentioned. My guess is that if I downloaded the 1.0.3 directly from the Arduino site it would work...

10-25-2013, 12:50 AM
My 1.0.5 was on a gentoo install. And I had to install avr-gcc too which was not included in the package.

It's probably an issue with some libraries but I've not idea if Arduino comes with some modified libc headers or whatever.

I might be wrong but it seems like the git version from their webpage also just provided the GUI and not a custom gcc. All I saw was some java code when "compiling".

Do you have to install some kind of gcc on a windows machine?

Maybe my gcc is just to new...

10-25-2013, 01:01 AM
The website sais:

from Arduino IDE 1.0.1 a full working avr-gcc package is included

You will need to install some programs to use Arduino under Linux (the way you do this depends on your distribution):

avr-gcc-c++ (Else you will get this error: Cannot run program "avr-g++":j ava.io.IOException:Error=2: No such file or directory)

Version 4.7 have break some older standard and the arduino core class give some compiling error.

[email protected] ~> avr-gcc --version
avr-gcc (Gentoo 4.7.3-r1 p1.3, pie-0.5.5) 4.7.3

So it's probably a linux and Arduino issue which comes cos the install-script on my system does not install the gcc from Arduino and uses the local one.

The more I've to use Arduino the more I enjoy the free plain C coding without it ;)

10-25-2013, 11:56 AM
For what it is worth, When installing on Mint 15 (Ubuntu 13.04), you get:

[email protected] ~ $ sudo apt-get install arduino
[sudo] password for kurt:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
arduino-core avr-libc avrdude binutils-avr extra-xdg-menus gcc-avr libjna-java
Suggested packages:
arduino-mk avrdude-doc task-c-devel gcc-doc gcc-4.2 libjna-java-doc
The following NEW packages will be installed:
arduino arduino-core avr-libc avrdude binutils-avr extra-xdg-menus gcc-avr libjna-java
0 upgraded, 9 newly installed, 0 to remove and 271 not upgraded.
Need to get 26.6 MB of archives.
After this operation, 88.0 MB of additional disk space will be used.

So as you mentioned, it is probably not using any of the same libraries.

08-01-2014, 12:46 PM

I struck this same issue with Ubuntu 14.04 and Arduino 1.0.5

The following seems to have solved it for me, making the change to the /sketchbook/hardware/arbotix/cores/arbotix/arduino.h file :

08-14-2014, 07:47 AM
"I fixed" the ' error: attempt to use poisoned "SIG_USART1_RECV" ' error downloading the Arduino IDE AND unzipping it.

Using the synaptic version shows that error :confused:

10-23-2014, 07:22 AM

I struck this same issue with Ubuntu 14.04 and Arduino 1.0.5

The following seems to have solved it for me, making the change to the /sketchbook/hardware/arbotix/cores/arbotix/arduino.h file :

This seems to have worked for me also, thanks CreedyNZ! Maybe someday I'll figure out why, but for today I'll be happy.

10-23-2014, 08:37 AM
Yes the Arbotix Arduino tree is not anywhere up to date.

I have my own fork of their project, where I updated it to Arduino 1.0.5 code base awhile ago, which I thought they were going to pull it into the main fork. Recently I updated mine to now the 1.0.6 code base. Mine is up at:

Note: I have done some with my fork on both Windows 7 and Ubuntu. I believe I ran some tests on it after I updated my Intel Nuc to 14.04.


10-26-2014, 08:30 AM
Looked over your website, I'll have to keep it in mind!