Question

Hi I have written a decibel level meter in C which reads Linux alsa constantly and output decibel levels numbers in STDOUT.

Now I would like to view via HTTP and streaming live data to clients, with proper js+html decoration, it behaves as a noise meter, with graph and needles.

Therefore I would like to know if some one can point me direction integrate them into a HTTP streaming server able to server multiple clients in real time.

Était-ce utile?

La solution

You can use several C libraries. Some C libraries provide HTTP server abilities, e.g. libonion or libmicrohttpd. Other libraries provide HTTP client abilities, e.g. libcurl

All are using some event loop, e.g. libev, libevent or at least some multiplexing syscall like poll(2)

You could also make your application a FASTCGI app.

Reading Advanced Linux Programming should help.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top