Author Topic: Linux user having problems  (Read 3128 times)

0 Members and 1 Guest are viewing this topic.

Offline epicbattleTopic starter

  • Jr. Member
  • **
  • Posts: 8
  • Helpful? 0
Linux user having problems
« on: November 10, 2008, 11:25:42 PM »
Ok, I'm using KontrollerLab through Ubuntu and I have avrdude. I cannot figure out how to tell the computer where the programmer is in the computer. Wine AVR Studio keeps crashing. Is anyone familiar with Linux I can start a dialog with to help me get everything to work? I am new to Linux and robot building so I am trying to get adjusted to both.  Thanks guys.

Offline Half Shell

  • Robot Overlord
  • ****
  • Posts: 225
  • Helpful? 0
Re: Linux user having problems
« Reply #1 on: November 10, 2008, 11:34:01 PM »
You need to answer this question first - is the programmer a USB, Serial, or Parallel programmer?

If it is USB, the programmer is at /dev/ttyUSB#, where # is the USB port (starts at 0).

If it is Serial, then it is /dev/ttyS# (once again, starts at 0)

Parallel - not too sure. Never had a computer with a parallel port in the past.... bajlilion years. I'm sure it's something like ttyP#.

Offline Commanderbob

  • Robot Overlord
  • ****
  • Posts: 146
  • Helpful? 2
  • Embeddedmicro.com
    • Embedded Micro
Re: Linux user having problems
« Reply #2 on: November 11, 2008, 02:15:08 PM »
I am on Ubuntu as well and use avrdude. I have not used kontrollerlab but with avrdude you can use something like

Code: [Select]
avrdude -c avrispmkII -P usb -p m644 -U prog.hex
to program prog.hex into a ATmega644 with an AVRISP mkII.

If you are having problems try
Code: [Select]
sudo avrdude -c avrispmkII -P usb -p m644 -U prog.hex
if that works then go to this thread and fix the permissions of the AVRISP mkII so you can use it as a regular user.
http://ubuntuforums.org/showthread.php?t=901891

You will need to make a the file 45-avr.rules in /etc/udev/rules.d. Then add this to it.
Code: [Select]
# Atmel AVRISP mkII rules

ACTION=="add", SUBSYSTEM=="usb", SYSFS{idVendor}=="03eb", SYSFS{idProduct}=="2104", GROUP="flip", MODE="0660"

You can also add
Code: [Select]
# Atmel JTAGICE mkII rules

ACTION=="add", SUBSYSTEM=="usb", SYSFS{idVendor}=="03eb", SYSFS{idProduct}=="2103", GROUP="flip", MODE="0660"

If you have a JTAGICE mkII.

This took me a long time to figure out so feel free to ask questions.

I use make to compile and burn the code onto the AVR. If you want an example makefile I can post it. They are set up so I can type

make
to compile the code and

make install
to flash the code onto the AVR

Justin

 

SMF spam blocked by CleanTalk