Git Product home page Git Product logo

Comments (3)

jgromes avatar jgromes commented on May 25, 2024 1

Please fill in the information requested by the issue template.

Receiver goes into an endless loop of Timeout error.

Timeout is not an error, it just means that the receiver did not hear anything in the time window it was receiving, that's it. Did you try with interrupts?

Library does not allow any control over paket size, or am I missing something?

I don't know what you are trying to say here - the library transmits the packets you provide, if you reqeust to send 15 bytes it will send a 15 byte packet + preamble/header/CRCc, which again is set by yourself. You have absolute control over the packet size being sent.

from radiolib.

kocinski15 avatar kocinski15 commented on May 25, 2024

Receiver goes into an endless loop of Timeout error.

Timeout is not an error, it just means that the receiver did not hear anything in the time window it was receiving, that's it. Did you try with interrupts?

No I haven't tried with interrupts. I would like to stick with one interrupt (is it interrupt or poll ? ) line DIO0 which is required. Polling mode on the receiving side is fine for me.
Without DIO0 declared and connected transmitter signals Timeout. So in the test setup both sides use DIO0.
If not being forced by library requirement I would be fine without DIO0 on the trasnmitting side too.

Data is being sent in the loop by the transmitter device every second and once it is received by the receiving side SX1278 it should be seen in the nearest receiver's loop . It isn't. It always ends up with continuous timeout regardless of trasmitter being on or off.

I don't know what you are trying to say here - the library transmits the packets you provide, if you reqeust to send 15 bytes it will send a 15 byte packet + preamble/header/CRCc, which again is set by yourself. You have absolute control over the packet size being sent.

That is clear now. In other devices with UART like Ebyte E22 they use predefined packet length so i thought there is some distinction between stream and packet modes. As I now understand there are always packets of arbitrary length that can be different every transmission event.

from radiolib.

jgromes avatar jgromes commented on May 25, 2024

is it interrupt or poll ?

In interrupt mode, it's an interrupt, as the name suggest. In blocking mode, the pin is polled.

No I haven't tried with interrupts. I would like to stick with one interrupt (... ) line DIO0 which is required.

Packet reception is signaled on DIO0. On the contrary, timeout is signaled on DIO1, or handled by software if you did not provide DIO1.

Polling mode on the receiving side is fine for me.

Then you will see timeouts. That's just what blocking mode is.

once it is received by the receiving side SX1278 it should be seen in the nearest receiver's loop

That's not how this works. If the receiver is not receiving while you are transmitting, then you will not get the packet. And when the receiver times out, it will no longer receive, until reception is restarted. That's the base of the blocking mode. With interrupts, the receiver is listening continuously and triggers an interrupt when it receives a packet.

Also, this is not an issue in the library, but a generic question about usage, so I'm converting this thread to a discussion.

from radiolib.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.