5 Replies Latest reply on Jun 25, 2015 6:27 PM by 함찬영

    Can I use the external interrupt using the CMSIS directly instead of WICED libaray?

    함찬영

      Hi all.

       

      I use the CMSIS for controlling the external interrupt instead of WICED-SDK, directly.

      But it does not work.

       

      I wonder about the proper external interrupt handler name which are used.

      I use the GPIOH11 (WICED_GPIO_45) of the SSBWMN01,

      and the external IRQ handler name is "void EXTI15_10_IRQHandler(void) ".

      I want to know where the interrup vector table of the CMSIS is?

       

      And I also want to know how can I use the IRQ handler function in the main() function.

      Whene I use the CMSIS using the IAR systems, the IRQ handler function is in the  stm32f10x_it.c.

      But the WICED-SDK does not provide the stm32f10x_it.c file.

       

       

      First of all, I refered to the Wiced-SDK/snip/push2scan, I have to modify it, actually.

       

      The external interrupt signal is the periodic signal(under 1 msec) from the other device.

       

      Best regards.

        • 1. Re: Can I use the external interrupt using the CMSIS directly instead of WICED libaray?
          jayi

          Hi,

           

          Which platform are you using and who was the supplier? We do not give ST support for the CMSIS, but in the case you want to use WICED for the interrupts you can do the following.

           

          You can define a new interrupt handler using the macro PLATFORM_DEFINE_ISR( my_irq ) defined in WICED-SDK-3.1.2\WICED\platform\ARM_CM4\platform_isr.h.

           

          @usage:

          PLATFORM_DEFINE_ISR( my_irq )

          {

               // Do something here

          }

           

          Which MCU do you use? Check out the platform_unhandled_isr.c where it defines the default IRQ Handler Declarations.

           

          WICED-SDK-3.1.2\WICED\platform\MCU\STM32F2xx\platform_unhandled_isr.c

           

          You can check the GPIO mapping in WICED-SDK-3.1.2\platforms\BCM943362WCD4\platform.c

          Note that the paths will depend on which platform / MCU you use.

           

          Thanks,

          Jaeyoung

          • 2. Re: Can I use the external interrupt using the CMSIS directly instead of WICED libaray?
            함찬영

            Thank you for answer jaeyoung over again.

             

            You mean that

              1.  I can use the isr which is defined in the platform_isr.h

                   ; PLATFORM_DEFINE_ISR( interrupt handler name )

              2. and the interrupt handler name are declared in the platform_unhandled_isr.c

                 ex> EXTI4_irq, SPI1_irq etc..

             

            So I want to use the external interrupt 4, I have to use the following ISR function.

               ; PLATFORM_DEFINE_ISR( EXTI4_irq )

             

            I would like to know whether I am right or not, jeayoung.

             

            My platform and development environment are the SSBWMN01 and WICED-SDK-3.1.2.

             

             

            Best regards.

            • 3. Re: Can I use the external interrupt using the CMSIS directly instead of WICED libaray?
              함찬영

              Hi jaeyoung.

               

              I have a question about your answers.

               

              1. Is it a creating new isr that the PLATFORM_DEFINE_ISR( my_irq ) is in the platform_isr.h?

                I just want to know the default isr handler name of enternal interrupt which is  provided WICED-SDK-3.1.2,

              and the way of using it.

               

              2. There are PLATFORM_SET_DEFAULT_ISR( EXTI0_irq, UnhandledInterrupt ),

                              PLATFORM_SET_DEFAULT_ISR( ADC_irq, UnhandledInterrupt ),

                             PLATFORM_SET_DEFAULT_ISR( TIM1_CC_irq, UnhandledInterrupt ) and so on in the platform_unhandled_isr.c.

              Is it maybe a default handler names?

               

              Best regards.

              • 4. Re: Can I use the external interrupt using the CMSIS directly instead of WICED libaray?
                jayi

                Do you know which platform SSBWMN01? I could not find the information on the internet. Which target name do you use for downloading apps onto SSBWMN01?

                 

                1. Yes you can create a new isr with PLATFORM_DEFINE_ISR( my_irq ).

                 

                2. You should use the PLATFORM_SET_DEFAULT_ISR to set the isr to your defined handler.

                 

                Thanks,

                Jaeyoung

                • 5. Re: Can I use the external interrupt using the CMSIS directly instead of WICED libaray?
                  함찬영

                  Thank you Jaeyoung.

                   

                  The SSBWMN01 is omiited the dash. The full name is the SSB-WM-N01 based on BCM43362 and Cortex-M3.

                  It is my mistake.

                   

                  Jaeyoung,

                  if I want to use the default interrupt service routine (isr), which macro I have to use in the platform_isr.h file?

                  There are macros in the platform_isr.h file, PLATFORM_MAP_ISR( my_irq, USART1_irq ), PLATFORM_SET_DEFAULT_ISR( USART1_irq, default_handler ) etc..

                   

                  If I want to use EXTI15_10_irq, I think I have to use PLATFORM_SET_DEFAULT_ISR( USART1_irq, default_handler ). Is it right?

                  And if it is right, how can I use it?

                  For example, where I can declare it, in the application_start() or others?

                  Or do I have to set any others except declaring the macro mentioned previously?

                   

                  Best regards.