The Iron Wolf
Registered
CC thread has all documented, but still a good point, will do on next refresh.
Hi K3nny,Hi Iron Wolf,
thanks for this plugin, it is very cool that you share your work.
Now to my question, I want to use your plugin to fill my LCD Display, because I realized that my first UDP solution is to slow.
Now I´m hanging at the point that I can access the mmap file via Python, but I don´t find out how the order of the data realy are, because my knowledge of C# or C++ are not very great, I don´t understand in which order you save the data in the mmap. I have tried a bit but the data I expect at a certain point are not the ones that are stored in the mmap. The debug text file confused me in the same way, because the expected data are not on the position I search.
Now I hope for your help, do you maybe have an overview in which order the data are stored?
Thanks for your help.
kind regards
k3nny
Hi Iron Wolf,Hi K3nny,
Thanks for the kind wordsHaving this in the open is the only way to ensure project won't die if I decide to go away into say, Arma
It is great to see people find this work useful.
We are somewhat in a same boat, I know nothing about Python, other than it is a pain. That said:
C struct to rF2 internals: https://github.com/TheIronWolfModding/rF2SharedMemoryMapPlugin/blob/master/Include/rF2State.h
C# marshaling struct: https://github.com/TheIronWolfModdi.../Monitor/rF2SMMonitor/rF2SMMonitor/rF2Data.cs
I did a quick research, and from what I understand, copy mapped buffer to local bytes using mmap (if 15FPS is enough, read just one buffer). Then, https://docs.python.org/2/library/struct.html you need to map those bytes into C like struct respecting my pack/padding. It is not clear to me if you will be able to use 16 byte pack in Python, and my structures are using 16 bytes for 64bit binary.
There's a caveat though, I am working on version 2 of a plugin, which will very different internally, but not so different to consume (1 day of rework for clients). There will be separate buffers for Telemetry/Scoring/Rules etc. V2 will have 4byte pack, so if for some reason you can't read 16byte pack easily in Python, you may want to wait for V2.
Hope this helps, let me know how it goes.
Vytautas

Oh good, if it's only for your use, I'll patch it, no problemHi Iron Wolf,
oh that I overlooked, I only read the first post of the issue with the speed and didn´t combine it with my behavior. But it would be very nice when you release the patch, when it is not too much work for you.
I don´t use crew chief. My script for the nextion display is only for my use.
Thanks for your help
cheers k3nny
That's best possible fixI have checked the answer in the issue thread, have you assume the code in the last comment, when yes, you don´t have to release it, that I can insert for my self in the branch of version V1 you released.