Comments (19)
First, you need to fork my work and adapt the socket layer with this package or an other that do the same things : https://www.npmjs.com/package/react-native-tcp-socket
Then, with this fork, adapt protobuf layer with this example : https://medium.com/@singhandresh09/using-protobuf-in-react-native-7cc8286389f5
from androidtv-remote.
Thanks @louis49. Working on it.
from androidtv-remote.
@louis49 Should i convert the pairingmessage.proto and remotemessage.proto in JS files using protoc compiler and use for message passing.
from androidtv-remote.
@louis49 Thanks. Was able to solve the .proto thing using google-protobuf.
I used the react-native-tcp-socket as suggested
Now i am stuck at TLS connection between client and server. Below is the screenshot attached.
from androidtv-remote.
@louis49 The issue is that in PairingManager.js in this.client.on('data') function, the data coming is not satisfying thhe
if condition. this.chunks.length > 0 && this.chunks.readInt8(0) === this.chunks.length - 1
.
Due to which Pairing code is not coming on TV
@louis49 Can u please help me solve the same.
from androidtv-remote.
For .proto files you can transform them in pure json : https://github.com/protobufjs/protobuf.js/#using-json-descriptors
from androidtv-remote.
@louis49 Proto thing is solved by transforming in pure json. The last thing in which i am stuck is
The issue is that in PairingManager.js in this.client.on('data') function, the data coming is not satisfying thhe
if condition. this.chunks.length > 0 && this.chunks.readInt8(0) === this.chunks.length - 1.
Due to which Pairing code is not coming on TV
@louis49 With ur guidance almost achieved the end goal. the above issue is creating a issue
from androidtv-remote.
@louis49 Can u please help on above issue mentioned
from androidtv-remote.
This line means that we are waiting enough data to analyze the received frame : the first byte say how many byte we are waiting.
What’s the size of the chunk you receive ?
from androidtv-remote.
@louis49
We just receive this much data {"data": [21, 3, 1, 0, 2, 2, 70], "type": "Buffer"} and after that no data. We only get this 7 bits of data.
No Idea why its happening. Can u please help
Want to share an observation.
After deeply analysing, I saw that object var options = { key: this.certs.key, cert: this.certs.cert, port: this.port, host: this.host, rejectUnauthorized: false, }
we pass in TcpSocket.createConnection is same as we pass in tls.connect.
Connection option in react-native-tcp-socket does not have key and cert .export ConnectionOptions = { port: number; host?: string | undefined; timeout?: number | undefined; localAddress?: string | undefined; localPort?: number | undefined; interface?: "wifi" | "cellular" | "ethernet" | undefined; reuseAddress?: boolean | undefined; tls?: boolean | undefined; tlsCheckValidity?: boolean | undefined; tlsCert?: any; };
from androidtv-remote.
To go more deep in that problem I need to observe it : can you publish your code ?
from androidtv-remote.
Yes Sure @louis49. U must have got the invite email. Can u please confirm? I have published the code there. Thanks Again @louis49
In the meantime, Any idea which part of the code should i look to get it fixed.
from androidtv-remote.
Hi @piyush2cloud I'm also trying to implement this on iOS if you want to team up on this or share some insights.
what's your email or Skype so I can contact you?
from androidtv-remote.
Hi @SodaSurfer
Sure. U can join me on below skype link.
https://join.skype.com/invite/w3bZKQNQ3GpY
from androidtv-remote.
Yes Sure @louis49. U must have got the invite email. Can u please confirm? I have published the code there. Thanks Again @louis49
In the meantime, Any idea which part of the code should i look to get it fixed.
@louis49 Can u also tell what timezone u r based of
from androidtv-remote.
Yes Sure @louis49. U must have got the invite email. Can u please confirm? I have published the code there. Thanks Again @louis49
Github Repo Link
In the meantime, Any idea which part of the code should i look to get it fixed.@louis49 Can u also tell what timezone u r based of
@louis49 Did u got some bandwidth to check
from androidtv-remote.
I’m in UTC+1 but i’ve a real life too : let me fews days to analyze it
from androidtv-remote.
I’m in UTC+1 but i’ve a real life too : let me fews days to analyze it
Sorry @louis49. Actually i was stuck in it and ur inputs were really helpful.
I was really getting frustated on this part and with no option just messaged u. Sorry Again @louis49.
from androidtv-remote.
HI! I watched your code but I didn't succeeded to run it on my Mac M1 : cocoa pods config seems not well configured for it
from androidtv-remote.
Related Issues (20)
- Setup Help - Hostname HOT 3
- keyboard keys are not working HOT 1
- get mac address
- send more data to TV with the app deep link
- Remote installation of app?
- Suggested improvements HOT 1
- can you write a swift version HOT 14
- How I can run this library in my react native project. I need to create a mobile app HOT 6
- Unhandled 'error' event in TLSSocket HOT 1
- How to send text HOT 2
- Method to send voice and send text HOT 4
- Send text, analog adb command: "shell input text" HOT 1
- Andoird TV: send mouse movement / get the installed app HOT 1
- Error: connect ECONNREFUSED HOT 2
- Ping message issue and resulted closed connection HOT 2
- Android TV (v2) 1st Configuration Message get error from TV
- Unhandled error (at TLSSocket.<anonymous> (/.../RemoteManager.js:107:21))
- setting the volume is not working
- HI! Is it possible to integrate it with React Native? HOT 1
- How to save the auth token to keep connected?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from androidtv-remote.