Installing on Ubuntu 12.04

Status
Not open for further replies.
Hi all

I am trying to install the programs I need to run teensy 2.0 on Ubuntu but I am completely lost. Does anyone know of a guide that I can follow for a complete beginner. I tried to follow the install on the website but aint a clue what I am doing.

Many thanks for some suggestions in advance.

Matthew
 
Ok I am lost as to what I am ment to do.

# This file must be placed at:
#
# /etc/udev/rules.d/49-teensy.rules (preferred location)
# or
# /lib/udev/rules.d/49-teensy.rules (req'd on some broken systems)

What file ? I have downloaded the gzip file and placed it on my desktop but have not unzipped it as of yet.

Please advise.

Thanks a million.

Matt
 
/etc/udev/rules.d/ is a directory that already exists on your system.

The file is the one you were looking at, with this stuff:

# This file must be placed at:
#
# /etc/udev/rules.d/49-teensy.rules (preferred location)

Here's the link:

http://www.pjrc.com/teensy/49-teensy.rules

While viewing that, use the File menu in your browser to save it. Name it "49-teensy.rules". Make a mental note of the location where you've saved it. Then use whatever program you prefer to copy file, to make a copy into the /etc/udev/rules.d/ directory. That directory requires root permissions to write.

Perhaps I should add code in the Teensy Loader to do this automatically? The tricky part, which I'm not very familiar with doing, is how to prompt the user to their password and obtain root permission to copy the file. If anyone reading this is a Linux programming expert, what's the best way to accomplish that, from a program like Teensy Loader that does not run with root permission, and isn't designed for security needed to run with root access?
 
Ok have the rules in the udev folder have double checked them and have unpacked the teensy controller on desktop but when I run the teensy program on desktop I come up with a program called Pypar2 this program then unpacks folders. Lets take some desktop shots and see if this makes sense to you......

By the way thanks a million for the all the help.

http://i1249.photobucket.com/albums/hh519/Matthew_Swart/teensypic_zpsdf86b305.png
http://i1249.photobucket.com/albums/hh519/Matthew_Swart/Pypar2_zps14e40bdf.png
http://i1249.photobucket.com/albums/hh519/Matthew_Swart/afterunpacked_zps77e2a371.png
 
I use Linux daily, but not Ubuntu's Unity interface, so I can't help you with what to click in Unity.

I can help you with the commands to type in a terminal window, which is basically the same on all Linux distros. Can you run the terminal program?

First, type this:

cd ~/Desktop/

That will change to the Desktop directory where you've downloaded all this stuff.

Before getting starting, you might delete everything you've already tried, so you're starting from a clean slate.

You need to download Arduino 1.0.2. The new 1.0.3 is not supported yet, so be sure to get version 1.0.2. Get it from www.arduino.cc. I can't tell from your screenshots if you're running 32 or 64 bits, so you'll need to figure out which version you have and then download the correct one.

Likewise, since I don't know which version you have, I have to make an assumption in these commands. I'll assume 32 bits. If you're using 64 bits, change these commands slightly for the filename with 64 bits.

After you've downloaded Arduino 1.0.2, type this command to extract it:

tar -xvzf arduino-1.0.2-linux.tgz

You'll see an incredibly long list of files print very rapidly.

Next, download the Teensyduino installer. It's available here. Make sure you get the one which matches your system (32 vs 64 bits):

http://www.pjrc.com/teensy/td_download.html

By default, the file will not have executable permissions. So type this command to make it executable:

chmod 755 teensyduino.32bit

Again, I don't know if you have 32 or 64 bit, so if you're using 64 bit, change this command to match the file you downloaded.

Then, to run the installer, type this:

./teensyduino.32bit

Click "Next", until you get to the part where you have to select the copy of Arduino to modify. Since this is all in your "Desktop" directory, double click it, and then highlight "arduino-1.0.2". The instant you highlight a copy of Arduino, the Next button will enable. Keep clicking Next until the install is done. You don't need the optional libraries, and if you later decide you do need some, just run the installer again to add them.

After you've finished the install, go back to the terminal window and type:

cd arduino-1.0.2

Then type this to run it

./arduino

You should see the Arduino window appear. The first thing to do is select Teensy 2.0 from the Tools > Boards menu. Then use File > Examples > 01.Basics > Blink to open the blink example.

Unfortunately, there is 1 more step needed on Linux. You must download and install (merely copy to a certain directory) the udev rules file. I described that above. If you don't have the rules file installed, everything will work up to this point. But when you click Upload, the Teensy Loader window will appear, but it will be unable to detect your board.

Hopefully this helps? There's probably a way to do all this stuff from within Ubuntu's Unity GUI, but I've never used it, so I just can't direct you on what to click. The command line within the terminal window can do everything, and the commands are essentially the same for all Linux systems.
 
Last edited:
You may also need to install the 32-bit libraries if you are on a 64-bit Unbunto system, since the compiler shipped with the Teensy releases was built elsewhere, and is only 32-bit. Ubunto does not install the 32-bit libraries by default when you install a 64-bit system.
 
You may also need to install the 32-bit libraries if you are on a 64-bit Unbunto system, since the compiler shipped with the Teensy releases was built elsewhere, and is only 32-bit. Ubunto does not install the 32-bit libraries by default when you install a 64-bit system.

That has not been my experience. I am running 64 bit Ubuntu. I have not added any 32 bit libraries that I am aware of.

My convoluted install process: I originally installed the ubuntu package 'sudo apt-get install arduino'. This gets an old version of Arduino installed. I then downloaded the beta9 zip file (64 bit) from Paul's web page, put it in /usr/share/arduino_1.0.2_b9 then edit the /usr/bin/arduino script to point to the correct directory and poof, I have a launcher and Icon for it in Ubuntu. This is with 12.04 and 12.10. At least with the Arduino environment, I have had no issues compiling and loading from my Ubuntu machine.

Keith
 
Ok guys now I have new error:


killerspec@I:~/Desktop$ ./teensyduino.32bit
killerspec@I:~/Desktop$ cd arduino-1.0.2
killerspec@I:~/Desktop/arduino-1.0.2$ ./arduino
./arduino: 22: ./arduino: java: not found

I am going to guess that I need to install java on this machine
 
Ok new problem but I have seen this when I tried to load this with windows. I have got arduino to load and have connected it to the Teensy when I try load it for the first time I get this error:


core.a(main.cpp.o): In function `main':
/home/killerspec/Desktop/arduino-1.0.2/hardware/teensy/cores/teensy/main.cpp:6: undefined reference to `setup'
/home/killerspec/Desktop/arduino-1.0.2/hardware/teensy/cores/teensy/main.cpp:8: undefined reference to `loop'
 
News update it seems that I have got it to work. The blink program works and I have tested it by changing the settings and all seems to be cool.

Now I have one more question does anyone know of a few newbie tutorials that I can cut my teeth on ?
 
Now I have one more question does anyone know of a few newbie tutorials that I can cut my teeth on ?

http://www.pjrc.com/teensy/tutorial2.html


You may also need to install the 32-bit libraries if you are on a 64-bit Unbunto system, since the compiler shipped with the Teensy releases was built elsewhere, and is only 32-bit. Ubunto does not install the 32-bit libraries by default when you install a 64-bit system.

That's necessary for Teensy 3.0, but not needed for Teensy 2.0.

It's also on my to-do list to build a newer toolchain on all 4 platforms (any maybe add Raspberry Pi as a 5th platform...)
 
int redPin = 12;
int greenPin = 15;
int bluePin = 14;
int orangePin = 11;

When I select Pin 11 the led on the board flashes and the led on my breadboard but if I select pin10 the led on the teensy stays lite and the led is very dim why is that.

Does anyone know off a tutorial for controlling a fan ..... like a computer fan. I wanna build a box for my desktop it is in a shed and have a whole in the shed as an inlet and out let for air to cool the system in the box but I don't want them to run all the time as I am on battery power in the shed and have other equipment that needs to run. I wanna put a temp control system in the box and have it switch on and off when to hot and cold.

Thanks for all the help and hope u all have a kick ass xmas
 
Status
Not open for further replies.
Back
Top