diff --git a/src/TriacOut/TriacOut.c b/src/TriacOut/TriacOut.c index 46bd41f..9e8fb06 100644 --- a/src/TriacOut/TriacOut.c +++ b/src/TriacOut/TriacOut.c @@ -22,16 +22,12 @@ void TriacOut_InitTimerA(void) void TriacOut_SetupPins(void) { RegEdit_SetBit((void *) &PORTA.DIR, G1); - RegEdit_SetBit((void *) &PORTB.DIR, G2); - RegEdit_SetBit((void *) &PORTB.DIR, G3); } void TriacOut_SetAllHigh(void) { RegEdit_SetBit((void *) &PORTA.OUT, G1); - RegEdit_SetBit((void *) &PORTB.OUT, G2); - RegEdit_SetBit((void *) &PORTB.OUT, G3); } @@ -41,6 +37,4 @@ void TriacOut_PulsePins(uint16_t pulse_time) Delay_MicroSeconds(pulse_time); RegEdit_ClearBit((void *) &PORTA.OUT, G1); - RegEdit_ClearBit((void *) &PORTB.OUT, G2); - RegEdit_ClearBit((void *) &PORTB.OUT, G3); } diff --git a/tests/TriacOut/test_TriacOut.cpp b/tests/TriacOut/test_TriacOut.cpp index f0d275e..4e85ba3 100644 --- a/tests/TriacOut/test_TriacOut.cpp +++ b/tests/TriacOut/test_TriacOut.cpp @@ -53,15 +53,6 @@ TEST(test_TriacOut, TriacOut_SetupPins) .withPointerParameter("reg", (void *) &PORTA.DIR) .withUnsignedIntParameter("bit_num", G1); - //Expect that pin PB3 is set to output - mock().expectOneCall("RegEdit_SetBit") - .withPointerParameter("reg", (void *) &PORTB.DIR) - .withUnsignedIntParameter("bit_num", G2); - - //Expect that pin PB2 is set to output - mock().expectOneCall("RegEdit_SetBit") - .withPointerParameter("reg", (void *) &PORTB.DIR) - .withUnsignedIntParameter("bit_num", G3); TriacOut_SetupPins(); } @@ -74,16 +65,6 @@ TEST(test_TriacOut, TriacOut_SetAllHigh) .withPointerParameter("reg", (void *) &PORTA.OUT) .withUnsignedIntParameter("bit_num", G1); - //Expect that pin PB3 is set to output - mock().expectOneCall("RegEdit_SetBit") - .withPointerParameter("reg", (void *) &PORTB.OUT) - .withUnsignedIntParameter("bit_num", G2); - - //Expect that pin PB2 is set to output - mock().expectOneCall("RegEdit_SetBit") - .withPointerParameter("reg", (void *) &PORTB.OUT) - .withUnsignedIntParameter("bit_num", G3); - TriacOut_SetAllHigh(); } @@ -95,15 +76,5 @@ TEST(test_TriacOut, TriacOut_PulsePins) .withPointerParameter("reg", (void *) &PORTA.OUT) .withUnsignedIntParameter("bit_num", G1); - //Expect that pin PB3 is set to output - mock().expectOneCall("RegEdit_ClearBit") - .withPointerParameter("reg", (void *) &PORTB.OUT) - .withUnsignedIntParameter("bit_num", G2); - - //Expect that pin PB2 is set to output - mock().expectOneCall("RegEdit_ClearBit") - .withPointerParameter("reg", (void *) &PORTB.OUT) - .withUnsignedIntParameter("bit_num", G3); - TriacOut_PulsePins(1000); }