Request for Source Code (moved) (1 Viewer)

M

mywaypeng

Guest
HI Aaron.
I'm a member of developing Vista remote control group in a Romte control company .
I need to read the data from tranciver which develop by us.
so the vid & pid is different from MS.
will you please send me the code, so that I would know how to open the port.
my e-mail: mywaypeng@126.com
Best regard.
--------
Jack
 

and-81

Retired Team Member
  • Premium Supporter
  • March 7, 2005
    2,257
    183
    Melbourne
    Home Country
    Australia Australia
    You developed a remote control but can't use it?

    The code is made to work with the Microsoft driver. If you have different VID and PID then you have your own driver?

    Can you explain your situation more, I'm very curious.

    Cheers,
     
    M

    mywaypeng

    Guest
    HI Aaron.
    so pleased that you have get eyes on my problem.
    I'm so sorry to my porr enlish.

    We are developing IR tranceiver & remote control for Vista.
    now our RCU (Remote Control Unit) & Receiver can control Media Center correctly.
    It also use the driver provided by MS ( cirlass & usbcir ).

    our second step is to develop Tranceiver.
    but the problem of mine is that I should first read the data from the device in form of RLC.
    so that we learn IR code in other format ( eg. NEC-1).

    I have read the code "MCEIR.DLL" for xp mce 2005. and it's work for recording IR code(under XP).
    But I can't use it in vista.......

    when use win32 API to create a handle for the device , it alway return -1.
    I'm not sure the GUID for the driver "USBCIR". so I look up regedit .
    there are four potential:
    {064f8c82-77b2-445e-b85d-c4e20f942fe1}
    {00873fdf-61a8-11d1-aa5e-0c04fb1728b}
    {7951772d-cd50-49b7-b103-2baac494fc57}//this is IRBUS 's guid for xp
    {a5dcbf10-6530-11d2-901f-00c04fb951ed}

    DevicePath as :"\\?\usb#vid_XXXX&pid_XXXX#v10010#{7951772d-cd50-49b7-b103-2baac494fc57}";

    I just want to know how to "createfile()" to open handle then read data from Device ( actual read from driver).

    thanks for attend.
    -----
    Jack
     

    and-81

    Retired Team Member
  • Premium Supporter
  • March 7, 2005
    2,257
    183
    Melbourne
    Home Country
    Australia Australia
    ahh, ok.

    I had the same trouble you are having for a long time before I figured out what I was doing wrong...

    You can't access the device in Vista the same way you did in XP. :(

    If you get a USB sniffer program and watch how Vista Media Center does it you will find it using a lot of Device IO Control calls.

    You use createfile to access the usbcir driver, but you can't just read out the incoming IR RLC data. You now use DeviceIOControl calls to do that.

    Do you have any of the publicly available WinHEC documents Microsoft released? There is some good info in them. But use a USB sniffer to trace all the calls Vista Media Center makes. I made a lot of progress once I started doing that.

    http://www.microsoft.com/whdc/system/platform/mediacenter/default.mspx

    I can give you a copy of the source code I've written, but it is Open Source and published under the terms of the GPL licence. Which means that if you use it you have to release the source code back to the public.

    I've got a problem at the moment though, my code doesn't work with Vista x64 properly yet.

    I've also got source code to interpret the RLC data. NEC is one of the protocols I support but is not 100% correct.

    What programming language are you writing your code in ? C++ I assume?

    Maybe we can both help the other?

    If you want to supply your source code to me I can try to fix it for you and send it back? That would get around the GPL license if that is a problem for you?

    Or I can send you my source code and you can give back any changes or improvements you make?

    If you want to negotiate an arrangement then contact me through the Private Message system on this forum and we can talk more there.

    Cheers,
     
    M

    mywaypeng

    Guest
    Your word brings me more clearness about the problem.
    As I'm just a graduate this year , I know little about driver development and some thing about GPL licence.
    It is hard for me to fully understand Device IO Control calls , but I'll try to do so.

    Tranceiver we developing aim to learn all format IR code , than blasting the learned code, to control all IR device.
    one engineer develop RCU & Tranceiver hardware,
    and I write UI to save data in computer when learning & send data to device when blasting.

    I write the UI program in C#, for embeding into MCE must use that language.
    and I also use C++ , for it is my frist language in programing. but I don't master it well, as I'm a beginner.

    I'm so happy that you can send the source code to me.
    and I'll send back to you when I improve it.

    glad to be your partner
    -----------------
    Jack
     

    Users who are viewing this thread

    Top Bottom