Page 1 of 1

Basic web app submitting parameters and acquiring data

Posted: Thu May 14, 2015 12:15 pm
by sidiouss
Hello!
I'm Michał and I'm from Poland.
It's my first post on the forum, but I'm following all the topics for a long time :)
Thanks for the RedPitaya, it is such a good instrument and development tool :)

I'm trying to build an web app that would have a form in which all the parameters of the lcr application would be submitted to the lcr exec and after measurements all the data would be displayed as a text and (in the future) send to an SQL database.

And I have some questions:
- What is the easiest way to submit parameters filled in the web form to the lcr (or another app) executable and receive output data?
- Are there any libraries on RedPitaya which are to be used with databases e.g. libpq?

Thanks in advance for all advice!

Best regards,
Michał

Re: Basic web app submitting parameters and acquiring data

Posted: Sat May 16, 2015 12:20 am
by Nils Roos
Hi Michał,
- What is the easiest way to submit parameters filled in the web form to the lcr (or another app) executable and receive output data?
The easiest way that I know of is to have the web form post its contents to a cgi-script. The script would parse the parameters, call an application of your choice and do something with its output - like, for example, generate hmtl from the data.

There are security and performance concerns with this method, but it is very simple to set up and anything you can do in a shell, you can do in the script. Last time I did anything like that was in the early oughties, so there are bound to be better approaches, but it's a start.
- Are there any libraries on RedPitaya which are to be used with databases e.g. libpq?
No