From: pito <pi...@vo...> - 2010-07-09 16:22:37
|
Hi dear friends, when I enable interrupt this works well: decimal 2variable ticker variable seconds 262144. 2constant clkpi ( clks per interrupt = 256*prescaler ) 1. ticker 2! 0 seconds ! \ overflow2 interupt service routine \ ! not optimised yet : tick_isr ticker 2@ clkpi d- ticker 2! ticker 2@ clkpi d< if f_cpu ticker 2@ d+ ticker 2! 1 seconds +! then ; However with 2variable "seconds" definition: decimal 2variable ticker 2variable seconds 262144. 2constant clkpi ( clk per interrupt = 256*prescaler ) 1. ticker 2! 0. seconds 2! \ overflow2 interupt service routine \ ! not optimised yet : tick_isr ticker 2@ clkpi d- ticker 2! ticker 2@ clkpi d< if f_cpu ticker 2@ d+ ticker 2! 1. seconds 2@ d+ seconds 2! then ; it crashes in such a way I have to reflash rom to get access to system. What is the trick here? I've tried : 2variable create 0 , 0 , ; as well as : 2variable here 2 cells allot constant ; Thanks a lot, Pito |
From: Matthias T. <mt...@we...> - 2010-07-09 18:26:19
|
Hi Pito, > it crashes in such a way I have to reflash rom to get access to system. > What is the trick here? Well, it crashes outside of any interrupt as well. I've got no idea why so far. And it's way too hot outside... Sorry Matthias |
From: pito <pi...@vo...> - 2010-07-09 18:58:35
|
Does your dev system stop working when outside 30degC? (:-))). P. ----- PŮVODNÍ ZPRÁVA ----- Od: "Matthias Trute" <mt...@we...> Komu: "Everything around amforth" <amf...@li...> Předmět: Re: [Amforth-devel] My issue with 2variable in int_isr Datum: 9.7.2010 - 20:26:08 > Hi Pito, > > > > it crashes in such a way I have to reflash rom to > > get access to system. > > > What is the trick here? > > Well, it crashes outside of any interrupt as well. > I've got > no idea why so far. And it's way too hot outside... > > Sorry > Matthias > |
From: <an...@ki...> - 2010-07-09 19:13:34
|
I don't know about the tronics but I certainly loose the urge to try. On 09/07/10 19:58, pito wrote: > Does your dev system stop working when outside 30degC? (:-))). P. > > ----- PŮVODNÍ ZPRÁVA ----- > Od: "Matthias Trute" <mt...@we...> > Komu: "Everything around amforth" <amf...@li...> > Předmět: Re: [Amforth-devel] My issue with 2variable in int_isr > Datum: 9.7.2010 - 20:26:08 > >> Hi Pito, >> >> >>> it crashes in such a way I have to reflash rom to >>> get access to system. >>>> What is the trick here? >> >> Well, it crashes outside of any interrupt as well. >> I've got >> no idea why so far. And it's way too hot outside... >> >> Sorry >> Matthias >> > > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by Sprint > What will you do first with EVO, the first 4G phone? > Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first > _______________________________________________ > Amforth-devel mailing list > Amf...@li... > https://lists.sourceforge.net/lists/listinfo/amforth-devel > |
From: Matthias T. <mt...@we...> - 2010-08-07 11:56:33
|
Hi Pito, it took quite a while, sorry for that > However with 2variable "seconds" definition: > > decimal > 2variable ticker > 2variable seconds > 262144. 2constant clkpi ( clk per interrupt = 256*prescaler ) > 1. ticker 2! > 0. seconds 2! > \ overflow2 interupt service routine > \ ! not optimised yet > : tick_isr > ticker 2@ clkpi d- ticker 2! > ticker 2@ clkpi d< if f_cpu ticker 2@ d+ ticker 2! > 1. seconds 2@ d+ seconds 2! > then ; > > it crashes in such a way I have to reflash rom to get access to system. > What is the trick here? well, a small bug leads to the error: amforth does not compile double cell numbers into the colon words, only single cell constants. I have no fix yet (still working on it). A workaround is a definition like : double1 1. ; and use of the double1 instead of 1. ... double1 seconds 2@ d+ seconds 2! ... that works for me with your code (without crash and increasing seconds after many tick_isr calls). Matthias |
From: Matthias T. <mt...@we...> - 2010-08-07 12:03:09
|
Hi again, > : double1 1. ; oops. I meant 1. 2constant double1 sorry for the confusion Matthias |
From: pito <pi...@vo...> - 2010-08-07 19:47:25
|
Hi Matthias, much cooler outside again (:-)). Thanks for the info.Pito. ----- PŮVODNÍ ZPRÁVA ----- Od: "Matthias Trute" <mt...@we...> Komu: "Everything around amforth" <amf...@li...> Předmět: Re: [Amforth-devel] My issue with 2variable in int_isr Datum: 7.8.2010 - 14:02:59 > Hi again, > > > : double1 1. ; > > oops. I meant > > 1. 2constant double1 > > sorry for the confusion > > Matthias > |