Author Topic: Proxy plugin  (Read 5093 times)

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Proxy plugin
« on: May 28, 2011, 04:21:02 PM »
Kart Racing Pro integrates a "proxy" plugin.

Opening KRPProxyObject
Code: [Select]
g_hMapFile = OpenFileMapping(FILE_MAP_READ,FALSE,"Local\\KRPProxyObject");
void *pBuf = MapViewOfFile(g_hMapFile,FILE_MAP_READ,0,0,sizeof(SProxyData_t));
external programs can read Kart Racing Pro output data.

The source code and data structure are available here: http://www.kartracing-pro.com/downloads/krp_proxy.c
« Last Edit: January 02, 2015, 10:32:06 PM by PiBoSo »

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #1 on: November 16, 2011, 01:24:56 PM »

Files updated.

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #2 on: October 05, 2012, 11:20:27 PM »

Files updated.

Quadie

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Proxy plugin
« Reply #3 on: September 08, 2013, 03:06:12 PM »
in the first post u show some code.

does this have to be put somewhere?

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #4 on: September 08, 2013, 06:56:05 PM »
in the first post u show some code.

does this have to be put somewhere?

No. It is only needed for developers.

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #5 on: April 06, 2014, 03:36:51 PM »

Files updated.

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #6 on: January 02, 2015, 10:29:17 PM »
Source code updated to the latest interface.
Starting with Beta12, the proxy plugin is packed with the build.
« Last Edit: January 02, 2015, 10:32:42 PM by PiBoSo »

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #7 on: July 23, 2015, 12:20:03 PM »
Source code updated to the latest interface.

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #8 on: August 12, 2016, 02:51:48 PM »

Source code updated to the latest interface.

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #9 on: March 11, 2017, 03:15:36 PM »

Source code updated to the latest interface.

ccesaretto

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: Proxy plugin
« Reply #10 on: August 05, 2017, 01:24:13 PM »
Hello.
I have been using Proxy plugin to interface to Kart Racing Pro from my C# application.
Everything works fine but, in the SPluginsKartSession_t structure, I had to add an extra property to make everything work fine (see code at the bottom)

is it possible that this file:

http://www.kartracing-pro.com/downloads/krp_proxy.c

is not completely up to date and the SPluginsKartSession_t structure actually need the property I have added?

Thanks


Code: [Select]
    internal struct SPluginsKartSession_t
    {
        public int m_iSession;
        public int m_iSessionSeries;
        public int m_iConditions;
        public float temp;//<============================  ADDED
        public float m_fAirTemperature;
        public float m_fTrackTemperature;
        [MarshalAs(UnmanagedType.ByValArray, SizeConst = 100)]
        public char[] m_szSetupFileName;
    }

PiBoSo

  • Administrator
  • Hero Member
  • *****
  • Posts: 1842
    • View Profile
    • Email
Re: Proxy plugin
« Reply #11 on: August 09, 2017, 08:08:53 PM »
Hello.
I have been using Proxy plugin to interface to Kart Racing Pro from my C# application.
Everything works fine but, in the SPluginsKartSession_t structure, I had to add an extra property to make everything work fine (see code at the bottom)

is it possible that this file:

http://www.kartracing-pro.com/downloads/krp_proxy.c

is not completely up to date and the SPluginsKartSession_t structure actually need the property I have added?

Thanks


Code: [Select]
    internal struct SPluginsKartSession_t
    {
        public int m_iSession;
        public int m_iSessionSeries;
        public int m_iConditions;
        public float temp;//<============================  ADDED
        public float m_fAirTemperature;
        public float m_fTrackTemperature;
        [MarshalAs(UnmanagedType.ByValArray, SizeConst = 100)]
        public char[] m_szSetupFileName;
    }

There is no missing member in the structure.
Could it be an alignment problem? The proxy plugin uses the default value of 8 bytes.
Also, please check the int size, that should be 4 bytes.