Skip to content
Snippets Groups Projects
Select Git revision
  • 128e627d4f00825fca423ff44b552e9a04c61f19
  • master default protected
  • backslash
  • nickname-match-configs
  • genofire/leds_rgb_get_state
  • genofire/rockets-state
  • genofire/ble-follow-py
  • plaetzchen/ios-workaround
  • blinkisync-as-preload
  • genofire/haule-ble-fs-deactive
  • schneider/max30001-pycardium
  • schneider/max30001-epicaridum
  • schneider/max30001
  • schneider/stream-locks
  • ios-workarounds
  • schneider/fundamental-test
  • schneider/ble-buffers
  • schneider/maxim-sdk-update
  • ch3/splashscreen
  • koalo/bhi160-works-but-dirty
  • koalo/wip/i2c-for-python
  • 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
34 results

meson.build

Blame
  • Forked from card10 / firmware
    Source project has a limited visibility.
    epicardium.h 14.20 KiB
    #ifndef _EPICARDIUM_H
    #define _EPICARDIUM_H
    
    #include <stdint.h>
    #include <errno.h>
    
    #ifndef __SPHINX_DOC
    /* stddef.h is not recognized by hawkmoth for some odd reason */
    #include <stddef.h>
    #else
    typedef unsigned int size_t;
    #endif /* __SPHINX_DOC */
    
    /*
     * These definitions are required for the code-generator.  Please don't touch!
     */
    #ifndef API
    #define API(id, def) def
    #endif
    #ifndef API_ISR
    #define API_ISR(id, isr) void isr(void);
    #endif
    
    /*
     * IDs for all defined API calls.  These IDs should not be needed in application
     * code on any side.
     */
    
    /* clang-format off */
    #define API_UART_WRITE         0x1
    #define API_UART_READ          0x2
    #define API_LEDS_SET           0x3
    #define API_VIBRA_SET          0x4
    #define API_VIBRA_VIBRATE      0x5
    #define API_STREAM_READ        0x6
    #define API_INTERRUPT_ENABLE   0x7
    #define API_INTERRUPT_DISABLE  0x8
    #define API_LIGHT_SENSOR_RUN   0x9
    #define API_LIGHT_SENSOR_GET   0xa
    #define API_LIGHT_SENSOR_STOP  0xb
    
    #define API_DISP_OPEN          0x10
    #define API_DISP_CLOSE         0x11
    #define API_DISP_PRINT         0x12
    #define API_DISP_CLEAR         0x13
    #define API_DISP_UPDATE        0x14
    #define API_DISP_LINE          0x15
    #define API_DISP_RECT          0x16
    #define API_DISP_CIRC          0x17
    #define API_DISP_PIXEL         0x18
    
    #define API_FILE_OPEN          0x30
    #define API_FILE_CLOSE         0x31
    #define API_FILE_READ          0x32
    #define API_FILE_WRITE         0x34
    #define API_FILE_FLUSH         0x35
    #define API_FILE_SEEK          0x36
    #define API_FILE_TELL          0x37
    #define API_FILE_STAT          0x38
    /* clang-format on */
    
    typedef uint32_t api_int_id_t;
    
    /**
     * Interrupts
     * ==========
     * Next to API calls, Epicardium API also has an interrupt mechanism to serve
     * the other direction.  These interrupts can be enabled/disabled
     * (masked/unmasked) using :c:func:`epic_interrupt_enable` and
     * :c:func:`epic_interrupt_disable`.