cancel
Showing results for 
Search instead for 
Did you mean: 

Please help, interrupt cannot work properly.

alanlai1
Associate II
Posted on February 20, 2004 at 01:54

Please help, interrupt cannot work properly.

3 REPLIES 3
alanlai1
Associate II
Posted on February 17, 2004 at 00:20

We have written a small program which generate square wave by interrupt (toggle, 2ms Hi, 2ms Lo)

But we found that the width is not accuracy.

Does anyone meet this problem before?

How can we solve this? Please suggest.

________________

Attachments :

timer.asm : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I043&d=%2Fa%2F0X0000000bVM%2F3LbSrNSIXvL9ZF7DTKMrjaFR.ldsxW4lUBkwbPD9e1g&asPdf=false
atoniolo
Associate
Posted on February 18, 2004 at 13:35

Hi,

can you specify what SW and HW are you using?

jatin
Associate II
Posted on February 20, 2004 at 01:54

Please check the following points;

1// In your software, You have a mixed configuration for the PortB(some i/o's in I/P and some are in O/P). Do not use bset/bres instructions for this port. To toggle the port pin use OR/AND instructions.

2// Ensure that, the cpu frequency is 8Mhz.