Move Intercom temp sensor initialisation from mendel.c to temp.c.
This commit is contained in:
parent
a9f1d00865
commit
f6115688c5
8
mendel.c
8
mendel.c
|
|
@ -186,14 +186,6 @@ void io_init(void) {
|
||||||
WRITE(MISO, 1); SET_INPUT(MISO);
|
WRITE(MISO, 1); SET_INPUT(MISO);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef TEMP_INTERCOM
|
|
||||||
// Enable the RS485 transceiver
|
|
||||||
SET_OUTPUT(RX_ENABLE_PIN);
|
|
||||||
SET_OUTPUT(TX_ENABLE_PIN);
|
|
||||||
WRITE(RX_ENABLE_PIN,0);
|
|
||||||
disable_transmit();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef DEBUG_LED_PIN
|
#ifdef DEBUG_LED_PIN
|
||||||
WRITE(DEBUG_LED_PIN, 0);
|
WRITE(DEBUG_LED_PIN, 0);
|
||||||
SET_OUTPUT(DEBUG_LED_PIN);
|
SET_OUTPUT(DEBUG_LED_PIN);
|
||||||
|
|
|
||||||
18
temp.c
18
temp.c
|
|
@ -97,12 +97,18 @@ void temp_init() {
|
||||||
break;*/
|
break;*/
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef TEMP_INTERCOM
|
#ifdef TEMP_INTERCOM
|
||||||
case TT_INTERCOM:
|
case TT_INTERCOM:
|
||||||
intercom_init();
|
// Enable the RS485 transceiver
|
||||||
send_temperature(0, 0);
|
SET_OUTPUT(RX_ENABLE_PIN);
|
||||||
break;
|
SET_OUTPUT(TX_ENABLE_PIN);
|
||||||
#endif
|
WRITE(RX_ENABLE_PIN,0);
|
||||||
|
disable_transmit();
|
||||||
|
|
||||||
|
intercom_init();
|
||||||
|
send_temperature(0, 0);
|
||||||
|
// Intentionally no break.
|
||||||
|
#endif
|
||||||
|
|
||||||
default: /* prevent compiler warning */
|
default: /* prevent compiler warning */
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue