diff --git a/.circleci/config.yml b/.circleci/config.yml index 2e1f364c..99c39c3c 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -11,8 +11,8 @@ target_steps_linux: &target_steps_linux - run: rustup target add x86_64-unknown-linux-gnu || true # For XDP - run: - sudo apt update && sudo apt install -qq build-essential m4 clang bpftool libelf-dev - libpcap-dev + sudo apt update && sudo apt install -qq build-essential m4 clang libelf-dev libpcap-dev + linux-hwe-6.5-tools-common # For XDP - run: sudo ln -s /usr/include/asm-generic/ /usr/include/asm - run: | diff --git a/src/lib.rs b/src/lib.rs index ec298ad8..0e2d3dfe 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -206,7 +206,7 @@ pub use ethercrab_wire::{ EtherCrabWireRead, EtherCrabWireReadSized, EtherCrabWireReadWrite, EtherCrabWireSized, EtherCrabWireWrite, EtherCrabWireWriteSized, }; -pub use pdu_loop::{PduLoop, PduRx, PduStorage, PduTx, SendableFrame}; +pub use pdu_loop::{PduLoop, PduRx, PduStorage, PduTx, ReceiveAction, SendableFrame}; pub use register::{DcSupport, RegisterAddress}; pub use slave::{DcSync, Slave, SlaveIdentity, SlavePdi, SlaveRef}; pub use slave_group::{GroupId, GroupSlaveIterator, SlaveGroup, SlaveGroupHandle}; diff --git a/tests/util.rs b/tests/util.rs index 14f1f2c9..f9525641 100644 --- a/tests/util.rs +++ b/tests/util.rs @@ -4,7 +4,7 @@ use ethercrab::{ error::Error, internals::{EthercatFrameHeader, PduHeader}, std::tx_rx_task, - PduRx, PduTx, + PduRx, PduTx, ReceiveAction, }; use ethercrab_wire::EtherCrabWireRead; use pcap_file::pcapng::{Block, PcapNgReader}; @@ -81,7 +81,7 @@ struct DummyTxRxFut<'a> { } impl Future for DummyTxRxFut<'_> { - type Output = Result<(), Error>; + type Output = Result; fn poll(mut self: Pin<&mut Self>, ctx: &mut core::task::Context<'_>) -> Poll { self.tx.replace_waker(ctx.waker()); @@ -127,7 +127,7 @@ impl Future for DummyTxRxFut<'_> { .pop_front() .expect("Not enough packets for this preamble"); - self.rx.receive_frame(expected.as_ref()).expect("Frame RX") + self.rx.receive_frame(expected.as_ref()).expect("Frame RX"); } Poll::Pending @@ -139,7 +139,7 @@ pub fn dummy_tx_rx_task( capture_file_path: &str, pdu_tx: PduTx<'static>, pdu_rx: PduRx<'static>, -) -> Result>, std::io::Error> { +) -> Result>, std::io::Error> { // let file_in = File::open(capture_file_path).expect("Error opening file"); let file_in2 = File::open(capture_file_path).expect("Error opening file"); // let pcapng_reader = PcapNgReader::new(file_in).expect("Failed to init PCAP reader");