"command not found" driving me crazy..


11 posts
by geppetto » Sat Nov 10, 2012 4:03 pm
Trying to get my Pi to run the software and timing for my Ham Radio beacon transmitter..
The operation is via USB to the beacon rig..

Followed the instructions for setting up on Linux from the beacon kit site..
http://docs.etherkit.com/OpenBeacon/Client_Software_Usage_Guide

Downloaded the linux file..
Made a directory using "mkdir" to put it in..
Set the file to be executable in permissions..
cd to the directory and "ls" shows the openbeacon file is in there in green lettering...
typed in "sudo ./openbeacon" and I just get..
"bash: openbeacon : command not found"

Total Linux noob and can't understand why this file won't run..

Grateful for any help on this folks...

Regards
Philip
Posts: 19
Joined: Mon Sep 19, 2011 8:03 am
by SN » Sat Nov 10, 2012 4:09 pm
not sure but try a sudo su - first which will get you to root
make sure you're still in right folder and cd there if not
and then try ./openbeacon
Steve N – binatone mk4->intellivision->zx81->spectrum->cbm64->cpc6128->520stfm->pc->raspi ?
User avatar
Posts: 1008
Joined: Mon Feb 13, 2012 8:06 pm
Location: Romiley, UK
by joan » Sat Nov 10, 2012 4:11 pm
If the previous doesn't work please post the result of

ls -l

in the directory you are running the command from.
User avatar
Posts: 4178
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK
by Serac » Sat Nov 10, 2012 4:18 pm
Had a quick look at the Openbeacon downloads - The executables are precompiled binaries aimed at x86-32 systems so will not work on a Pi (which requires ARM binaries). Suggest reading http://bobolink.tumblr.com/post/34027033829/bb-openbeacon for details on how to compile the software for the ARM board.
Posts: 124
Joined: Wed Jul 18, 2012 2:49 pm
by geppetto » Sat Nov 10, 2012 4:33 pm
Ahhhhhhh!
Told you I was a Linux noob :oops:
So the file won't work on the PI....
At least now I know what the problem is and I'm not going crazy...

Will get in touch with Jason at Etherkit and see if he can help out on this..

Many thanks folks, you're stars..

Regards
Philip
Posts: 19
Joined: Mon Sep 19, 2011 8:03 am
by bgirardot » Sat Nov 10, 2012 4:42 pm
Just to note those compile instructions are for cross compiling on a non arm computer.

I just compiled this on my RPi directly using:

sudo apt-get install libusb-dev
git clone git://github.com/etherkit/OpenBeacon
cd OpenBeacon/client/
gcc -Wall -o openbeacon openbeacon.c -lusb

compiled without errors or warnings, I don't know if actually works as I don't have the device. I already had git installed on my pi so you might need to install git first (sudo apt-get install git-core).
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by geppetto » Sat Nov 10, 2012 5:06 pm
Ok will have a try at doing that, thank you...

It doesn't need the hardware to run as typing ./openbeacon should just list up the options such as openbeacon status which brings up the status of a connected device..

Philip
Posts: 19
Joined: Mon Sep 19, 2011 8:03 am
by bgirardot » Sat Nov 10, 2012 5:10 pm
Oh ya, I should have mentioned that, it at least does return the usage text on mine.

After doing the GCC command, you will have created a binary file named openbeacon so in that same directory you should be able to test it by doing a ./openbeacon command

if it works, you can move the file to /usr/local/bin with:

mv openbeacon /usr/local/bin/

then the openbeacon command should work from anywhere
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by geppetto » Sat Nov 10, 2012 5:22 pm
WooooHoooo!

That worked... 8-)
Able to talk to and alter the data in the rig's chip...
Just got to sort out using Cron as suggested on the site for the timing and I'm up and running..

Can't thank you enough for sorting me out with this...

Regards
Philip G4JVF
Posts: 19
Joined: Mon Sep 19, 2011 8:03 am
by geppetto » Sat Nov 10, 2012 7:35 pm
Got the Crontab statement working so now my little beacon is fully operational
under the control of my Pi 8-)

Huge thanks again for all the help...

Philip
Posts: 19
Joined: Mon Sep 19, 2011 8:03 am
by bgirardot » Sat Nov 10, 2012 9:03 pm
Glad to hear it is all working
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland