Still Problems on win7 - when changing dicom.ini on the fly

  • Hi,


    changing MagDEVICE sounds like a bad idea as old data cannot be retrieved anymore and a temp folder changea as well. You can better change FileNameSyntax, e.g., by prepending it with your subfolder of choice. This can be done at any time, as for old data the filename is stored in the database and remains valid. To set use, e.g,:


    dgate "--put_param:FileNameSyntax,folder\%studyid\%seriesid\%sopuid.dcm"
    dgate --read_ini:


    or


    dgate "--lua:Global.FileNameSyntax=[[folder\%studyid\%seriesid\%sopuid.dcm]]"


    where folder is your variable path. See futher the documentation of FileNameSyntax


    Marcel

  • Ok, I understand your explanation, but I have about 12-13 conquest in some medical (private) centers and I'm getting negative feedback only from win7/8 users.


    What do you think about this:


    as I told you, for each new study I delete the existing dicom.ini, write a new one from code with the appropriate path and parameters, then launch dgate --read_ini:


    It seems that dgate --read_ini: is launched (sometimes) before the entire dicom.ini is written.
    If I understand right, the missing dicom.ini file on the hard disk causes conquest to start as a fresh new installation (and sometimes I get the screen with the db type choice)


    If I put a timer, for example to wait 2 secs. before launching dgate --read_ini: I assume the entire dicom.ini is written. What do you think?


    let me know, regards,


    thanks, ciro

  • Hi,


    dicom.ini is continuously read and monitored by dgate, for instance when images are recieved. Deleting it can or will cause all sorts of trouble. I would find another solution where only the relevant parameter is changed wihout touching dicom.ini.


    Marcel

  • Hi Marcel, following your hint I'll change values in dicom.ini this way


    Code
    dgate "--put_param:FileNameSyntax,folder\%studyid\%seriesid\%sopuid.dcm"
    dgate --read_ini:


    rather than deleting and creating a new dicom.ini everytime.
    The parameter I should change are:


    MyACRNema
    TCPPort
    MagDevice0

    and these lines:


    ImportConverters = 5
    ImportConverter0 = ifnotequal "%m","SR";save to Z:\ECOGYN\IMG_ECO\P000001\PT20130910\temp.dcm
    ImportConverter1 = ifequal "%m","SR";save to Z:\ECOGYN\IMG_ECO\P000001\PT20130910\misure.dcm
    ImportConverter2 = ifnotequal "%m","SR";process with dgate.exe "--convert_to_jpg:Z:\ECOGYN\IMG_ECO\P000001\PT20130910\temp.dcm,1024,Z:\ECOGYN\IMG_ECO\P000001\PT20130910\%V0020,0013.jpg,//0
    ImportConverter3 = ifequal "%m","SR";process with C:\DICOM\dsr2xml.exe Z:\ECOGYN\IMG_ECO\P000001\PT20130910\temp.dcm Z:\ECOGYN\IMG_ECO\P000001\PT20130910\misure.xml
    ImportConverter4 = destroy


    do you think that all could be made with the command put_param?
    And, how can I check that the param has the correct value? Now I open the dicom.ini in notepad and see the value....


    Let me know, the problems are increasing especially on GE machines....


    thanks


    ciro

  • Hi,


    I will check tonight which parameters can be changed live without touchin dicom.ini. Note though, the these changes are global and will affect multiple incoming connections if they run at the same time.


    Can't you script all your processing and storage and forget about filenamesyntax? With 1.4.17b and lua you should be able to come a very long way.


    Marcel

  • ok, no problem for connections because each workstation has its own conquest server, so there aren't multiple incoming connections.


    no, I can't script the storage, because change for each study, I get the full path in a working variable that I pass to dicom.ini.


    Let me know if I can change these parameters and how can I test them


    regards,
    ciro

  • Hi Ciro,


    the safest thing to do would be to create dicom.ini and then start dgate as "dgate -v". This is the ONLY way to change the port number. You can when done kill dgate with "dgate --quit:"


    The parameters you want changed are not live, they can only be read from dicom.ini. Alternatively you might therefore try this:


    lua parameters are all thread local, except parameter Global. You could therefore write e.g. Global.StatusString and pick it up in the script. E.g.,


    dgate "--lua:Global.StatusString=[[ECOGYN\IMG_ECO\P000001\PT20130910\]]"


    and


    MagDevice0 = Z:\
    FilenameSyntax = lua:Global.StatusString..Data.SOPInstanceUID..[[.dcm]]


    [lua]
    ImportConverter0 = if Data.Modality~="SR" then Data:Write(Global.StatusString..'temp.dcm' end
    ImportConverter1 = if Data.Modality=="SR" then Data:Write(Global.StatusString..'misure.dcm' end
    ImportConverter2 = if Data.Modality~="SR" then Data:Script('save jpg to '..Global.StatusString..Data.InstanceNumber..'.jpg') end
    ImportConverter3 = if Data.Modality=="SR" then system('C:\DICOM\dsr2xml.exe '..Global.StatusString..'temp.dcm ' ..Global.StatusString..'misure.xml') end
    ImportConverter4 = script('destroy')


    regards,


    Marcel

  • ok Marcel, for me the best thing to do is:


    - NOT install dgate as service (as it can cause problems, like authentication on win7-8, ecc....)
    - when I start a new study (ultrasound exam) I write dicom.ini as I need
    - start dgate (from a command like a batch)
    - do the examination, after that stop dgate (with a batch o a command)


    this could be safe according to you?
    strange is that conquest hangs at random,yesterday after an entire afternoon without problems. And, I've noticed, especially on GE machines.....


    so, which are the best commands to start and stop dgate in this way?

  • Hi,


    reads automatically. Dgate.exe is the actual server.


    Marcel


    This snippet of a lua script generates, starts and stops a minimal server:


  • Ok, marcel tried


    dgate.exe --quit:
    dgate.exe -v


    but when I start dgate, it remains as dos win, is possible to hide as tray?


    and last question: I'm checking on a 32bit xp system, if I use 64bit system, do I have to change the syntax to dgate64.exe -v or It does automatically?

  • Hi,


    your starter code should control the display of the window (see backgroundexec in dgate.cpp, or system() in lua). For 64 bits you have to start dgate64.exe. My GUI tries first dgate64.exe and if that fails runs dgate.exe.


    regards,


    Marcel

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!