PHP - Access shared Memory created with C++
问题 Since a few days i'm trying to get the following thing to work: I have a tiny C++ program which reads some data continuously from a serial port. This data is stored in shared memory like this: HANDLE hMapFile; hMapFile = CreateFileMapping( INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 10, NULL); LPCTSTR pBuf; pBuf = (LPTSTR) MapViewOfFileEx( hMapFile, FILE_MAP_ALL_ACCESS, 0, 0, 10, NULL); while(true) { //... some code ... CopyMemory((PVOID)pBuf, szMsg, (_tcslen(szMsg) * sizeof(TCHAR))); //..