Why are you even messing with asm right now? It seems to be causing you a
fair amount of grief.
I downloaded Atmel Studio 4.0 and the service pack (->4.498), created a new
GCC project (downloaded and installed WinAvr), created the new project,
added some code, hit build and run and was immediately in the debugger
(simulator) and it just worked.
I was (given that I have been working with this stuff for 8 years now)
completely shocked at how easy and fast it was.
Now, if Studio can handle multiple files I'll really be pleased....
YES! It does. Nice.
-----Original Message-----
From: AVR-Chat@yahoogroups.com [mailto:AVR-Chat@yahoogroups.com] On Behalf
Of Thomas Keller
Sent: Saturday, December 30, 2006 11:06 AM
To: AVR-Chat@yahoogroups.com
Subject: Re: [AVR-Chat] now what?
Easy for you to say ! *grin*
include "tn25def.inc"
; Define here the variables
;
.def temp =r16
; Define here Reset and interrupt vectors, if any
;
RESET:
rjmp START
reti ; Addr $01
reti ; Addr $02
reti ; Addr $03
reti ; Addr $04
reti ; Addr $05
reti ; Addr $06 Use 'rjmp myVector'
reti ; Addr $07 to define a interrupt vector
reti ; Addr $08
reti ; Addr $09
reti ; Addr $0A
reti ; Addr $0B This is just an example
reti ; Addr $0C Not all MCUs have the same
reti ; Addr $0D number of interrupt vectors
reti ; Addr $0E
reti ; Addr $0F
reti ; Addr $10
; Program starts here after Reset
;
START:
; this table povides the data for the intensity curve needed for
; xxxxxxxxxxxxxxx.
.dseg
TABLE:
; .db 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 2, 3, 3, 4, 5, 6, 6
; .db 8, 9, 10, 11, 13, 14, 16, 18, 20, 22, 24, 26, 29, 31, 34, 36
; .db 39, 44, 48, 52, 55, 59, 62, 66, 70, 74, 78, 82, 86, 90, 94, 99
; .db 103, 108, 112, 117, 121, 126, 130, 135, 140, 144, 149, 153
; .db 158, 163, 167, 172, 176, 180, 185, 189, 193, 197, 201, 205
; .db 209, 212, 216, 219, 223, 226, 229, 232, 234, 237, 239, 242
; .db 344, 346, 247, 249, 250, 252, 253, 254, 255, 255, 255
;
.cseg
BEGIN:
ldi r31, 0x00 ; set up upper WGM byte
out WGM01, r31 ; and once again
ldi r31, 0x03 ; set upo to set
waveform configuration
out WGM00, r31 ; output to appropriate control
register
;
; set up timer delay for .01 second
;
; counter clock will be prescaled by 1024 to make the .01 second
count easier
;
ldi r31, 0x38 ; load low byte of delay count
out TCNT0, r31 ; output to counter/timer 0-
.exit
Ned Konz wrote:
>
> Why don't you post your code?
>
> --
> Ned Konz
> ned <mailto:ned%40bike-nomad.com>
>
> .
>
>
> ------------------------------------------------------------------------
>
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.1.409 / Virus Database: 268.16.0/610 - Release Date: 12/30/2006
>
Yahoo! Groups LinksMessage
RE: [AVR-Chat] now what?
2007-01-03 by larry barello
Attachments
- No local attachments were found for this message.