Jump to content
The simFlight Network Forums

Precision Flight Controls PFC430 recognized button commands


Recommended Posts

Posted

I am revisiting getting the Precision Flight Controls PFC430 to control Garmin 430/530 functions in MSFS. FSUIPC recognizes this unit but does not recognize any of the button presses or turning of the knobs. I have a program from PFC which tests the unit for function and also makes a list of the commands. Would that data allow me to make a manual edit to FSUIPC and get this unit to work for programming it to control the Garmin 430/530 GPS units? I have attached my FSUIPC log and PFChid64 log files and a screenshot of the PFC protocol test and text file of that data.

PFC_Test_GUI_data.jpg

PFChid64.log PFC430_data.txt FSUIPC7.log

Posted

As your question is related to FSUIPC7 / MSFS, please use the sub-forum for this. I have moved your post to this sub-forum.

Your FSUIPC7.log file shows that you did not load an aircraft and get ready-to-fly. Please do this and try again - I think this maybe a pre-requisite before assigning to PFC hardware, but not sure....

1 hour ago, zfehr said:

FSUIPC recognizes this unit but does not recognize any of the button presses or turning of the knobs.

It won't - control of such devices is pre-programmed in the dll, and can be overwritten using the PFC.mcro file, which you seem to be using:

Quote

   144234: Using macros from "C:\FSUIPC7\PFC.mcro" selected

Please attach that file also if it contains anything, but I suspect it is empty....

You also seem to be using an older version of the PFChid64.dll, 5.141 - the latest version is 5.143,  so please update and ret with that version.

The PFChid User Guide also says:

Quote

It is designed to handle all known PFC USB “HID” devices, but has only so far been fully tested on these:

Cirrus II Professional Console

Cirrus II Professional Avionics

So the dll hasn't been tested on your device as far as I am aware,

The error messages in your log are strange and worrying as well...

I suggest you read the User Guide and try again, with an aircraft loaded, and set some logging options for your PFC device, mainly
    LogMacroNames=Yes
This should hopefully show you the macro names called when you press the buttons, which you can override in the PFC.mcro file if needed.

 

 

Posted
1 minute ago, John Dowson said:

No point attaching then....

I created the file since there was no PFC.mcro file in the FSUIPC folder and I noticed that FSUIPC seemed to be looking for it. Thought it might populate but seems that it is a file I need to enter something in to. I am starting the sim up now to get the files with the sim running as requested.

Posted
16 hours ago, zfehr said:

I created the file since there was no PFC.mcro file in the FSUIPC folder and I noticed that FSUIPC seemed to be looking for it.

If  that file is not present, the default/in-built assignments/macros are used, and a message is logged just to say that that file cannot be found.

16 hours ago, zfehr said:

Thought it might populate but seems that it is a file I need to enter something in to.

Yes - you add your own macros to that file to overwrite/change the default action - see the PFChidDLL User guide for details.

However, the macro names are not being logged and you are only getting write errors.

I can't really help with this, as my knowledge on PFC equipment/drivers is limited. I will ask Pete about this (as well as your issues with the com device in your other post. Unfortunately he is on holiday this week, so this won't be until next week.

Posted

Thank you John. If I could just get FSUIPC to recognize the button presses and knob turns on the USB PFC430 I could have something to assign to. Wishing Pete a wonderful vacation.

Posted

I've just noticed that you already reported this back in January here: 

 

Pete has already replied to this in that post:

Quote

 

BUT I have never seen a PFC GPS device and therefore have never developed anything for it.  As it is recognised by the Scan then there's a possibility that some of the command blocks it sends to the PC are actually covered already by the PFC driver I wrote, but there are probably parts which it won't recognise. There's also the possibility that it operates as a Joystick type device in which can the buttons and switches should be visible to Windows and therefor FS and MSFS without the need for a driver.

I haven't done any development work for PFC devices for a long, long time. I assumed PFC only sold the newer devices for use with X-Plane. Did they say it worked with FS?

I am retired now and not really able to do further developments. It might be better if you asked PFC about it.

 

So I'm afraid there is nothing I can do about this - try asking PFC.

John

Posted

The post in January was because I thought the buttons and knobs were recognized in an earlier version. The earlier hardware failed and I had to purchase a replacement. I am perplexed that the USB controller card is recognized and reports the unit as a joystick in FSUIPC but none of the keystrokes are recognized. I thought the data provided from the PFC430 diagnostic software may have information that could lead to me making a manual edit entering all those alpha numeric sequences that would make them be recognized in FSUIPC.

Posted
3 minutes ago, zfehr said:

. I am perplexed that the USB controller card is recognized and reports the unit as a joystick in FSUIPC but none of the keystrokes are recognized.

If it is a joystick type HID device then it should be recognised by FSUIPC7 and can be assigned there. However, I cannot tell as you are only posting continuation logs, not full log files that include the joystick scanning section. Remove the PFChid64.dll, start MSFS/FSUIPC7, set logging for Buttons & Keys, press a few of the buttons on the PFC430 and see of the buttons are recognised. If so, they can be programmed, if not then it is just not possible. If it is recognsed as another HID type device, it may be possible to control via lua using the com library.

10 minutes ago, zfehr said:

I thought the data provided from the PFC430 diagnostic software may have information that could lead to me making a manual edit entering all those alpha numeric sequences that would make them be recognized in FSUIPC.

No. that means nothing to me. If you have installed any specific drivers for this device, you should also remove them and let windows install the generic HID joystick drivers, which is what FSUIPC would need to be able to use the device as a generic joystick type HID device.

Posted
1 hour ago, John Dowson said:

If it is a joystick type HID device then it should be recognised by FSUIPC7 and can be assigned there. However, I cannot tell as you are only posting continuation logs, not full log files that include the joystick scanning section. Remove the PFChid64.dll, start MSFS/FSUIPC7, set logging for Buttons & Keys, press a few of the buttons on the PFC430 and see of the buttons are recognised. If so, they can be programmed, if not then it is just not possible. If it is recognsed as another HID type device, it may be possible to control via lua using the com library.

No. that means nothing to me. If you have installed any specific drivers for this device, you should also remove them and let windows install the generic HID joystick drivers, which is what FSUIPC would need to be able to use the device as a generic joystick type HID device.

Thank you, I will perform that and post the log. I will have to see if there are any specific drivers PFC had me install, possibly RealityXP had one so that it only communicated with Jean-Luc's programming.

Posted

Here is the log file and as you can see no button presses are acknowledged. I did further testing using Windows 10 "setting up USB game controllers" and the PFC430 is recognized as a USB device and 32 buttons are assigned to it but when I press them using that test they do not activate. I think there is a "tickle" sent by the GUItest program that powers up the buttons as well as the RealityXP dll's also sending a signal that then gets a return from the hardware. I left the GUItest program running and tried the "setting up USB game controllers" to see if that would make a difference and it didn't. My assumption at this point is the USBhidPlugin.xpl (for xPlane v9) and rxpGNSdriver.dll (for FSX with RealityXP GNS software) both are sending something to the USB hardware that is then read coming back to the computer and without that signal the unit is a brick in MSFS.

FSUIPC7.log

Posted

Again the log file you posted is useless - please always post full logs.

You can try with lua - take a look at the HidDemo.lua script provided: copy it to your FSUIPC7 installation folder, update the Vendor and Product names and add it to the [Auto] section of your FSUIPC7.ini file (see the Advanced User guide for further details on how to auto-start lua scripts, if needed). Once that is up and running, see if the virtual flags are recognised in the button assignments panel.

13 hours ago, zfehr said:

I think there is a "tickle" sent by the GUItest program that powers up the buttons as well as the RealityXP dll's also sending a signal that then gets a return from the hardware.

Possibly. If you can work out what this is (any documentation with the device? Or PFC support?) then it may be possible to send this via lua.

Posted
5 hours ago, John Dowson said:

Again the log file you posted is useless - please always post full logs.

You can try with lua - take a look at the HidDemo.lua script provided: copy it to your FSUIPC7 installation folder, update the Vendor and Product names and add it to the [Auto] section of your FSUIPC7.ini file (see the Advanced User guide for further details on how to auto-start lua scripts, if needed). Once that is up and running, see if the virtual flags are recognised in the button assignments panel.

Possibly. If you can work out what this is (any documentation with the device? Or PFC support?) then it may be possible to send this via lua.

Hey, I'm trying here. I'm not an IT specialist or software engineer. I'll see if I can figure out how to get this full log. 

Posted
10 minutes ago, zfehr said:

I'll see if I can figure out how to get this full log. 

Just don't use the New Log feature - that starts a new log file, as the name suggests, You don't need, and I am not expecting you, to be an IT specialist or software engineer...

Posted
32 minutes ago, John Dowson said:

Just don't use the New Log feature - that starts a new log file, as the name suggests, You don't need, and I am not expecting you, to be an IT specialist or software engineer...

Thank you, I will not use that selection in the future.

Posted

The first log you posted shows:

Quote

      266 ---------------------- Joystick Device Scan -----------------------
      266 Product= PFC 430 GPS panel
      266    Manufacturer= Precision Flight Controls, Inc.
      266    Vendor=0689, Product=D002 (Version 2.0)
      266    GUIDs returned for product: VID_0689&PID_D002:
      266       GUID= {9368AA80-CF68-11EA-8001-444553540000}
      266       Details: Btns=128, POVs=(0, 0, 0, 0), Cal=x00000000, Max=R0,U0,V0,X0,Y0,Z0
      266 -------------------------------------------------------------------
      282 Device acquired for use:
      282    Joystick ID = 0 (Registry okay)
      282    0=PFC 430 GPS panel
      282    0.GUID={9368AA80-CF68-11EA-8001-444553540000}
      282 -------------------------------------------------------------------

which should indicate that the device is detected as a standard HID device and should be assignable without the need for any other driver. Did you try without using the PFChid64.dll and without the PFC Test GUI running? If not, can you try that please, and set logging for Buttons & Keys (Log -> Buttons & Keys), open the logging console (Log -> Open console) and see if you get anything logged when you press a button. Also, please attach your FSUIPC7.ini file.

Posted
23 hours ago, John Dowson said:

The first log you posted shows:

which should indicate that the device is detected as a standard HID device and should be assignable without the need for any other driver. Did you try without using the PFChid64.dll and without the PFC Test GUI running? If not, can you try that please, and set logging for Buttons & Keys (Log -> Buttons & Keys), open the logging console (Log -> Open console) and see if you get anything logged when you press a button. Also, please attach your FSUIPC7.ini file.

OK, I put the HidDemo.lua script with edits for the product and vendor. Removed PFChid64.dll from FSUIPC folder, the PFC Test GUI is not running. Log Buttons and Keys, logging console open and forced on top. I see no interaction with any button press on the hardware. Attached logs and .ini file.

HidDemo.lua FSUIPC7.log FSUIPC7.ini

Posted

For the lua script test. the lua file is not being started as this is your [Auto] section:

Quote

[Auto]
1=HidDemo

whereas it should be

Quote

[Auto]
1=Lua HidDemo

As I said:

On 4/4/2023 at 12:46 PM, John Dowson said:

update the Vendor and Product names and add it to the [Auto] section of your FSUIPC7.ini file (see the Advanced User guide for further details on how to auto-start lua scripts, if needed)

So please try that. Also, with this lua test, open the button assignments dialog to see if any (virtual) button is recognised.

However, this is the test I asked for in my last post, so you can ignore that one now. Your log shows that only button presses on device 19 were detected, which I presume is one of your PFC com devices.

Also note it is also a good idea to wait for a short period after aircraft load for everything to be initialised and started, especially when trying to track down issues. If you have the console window open, wait until the following lines are logged before doing anything:

Quote

   237890 -------------------- Starting everything now ----------------------
   238125 Lvars received: 728 L:vars & 0 H:vars now available
   238125 Lvars/Hvars received - checking aircraft autos....

Please try the lua test, but it does seem that this device requires some sort of "tickle" to be sent by the/a driver before it becomes active...Have you asked PFC about using this device with MSFS2020? Do you have any technical documentation for this device?

Try the lua test but after this I am out of ideas. I will ask Pete, who has more experience with PFC devices (and wrote the drivers) next week, but I think it will be PFC you need to contact for this device...

John

Posted
39 minutes ago, John Dowson said:

...but it does seem that this device requires some sort of "tickle" to be sent by the/a driver before it becomes active...Have you asked PFC about using this device with MSFS2020? Do you have any technical documentation for this device?

Try the lua test but after this I am out of ideas. I will ask Pete, who has more experience with PFC devices (and wrote the drivers) next week, but I think it will be PFC you need to contact for this device...

John

PFC told me that the PFCCom and PFCHid files are supposed to work in conjunction with FSUIPC but the stickler is they were designed to work with RealityXP's Garmin GNS430/530 programs and they do when accompanied by the RXPGNSdriver.dll to run the RXP Garmins in FS9 and FS10. RXP Garmin is not available for MSFS2020 so PFC does not have a responsibility to make the hardware work outside of its original design criteria.

I will make the edit so the Auto section also has Lua preceding in it (I wondered if I needed to add that when reading the instructions, I wasn't sure if the file in the instructions had Lua in the name or that was needed preceding the file name).

Thanks,

Zane

Posted

It worked! Quite excited to see something being read with button pushes on the PFC430 hardware in FSUIPC. Now I need to figure out what to do with it and see if it correlates with the log I have from the PFC test GUI because that lists button function.

HidDemo.lua FSUIPC7.log

Posted
9 minutes ago, zfehr said:

It worked! Quite excited to see something being read with button pushes on the PFC430 hardware in FSUIPC.

Ok, some progress... But did you see anything registered in the button assignments window? I don't think so, as the button state reported is always empty:

Quote

   425906 LUA.1: Buttons= 0 0 0 0 0 0 0 0

So no virtual flag would be triggered. However, it does look like something is changing,  as the actual 'data read' is different, so you could perhaps do something with this, but that could/would be quite complicated - especially for a non-programmer, or someone who doesn't have the device...

 

Posted
Just now, John Dowson said:

Ok, some progress... But did you see anything registered in the button assignments window? I don't think so, as the button state reported is always empty:

So no virtual flag would be triggered. However, it does look like something is changing,  as the actual 'data read' is different, so you could perhaps do something with this, but that could/would be quite complicated - especially for a non-programmer, or someone who doesn't have the device...

 

I know. I wonder if I am up to getting a decompiler and seeing if opening up that rxpgnsdriver.dll would reveal anything to me?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.