Hackuarium / bioreactor-ui

https://hackuarium.github.io/bioreactor-ui/.
0 stars 1 forks source link

Parsing the simple parameters #15

Closed lpatiny closed 3 years ago

lpatiny commented 3 years ago

The simple spectra and openbio6 parameters are described in the file https://github.com/Hackuarium/legoino-device-information/tree/master/src/devices

For the spectro (and bio) we have the following commands (each command should be followed by \n)

The result of compact settings (uc) can be parsed using : https://hackuarium.github.io/legoino-util/#parsecurrentsettings You should set the options: parametersArray, parameterLabel and parameterInfo (maybe also flatten. kind should be SimpleSpectro or OpenBio6.

For the Simple Spectro some parameters are editable. A parameter is always one or more uppercase. You can read a parameter using 'uc' but one parameter can also be read using the parameter name. For example entering K will read the delay before blank : https://github.com/Hackuarium/legoino-device-information/blob/master/src/devices/SimpleSpectro.js#L86

If you want to set this parameter you should enter K123 where in this case the value 123 is the delay in seconds. We need to take care in the user interface that some parameters need to be converted using the 'factor'. In the spectro all the parameters are int16 (so a number between -32768 and 32767).

The following parameters should be editable: K, L, M, N, O

Command r running an experiment

If you send r the experiment will start. The system will wait K seconds then start the acquisition of the reference they wait L second and start the experiment of the sample. Reading parameter P should allow to know how long we should wait before the next even and display the waiting time in s.

The results are stored in the parameters F,G,H,I and A,B,C,D

Once this is done we will think about a small graphical interface to display what is going on