Skip to content

Commit

Permalink
Fixed logic bug with ppsFuncIsOutput() macro.
Browse files Browse the repository at this point in the history
  • Loading branch information
EmbeddedMan committed Sep 20, 2012
1 parent d1334be commit a8df270
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hardware/pic32/cores/pic32/pins_arduino.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@
#define ppsInputFromFunc(F) ((F) & PPS_IN_MASK)
#define ppsOutputFromFunc(F) ((F) & PPS_OUT_MASK)
#define ppsFuncIsInput(F) ((F) & _PPS_INPUT_BIT)
#define ppsFuncIsOutput(F) (~ppsFuncIsInput(F))
#define ppsFuncIsOutput(F) (!ppsFuncIsInput(F))
#define ppsOutputRegister(P) (volatile uint32_t *)((uint32_t)(&_RPOBASE) + 4*digital_pin_to_pps_out_PGM[P])
#define ppsInputRegister(F) ((uint32_t *)(4*(ppsInputFromFunc(F)) + (uint32_t)&_RPIBASE))

Expand Down

0 comments on commit a8df270

Please sign in to comment.