Modified the AT91SAM7S port and the ATmega168 port to use a slimmed down MS/TP state machine and datalink layer. Tested on AT91SAM7S-EK board.

This commit is contained in:
skarg
2007-09-07 01:34:19 +00:00
parent 4f34f6994b
commit 8fb328ce23
10 changed files with 1285 additions and 359 deletions
+3 -1
View File
@@ -441,7 +441,6 @@ static void MSTP_Send_Frame(
RS485_Send_Data(buffer, 2);
}
RS485_Transmitter_Enable(false);
Timer_Silence_Reset();
}
static void MSTP_Receive_Frame_FSM(void)
@@ -1243,6 +1242,9 @@ uint16_t dlmstp_receive(
if (MSTP_Flag.ReceivePacketPending) {
MSTP_Flag.ReceivePacketPending = false;
pdu_len = DataLength;
src->mac_len = 1;
src->mac[0] = SourceAddress;
/* data is already in the pdu pointer */
}
return pdu_len;