Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
I am new to Internet Of things. I have pushed temperature data to mosquito server and successfully consumed all data. Now I want to push data from arduino to kafka server and consume from kafka. Is there any kafka library for arduino?
What architecture will be suitable for scaling mqqt using apache kafka?
Thanks
You might wanna take a look at the below article for the architecture and scalability part of your design:
http://www.confluent.io/blog/stream-data-platform-1/
Not tying the answer to a particular language- but personally I find Kafka Library for Java is much more mature than the counterparts.
You could easily write a wrapper around the arduino library (http://mvnrepository.com/artifact/li.rudin.arduino/arduino-api), that collects the data as input and streams it real-time to Kafka as kafka-producer using the library (http://mvnrepository.com/artifact/org.apache.kafka/kafka_2.10).
If you are using Arduino Yun to build your IoT application(s), yes!
Arduino Yun contains two processors, one of these processors runs OpenWRT linux distribution. You can simply port kafka to this OS and run kafka client to push data to apache kafka server.
I've done it myself. To do this, you simply have to access the Yun's root by doing ssh from the terminal.
Run
$ opkg install update
Download the kafka library written in Python (OpenWRT has Python already installed).
Run Python kafka script inside your OS as client. Make sure you have your Yun connected to the network. Poof! It is working now.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
Hi guys I'm creating a device that can be controlled by google assistant;
currently I created an arduino that interfaces with an esp8266 and through the service "IFTTT" I can communicate without problems. Now I would like to extend the project so as to make it public so as to find it in the "Home control" devices of google.
Is it possible to use "Arduino / esp8266"? How?
If it is not possible in this way what kind of board do you recommend?
In order for your device to work with the Google Assistant, you should consult the smart home documentation. If your device can connect to the Internet, you're good. The ESP8266, since it already connects through IFTTT, will work for a more public project as well.
You'll need to create some sort of server backend which will act as the source of truth, responding to requests from the Google Assistant and dispatching commands to devices. If you can use the ESP8266 as a web server with minimal (< 5s) latency, you'll be set. Alternatively, you can use a simple service like Firebase.
Your web server will need to respond to three primary types of intents: SYNC, QUERY, and EXECUTE. The documentation walks through all of them, but they give you the ability to provide devices for each user, return the state of these devices, and send commands to do actions.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 4 years ago.
Improve this question
I am making a small project where there is a qt client application and basic server application written in c++. I am able to connect between two different computers through my application (over SSL, Socket). Now I want to connect my client application to access a sqlite database which is on server.
For example. lets say my client application is a simple login form. When user press Login button then I want my application to access the sqlite database on server, and verify whether the details are valid.
Above a just a example fr explanation. I know I can do the above thing in various other ways but I want the above functionality for something different.I searched a lot over internet but unable to find a good example or explanation. Please through some insight.
SQLite data is stored in a single file, and there's no database server running on top of it. So it does not have any network connection capability. A very simple solution is to make the SQLite database file available on a network in some way like sharing it's directory.
There are other options which use third party libraries :
netSQLite : a client/server solution running over TCP/IP with SQLite3 at its core.
Navicat : enables remote SQLite connection although it is not free.
SQLiteServer: a multithreaded TCP/IP server for SQLite
SQLiteDBMS: a database management server for SQLite. It allows an sqlite3 process to be accessed via a TCP/IP network.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
The community reviewed whether to reopen this question 10 months ago and left it closed:
Original close reason(s) were not resolved
Improve this question
I'm trying to get a deeper understanding of how IIS works.
http.sys i understand is one its major components. However, i have been having trouble finding easily digestible information about it. I couldn't get a good mental model going until i heard about the WSK, then i think it all fell into place.
From a lot of random googling a little experimentation this is my current high level understanding of why it exists and how it does it's stuff.
Why:
Port sharing, and higher performance caching.
How:
User mode processes use the WinSock api to open a socket listening on a port to gain access to the networking subsystem, e.g. tcp/ip. Kernal mode software like the http.sys driver uses Winsock Kernal Sockets (WSK) api to achieve the same end using the same pool of TCP port numbers as the WinSock api.
IIS, a web service or anything that wants to use http registers itself with http.sys using a unique url/port combination. http.sys opens up a socket on this port using WSK (if it hasn't already for another url/port combination with the same port) and listens.
When the transport layer (tcpip.sys) has reconstructed a load of ip packets back into an http request that a client sent it gives it to http.sys via the port in the request. Http.sys uses the url/port number to send it the the appropriate process which parses it however it pleases.
I know it seems like I'm answering my own question but I'm really not that sure of myself on this and would like some closure so i can get on with more interesting things.
Am i close?
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I read about OpenBTS it's really amazing... but I was wondering if we can use it to build phone-to-phone provider-less network.
Any clues or experiments are really appreciated.
One thing to be aware of is that open BTS is 2G/GSM only - i.e. it does not support 3G/UMTS.
This may or may not be important to you depending on what you would like to achieve.
There does appear to be some discussion on adding this functionality in the future (i.e. building an open node b/RNC effectively) but it will be tricky as the authentication mechanism used in 3G requires the network owning the SIM to provide authentication data for even the most basic communication.
GSM follows a strict client-server model. Mobile phones are intended to be clients.
If you would want to build phones with phone-to-phone capability you would need to implement network functionality in the phone. With this, phone-to-phone (theoretically) could be done in an ad-hoc-network model, with one phone running the network part.
I would suspect that one has to look at impacts on the pyhsical/radio layer as well.
Rather unrealistic, IMHO.
May be of interest:
http://terranet.se/history/
So far this company (TerraNet) seem to be only offering sowftware for creating mesh networks over Wifi (I think Wifi is a big disadvantage due to the battery drain. If only we could use GSM), but they seem to share this idea.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I am trying my hands understanding PCAP libraries.
I am able to apply a filter and get the TCP payload at port 80. But what next ? How can I read the HTTP data - suppose I want to know the "User Agent" field value in the http header..how should I proceed ?
I have searched the website (and googled a lot too), and could find a related thread here :
writing a http sniffer. But this doesn't help me anywhere...
Thanks !!
First, you should know that PCAP give you packets, and will not reconstruct the TCP stream so you won't be able to read full HTTP TCP streams without first reconstructing the data.
Assuming all the data is available in one packet try and look at my answer for a similar question. All you need to do different is to parse the HTTP header and get the user agent.
If you don't limit yourself to C, and if you can use Windows, you can write a .NET application and use Pcap.Net to parse Ethernet, IPv4 and TCP perfectly.
Why don't you use a Wireshark Dissector?
There is already a good Pcap wrapper for .net called Pcap.Net - here it is
"Pcap.Net is a .NET wrapper for
WinPcap written in C++/CLI and C#. It
Features almost all WinPcap features
and includes a packet interpretation
framework."