91 Commits

Author SHA1 Message Date
9834b07b47
Dev/fix port size (#805)
* port datatype changing from int to uint16_t
* throwing for -1 given for uint16_t ports
2023-09-28 09:36:39 +02:00
d65825e9ef
Rx roi zmq (#726) (#740)
adding rx_roi also in the zmq header for external guis to put the "yellow box".. sending full roi instead of -1, and sending for each zmq port. "(multiple yellow boxes)".
2023-05-08 16:03:48 +02:00
4ee4d66977
Jf zeromq display (#644)
* modified ZmqSocket to expose the SO_RCVBUF and SO_SENDBUF parameters. Modified DataStreamer.cpp to change the SENDBUF to 1MB when HWL is <10. Modified Datastreamer.cpp so that when HWL is changed, socket is unbind/rebind. Added rebind to ZmqSocket.cpp.
Changed slot UpdatePlot() in qdrawplot.h from privat tto public, added plot->UpdatePlot() after every axis range change, so the plots are updated immediatly and not at the next image.
Added onlinedisp_zmq program which connects to the receiver ZMQ port and show images and histos. Compiled against  ROOT 6.22/02. Added examples files.

* added setbuffer size also for gui, moved hardcoded values to a macro, removed unnecessary return of ok or success, added actual zmq exception message to could not create sockets error

* zmq: changing buffer size done within hwm

---------

Co-authored-by: mozzanica <l_mozzanica@mpc2012.psi.ch>
Co-authored-by: Dhanya Thattil <dhanya.thattil@psi.ch>
2023-02-09 17:24:28 +01:00
Dhanya Thattil
4bb1a612f1
changed detector header version to detector specific field names and incremented version number, also for zmq (#574) 2022-11-17 15:24:12 +01:00
Dhanya Thattil
6bf9dbf6d3
Format (#506)
Formatted package
2022-08-05 15:39:34 +02:00
Dhanya Thattil
89e293cb5a
Rxpointers (#504)
* gui message doesnt show if it has a '>' symbol in error msg

* minor refactoring for readability (size_t calc fifo size)

* refactoring listening udp socket code: activated and datastream dont create udp sockets anyway, rc<=- should be discarded in any case

* wip

* refactoring memory structure access

* wip: bugfix write header + data to binary

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* portRoi no roi effecto on progress

* fail at receiver progress, wip

* segfaults for char pointer in struct

* reference to header to get header and data

* refactoring

* use const defined for size of header of fifo

* updated release notes

* remove pointer in callback for sls_receiver_header pointer

* rx same name arguments in constructors

* rx: same name arguments in constructor

* rx: removing the '_' suffix in class data members

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* diff undo for clang later

* wip

* Wip

* const string&
2022-08-05 09:08:18 +02:00
Dhanya Thattil
9ac8dab8af
Rxclassmembers (#503)
* gui message doesnt show if it has a '>' symbol in error msg

* minor refactoring for readability (size_t calc fifo size)

* refactoring listening udp socket code: activated and datastream dont create udp sockets anyway, rc<=- should be discarded in any case

* wip

* refactoring memory structure access

* wip: bugfix write header + data to binary

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* portRoi no roi effecto on progress

* fail at receiver progress, wip

* segfaults for char pointer in struct

* reference to header to get header and data

* refactoring

* use const defined for size of header of fifo

* updated release notes

* remove pointer in callback for sls_receiver_header pointer

* rx same name arguments in constructors

* rx: same name arguments in constructor

* rx: removing the '_' suffix in class data members

* merge fix

* merge fix

* review fix refactoring
2022-07-25 14:02:11 +02:00
Dhanya Thattil
4117cda79b
Rx: refactor memory structure and listener (#496)
* gui message doesnt show if it has a '>' symbol in error msg

* minor refactoring for readability (size_t calc fifo size)

* refactoring listening udp socket code: activated and datastream dont create udp sockets anyway, rc<=- should be discarded in any case

* wip

* refactoring memory structure access

* wip: bugfix write header + data to binary

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* portRoi no roi effecto on progress

* fail at receiver progress, wip

* segfaults for char pointer in struct

* reference to header to get header and data

* refactoring

* use const defined for size of header of fifo

* updated release notes

* refactoring from review: fwrite, static_cast
2022-07-22 15:32:41 +02:00
Dhanya Thattil
4259363169
rxr sls namespace (#457)
* rxr src files and classes (detectordata, ZmqSocket) added to sls namespace

* moving defines inside namespace

* moving defines inside namespace, added helpdacs to namespace

* added namespace to gui

* gui also updated

* removed unnecessary sls:: when already in sls namespace for slsDetectoSoftware, receverSoftware, slsDetectorGui and slsSupportlib
2022-05-18 11:48:38 +02:00
Dhanya Thattil
fcc7f7aef8
Rx roi (#428)
* roi structure expanded to have ymin and ymax

* compile with 'detector roi'

* wip

* wip, rx_roi, rx_clearroi

* wip rxroi

* rxroi wip

* wip rxroi

* merge fix

* wip

* rx_roi works, impl wip, test

* tests in, impl left

* wip, rxroi impl

* wip, rxroi impl

* wip

* setrx_Roi works, getrx_roi, wip

* rx_roi impl done

* wip, rxroi

* wip, getrx_roi rxr ports

* fix ports

* wip

* wip

* fix positions on server side

* wip

* numports wip

* wip

* jungfrau top inner interface row increment

* x, y detpos, wip

* removed eiger row indices flipping in gui (bottom flipping maintained)

* wip

* wip, jungfrau numinterfaces2

* jungfrau virtual works

* eiger, jungfrau, g2 virtual server works

* eiger positions fix, wip

* binaries in

* minor printout

* binaries in

* merge fix

* merge fix

* removing getposition

* setrxroi wip

* set upto port

* get messed, wip

* roi multi to module works, wip

* wip

* roi dont return -1

* added rxroi metadata in master file

* added rxroifromshm, not yet in detector

* rx roi in gui with box, also for gap pixels (gappixels for jungfrau mess)

* fix for segfault in gui with detaching roi box in gui

* wip

* m3 gui: slave timing modes should be discarded when squashing

* fixed m3 virtual data, and fixed counters in gui asthetics

* m3 roi works

* wip, g2

* wip

* handling g225um boards, and showing roi for gainplot as well

* udpate python functions

* fix for 1d and a2d roi written

* fixed actual roi written to file

* no virtual hdf5 when handling rx roi

* test

* minor

* binarie in
2022-05-16 12:35:06 +02:00
Dhanya Thattil
afeee5501c
Fixpositions (#436)
* fix positions on server side

* wip

* numports wip

* wip

* jungfrau top inner interface row increment

* x, y detpos, wip

* removed eiger row indices flipping in gui (bottom flipping maintained)

* wip

* wip, jungfrau numinterfaces2

* jungfrau virtual works

* eiger, jungfrau, g2 virtual server works

* eiger positions fix, wip

* binaries in

* minor printout

* binaries in

* pointer bug

* comment to define test_mod_geometry define
2022-04-28 16:32:26 +02:00
bf43b003b6 using xy instead of portGeometry 2022-01-24 15:42:25 +01:00
b39c64032d clang format 2021-10-19 14:49:43 +02:00
dac60ad76d added .cpp licenses 2021-10-15 15:47:04 +02:00
619f3b71c1 flippeddataoverxaxis changed to flipRows 2021-08-05 14:44:25 +02:00
c30716db12 Wip 2021-07-02 16:09:57 +02:00
Erik Fröjdh
a15d8dd30a
Moving headers into include/sls (#212) 2020-11-02 16:05:28 +01:00
6c1035aa99 zmq hwm are specified to 2 for gui and restreaming of receiver if all zmq not closed at end of acquiistion 2020-10-08 13:01:01 +02:00
ea601fe1f7 lock to ensure json add header can be updated on the fly 2020-09-07 11:52:51 +02:00
f0c576c779 WIP 2020-09-07 11:15:51 +02:00
3bdf02a23c rx_zmqstartfnum added to have an offset of streaming frame numbers 2020-07-17 11:11:19 +02:00
eea67014b7 gotthard2 with veto data on second interface 2020-05-13 17:50:18 +02:00
Erik Frojdh
e599bb7c24 format receiver 2020-05-05 10:04:52 +02:00
Erik Fröjdh
c1ae67ac46
Small refactor on ThreadObject and listener (#93)
* removed pointer, slight cleaning of loop

* removed semaphore, use getters

* removed redundant log msg

* removed comment

* added const

* removed comment

* changed header
2020-04-21 09:45:29 +02:00
Erik Frojdh
815b6a37aa moved flag to base class 2020-04-16 13:22:51 +02:00
Dhanya Thattil
fdb6e3f3d4 Removeshm (#90)
* eiger: moved rate correction outside, fixed threshold energy bug in client (binaries not  updated yet)

* removed dr and deadtiem from shm

* help for rx_status and status to point them to rx_Start, rx_stop, start and stop

* moved progress to receiver

* removed currentsettings from eiger shm

* updated server binaries, and client api

* moench and ctb virtual servers compile fix

* gui: moved acquire to a concurrent qt thread so it doesnt block updateplot
2020-04-06 10:44:44 +02:00
Dhanya Thattil
d58eb1dc6e
Gappixels (#89)
* WIP

* WIP virtual delays, imagetest for saturation

* WIP, vertical and horizontal

* WIP

* gap pixels work, fixed 32 bit data out (10gbe=0) for virtual servers

* quad works (also in virtual), handling gappixels and quad

* jungfrau gapppixels work

* jungfrau: done

* complete image or missing packets given in json header and gui

* eiger virtual 4 bit mode bug fix

* working version of zmq add json header, except printout

* printout bug

* fix for json para

* to map WIP

* map done

* map print , mapwith result left

* json result works, testing added

* updated server binaries

* compiling on rhels7, variable size char array iniitalization

* zmqsocket parsing didnt need Document

* const to map, json para is strings not map

* json add header: mapping cleaner without insert make_pair
2020-03-30 14:54:35 +02:00
b608ec6fbd zmqsocket: fname to string to remove warning in copying maxstr in maxstr in json header 2020-03-19 10:24:08 +01:00
Erik Frojdh
0de0d82a1a replaced old logger 2020-03-11 12:40:12 +01:00
1a8337540a rxr: switched to threads for threadObject (from pthread), moved priorities to threadObject, mutex 2019-11-29 16:19:02 +01:00
2ece6b945e rxr: warnings shouldnt throw exception 2019-11-29 11:09:41 +01:00
1d6be74ee5 rxr: removed return ok or fail and replaced with exceptions 2019-11-29 10:29:36 +01:00
f2c0ff7f98 rxr: removed char array memebers in rxrimplementation 2019-11-18 14:29:01 +01:00
eb2040f0a7 fixed effects of scan 2019-10-29 14:43:51 +01:00
Dhanya Thattil
995f0924e5
Commandline (#66)
* WIP

* WIP

* removed status to string from defs

* WIP

* WIP

* WIP removed unused functions in multi

* WIP

* print hex in a terrible way

* WIP, loadconfig error

* WIP, type to string

* WIP

* fix to conversion

* WIP, hostname doesnt work

* WIP

* WIP

* WIP

* WIP, threshold

* WIP, threshold

* WIP

* WIP, triggers

* WIP, cycles to triggers

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* rx_udsocksize fx, WIP

* WIP

* WIP

* WIP

* file index (64 bit), WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* merge

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* WIP

* New python mod
2019-10-21 10:29:06 +02:00
ba0c6ff286 eiger bug fix: quad gap pixels 2019-08-14 17:49:09 +02:00
d4d8cbe9bc gotthard fixed roi only xmin and xmax.remove updateoffsets 2019-08-14 09:20:50 +02:00
Dhanya Thattil
e7a76ccea1
Quad (#39)
* making quad work in developer branch

* binary added

* minor changes

* bug fix to set quad to 0 when more than 1 detector
2019-07-22 16:41:03 +02:00
Erik Frojdh
24fc5de58d clang-tidy header include order 2019-05-14 17:34:51 +02:00
Erik Frojdh
97692ae3ab moved from c headers 2019-05-14 17:17:21 +02:00
Erik Frojdh
74d67261a9 no check for null when deleting 2019-05-14 17:09:24 +02:00
89a06f099c merging refactor (replacing) 2019-04-12 10:53:09 +02:00
Erik Frojdh
cd738106ec printf and uninitialized variables 2019-02-08 11:14:16 +01:00
c2db073d5e receiver and client: changed xcoord to row and ycoord to column, zcoord to reserved 2018-09-26 15:03:04 +02:00
9f84bf7175 gui: crashing when using roi fixed 2018-09-20 18:10:10 +02:00
c784f0f539 client: moved shortenable to roi in reciever, roi not yet written in master file 2018-09-19 17:35:26 +02:00
830f92dedc client and receiver: silent mode put into shared memory, works properly now 2018-08-15 19:51:04 +02:00
da4253fe13 Exception handling from constructors for slsDetector and multiSlsDetector, zmqsockets deleted first in multi freeshm/constructor, removed unnecessary exceptions from exceptions list, replaced in slsDetector socket assign from NULL to 0 2018-08-10 17:07:29 +02:00
a0512a01d5 Exceptions: zmq socket class descriptors made into its own class for auto destruction upon construction exception, similarly for other try blocks. slsDetector and multislsdetector left to do 2018-08-09 18:12:56 +02:00
c366e94a96 bit field for missing packets, added commands r_padding and r_discardpolicy, hdf5 bitfield metadata left to do 2018-07-05 13:47:20 +02:00