Dear Fons, dear Rooters, >The idea is that you, for example, create two mapped files and write down the >starting address for each file. Next in the other program you now connect to >these >files using: > TMapFile::SetMapAddress(0x40eb9000); > TMapFile *mfile1 = TMapFile::Create("file1.map"); > TMapFile::SetMapAddress(0x41843000); > TMapFile *mfile2 = TMapFile::Create("file2.map"); >be sure that the "other" program does not have any other objects mapped >in this addess space. Check that by creating a new mapped file in that >process (without mapping any other TMapFile) and check that the map address >of the file is smaller than that of the first program. I have tried what you have suggested in your last mail. I am not sure, however, that I have understood correctly what you want to tell me. So far, I have tried the following: - I have tried to open two "TMapFile"s in the same Producer program following your suggestions concerning writing down preferred addresses and passing them to the program via the "SetMapAddress" method. This leads always to Segmentation fault, when I try to write into the second shared mem area. - What I actually want works even less. I want two different producer programs that open two different "TMapFile"s that then are read from one consumer program. The problem is that I can set the address by hand via SetMapAddress but that this leads to a crash. Either I overwrite memory areas that are occupied by the system ( how can I find out about really free space ?) or it crashes for some other reason. Moreover, I can not set the address always by hand, as my program is supposed to run on different machines, so that this address would have to be changed for each machine before starting the program. The project is to realize an event display that reads in an infinite loop data from DAQ and passes these data as histos to a "displaying" consumer which itself is supposed to be manipulated via shared memory by a little GUI. Which ever combination that I have tried with producers and consumers and more than one shared memory it has crashed except for the case in which more than one consumer reads from one TMapFile. Any input on this will be appreciated :-)) Regards and Thanks in advance Tom -- Thomas Eberl Phone: (+49 89) 289 1 2425 Physik-Department E12, Technische Universitaet Muenchen James-Franck-Strasse *** 85748 Garching b. Muenchen Email: Thomas.Eberl@physik.tu-muenchen.de
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:43:33 MET