A successful Glade panel working with deltaFSD requires a large number of elements to be working correctly.
Whilst all of these are standard/default settings and no special software (other than Glade) itself is required, there a a lot of opportunities for something to go wrong.
We suggest that you work through the following notes - they should help highlight where the problems lie (if there are any).
The sample Glade panel code is intended to demonstrate how things fit together. A number of shortcuts have been taken in the interests of keeping things simple. Please email us at the deltaFSD team if you spot any bugs or improvements.
Start up Glade and create a new project.
Typical settings for the general project options would be:
Project Directory: /YourGladeHome/Projects/car Project Name: Car Program Name: car Project File: car.gladeSet the C options to suit your environment. (You don't need Gettext support.)
Leave the project empty.
Click the "Build the Source Code" button in Glade.
Close down Glade and go to /YourGladeHome/Projects/car.
Build the empty project:
autogen.sh makeThis should produce an executable:
/YourGladeHome/Projects/car/src/carThis will run but produce no display.
Copy in (overwrite) the Glade project file with the one provided with deltaFSD:
cp /deltaFSDhome/samples/gladepanel/car.glade /YourGladeHome/Projects/car/car.gladeRestart Glade and select your car project
The main Glade window should now show two windows
Click the "Build the Source Code" button.
Close Glade and copy the sample main.c into the src directory (this will overwrite the autogenerated version):
cp /deltaFSDhome/samples/gladepanel/main.c /YourGladeHome/Projects/car/src/main.cGo (back) to /YourGladeHome/Projects/car/ and rebuild the executable:
makeYou should get some warnings but no errors.
Try running the executable:
src/carThis should produce the message:
Connection failedSince there is no deltaFSD server process running for your panel to talk to.
Run deltaFSD.
Select Socket from the "Other functions" menu.
Set 2 inputs and 2 outputs for the function.
Leave the socket number set to the default 6739.
Restart the Glade executable:
src/carYour two panel windows should now appear.
If you attach Get functions to the inputs of your Socket function you should be able to change the dial displays in window2.
If you attach Print functions to the outputs of your Socket function you should be able to see the slider and button values from window 1.
(The Up/Down buttons produce only an instantaneous +1, -1 before reverting to 0.)
Close everything down and restart deltaFSD.
Read in the car model.
Restart your Glade panel and everything should spring into life.
Giving you something like: