Giter VIP home page Giter VIP logo

Comments (23)

ea5gvk avatar ea5gvk commented on August 15, 2024

Hi everyone,
The same problem happens to me.
Some help to solve this problem in my XLX051.
ยด73 EA5GVK.

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

After several attempts to put the code in order to find a solution to the problem, it seems that by adjusting the various time out the phenomenon is resolved.

From various tests done in the presence of latency with a variation of 2 seconds the communication stops and when the next stream reopens, it starts again correctly.

Here I report the changes made. Someone try them and check that they behave the same way.

-------------xlxd---------------
in main.h

#define TRANSCODER_KEEPALIVE_PERIOD     1    // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT    (TRANSCODER_KEEPALIVE_PERIOD * 3)     // in seconds
#define TRANSCODER_AMBEPACKET_TIMEOUT   (TRANSCODER_KEEPALIVE_PERIOD * 1000)  // in ms

in ctranscoder.cpp

#define AMBED_OPENSTREAM_TIMEOUT    TRANSCODER_AMBEPACKET_TIMEOUT   // in ms

in cpacketstream.h

#define STREAM_TIMEOUT      (TRANSCODER_AMBEPACKET_TIMEOUT / 1000.0f))  // in seconds

OR

in main.h

#define TRANSCODER_KEEPALIVE_PERIOD     2                                   // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT    (TRANSCODER_KEEPALIVE_PERIOD + 1)     // in seconds
#define TRANSCODER_AMBEPACKET_TIMEOUT   (TRANSCODER_KEEPALIVE_PERIOD * 1000)  // in ms

in ctranscoder.cpp

#define AMBED_OPENSTREAM_TIMEOUT    TRANSCODER_AMBEPACKET_TIMEOUT   // in ms

in cpacketstream.h

#define STREAM_TIMEOUT      (TRANSCODER_AMBEPACKET_TIMEOUT / 1000.0f))   // in seconds

in ccodecstream.cpp

    // any packet from transcoder
    if ( m_Socket.Receive(&Buffer, &Ip, 20) != -1 )  // change from 5 to 20,

--------------ambed----------

in main.h

#define TRANSCODER_KEEPALIVE_PERIOD     1                                   // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT    (TRANSCODER_KEEPALIVE_PERIOD*3)     // in seconds

#define STREAM_ACTIVITY_TIMEOUT         TRANSCODER_KEEPALIVE_TIMEOUT        // in seconds

OR

#define TRANSCODER_KEEPALIVE_PERIOD     2                                   // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT    (TRANSCODER_KEEPALIVE_PERIOD + 1)     // in seconds

#define STREAM_ACTIVITY_TIMEOUT         TRANSCODER_KEEPALIVE_TIMEOUT        // in seconds

in cstream.cpp

    // anything coming in from codec client ?
    if ( m_Socket.Receive(&Buffer, &Ip, 20) != -1 )  // change from 1 to 20,

73... iz1mlt Luca

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Hi, Thx Luca.
Are these modifications made before compiling the xlxd or can they be modified after compilation?

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

First you need to edit and then rebuild by running make clean and after make.

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

ok, Many thx. I try it, and I tell him about the experience.
A greeting.

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

Tnx! Wait the reports

73... Iz1mlt

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Sorry, In original Code en Main.h
// Transcoder server --------------------------------------------

#define TRANSCODER_PORT 10100 // UDP port
#define TRANSCODER_KEEPALIVE_PERIOD 5 // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT 30 // in seconds
#define TRANSCODER_AMBEPACKET_TIMEOUT 400 // in ms

modified, according to its indications it would be like this.

// Transcoder server --------------------------------------------

#define TRANSCODER_PORT 10100 // UDP port
#define TRANSCODER_KEEPALIVE_PERIOD 1 // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT 3 // in seconds (1 * 3)
#define TRANSCODER_AMBEPACKET_TIMEOUT 1000 // in ms ( 1 * 1000)

It is correct?

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

yes!
Alternatively, I also have this second solution which is perhaps better than the first.

#define TRANSCODER_KEEPALIVE_PERIOD     2                                   // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT    (TRANSCODER_KEEPALIVE_PERIOD + 1)     // in seconds
#define TRANSCODER_AMBEPACKET_TIMEOUT   (TRANSCODER_KEEPALIVE_PERIOD * 1000)  // in ms

The important thing is that AMBED_OPENSTREAM_TIMEOUT = STREAM_TIMEOUT because the problem solution is there.
I chose this solution in main.h in order to have all the timers synchronized.

Find the code with the changes also on my repository.
https://github.com/lucamarche-iz1mlt

mlt

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Many thx.

from xlxd.

sm0tsc avatar sm0tsc commented on August 15, 2024

yes!
Alternatively, I also have this second solution which is perhaps better than the first.

#define TRANSCODER_KEEPALIVE_PERIOD     2                                   // in seconds
#define TRANSCODER_KEEPALIVE_TIMEOUT    (TRANSCODER_KEEPALIVE_PERIOD + 1)     // in seconds
#define TRANSCODER_AMBEPACKET_TIMEOUT   (TRANSCODER_KEEPALIVE_PERIOD * 1000)  // in ms

The important thing is that AMBED_OPENSTREAM_TIMEOUT = STREAM_TIMEOUT because the problem solution is there.
I chose this solution in main.h in order to have all the timers synchronized.

Find the code with the changes also on my repository.
https://github.com/lucamarche-iz1mlt

mlt

Does the forked XLXD work with your fork of AMBEd with TEAM6160 support?

//TSC

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Yes Luca. I compiled you github
https://github.com/lucamarche-iz1mlt/xlx_ambed --> For my Ambe BAOFARM1 (3 x Unit) 12 Stream
and
https://github.com/lucamarche-iz1mlt/xlxd --> For my XLX051
Working Fine until now.

from xlxd.

sm0tsc avatar sm0tsc commented on August 15, 2024

Luca after installing your branch on XLX010 with a remote ambed it seems we only get the callsign info no voice streams Please advise

//SM0TSC

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Yes, correct. At the time of being working, the audio is cut and only indicative output.
Please help check the code.

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

Strange! Aside from changing the timeouts and removing worning from compiling did not do anything else. What is written on the logs when this phenomenon happens?
I do however have a recheck to the code

from xlxd.

sm0tsc avatar sm0tsc commented on August 15, 2024

Strange! Aside from changing the timeouts and removing worning from compiling did not do anything else. What is written on the logs when this phenomenon happens?
I do however have a recheck to the code

Nothing strange, no missed packets etc on AMBED side...
/TSC

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

Strange! Aside from changing the timeouts and removing worning from compiling did not do anything else. What is written on the logs when this phenomenon happens?
I do however have a recheck to the code

Nothing strange, no missed packets etc on AMBED side...
/TSC

Confirm that the changes made to my fork work?
I seemed to understand that there were problems.

IZ1MLT

from xlxd.

sm0tsc avatar sm0tsc commented on August 15, 2024

Strange! Aside from changing the timeouts and removing worning from compiling did not do anything else. What is written on the logs when this phenomenon happens?
I do however have a recheck to the code

Nothing strange, no missed packets etc on AMBED side...
/TSC

Confirm that the changes made to my fork work?
I seemed to understand that there were problems.

IZ1MLT

Fork compiled 3 days ago does NOT work

//TSC

from xlxd.

sm0tsc avatar sm0tsc commented on August 15, 2024

Luca you can contact me [email protected] If you want access to my setup for debugging

//TSC

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Hi Luca and sm0tsc,
Any solution, please report it to me here or to my email [email protected]
So I can also apply it to my xlx051 and ambed with BAOFARM1.
Thank you.

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

if you use the hardware boafarm you have to use the team6160 ambed, xlxd is fine regardless of the ambe card.

Ambed of the team6160 is also work with the other ambe hardware.
Try to believe, damage is not done, when it comes back.

If you have problems, put the output prints with the errors found.

IZ1MLT

from xlxd.

ea5gvk avatar ea5gvk commented on August 15, 2024

Ok, Many thx, Luca, NOW yes operational. PERFECT.
xlx051 and baofarm1 x 3 =12 stream, ALL PERFECT.
MANY THX LUCA IZ1MLT.

from xlxd.

lucamarche-iz1mlt avatar lucamarche-iz1mlt commented on August 15, 2024

Very well!

For news, I'm working on a version with read configuration from file, like jonathan software. I'll let you know.

73... Luca

from xlxd.

 avatar commented on August 15, 2024

@lucamarche-iz1mlt Has this timeout update fix been added into xlxd by default or do we still have to add it in ourselves? Also can you give the status on the configuration file version?

73

from xlxd.

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.