Skip to content
Snippets Groups Projects
Select Git revision
  • 5e9bbd9adf2c5d569e865e08ec2e7141e626badf
  • master default protected
  • esp32-nimble-wiki
  • rahix/hw-lock-new-mutex
  • dx/somewhat-more-dynamic-config
  • schneider/sdk-0.2.1-7
  • schneider/bsec
  • dx/meh-bdf-to-stm
  • dx/flatten-config-module
  • genofire/ble-follow-py
  • schneider/ble-stability
  • schneider/ble-stability-new-phy
  • add_menu_vibration
  • plaetzchen/ios-workaround
  • blinkisync-as-preload
  • schneider/max30001-pycardium
  • schneider/max30001-epicaridum
  • schneider/max30001
  • schneider/stream-locks
  • schneider/fundamental-test
  • schneider/ble-buffers
  • v1.12
  • v1.11
  • v1.10
  • v1.9
  • v1.8
  • v1.7
  • v1.6
  • v1.5
  • v1.4
  • v1.3
  • v1.2
  • v1.1
  • v1.0
  • release-1
  • bootloader-v1
  • v0.0
37 results

mpconfigport.h

Blame
  • Forked from card10 / firmware
    Source project has a limited visibility.
    mpconfigport.h 2.16 KiB
    /* Hardware Name */
    #define MICROPY_HW_BOARD_NAME "card10"
    #define MICROPY_HW_MCU_NAME "max32665"
    
    /* MicroPython Config Options */
    
    /* We raise asynchronously from an interrupt handler */
    #define MICROPY_ASYNC_KBD_INTR              (1)
    #define MICROPY_KBD_EXCEPTION               (1)
    
    /* Enable precompiled frozen modules */
    #define MICROPY_MODULE_FROZEN_MPY           (1)
    #define MICROPY_MODULE_FROZEN               (1)
    #define MICROPY_QSTR_EXTRA_POOL             mp_qstr_frozen_const_pool
    
    #define MICROPY_ENABLE_DOC_STRING           (1)
    #define MICROPY_ENABLE_GC                   (1)
    #define MICROPY_FLOAT_IMPL                  (MICROPY_FLOAT_IMPL_FLOAT)
    #define MICROPY_HELPER_REPL                 (1)
    #define MICROPY_LONGINT_IMPL                (MICROPY_LONGINT_IMPL_LONGLONG)
    #define MICROPY_PY_BUILTINS_HELP            (1)
    #define MICROPY_PY_BUILTINS_HELP_MODULES    (1)
    #define MICROPY_PY_UTIME_MP_HAL             (1)
    
    /* Modules */
    #define MODULE_UTIME_ENABLED                (1)
    #define MODULE_LEDS_ENABLED                 (1)
    #define MODULE_VIBRA_ENABLED                (1)
    
    /*
     * This port is intended to be 32-bit, but unfortunately, int32_t for
     * different targets may be defined in different ways - either as int
     * or as long. This requires different printf formatting specifiers
     * to print such value. So, we avoid int32_t and use int directly.
     */
    #define UINT_FMT "%u"
    #define INT_FMT "%d"
    typedef int mp_int_t;       /* must be pointer size */
    typedef unsigned mp_uint_t; /* must be pointer size */
    
    typedef long mp_off_t;
    
    /* extra built in names to add to the global namespace */
    #define MICROPY_PORT_BUILTINS \
        { MP_ROM_QSTR(MP_QSTR_open), MP_ROM_PTR(&mp_builtin_open_obj) },
    
    /*
     * Make a pointer to RAM callable (eg set lower bit for Thumb code)
     * (This scheme won't work if we want to mix Thumb and normal ARM code.)
     */
    #define MICROPY_MAKE_POINTER_CALLABLE(p) ((void*)((mp_uint_t)(p) | 1))
    
    /* We need to provide a declaration/definition of alloca() */
    #include <alloca.h>
    
    /* TODO: Document this */
    #define MP_STATE_PORT MP_STATE_VM
    
    /* For some reason, we need to define readline history manually */
    #define MICROPY_PORT_ROOT_POINTERS \
        const char *readline_hist[16];