[NSWI004] Timer enabling

Josef Starychfojtu josef.starychfojtu at gmail.com
Tue Dec 3 20:25:09 CET 2019


Hi, thanks ! Now everything works ok.

On Tue, 3 Dec 2019 at 09:23, Vojtech Horky <horky at d3s.mff.cuni.cz> wrote:

> Hello.
>
> Dne 02. 12. 19 v 23:40 Vojtěch Antošík napsal(a):
> > I believe the problem is actually somewhere else. Interrupt vector table
> > (or whatever it's called) only dumps registers and switches msim to
> > interactive mode. I am not completely sure whether it is meant to be
> > part of the assignment or not (more likely just a forgotten part of
> > exception handling implementation) but you have to change those
> > instructions to make it actually jump to the handler when an interrupt
> > is raised.
>
> Ooops, I forgot to commit changes to head.S to actually jump to the C
> code. Please, merge with 0678bb6494 if you have not already added the
> jump there. Sorry about this.
>
> - VH
>
>
>
> >
> > po 2. 12. 2019 v 22:44 odesílatel Vojtech Horky <horky at d3s.mff.cuni.cz
> > <mailto:horky at d3s.mff.cuni.cz>> napsal:
> >
> >     Hello.
> >
> >     Dne 02. 12. 19 v 22:38 Josef Starychfojtu napsal(a):
> >      > Hi,
> >      >
> >      > I am trying to make the interruption just work (jump to handle
> >     exception
> >      > code after some cycles). According to documentation, when Compare
> >      > register and Count register equal, it causes interrupt. I used the
> >      > time_interrupt_after function to set Compare = Count + X and then
> >      > watched their values in while loop, but nothing happens, even tho
> >     Count
> >      > was greater than Compare after a while. I have just a simple
> >     debug print
> >      > in handle_exception_general function and it is not triggered. I
> >      > call time_interrupt_after and interrupts_restore(true) (tried even
> >      > without it) in main function of a thread. Any suggestions on what
> >     am I
> >      > doing wrong?
> >
> >     Your explanation is correct, it only misses one extra point. Timer
> >     interrupt is not triggered when interrupts are disabled. I would thus
> >     suggest checking that.
> >
> >     - VH
> >
> >      >
> >      > Thanks !
> >      >
> >      > Josef Starychfojtu
> >      >
> >      > _______________________________________________
> >      > NSWI004 mailing list
> >      > NSWI004 at d3s.mff.cuni.cz <mailto:NSWI004 at d3s.mff.cuni.cz>
> >      > https://d3s.mff.cuni.cz/mailman/listinfo/nswi004
> >      >
> >     _______________________________________________
> >     NSWI004 mailing list
> >     NSWI004 at d3s.mff.cuni.cz <mailto:NSWI004 at d3s.mff.cuni.cz>
> >     https://d3s.mff.cuni.cz/mailman/listinfo/nswi004
> >
> >
> > _______________________________________________
> > NSWI004 mailing list
> > NSWI004 at d3s.mff.cuni.cz
> > https://d3s.mff.cuni.cz/mailman/listinfo/nswi004
> >
>
> _______________________________________________
> NSWI004 mailing list
> NSWI004 at d3s.mff.cuni.cz
> https://d3s.mff.cuni.cz/mailman/listinfo/nswi004
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://d3s.mff.cuni.cz/pipermail/nswi004/attachments/20191203/0cf99a8a/attachment.html>


More information about the NSWI004 mailing list