From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Robert Cragie" To: "Huang Qiang" Cc: "eCos" Subject: RE: [ECOS] Strange Problem in cyg_thread_delay( )? Date: Thu, 26 Apr 2001 02:43:00 -0000 Message-id: References: <20010423130822.E2129@biferten.ma.tech.ascom.ch> X-SW-Source: 2001-04/msg00427.html I have had a look at the Samsung chip user manual and the Evaluator manual, and would suggest the following: 1) Check IOPCON is set correctly, especially with regard to interrupts; it may be possible that you are getting a spurious interrupt by writing to P8. 2) Check IOPMODE is correctly set for P4:7 (I presume it is or else you wouldn't have seen any LEDs lit). 3) It should be OK to use 'unsigned' as the type, as this is what ARM use. 4) As other people have suggested, and as it states in the ARM Evaluator manual, use a read modify write operation on IOPDATA: *IOPDATA = (*IOPDATA & ~0xF0) | (dispcnt << 4); HTH Robert Cragie Design Engineer Jennic Ltd. Furnival Street Sheffield S1 4QT United Kingdom Tel: +44 (0) 114 281 4512 Fax: +44 (0) 114 281 2951 mailto:rcc@jennic.com http://www.jennic.com > -----Original Message----- > From: ecos-discuss-owner@sources.redhat.com > [ mailto:ecos-discuss-owner@sources.redhat.com]On Behalf Of Andrew Lunn > Sent: 23 April 2001 12:08 > To: Huang Qiang > Cc: eCos > Subject: Re: [ECOS] Strange Problem in cyg_thread_delay( )? > > > On Mon, Apr 23, 2001 at 12:03:05PM +0100, Huang Qiang wrote: > > Dear all: > > I am using ARM Evaluator7T . My test program has a sigle thread > > runnning, while I call cyg_thread_delay(200) each time in the > thread (loop). > > It pass the first and second call to the cyg_thread_delay(200), > but halted > > at the third call to the cyg_thread_delay. What's wrong with > it? Can anyone > > help me? > > Thanks a lot! > > james > > Given the little information you have provided there could be lots of > possibilites.... > > Have you started the schedular? > Is your stack big enough? > Have you memset(0,0,10000); > > Have you built eCos with assertions enables in package infra? That may > help. > > Supply more details and then we may be able to help. > > Andrew