custom timer1 not work

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 6.

Moderator: Benj

User avatar
Francisco Cabrera
Posts: 47
Joined: Sat Mar 19, 2016 4:56 pm
Location: Canary Island
Has thanked: 23 times
Been thanked: 7 times
Contact:

custom timer1 not work

Postby Francisco Cabrera » Fri Oct 27, 2017 7:36 am

Hi friends, the option custom timer1 something is badly because it does not work, they can help me, thank you.
Attachments
general.fcfx
(8.04 KiB) Downloaded 21 times

User avatar
Benj
Matrix Staff
Posts: 12488
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 3421 times
Been thanked: 3357 times
Contact:

Re: custom timer1 not work

Postby Benj » Fri Oct 27, 2017 11:19 am

Hello,

In your interrupt handler you currently have this.

Code: Select all

if (pir1 y (1 << TMR1IF)) 


this should instead be like this.

Code: Select all

if (pir1 & (1 << TMR1IF)) 
These users thanked the author Benj for the post:
Francisco Cabrera (Fri Oct 27, 2017 12:32 pm)
Rating: 5.88%
 

User avatar
Francisco Cabrera
Posts: 47
Joined: Sat Mar 19, 2016 4:56 pm
Location: Canary Island
Has thanked: 23 times
Been thanked: 7 times
Contact:

Re: custom timer1 not work

Postby Francisco Cabrera » Fri Oct 27, 2017 12:31 pm

Thank you bemg for answering, I have modified the mistake, and the interruption does not work.... :(
Do you see well everything else? .... if I fit interruption tmr1 without being custom, in the same program it works perfectly simulating in flowcode

regards

User avatar
Benj
Matrix Staff
Posts: 12488
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 3421 times
Been thanked: 3357 times
Contact:

Re: custom timer1 not work

Postby Benj » Fri Oct 27, 2017 1:20 pm

Hello,

Custom interrupts will not simulate as they could be an interrupt for anything, they will only work on the hardware. Have you tested on hardware?
These users thanked the author Benj for the post:
Francisco Cabrera (Fri Oct 27, 2017 1:26 pm)
Rating: 5.88%
 

User avatar
Francisco Cabrera
Posts: 47
Joined: Sat Mar 19, 2016 4:56 pm
Location: Canary Island
Has thanked: 23 times
Been thanked: 7 times
Contact:

Re: custom timer1 not work

Postby Francisco Cabrera » Fri Oct 27, 2017 1:26 pm

no benj, :shock: Only I have simulated it in flowcode, Then this it is the problem .... thank you very much for your help :D
These users thanked the author Francisco Cabrera for the post:
Benj (Mon Oct 30, 2017 9:37 am)
Rating: 5.88%