Skip to content
Snippets Groups Projects
Select Git revision
  • d4a814d77a6bd30cd8dc5f8c0f6296dd104e5f5a
  • master default protected
  • schneider/max30001-epicaridum
  • schneider/max30001-pycardium
  • koalo/bhi160documentation
  • genofire/rockets-state
  • schneider/max30001
  • schneider/stream-locks
  • ios-workarounds
  • schneider/fundamental-test
  • schneider/ble-buffers
  • schneider/maxim-sdk-update
  • rahix/simple_menu
  • ch3/splashscreen
  • koalo/bhi160-works-but-dirty
  • koalo/wip/i2c-for-python
  • renze/safe_mode
  • renze/hatchery_apps
  • koalo/factory-reset
  • msgctl/gfx_rle
  • msgctl/faultscreen
  • v1.5
  • v1.4
  • v1.3
  • v1.2
  • v1.1
  • v1.0
  • release-1
  • bootloader-v1
  • v0.0
30 results

pmic.c

Blame
  • Forked from card10 / firmware
    Source project has a limited visibility.
    FreeRTOSConfig.h 2.23 KiB
    #ifndef FREERTOS_CONFIG_H
    #define FREERTOS_CONFIG_H
    
    #define  MXC_ASSERT_ENABLE
    #include "mxc_assert.h"
    
    #include "max32665.h"
    
    /* CMSIS keeps a global updated with current system clock in Hz */
    #define configCPU_CLOCK_HZ          ((unsigned long)120000000)
    
    /* TODO: Adjust this for tickless idle */
    #define configTICK_RATE_HZ          ((portTickType)1000)
    
    /* Memory
     *
     * Heap is managed by libc (heap_3.c).
     */
    #define configMINIMAL_STACK_SIZE    ((unsigned short)128)
    
    #define configMAX_PRIORITIES        5
    /* # of priority bits (configured in hardware) is provided by CMSIS */
    #define configPRIO_BITS             __NVIC_PRIO_BITS
    /* Priority 7, or 255 as only the top three bits are implemented.  This is the lowest priority. */
    #define configKERNEL_INTERRUPT_PRIORITY       ( ( unsigned char ) 7 << ( 8 - configPRIO_BITS) )
    /* Priority 5, or 160 as only the top three bits are implemented. */
    #define configMAX_SYSCALL_INTERRUPT_PRIORITY  ( ( unsigned char ) 5 << ( 8 - configPRIO_BITS) )  
    
    /* We want to use preemption to easier integrate components */
    #define configUSE_PREEMPTION        1
    
    /*
     * Tickless idle from the FreeRTOS port + our own hooks (defined further down in
     * this file)
     */
    #define configUSE_TICKLESS_IDLE     1
    
    /* TODO: Adjust */
    #define configUSE_IDLE_HOOK         0
    #define configUSE_TICK_HOOK         0
    #define configUSE_CO_ROUTINES       0
    #define configUSE_16_BIT_TICKS      0
    #define configUSE_MUTEXES           1
    
    #define INCLUDE_vTaskSuspend        1
    #define INCLUDE_vTaskDelay          1
    
    /* Allow static allocation of data structures */
    #define configSUPPORT_STATIC_ALLOCATION 1
    
    /* Alias the default handler names to match CMSIS weak symbols */
    #define vPortSVCHandler       SVC_Handler
    #define xPortPendSVHandler    PendSV_Handler
    #define xPortSysTickHandler   SysTick_Handler
    
    /* Assert */
    #define configASSERT(x)       MXC_ASSERT(x)
    
    /* Tickless idle hooks */
    typedef uint32_t TickType_t;
    void pre_idle_sleep(TickType_t xExpectedIdleTime);
    #define configPRE_SLEEP_PROCESSING(xModifiableIdleTime) \
    	pre_idle_sleep(xModifiableIdleTime); xModifiableIdleTime = 0
    
    void post_idle_sleep(TickType_t xExpectedIdleTime);
    #define configPOST_SLEEP_PROCESSING(xExpectedIdleTime) \
    	post_idle_sleep(xExpectedIdleTime)
    
    #endif /* FREERTOS_CONFIG_H */