Giter VIP home page Giter VIP logo

sipdotnet's People

Contributors

3dprogramin avatar bedefaced avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sipdotnet's Issues

PInvokeStackImbalance was detected

Hi,

I'm trying to get this working (Win 8.1 x64), ive dropped the windows dll's from your mega link in to the bin folder, however when running the code i'm hitting this exception.

"A call to PInvoke function 'sipdotnet!sipdotnet.Linphone::linphone_core_new' has unbalanced the stack. This is likely because the managed PInvoke signature does not match the unmanaged target signature. Check that the calling convention and parameters of the PInvoke signature match the target unmanaged signature."

on this line: linphoneCore = linphone_core_new(vtablePtr, null, null, IntPtr.Zero);

Any ideas why?

James.

Audio issue, probably NAT related

Summary:
I have built a simple WPF app using sipdotner, and calls both inbound and outbound are working. However, audio is not present for outbound calls.

Details:
Linphone works fine on the same PC, but an app built on sipdotnet has no audio for outbound calls.
It appears that the SDP packet has the internal IP of the machine from which the call is placed.
Screen cap of sngrep is here: https://cloud.branham.us/apps/gallery/s/Id1kajHUg5iMvRz

It's almost certainly a NAT issue, of course, but so far I've been unable to properly send the external IP in the SDP packet. I've tried several different ways to set a STUN server address and enable its usage but nothing so far has worked. Since I know the hostname/IP of the machine to which I'm connecting, I'd like to try setting an explicit value for the address just to confirm that this is the issue, but I haven't been able to do that, either.

The source code is at https://cloud.branham.us/s/RTpEdob706R0uWi. The area in the code where I'm setting up STUN is near the bottom of the CreatePhone method. I pasted a copy of the method at the top of the source file to make it easier to find.

Any help you can offer would be greatly appreciated!
Richard

Help Please!

How do I add linphone.dll to my C # project in Visual Studio?

When I run my sipdotnet test project, this is appearing to me;

{"Unable to load DLL 'linphone.dll': No se puede encontrar el módulo especificado. (Exception from HRESULT: 0x8007007E)"}

Audio disappears if Process is killed

Hi!

I think I found a way to replicate the issue partially described in #22

If you start a Call, and then kill the process while it is still in Call, the next instance of the liblinphone app will be muted.

Using Process.Kill() during a Call, I can replicate this issue almost every time.
After some while, audio will be back working.

Thank you

Read Custom Headers

Hi!

I just need some help with reading Custom Headers.
I tried to implement by myself this methods like this:

[DllImport(LIBNAME, CallingConvention = CallingConvention.Cdecl)]
static extern IntPtr linphone_call_params_get_custom_header(IntPtr callparams, string header_name);

[DllImport(LIBNAME, CallingConvention = CallingConvention.Cdecl)]
static extern IntPtr linphone_call_get_remote_params(IntPtr call);

But in OnCallStateChanged, if I try to

var param = linphone_call_get_remote_params(existCall.LinphoneCallPtr);

byte[] bytes = Encoding.Default.GetBytes("HEADER_NAME_HERE");
var myString = Encoding.UTF8.GetString(bytes);

IntPtr test = linphone_call_params_get_custom_header(param,  myString);
var str = Marshal.PtrToStringAnsi(test);

I always get null result.
@bedefaced Do you have any suggestions?

Thank you

Error "Could not load DLL file linphone.dll"

Hi, I have a problem with the published version of the application, it is a windows forms application C #, when I try to make a call it gives me the error that "DLL file 'linphone.dll can not be loaded. please your support one more time, thank you very much for the help.

Unable to find linphone.dll

Hi,
i think i need a bit of help...

i wrote a small program to use as intercom on raspbian. (actually wrote in VS2013 then moved exe to raspbian.)
On execution, (mono exefilename) i get this error:

Unhandled Exception:
System.DllNotFoundException: linphone.dll

The dll is there, together with the Exe file i'm calling.
Also, i tried to compile on raspbian, with xbuild, but i get the same error....i don't know where to smack my head! I'm targeting .net framework 4. The same projects (without the gpio below enabled, works fine on windows.)
Also, i'm using a dll to make use of the Gpio of the raspberry and that is working fine....the dll is in the same folder.

Help please!!

Thanks
Giulio

Success create call but no sound when it picked up.

Account account = new Account("1001","mypassword", "192.168.100.1");
 phone = new Phone(account);
 phone.PhoneConnectedEvent += delegate ()
 {
     phone.MakeCall("1002");
 }

this scripts are work. but when the call picked up from other party. the sound is not transfered.
is it related your experimental feature "PlaybackDevices, CaptureDevices"? and can you give us an example how to use it?

Please Help Me With Example

bedefaced, so as not to be creating a lot of issues, I will explain with an image what I need to be able to do, and who knows, you may be helping me. As you already seem to be an expert in the theme, what I need to do is something basic, a form in C #, which contains the following functions: Call, End Call, and I will save the call in an mp3 file. If it's not too much trouble, and you can support me with a simple example project, thank you very much. Thank you for all the attention so far.

Possibility to forward call

It would be great to have a method to forward the current incoming call on another phone extension or on a mobile :)

Unable to send and receive chat message

i am trying to implement chat message functionality using linphone library. but there is no chat message functionality. I have no idea, how to implement .

please help me on this .

Memory leak

i am facing app crashes every few hours of using the class. The Windows event logs indicate that the app crashed due to:
Faulting module name: ucrtbase.dll, version: 10.0.16299.248, time stamp: 0xdcc3eab0

The app crashes even if there are no calls or no activity at all. So i am suspecting maybe there is a memory leak in the loop LinphoneMainLoop() calling linphone_core_iterate as some suggested it in some old articles:
https://lists.nongnu.org/archive/html/linphone-developers/2014-07/msg00050.html

I am not sure how to resolve it. Any suggestions please.

Library does not display destination phone number while incoming call

case LinphoneCallState.LinphoneCallIncomingReceived:
				case LinphoneCallState.LinphoneCallIncomingEarlyMedia:
					newstate = Call.CallState.Loading;
					newtype = Call.CallType.Incoming;
                                        addressStringPtr = linphone_call_get_remote_address_as_string(call);
                                        if (addressStringPtr != IntPtr.Zero) from = Marshal.PtrToStringAnsi(addressStringPtr);
					to = identity;

Problem here is that "to" variable contains just identity like "sip:user1@...", but does not takes any information about destination phone number from incoming call.
Any ideas what linphone function can we use for it?

RegisterFailed in case of IP to IP call (no proxy)

I am trying to register an Account object for IP to IP call as follows:

        Account account = new Account("sip", "", "127.0.0.1", 5060); // no password
        Phone phone = new Phone(account);
        phone.IncomingCallEvent += delegate (Call call) {
            Console.WriteLine("Incoming call.");
        };
        phone.ErrorEvent += delegate (Call call, Phone.Error error) {
            Console.WriteLine("Error: " + error.ToString());
        };
        phone.Connect(); // connecting

I get RegisterFailed. Does this wrapper (and linphone) support direct IP to IP without proxy? If so, can anyone please help me find the error in the code snippet above? (any idea on the SIP account parameters?)

Thanks,
Hisham

Problemas con conexion

Al utilizar la libreria me aparecen los siguiente errrores alguien sabe por que?
[DEBUG] Connection failed for fd [2592]: cause [No se puede establecer una conexión ya que el equipo de destino denegó expresamente dicha conexión.
]
[DEBUG] channel 151C1578: state ERROR
[DEBUG] Cannot connect to [TCP://192.168.15.8:5060]
[DEBUG] transaction [0DEF4088] channel state changed to [ERROR]
[DEBUG] Refresher[0DED4A30]: scheduling next timer in 500 ms for purpose [retry]
[DEBUG] Register refresher [503] reason [io error] for proxy [sip:192.168.15.8:5060]
[DEBUG] Proxy config [07B3D760] for identity [sip:[email protected]] moving from state [LinphoneRegistrationProgress] to [LinphoneRegistrationFailed] on core [07AEE1D8]
[DEBUG] Linphone core [07AEE1D8] notified [registration_state_changed]
[DEBUG] OnRegistrationChanged: LinphoneRegistrationFailed
[DEBUG] Changing [client] [REGISTER] transaction [0DEF4088], from state [INIT] to [TERMINATED]
[DEBUG] Client internal REGISTER transaction [0DEF4088] terminated
Waiting for task completion: System.Object b__84_1()
[DEBUG] Channel [151C1578] destroyed

How to end call that i started?

Hello, i asume that for ending a call which i recive i can retrieve the call object with the event incomingCallEvent, but i dont see the way to retrieve the call object when i start the call.

"System.AccessViolationException" in LinphoneMainLoop

Hi!

After starting main linphone loop( class Linphone> method LinphoneMainLoop) with test code suggested in README i always get an exception
Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
when thread tries to invoke linphone_core_iterate(linphoneCore); for the first time.

If i ignore this exception and continue execution other linphone_core_iterate calls work without exception. May be there is a problem with thread sync in wrapper? Anyone had same issue?

Any thoughts appreciated, thanks!

Links broken

Hello
The links to the binaries of liblinphone are both broke broken. In the current release of libLinphone is no dll called "liblinphone-6.dll" which dll can we use instead?. mega.co.nz -link is also broken.

I have no GCC experience to compile the binaries for myself.

Thanks.

unable to use library

I receive the following message:

A call to PInvoke function 'sipdotnet!sipdotnet.Linphone::linphone_core_new' has unbalanced the stack. This is likely because the managed PInvoke signature does not match the unmanaged target signature. Check that the calling convention and parameters of the PInvoke signature match the target unmanaged signature.

Unable to find 'liblinphone.dll'

Hi! So I'm trying to call Phone.Connect(), and the error 'unable to find Liblinphone.DLL' occurs. If I remove this line it doesn't happen, but also this line is essential to connect my created phones. I've tried the solutions previously suggested (checking how it is compiled, redownloading the SDK and libraries, etc.), but have not had any success. Any help would be appreciated!

Can't record the call

I tried to use MakeCallAndRecord method, but there is no recorded file.
Can you please help me, Thank

Audio codecs, echocanceletion, keep alive query and auto registration

HI! Thank you for your solution.
We try to integrate your solution in our project, but didn't found next things:

  1. How to switch on keep alive query. Is it possible?
  2. How to change audio codec, we want to use G722 by default.
  3. Is echocanceletion on or off? How we can detect it?
  4. How make set timer for registration?
  5. Can we use some config file ?

If you could chat with me in skype, it would be great.

Invalid From number determined

I catched next problem while using library. First one or set of first calls are coming to library correct and have correct "From" number in instance of "Call" class.
However set of next calls have From address exactly like the last the one call (in fact they are different).
It looks like some unnecessary caching at first look.

For example:

  1. 04.11.2016 18:37:12: 792310115XX
  2. 04.11.2016 18:37:36: 792319018XX
  3. 04.11.2016 18:46:22: 791393165XX
  4. 04.11.2016 18:46:35: 791393165XX
  5. 04.11.2016 19:23:59: 791393165XX

Like you can see, last three calls have same From number, but in SIP they all are different. Only call #1, #2 and #3 have correct numbers. Calls #4 and #5 are incorrect.

System.BadImageFormatException

System info

  • Windows 10
  • Visual Studio 2017 Community
  • .NET 4.0

Problem

Getting a System.BadImageFormatException at runtime.
I'm trying to get this runnig the 3rd time now, but getting the same error all the time.

Here is the error:
screenshot


VS is also showing warnings, methods being deprecated:

screenshot_2

I've used the linphone DLLs from the repo.

If there's anything I can provide, let me know.

Thanks in advance !

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.