Skip to content
Snippets Groups Projects
  1. Oct 05, 2019
    • rahix's avatar
      feat(serial): Add function to switch serial to synchronous · 5e25bc89
      rahix authored
      
      In severe error conditions, asynchronous prints will never work.  For
      such cases we need a way to make prints happen synchronously again, the
      same way it works during early boot.  Add a serial_return_to_synchronous()
      function which unconditionally switches the serial driver code to
      synchronous mode.
      
      Only use this function in unrecoverable error conditions!
      
      Signed-off-by: default avatarRahix <rahix@rahix.de>
      5e25bc89
    • rahix's avatar
      fix(libcard10): Mark card10_reset() as noreturn · 8ac93244
      rahix authored
      
      card10_reset() won't ever return to where it was called from.  Telling
      the compiler this can help with program-flow analysis.
      
      Signed-off-by: default avatarRahix <rahix@rahix.de>
      8ac93244
    • rahix's avatar
      Merge 'Draw offscreen lines' · a9e1b238
      rahix authored
      See merge request card10/firmware!332
      a9e1b238
    • Philip Stewart's avatar
      fix(gfx/display): Draw partially clipped primitives · 14d5abcc
      Philip Stewart authored and rahix's avatar rahix committed
      Fix two bugs in the display/gfx module:
      
      1. The animation of the simple_menu used in the main menu had the issue
         that there is a black line visible at the top.  This is due the
         gfx_puts method ignoring lines, where the top pixel of the string is
         above the top of the screen.  As gfx_puts uses gfx_setpixel which in
         turn ignores pixels outside of the screen, remove the check in
         gfx_puts.
      2. X and Y coordinates were cast to unsigned-ints before being given to
         the gfx-library which means calls like circ(0, -10, 30) would be draw
         at coordinates like [0,65526].  Fix this by changing the data-type of
         all coordinates to signed-integers.
      
      Also remove the x and y ranges from the documentation of the individual
      python functions and instead add a general documentation about the
      screen and it's size/coordinate system.
      14d5abcc
  2. Oct 04, 2019
  3. Oct 03, 2019
  4. Oct 01, 2019
  5. Sep 25, 2019
  6. Sep 24, 2019
  7. Sep 22, 2019
    • rahix's avatar
      Merge 'ECG App update' · ee45bbd8
      rahix authored
      See merge request card10/firmware!296
      ee45bbd8
    • Daniel Hoffend's avatar
      feat(ecg-app): Refactor ECG App · d7edf7e5
      Daniel Hoffend authored and rahix's avatar rahix committed
      New Button-Layout
      =================
      
                /-----------------------\
                |   xxxxxxxxxxxxxxxxx   |
                |                       |
                |                      <> * Pause screen
                |         card10        |
       +------- <>                     <> * During pause: Scroll right.
       |        |                       | * Short press: Toggle between Finger
       |        \-----------------------/    and USB.
      * During pause: Scroll left.        * Long press: Toggle bias on/off.
      * Short press: Toggle LED mode.
      * Long press: Start/stop logging.
      
      Other Changes
      =============
      - Split the bar into negativ [10:5] and positive [5:0] scale and update
        them seperate to have a better visualization.
      - Blink red with backside LEDs on detected pulse.
      - Allow toggling the LED modes on and off (see new button layout).
      - Lock mode & bias during logging.
      d7edf7e5
    • rahix's avatar
      docs(utime): Document monotonic clock API · d3935ffd
      rahix authored
      
      Signed-off-by: default avatarRahix <rahix@rahix.de>
      d3935ffd
    • rahix's avatar
      chore: Update CHANGELOG and docs · db0ff2f6
      rahix authored
      db0ff2f6
    • rahix's avatar
      Merge 'Refactor BHI160 App' · 50839184
      rahix authored
      See merge request card10/firmware!316
      50839184
    • rahix's avatar
      refactor(preload/bhi): Make app more pythonic · 003aa2a0
      rahix authored
      
      This patch makes the BHI160 app more pythonic and fixes a few
      bugs/issues:
      
      - An exception (including KeyboardInterrupt) will trigger the sensor to
        be closed again.  Otherwise you'd get strange behavior trying to
        reopen then afterwards.
      - Use simple_menu.button_events() instead of home-cooked solution.  This
        should hopefully make the code more future-proof.
      - Fix overlapping text caused by the font-rendering changes.
      
      Signed-off-by: default avatarRahix <rahix@rahix.de>
      003aa2a0
    • rahix's avatar
      hack(streams): Discard overflowing samples · d974cd2f
      rahix authored
      
      As discussed in !316, this commit prevents I2C lockup by
      discarding overflowing samples instead of blocking until they have been
      read.  This is not ideal as the samples read will not be the most recent
      ones.  A deeper refactor of the sensor-stream internal API can fix this
      in the future.
      
      Cc: @flo_h
      Signed-off-by: default avatarRahix <rahix@rahix.de>
      d974cd2f
  8. Sep 21, 2019
    • rahix's avatar
      Merge 'Add monotonic clock' · c3ca9d22
      rahix authored
      See merge request card10/firmware!285 and card10/firmware#146
      c3ca9d22
    • Ferdinand Bachmann's avatar
      feat(rtc): Add monotonic clock · f1251d66
      Ferdinand Bachmann authored and rahix's avatar rahix committed
      Squashed commits:
      
      e94f7bf9 epicardium/rtc: add monotonic time
      e0691c6d pycardium/modules/utime.c: add bindings for monotonic time
      756c13df epicardium/rtc: fix numerically unstable subsecond decoding
      
               the subsecond encoding function from epic_rtc_set_milliseconds
               and the corresponding decoding function from
               epic_rtc_get_milliseconds are not numerically stable.
      
               i.e., encoding 5 milliseconds to 20 subsecs and immediately
               afterwards decoding that yields 4 milliseconds.
      
               Adding a bias of 999 (0.24 milliseconds) to the decoding
               function makes it numerically stable, while never decoding any
               subsecond value to more than 999 milliseconds.
      
      e99e278b epicardium/rtc: only poll time once for calculating monotonic_offset
      18936b7e pycardium/modules/utime.c: run clang-format
      869ac617 epicardium/rtc: add explanation comment for numerically stable subsecond decode
      f1251d66
Loading