Skip to content

Commit

Permalink
update libavr32, protects spi/etc
Browse files Browse the repository at this point in the history
  • Loading branch information
tehn committed Sep 25, 2017
1 parent c791f70 commit 350b7b7
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
1 change: 1 addition & 0 deletions module/config.mk
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ CSRCS = \
../libavr32/src/i2c.c \
../libavr32/src/init_teletype.c \
../libavr32/src/init_common.c \
../libavr32/src/interrupts.c \
../libavr32/src/kbd.c \
../libavr32/src/region.c \
../libavr32/src/screen.c \
Expand Down
5 changes: 3 additions & 2 deletions module/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#include "i2c.h"
#include "init_common.h"
#include "init_teletype.h"
#include "interrupts.h"
#include "kbd.h"
#include "region.h"
#include "screen.h"
Expand Down Expand Up @@ -316,7 +317,7 @@ void handler_MscConnect(int32_t data) {
assign_msc_event_handlers();

// disable timers
timers_pause();
u8 flags = irqs_pause();

// clear screen
for (size_t i = 0; i < 8; i++) {
Expand All @@ -330,7 +331,7 @@ void handler_MscConnect(int32_t data) {
// renable teletype
set_mode(M_LIVE);
assign_main_event_handlers();
timers_resume();
irqs_resume(flags);
}

void handler_Trigger(int32_t data) {
Expand Down
2 changes: 1 addition & 1 deletion src/teletype.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include "command.h"
#include "state.h"

#define TELETYPE_VERSION "TELETYPE 2.0.0"
#define TELETYPE_VERSION "TELETYPE 2.0.1"
#define TELE_ERROR_MSG_LENGTH 16

typedef enum {
Expand Down

0 comments on commit 350b7b7

Please sign in to comment.