fix connect

This commit is contained in:
Thomas Kunze 2019-08-31 03:00:35 +02:00
parent 5a93bbc91c
commit cdcfbb4e83
2 changed files with 5 additions and 1 deletions

View File

@ -175,7 +175,10 @@ void ApplicationLayer::connectIndication(uint16_t tsap)
void ApplicationLayer::connectConfirm(uint16_t destination, uint16_t tsap, bool status) void ApplicationLayer::connectConfirm(uint16_t destination, uint16_t tsap, bool status)
{ {
if (status)
_connectedTsap = tsap;
else
_connectedTsap = -1;
} }
void ApplicationLayer::disconnectIndication(uint16_t tsap) void ApplicationLayer::disconnectIndication(uint16_t tsap)

View File

@ -666,6 +666,7 @@ void TransportLayer::A12(uint16_t destination, Priority priority)
CemiFrame frame(0); CemiFrame frame(0);
TPDU& tpdu = frame.tpdu(); TPDU& tpdu = frame.tpdu();
tpdu.type(Connect); tpdu.type(Connect);
_networkLayer->dataIndividualRequest(AckRequested, destination, NetworkLayerParameter, priority, tpdu);
_seqNoRecv = 0; _seqNoRecv = 0;
_seqNoSend = 0; _seqNoSend = 0;
enableConnectionTimeout(); enableConnectionTimeout();