beginning with VUSB.. need help

General discussions about V-USB, our firmware-only implementation of a low speed USB device on Atmel's AVR microcontrollers
Post Reply
Zaigham Khalid

beginning with VUSB.. need help

Post by Zaigham Khalid » Thu Aug 12, 2010 8:18 pm

Hi..
I am just beginning with VUSB.. I downloaded the package from objective development web and gave a try to custom-class example.. In the "Building the firmware" section of readme file (in second para), it is written "Type "make hex" to build main.hex" . I can't understand that where I need to type it. i.e where I need to type "make hex" to build the project...

I also tried to add .C files , .h files,make file and files in usbdrv folder in a AVR studio project .But I got errors.. VUSB wiki documents link is also not working.. Please can anyone make a tutorial for beginners in VUSB.. I have previously made several AVR projects in assembly and codevision AVR but have just gotten stuck here..

I am using windows platform.

frank26080115
Rank 2
Rank 2
Posts: 43
Joined: Fri Jun 19, 2009 4:43 pm

Re: beginning with VUSB.. need help

Post by frank26080115 » Thu Aug 12, 2010 8:40 pm

if you are new to C, you need to get familiar with "make", "makefiles" and compiling C projects in general. That command is meant to be typed into the command line or console.

To use AVR Studio with V-USB, only add usbdrv.c and usbdrvasm.S into the project, not the other stuff you mentioned

Vaidotas
Posts: 5
Joined: Thu Aug 12, 2010 9:21 am

Re: beginning with VUSB.. need help

Post by Vaidotas » Tue Aug 17, 2010 8:45 am

Hello,
I'm begginer with v-usb too. The problems of making hex files of examples, like PowerSwitch, Automator. It's no problem, then project is using ports which isn't in my uC, i just change it or delete ( if it is funkction to do something, like turn on led). The problem is then I' compiling project, every time it shows me that i missing function "usbCrc16Append", ant i don't seen ever how to write this function, so the only thing to do is to make "//" before function in usbdrv.c file. Is there other solution?
I'm using Attiny26 uC with 12Mhz crystal, and i set frequency F_CPU 12000000L. Is is good?

Thank you,
Vaidotas.

Vaidotas
Posts: 5
Joined: Thu Aug 12, 2010 9:21 am

Re: beginning with VUSB.. need help

Post by Vaidotas » Tue Aug 17, 2010 1:42 pm

I have one more question. I was made USBASP programmer, it works nice, computer recognize it, but if i compile hex file using source, it is smaller and does not works. Why it's happening? How to make hex file from source. I'm using AVR Studio 4.
Thank you.

_frank26080115

Re: beginning with VUSB.. need help

Post by _frank26080115 » Wed Aug 18, 2010 7:07 pm

did you compile usbdrvasm.S ?

Vaidotas
Posts: 5
Joined: Thu Aug 12, 2010 9:21 am

Re: beginning with VUSB.. need help

Post by Vaidotas » Wed Aug 18, 2010 9:57 pm

the problem was including files to project, but now it's solved. Another problem is with Host software, which file is describing usb_int() and other functions? I try to include libusb library but i failed. So my question is which file describes all this functions an where i can get it, becouse i failed with Libusb-win32, I just can't find files I need... please help me.
Thank You, Vaidotas.

_frank26080115

Re: beginning with VUSB.. need help

Post by _frank26080115 » Wed Aug 18, 2010 10:23 pm

usbdrv.h and http://vusb.wikidot.com/driver-api describes functions

device firmware has nothing to do with libusb

Vaidotas
Posts: 5
Joined: Thu Aug 12, 2010 9:21 am

Re: beginning with VUSB.. need help

Post by Vaidotas » Thu Aug 19, 2010 9:49 am

Thank You _frank26080115, but this link is for device firmware, I solved my problem of compiling program. I need files to include in Host software, becouse functions like usb_int() is not described (usbInit() is in firmware, usb_init() in software). And I don't find files there is this function ( and others also).
Thank You,
Vaidotas.

chandantiwary
Posts: 1
Joined: Sun Aug 22, 2010 2:42 pm

Re: beginning with VUSB.. need help

Post by chandantiwary » Sun Aug 22, 2010 2:51 pm

hi everyone.
I am trying to make a AVR USBASP PROGRAMMER.the circuit has been completed as i got the printed boards.Its working and is 100% checked.I have also burnt that firmware along with the fuse bits.still the programmer is not working.can any one help me put?

_frank26080115

Re: beginning with VUSB.. need help

Post by _frank26080115 » Mon Aug 23, 2010 6:43 pm

Vaidotas wrote:Thank You _frank26080115, but this link is for device firmware, I solved my problem of compiling program. I need files to include in Host software, becouse functions like usb_int() is not described (usbInit() is in firmware, usb_init() in software). And I don't find files there is this function ( and others also).
Thank You,
Vaidotas.


http://libusb.sourceforge.net/doc/
http://libusb.sourceforge.net/doc/function.usbinit.html

Post Reply