1. 05 Oct, 2019 8 commits
    • Rahix's avatar
      chore(epicardium): Use panic() for all critical errors · 0e5c6243
      Rahix authored
      Unify unrecoverable errors to use panic() in all cases.  This will allow
      further changes to panic() to work for all critical errors.
      Signed-off-by: Rahix's avatarRahix <rahix@rahix.de>
    • Rahix's avatar
      chore(epicardium): Switch from MXC_ASSERT to assert · 070867f8
      Rahix authored
      Newlib assert uses __assert_func and thus our panic() function while
      MXC_ASSERT uses a custom assertion logic.  Newlib assert is also more
      portable as it works in expression position while MXC_ASSERT only works
      as a statement.
      Signed-off-by: Rahix's avatarRahix <rahix@rahix.de>
    • Rahix's avatar
      feat(epicardium): Use panic() for assertion failures · 9d44017b
      Rahix authored
      Define `__assert_func()` so a failing `assert()` will trigger a panic.
      Signed-off-by: Rahix's avatarRahix <rahix@rahix.de>
    • Rahix's avatar
      feat(epicardium): Add a panic() function · 1536da34
      Rahix authored
      In unrecoverable situations we should provide a common way to output the
      cause of the error and then reset the CPU.  The panic() function is
      mean to be exactly that.  It outputs the error-cause, stack-trace, and
      firmware revision, accompanied by a link to the issue-tracker to
      encourage people to report the error.  After a timeout of ~1.5s it
      resets the CPU and reboots.
      Future Work:
       - Right now, the stack-trace only has a depth of one which is the
         return address from where panic() was called.  In the future it might
         make sense to provide a deeper stack-trace if a robust implementation
         is possible.
       - Integration of @msgctl
      's faultscreen (!79) so users who don't have
         the serial console open at all times can also see what happened.
      Signed-off-by: Rahix's avatarRahix <rahix@rahix.de>
    • 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: Rahix's avatarRahix <rahix@rahix.de>
    • 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: Rahix's avatarRahix <rahix@rahix.de>
    • Rahix's avatar
      Merge 'Draw offscreen lines' · a9e1b238
      Rahix authored
      See merge request card10/firmware!332
    • 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
      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.
  2. 04 Oct, 2019 10 commits
  3. 03 Oct, 2019 4 commits
  4. 01 Oct, 2019 8 commits
  5. 25 Sep, 2019 1 commit
  6. 24 Sep, 2019 4 commits
  7. 22 Sep, 2019 5 commits