From d3630cc86d5ae5a678ea5981566213e8c2520032 Mon Sep 17 00:00:00 2001 From: Christina Quast Date: Fri, 3 Apr 2015 11:38:24 +0200 Subject: [PATCH] phone ISR with mask (does not function yet) --- sam3s_example/simtrace/phone.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/sam3s_example/simtrace/phone.c b/sam3s_example/simtrace/phone.c index c4ce6d8d..e70c73df 100644 --- a/sam3s_example/simtrace/phone.c +++ b/sam3s_example/simtrace/phone.c @@ -134,7 +134,15 @@ static rst_cnt = 0; #define RESET 'R' static void ISR_PhoneRST( const Pin *pPin) { - printf("+++ Int!!\n\r"); + printf("+++ Int!! %x\n\r", pinPhoneRST.pio->PIO_ISR); + if ( ((pinPhoneRST.pio->PIO_ISR & pinPhoneRST.mask) != 0) ) + { + if(PIO_Get( &pinPhoneRST ) == 0) { + printf(" 0 "); + } else { + printf(" 1 "); + } + } state = RST_RCVD; /* if (state == NONE || rst_cnt > 2) {