From: <an...@ki...> - 2010-05-20 11:46:53
|
Guys I have compiled and downloaded the image for the amforth core as it comes, using a hand tweaked set of device defs. But cant get a squeak out of the board. (atmega1280, on an arduino mega clone) Compilation is fine except for a single warning:- C:\Documents and settings\andy\Desktop\forthduino_3.8\core\devices/atmega1280.asm(192): warning: .cseg .db misalignment - padding zero byte ATmega1280 memory use summary [bytes]: Segment Begin End Code Data Used Size Use% --------------------------------------------------------------- [.cseg] 0x000000 0x01e7e0 1904 5908 7812 131072 6.0% [.dseg] 0x000200 0x000200 0 0 0 8192 0.0% [.eseg] 0x000000 0x000040 0 64 64 4096 1.6% Assembly complete, 0 errors. 1 warnings At the moment I am considering the list below. 1. I missed tweaking something in the code as it comes, Mathias suggested using polled serial comms instead of ISR's. Do I need to tweak something to make this so, or does it do it already? There may be no response from the serial link but the board may actually be running. 2. I have got something wrong with the fuses and addresses etc and the board just is'nt running. Programing all verifies etc and is done from AVR Studio, 4.18 with an AVR ISP Mk2. BOD, Disabled SPI, Enabled Boot Flash 4k, start $F000 (to match .equ max_dict_addr = $F000) Full swing osc , slow rise time with max delays 3. I have got something wrong with the hardware defs or the tweaks to the app asm file and the code just is'nt running, crashed. To help with the debugging, I need to turn on the debugging LED that is connected to port B7. Where and how is best to place the code? Where: as in it will run at boot and turn on the LED showing something is live. Where it can stay once I have completed and become part of the templates in the distribution. (not somewhere it will interfere with someone else's implementation of a 1280 based non arduino board, will blink it rather than leave it on eventualy) How: as in, just in line assembler at the indicated spot, or do something that approaches the assembler approximation of forth. 40 DDRB c! 40 PORTB c! Whilst ultimately blinking would be nice for now I am happy with turn the LED on. I am not really looking for someone to do this for me here, just point me in the right Amforth compatible direction. All input and advice welcome. Cheers Andy Kirby |