+AirspeedIndicator::AirspeedIndicator ( SGPropertyNode *node )
+ :
+ name("airspeed-indicator"),
+ num(0),
+ pitot_port("/systems/pitot"),
+ static_port("/systems/static")
+{
+ int i;
+ for ( i = 0; i < node->nChildren(); ++i ) {
+ SGPropertyNode *child = node->getChild(i);
+ string cname = child->getName();
+ string cval = child->getStringValue();
+ if ( cname == "name" ) {
+ name = cval;
+ } else if ( cname == "number" ) {
+ num = child->getIntValue();
+ } else if ( cname == "pitot-port" ) {
+ pitot_port = cval;
+ } else if ( cname == "static-port" ) {
+ static_port = cval;
+ } else {
+ SG_LOG( SG_INSTR, SG_WARN, "Error in aispeed-indicator config logic" );
+ if ( name.length() ) {
+ SG_LOG( SG_INSTR, SG_WARN, "Section = " << name );
+ }
+ }
+ }
+}