Open source Very Long Baseline Interferometry
OpenVLBI
|
You can write an application using libopenvlbi by linking against libopenvlbi.so in your gcc command line:
gcc yourapp.c -lopenvlbi -o yourapp
Each instance of vlbi is initiated by vlbi_init():
...
stream1->location.geographic.lat = Latitude;
stream1->location.geographic.lon = Longitude;
stream1->location.geographic.el = Elevation;
...
vlbi_add_node(context, stream2, "location2_capture", 1);
...
vlbi_add_stream(context, stream3);
...
double* target = calloc(sizeof(double), 3);
target[0] = RightAscension * 360.0 / 24.0;
target[1] = Declination;
double frequency = 60.0e+6;
double samplerate = 100.0e+6;
int no_delay_calculation = 0;
int moving_baseline = 0;
vlbi_get_ifft(context,
"ifft_estimation",
"obs1_plot_model",
"my_phase_estimation");
...
dsp_stream_free_buffer(image_estimation);
You can read the API documentation at https://iliaplatone.github.io/OpenVLBI/
DLL_EXPORT vlbi_context vlbi_init(void)
Initialize a OpenVLBI instance.
DLL_EXPORT void vlbi_exit(vlbi_context ctx)
Close a OpenVLBI instance.
DLL_EXPORT void vlbi_get_uv_plot(void *ctx, const char *name, int u, int v, double *target, double freq, double sr, int nodelay, int moving_baseline, vlbi_func2_t delegate, int *interrupt)
Fill a fourier plane with an aperture synthesis projection of the baselines during the integration ti...
DLL_EXPORT void vlbi_add_model_from_png(void *ctx, char *filename, const char *name)
Add a model from a png file.
double vlbi_default_delegate(double x, double y)
A placeholder delegate that simply multiplies the values received from vlbi_get_uv_plot.
Definition: vlbi.h:635
Contains a set of informations and data relative to a buffer and how to use it.
Definition: dsp.h:375
DLL_EXPORT void dsp_stream_free(dsp_stream_p stream)
Free the DSP stream passed as argument.
DLL_EXPORT dsp_stream_p dsp_stream_new(void)
Allocate a new DSP stream type.
DLL_EXPORT void dsp_stream_alloc_buffer(dsp_stream_p stream, int len)
Allocate a buffer with length len on the stream passed as argument.
DLL_EXPORT void dsp_stream_add_dim(dsp_stream_p stream, int len)
Add a dimension with length len to a DSP stream.
void * vlbi_context
the OpenVLBI context object type
Definition: vlbi.h:345
DLL_EXPORT void vlbi_get_ifft(vlbi_context ctx, const char *name, const char *magnitude, const char *phase)
Save into name an inverse fourier transform of the uv plot using its current magnitude and phase comp...
DLL_EXPORT timespec_t vlbi_time_string_to_timespec(const char *time)
Obtain a timespec struct containing the date and time specified by a time string.
#define dsp_buffer_copy(in, out, len)
Fill the output buffer with the values of the elements of the input stream by casting them to the out...
Definition: dsp.h:1051
DLL_EXPORT dsp_stream_p vlbi_get_model(void *ctx, const char *name)
Get a single model from the current OpenVLBI context.
DLL_EXPORT void vlbi_add_node(vlbi_context ctx, dsp_stream_p Stream, const char *name, int geographic_coordinates)
Add a stream into the current OpenVLBI context.