6 Replies Latest reply on Aug 3, 2018 2:47 AM by axel.lin_1746341

    (CYW43907) powersave test app - verify that it is working as intended

    NickMckendree_1688136

      I want to verify that the powersave application in deepsleep is working as intended. I am using the CYW943907AEVAL1F eval board with the powersave test application with SDK 6.2.

      The issue also occurs on the Arrow QuickSilverEval platform.

      I have POWERSAVE_STANDALONE_TEST_DEEPSLEEP_NO_ASSOC set to 1, attempting to test deepsleep power levels.

      The only modification I made to the application was to change to long sleep time from 120s to 30s.

       

      I program the device then do a power cycle to the board.

      I use the following build commands

      testProjects.powersave-CYW943907AEVAL1F-ThreadX-NetX download run

      testProjects.powersave-CYW943907AEVAL1F-FreeRTOS-LwIP download run

       

      Both RTOS/IP stack combos behave similarly.

      The board boots, waits for a few seconds, then enters a low power mode of 300uA for 30s, and then sits in some kind of high current state at 38mA for about 20 seconds before rebooting. Only the FreeRTOS build displays a cold boot and time since deep sleep message on wake (before rebooting).

       

       

      ThreadX/NetX

       

      Starting WICED vWiced_006.002.000.0072

      Platform CYW943907AEVAL1F initialised

      Started ThreadX v5.8

      Initialising NetX v5.10_sp3

      Creating Packet pools

      WLAN MAC Address : A4:08:EA:D9:BA:8A

      WLAN Firmware    : wl0: May 15 2018 19:39:17 version 7.15.168.114 (r689934) FWID 01-d6f88905

      WLAN CLM         : API: 12.2 Data: 9.10.74 Compiler: 1.31.3 ClmImport: 1.36.3 Creation: 2018-05-15 19:33:15

      >

      *** Goes to sleep for ~30s and then enters a unknown 38mA state for 20s ****

       

      Starting WICED vWiced_006.002.000.0072

      Platform CYW943907AEVAL1F initialised

      Started ThreadX v5.8

      Initialising NetX v5.10_sp3

      Creating Packet pools

      WLAN MAC Address : A4:08:EA:D9:BA:8A

      WLAN Firmware    : wl0: May 15 2018 19:39:17 version 7.15.168.114 (r689934) FWID 01-d6f88905

      WLAN CLM         : API: 12.2 Data: 9.10.74 Compiler: 1.31.3 ClmImport: 1.36.3 Creation: 2018-05-15 19:33:15

      >

       

      FreeRTOS/lwIP

      Starting WICED vWiced_006.002.000.0072

      Platform CYW943907AEVAL1F initialised

      Started FreeRTOS v10.0.1     (Custom)

      Initialising LwIP v2.0.3

      DHCP CLIENT hostname WICED IP

      WLAN MAC Address : A4:08:EA:D9:BA:8A

      WLAN Firmware    : wl0: May 15 2018 19:39:17 version 7.15.168.114 (r689934) FWID 01-d6f88905

      WLAN CLM         : API: 12.2 Data: 9.10.74 Compiler: 1.31.3 ClmImport: 1.36.3 Creation: 2018-05-15 19:33:15

      >

      ***** Goes to sleep at 300uA for 30s *********

      COLD boot

      BEACONS:

          before sleep: from BSS 0 from not BSS 0

          after  sleep: from BSS 0 from not BSS 0

          during sleep: from BSS 0 from not BSS 0

      TIME since deep-sleep enter: 104509

      ***** Sits at 38mA for 20+seconds *********

       

      Starting WICED vWiced_006.002.000.0072

      Platform CYW943907AEVAL1F initialised

      Started FreeRTOS v10.0.1

      Initialising LwIP v2.0.3

      DHCP CLIENT hostname WICED IP

      WLAN MAC Address : A4:08:EA:D9:BA:8A

      WLAN Firmware    : wl0: May 15 2018 19:39:17 version 7.15.168.114 (r689934) FWID 01-d6f88905

      WLAN CLM         : API: 12.2 Data: 9.10.74 Compiler: 1.31.3 ClmImport: 1.36.3 Creation: 2018-05-15 19:33:15

      >

      ***** Goes to sleep at 300uA for 30s *********

        • 1. Re: (CYW43907) powersave test app - verify that it is working as intended
          vikr

          There is an issue with 6.2 SDK, we are working on the fix.

          • 2. Re: (CYW43907) powersave test app - verify that it is working as intended
            axel.lin_1746341

            vikr wrote:

             

            There is an issue with 6.2 SDK, we are working on the fix.

            vikr

             

            Can you elaborate a bit about the issue with 6.2 sdk?

            I believe the 6.2 users want to check if their application has impacted by a know issue.

            • 3. Re: (CYW43907) powersave test app - verify that it is working as intended
              NickMckendree_1688136

              Yes vikr, it will be very helpful to know what the identified problem is and a potential work around.

               

              I created a new application to try out sleep mode, based on information from the WICED Development Power Save System PDF (from the docs folder in SDK).

               

              With my customized build using FreeRTOS v10 (changes from v9 ported over) I am seeing FreeRTOS calling platform_power_down_hook repeatedly during the time that the processor should be in sleep mode ( i placed a print statement in this function for testing).

               

              If I change to the FreeRTOS v9 build, then the application just resets when the sleep time is over which doesnt seem right as this is sleep mode, not deep sleep.

               

              void application_start( )  
              {  
              wiced_init();  
              platform_led_set_state(PLATFORM_GREEN_LED_INDEX, WICED_LED_OFF );  
              platform_led_set_state(PLATFORM_RED_LED_INDEX, WICED_LED_OFF );  
                
                
              connectivity_deinit();  
              while(1)  
              {  
              platform_led_set_state(PLATFORM_GREEN_LED_INDEX, WICED_LED_OFF );  
              wiced_platform_mcu_enable_powersave();  
              wiced_rtos_delay_milliseconds(15000);  
              wiced_platform_mcu_disable_powersave();  
              platform_led_set_state(PLATFORM_GREEN_LED_INDEX, WICED_LED_ON );  
              WPRINT_APP_INFO( ( "Hello\n" ) );  
              wiced_rtos_delay_milliseconds(5000);  
              }  
              }  
              }  
              

               

               

              NAME := testSleep
              
              
              
              
              APPLICATION_DCT    := application_dct.c
              
              
              
              
              GLOBAL_DEFINES  += PLATFORM_POWERSAVE_DEFAULT=1
              GLOBAL_DEFINES  += PLATFORM_WLAN_POWERSAVE_STATS=1
              GLOBAL_DEFINES  += PLATFORM_MCU_POWERSAVE_MODE_INIT=PLATFORM_MCU_POWERSAVE_MODE_SLEEP
              GLOBAL_DEFINES  += WICED_DEEP_SLEEP_SAVE_PACKETS_NUM=4
              
              
              
              
              $(NAME)_COMPONENTS := utilities/wiced_log \
              filesystems/wicedfs \
              protocols/HTTP_client \
              libraries/utilities/JSON_parser \
                                    utilities/mini_printf
              $(NAME)_SOURCES    := main.c
              $(NAME)_INCLUDES   := . \
              $(WICED_LIB)/filesystems/ota2 \
              $(WICED_LIB)/utilities/wiced_log \
              $(WICED_LIB)/utilities/mini_printf
              WIFI_CONFIG_DCT_H := wifi_config_dct.h
              
              • 4. Re: (CYW43907) powersave test app - verify that it is working as intended
                NickMckendree_1688136

                vikr

                When using the FreeRTOS v9 build, the reset is due to being trapped in an assert in FreeRTOS which causes a Watchdog reset

                 

                void vTaskStepTick( const TickType_t xTicksToJump )

                {

                /* Correct the tick count value after a period during which the tick

                was suppressed.  Note this does *not* call the tick hook function for

                each stepped tick. */

                configASSERT( ( xTickCount + xTicksToJump ) <= xNextTaskUnblockTime );

                xTickCount += xTicksToJump;

                traceINCREASE_TICK_COUNT( xTicksToJump );

                }

                • 5. Re: (CYW43907) powersave test app - verify that it is working as intended
                  NickMckendree_1688136

                  I made this modification because the xTickCount + xTicksToJump was always > xNextTaskUnblockTime by 1.

                   

                  configASSERT( ( xTickCount + xTicksToJump - 1 ) <= xNextTaskUnblockTime );

                  xTickCount += xTicksToJump - 1;

                   

                  The project runs but the application is not entering any low power modes. The current is 42mA, regardless of running or sleep, as views witgh a meter and a scope. 

                  • 6. Re: (CYW43907) powersave test app - verify that it is working as intended
                    axel.lin_1746341

                    vikr wrote:

                     

                    There is an issue with 6.2 SDK, we are working on the fix.

                    Is the fix available?