Autore Topic: Valori Precalcolati E C64  (Letto 2383 volte)

Freshness79

  • Utente
  • **
  • Post: 128
  • Gioco Preferito: Dizzy collection
Valori Precalcolati E C64
« il: 21 Maggio 2009, 22:12:02 »
 Ieri sera stavo pensando a come poteva essere possibile elaborare la trasformata di fourier utilizzando una tabella precalcolata ed il povero Megahertz del nostro biscottone. La routine é ancora da sistemare ma permette già di ottenere alcuni risultati.
Vi propongo il source:

Codice: [Seleziona]
; Fast fourier transform with precalculated values

*=$1000

lda #<Data
sta $fb
eor #<Data
sta $fd
clc
sbc #$00
sta $fe
lda #>Data
sta $fc
ldx #$00 ; Contatore 8
ldy #$00 ; Contatore 5
mainloop
cpy #$00
bne stp1
lda ($fb),y
inc $fb
pha
lda $fb
cmp #<EndData+1
pla
bcs end1
stp1
asl
rol $fa
inx
iny
cpx #$05
bne stp2
pha
tya
pha
ldy #$00
lda $fa
bne stp3
sec
ror
ror
ror
stp3
sta ($fd),y
inc $fd
sty $fa
pla
tay
pla
ldx #$00
stp2
cpy #$08
bne end0
ldy #$00
end0
jmp mainloop
end1
rts


Data
byte $68,$41,$1A,$85,$D4,$78,$24,$F6,$C1,$EE,$78,$18,$50,$08,$2C,$61,$41,$3A,$24,$0C
byte $0B,$4B,$20,$11,$20,$69,$64,$40,$80,$00,$00,$26,$50,$05,$8D,$2B,$9E,$0B,$3D,$20
byte $73,$DC,$06,$3C,$13,$49,$68,$50,$14,$13,$A0,$68,$50,$30,$A7,$39,$5C,$47,$80,$89
byte $A1,$40,$C0,$82,$CF,$9D,$24,$10,$38,$AC,$05,$11,$22,$84,$80,$00,$00,$C2,$82,$12
byte $4B,$4A,$0A,$48,$A0,$80,$64,$F6,$14,$04,$2B,$01,$67,$CE,$92,$78,$20,$F9,$D0,$04
byte $7D,$A4,$17,$39,$E0,$80,$65,$44,$C8,$A0,$1B,$DC,$06,$04,$0C,$2D,$28,$59,$04,$01
byte $00,$00,$08,$16,$40,$4B,$01,$22,$CE,$8F,$01,$83,$42,$82,$AE,$04,$1E,$02,$24,$13
byte $0B,$82,$04,$C9,$EE,$48,$40
EndData
Attendo anche altre soluzioni!
 

iAN CooG

  • Utente
  • **
  • Post: 1774
    • http://iancoog.altervista.org
  • Gioco Preferito: Turbo Assembler, ActionReplay Monitor, DiskDemon
Valori Precalcolati E C64
« Risposta #1 il: 21 Maggio 2009, 22:42:06 »
 All'inizio non capivo.
Adesso ho tracciato.
Alla faccia, che bravo!

Questi sono i miei dati, sono di meno ma il risultato e' eloquente
Codice: [Seleziona]
Data
byte $7D,$28,$96,$BC,$06,$91,$66,$87,$16,$73,$00,$01,$3A,$04,$0D,$0C,$E6,$10,$11,$20
byte $21,$46,$59,$14,$52,$0D,$12,$07,$3D,$C0,$18,$60,$99,$14,$42,$28,$1A,$14,$81,$C5
byte $6B,$4A,$E7,$82,$65,$01,$D8,$92,$B1,$E0,$9C,$12,$53,$86,$73,$4B,$5E,$00,$40,$B2
byte $04,$6A,$56,$00,$68,$28,$1A,$90,$49,$27,$A8,$64,$40,$81,$81,$04,$CB,$A4,$BD,$C5
byte $04,$24,$F3,$C8,$2D,$68,$74,$97,$B8,$A0,$23,$ED,$22,$88,$45,$05,$8A,$E4,$C8,$05
byte $85,$64,$1A,$04,$04,$08,$23,$50,$B2,$AE,$8D,$4A,$02,$26,$74,$AC,$84,$1A,$3E,$45
byte $01,$41,$22,$B0,$34,$4D,$92,$08,$3E,$74,$00

EndData
-=[]=--- iAN CooG/HVSC^C64Intros ---=[]=-
- http://hvsc.c64.org - http://intros.c64.org -

Freshness79

  • Utente
  • **
  • Post: 128
  • Gioco Preferito: Dizzy collection
Valori Precalcolati E C64
« Risposta #2 il: 24 Maggio 2009, 22:57:30 »
 Attendo ancora altre proposte...
Per il momento, ottimizzando un po' ho tirato fuori questa sequenza:

Codice: [Seleziona]
byte $68,$50,$00,$00,$10,$28,$C6,$1A,$3C,$03,$41,$40,$E2,$CE,$75,$73,$C1,$34,$84,$09
byte $75,$0B,$22,$CE,$61,$A3,$C0,$10,$4E,$8F,$05,$11,$22,$84,$80,$00,$03,$4A,$15,$C4
byte $78,$27,$02,$C8,$2E,$D3,$E6,$F0,$25,$80,$84,$92,$D7,$82,$05,$98,$CA,$07,$15,$8C
byte $08,$24,$5A,$14