IODisplay Programmer Notes

Primarily IODisplay is a series of functions which are included in any module which uses input devices. These functions allow the module to initiate, monitor, and terminate each approved SSL input device. To include this functionality use the information for Linking to IODisplay. Since IODisplay is also a stand alone the following information is given for that purpose.

 Application Name:

 IODisplay

 Development Path:

 ACS/ioDisplay

 Wm_appl =

 11

 Wm_winNum =

 1

Contents

Form Information
IO Display = IODisplay
Linking to IODisplay
Input Reader Module Action/Status

Form Infomation


Wm_form[1] = IODisplay
Label = "IO Display"

Objects

ioDisplaySysObj
[0] = File Menu button
[2] = Display Menu Button
 
ioDisplayChoiceObj
[1] = iod_InputChoiceMenu -> iod_InputCB(0)
[2] = iod_InfoChoiceMenu -> iod_InfoCB(0)
 
ioDisplayLabelObj
None
 
ioDisplayCmdObj
None
 
ioDisplayTelObj = ioDisplayObj
[1-6] = value sliders (Fwd,Side,Up,Roll,Pitch,Yaw)
[10-19] = spaceball buttons
[20-24] = HC buttons

Linking to IODisplay

Files required
 headers

iod_CB.h

iod_forms.h

 files

iod_CB.c = holds most functions

iod_forms.c = has functions used to create the IODisplay form

iod_sTFN_ranger.c = NDDS auxillary functions for handling IOR messages

 libraries

libforms.a

libforms.so - needed at run time

API Functions
 Function Prototype:
void iod_Initialize(void)
 Description: This function sets up the form, including initalizing object states.
 Notes: Call after fl_initialize()
 Function Prototype:
void iod_checkForDropouts(void)
 Description: This function looks at a global array which acts as a heartbeat. When a heartbeat has not be heard for a while the program assumes that the io device has been killed.
 Notes: Call in the main event loop
 Function Prototype:
void iod_DisplayDG(void)
 Description: This function is used to display graphics for the IO Display Form
 Notes: Call in the main event loop
 Function Prototype:
void iod_programQuitCB
 Description: This function cleans up NDDS allocated memory,
 Notes: Call when shutting down the process.


Input Reader Module Action/Status

There are five states which can be commanded and/or updated as the status for each input device.

 Value

Command

Status

Information
 0

No Command

No Information

 There are many input devices which are commanded and updated through one common structure. Therefore commands can be given to all input devices at once, if no command needs to be given this command state is used. A single structure also indicates the status of all devices at one, if no information is known this update status is used.
 1

Run

Running/Allocated

 This state is to command the input device active. The status will then mimic this state indicating that the specified input device is already being used to control something.
 2

Zero Input Device

Zeroed Device

 This state is to command the input device to reset the value to zero. This becomes necessary due to drift in the input device's sensors. After the device is zeroed the update status reports this state.
 3

 Quit Input Device

Input Device Terminated

 This command is used to have an input device self terminate. Proper shutdown procedures are initiated, and the this state is broadcast prior to termination.
 4

No Command 

Device Not Allocated

 This state is used only by the input device to indicate that the device is running, however no module is currently using it to control something, as in state 1.