Forum Menu




 


Log in Problems?
New User? Sign Up!
AVR Freaks Forum Index

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
zoltanvoros
PostPosted: Oct 04, 2011 - 07:42 PM
Hangaround


Joined: Aug 06, 2007
Posts: 275


Hi All,

I was wondering whether someone could shed some light on the following problem. I would like to use the two DAC channels on PORTB (these would be PIN2, and PIN3), but at the same time, I would also need a general purpose digital output line on PIN7. However, when I try to do this, it simply does not work. When I move the digital output to PORTC or PORTA, everything is OK, so I conclude that the code is right. (Nothing re-sets the output direction on PORTB.)
My question is whether the digital output lines on PORTB can be used in conjunction with the DAC.
Cheers,
Zoltán
 
 View user's profile Send private message  
Reply with quote Back to top
Slordak
PostPosted: Oct 04, 2011 - 08:04 PM
Wannabe


Joined: Sep 22, 2011
Posts: 91


The issue is that you have a conflict with the XMEGA JTAG, which uses pins PB4 - PB7. You'll either have to disable the JTAG interface (if this is acceptable), or use different pins.
 
 View user's profile Send private message  
Reply with quote Back to top
zoltanvoros
PostPosted: Oct 04, 2011 - 08:27 PM
Hangaround


Joined: Aug 06, 2007
Posts: 275


Thanks for the quick reply! I don't need JTAG, so I could definitely get rid of that. But I could not figure out how to set the fusebytes on the xmega using avrdude. Any comments on that? Is it possible at all, or should I do it through avrstudio?
Thanks,
Zoltán
 
 View user's profile Send private message  
Reply with quote Back to top
Slordak
PostPosted: Oct 04, 2011 - 09:08 PM
Wannabe


Joined: Sep 22, 2011
Posts: 91


It's probably safer (with less chance of accidental error) to do it using AVR Studio.

I haven't tried it with AVRDUDE myself, but the last time I used AVRDUDE to program my XMEGA, it blew away the bootloader even though I thought I was only programming the application section. It might have been user error, but it may also be that AVRDUDE support for the XMEGA is incomplete.
 
 View user's profile Send private message  
Reply with quote Back to top
zoltanvoros
PostPosted: Oct 05, 2011 - 07:32 AM
Hangaround


Joined: Aug 06, 2007
Posts: 275


AVRDUDE can program the xmega without any problems, but if cannot write into the boot section. You might have to patch the source, and compile it for yourself. See the link.
http://code.google.com/p/avr-xboot/wiki/Documentation
Cheers,
Zoltán
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT + 1 Hour
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2006 The PNphpBB Group
Credits