My question is about whether I can connect to peerjs without a browser. So if or how I can create a WebRtc video and data peer to peer connection between a device that send and a device that can see the video through the browser.
So far I have a well working WebRtc connection from one browser to the other. I have a website using NodeJS, a peerjs server as well as a stun and turn server running and I connect using the peerjs api using the javascript code that is executed in the browser.
However, I would like to connect on one side without a browser, for example to make it more efficient on a Raspberry pi.
I found this example which provides a python port for peerjs, but it is very hard to understand and poorly documented.
https://github.com/ambianic/peerjs-python
I was able to connect to my peerjs server with this. Now I can't get any further.
I would appreciate any suggestions to solve this problem or any other ideas or examples to establish a connection using peerjs without a browser. Maybe with c++ or Nodejs.
You can use a native WebRTC library like libdatachannel. The examples show how to connect browsers to native clients, and you might adapt them to be compatible with the PeerJS signaling protocol. It features a C and C++ API but there is also a Node.js wrapper.