Skip to content
This repository has been archived by the owner on Sep 6, 2024. It is now read-only.

Commit

Permalink
Include haddock
Browse files Browse the repository at this point in the history
  • Loading branch information
Akribes committed Jun 4, 2024
1 parent cafc988 commit acb33bf
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/Clash/Cores/Ethernet/Examples/EchoStack.hs
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ ipEchoStackC rxClk rxRst rxEn txClk txRst txEn mac ip = ckt
|> packetBufferC d10 d4
|> mapMeta swapIp
|> ipTxStack @4 txClk txRst txEn mac

-- | Full stack from ethernet to ethernet.
fullStackC
:: forall
(dom :: Domain)
Expand All @@ -86,7 +88,9 @@ fullStackC
-> Reset domEthTx
-> Enable domEthTx
-> Signal dom MacAddress
-- ^ My mac address
-> Signal dom (IPv4Address, IPv4Address)
-- ^ Tuple of my IP and subnet mask
-> Circuit (PacketStream domEthRx 1 ()) (PacketStream domEthTx 1 ())
fullStackC rxClk rxRst rxEn txClk txRst txEn mac ip =
macRxStack @4 rxClk rxRst rxEn mac
Expand All @@ -98,6 +102,8 @@ fullStackC rxClk rxRst rxEn txClk txRst txEn mac ip =
, _udplDstPort = _udplSrcPort
}

-- | Wraps a circuit that handles UDP packets into a stack that handles IP, ICMP
-- and ARP.
arpIcmpUdpStackC
:: forall (dataWidth :: Nat) (dom :: Domain)
. HiddenClockResetEnable dom
Expand Down

0 comments on commit acb33bf

Please sign in to comment.