Loading ...
Sorry, an error occurred while loading the content.
 

Re: Het can't interrupt CPU

Expand Messages
  • incredibleengine
    Hi Stosh! Thanks for your response, now I m sure the code doesn t have any terrible mistake. I stoped trying to make het work for a while and started to code
    Message 1 of 5 , Mar 3, 2009
      Hi Stosh!
      Thanks for your response, now I'm sure the code doesn't have any
      terrible mistake. I stoped trying to make het work for a while and
      started to code for other peripherals. When I finish with them I'll
      return to HET... About your ideas:

      - The project it's been compiled dor debug.
      - The REQMASK is correct. This is used just once in code.
      - I have other modules working fine (CAN, RTI, ADC)... Even HET worked
      with a PWM code, but without interrupting CPU. It seems to me that the
      unique trouble is HET irq!
      - Registers are correct!
      - I took a look at link map, but sincerely, I don't have enough
      knowledge to be sure it's correct... Do you have any docs about it?
      I've compared it with another files and it seems to be ok...
      - I used the same project configuration options for other projects and
      everything worked fine...
      - No optimizations are turned on (This is the first configuration that
      I set in any project! I've had some traumas with this in other
      plataforms! :))

      Thanks so much for your response. When I get news I'll post here...

      Yes! .br from Brazil. I do some java, but just little codes when I
      need to program for PC... Why do you ask?

      regards!

      >
      > Dear  incredibleengine,
      > Is .br for Brazil?  You do any Java?
      > Here are some ideas on your trouble.
      > Make sure you're compiling for debug (no optimizations) so that you
      can expect your breakpoint to be hit.
      > I have this "no interrupt" trouble if I do   REQMASK=(1 <<
      CIM_HET1); // Enable HET Interrupt mask
      > for two different interrupts.  Then the = of the second turns off
      the bit for the first.  So using |= instead of = is the usual
      practice.  You might search your code to see if you're changing
      REQMASK somewhere else.
      > The HET is tough to use.   You can divide and conquer your problem.
       Try getting an interrupt working from another example and see if your
      bug is just with making interrupts work. Then you can come back to
      interrupts from the HET.
      > Another suggestion is to look at all the registers you've set up in
      your code and see if they (still) have the correct values in them.
       This is very easy to do with IAR because it will let you directly
      view and change all the registers.
      > Look at your link map and make sure the vectors are being placed
      correctly.  Are you compiling into RAM or FLASH?  Where are your vectors?
      > Lastly, look for where you have changed the example code and/or try
      a different example.  Is the project configuration part of the
      example?  Is something in the project set up wrong?
      > :-)  Interrupts work for me  :-)Well, I'm using a TMS470r1b1m though
      ...-Stosh
    • JohnStosh
      I hear Java is big in Brazil.  What smart people. I love Java.Have you checked the errata? ... From: incredibleengine Subject:
      Message 2 of 5 , Mar 3, 2009
        I hear Java is big in Brazil.  What smart people. I love Java.
        Have you checked the errata?

        --- On Tue, 3/3/09, incredibleengine <incredibleengine@...> wrote:

        From: incredibleengine <incredibleengine@...>
        Subject: [TMS470_ARM] Re: Het can't interrupt CPU
        To: TMS470_ARM@yahoogroups.com
        Date: Tuesday, March 3, 2009, 5:32 AM

        Hi Stosh!
        Thanks for your response, now I'm sure the code doesn't have any
        terrible mistake. I stoped trying to make het work for a while and
        started to code for other peripherals. When I finish with them I'll
        return to HET... About your ideas:

        - The project it's been compiled dor debug.
        - The REQMASK is correct. This is used just once in code.
        - I have other modules working fine (CAN, RTI, ADC)... Even HET worked
        with a PWM code, but without interrupting CPU. It seems to me that the
        unique trouble is HET irq!
        - Registers are correct!
        - I took a look at link map, but sincerely, I don't have enough
        knowledge to be sure it's correct... Do you have any docs about it?
        I've compared it with another files and it seems to be ok...
        - I used the same project configuration options for other projects and
        everything worked fine...
        - No optimizations are turned on (This is the first configuration that
        I set in any project! I've had some traumas with this in other
        plataforms! :))

        Thanks so much for your response. When I get news I'll post here...

        Yes! .br from Brazil. I do some java, but just little codes when I
        need to program for PC... Why do you ask?

        regards!

        >
        > Dear  incredibleengin e,
        > Is .br for Brazil?  You do any Java?
        > Here are some ideas on your trouble.
        > Make sure you're compiling for debug (no optimizations) so that you
        can expect your breakpoint to be hit.
        > I have this "no interrupt" trouble if I do   REQMASK=(1 <<
        CIM_HET1); // Enable HET Interrupt mask
        > for two different interrupts.  Then the = of the second turns off
        the bit for the first.  So using |= instead of = is the usual
        practice.  You might search your code to see if you're changing
        REQMASK somewhere else.
        > The HET is tough to use.   You can divide and conquer your problem.
         Try getting an interrupt working from another example and see if your
        bug is just with making interrupts work. Then you can come back to
        interrupts from the HET.
        > Another suggestion is to look at all the registers you've set up in
        your code and see if they (still) have the correct values in them.
         This is very easy to do with IAR because it will let you directly
        view and change all the registers.
        > Look at your link map and make sure the vectors are being placed
        correctly.  Are you compiling into RAM or FLASH?  Where are your vectors?
        > Lastly, look for where you have changed the example code and/or try
        a different example.  Is the project configuration part of the
        example?  Is something in the project set up wrong?
        > :-)  Interrupts work for me  :-)Well, I'm using a TMS470r1b1m though
        ...-Stosh


      • incredibleengine
        Hi Stosh! Finally I got HET IRQ working! There were two problems: - Board s crystal is not welded on board! It s just attached with sockets. It s difficult to
        Message 3 of 5 , Mar 5, 2009
          Hi Stosh!

          Finally I got HET IRQ working!

          There were two problems:

          - Board's crystal is not welded on board! It's just attached with sockets. It's difficult to perceive that due to very short crystal pins! Due to that or crystal "quality" the oscillator was intermitent and seems to work better when scope probe was in contact with it... I just replaced 12MHz to a 6MHz crystal and oscillation problems was solved.
          Ok, I know they would done that to allow easy crystal replacement but I think it drives to many problems... I guess every crystal should be WELL welded (have had many problems with that).

          - "Low_level_flash_init" file was present at IAR Workspace Window but it wasn't been builded! It was marked as "Exclude from Build".
          All other peripherals (ADC, RTI, CAN, SPI) worked without this file because they don't use RAM memory. But HET needs proper memory intialization contained inside this file!

          Well, I'm relieved to have this working! Thanks for your attention and time trying to help me!

          About Java:
          Yes, there are many Java developers here. I like java too, it's ideas helped me to code better even for C, C++ and embedded software!

          regards!


          --- In TMS470_ARM@yahoogroups.com, JohnStosh <johnstosh@...> wrote:
          >
          > I hear Java is big in Brazil.  What smart people. I love Java.Have you checked the errata?
        Your message has been successfully submitted and would be delivered to recipients shortly.