public void processInput(Atom[] atoms) {

		//System.out.println("received input: " + AtomUtils.AtomListToString(atoms));
		//System.out.println(name + " received input");

		Stack args = AtomUtils.makeStack(atoms);

		Atom firstArg = (Atom) args.pop();

		//System.out.println("first atom: " + firstArg.toString());
		
		if (firstArg.toString().equals(name)) {

			Atom atom = (Atom) args.pop();
			String atomString = atom.toString();

			//System.out.println("MaxLink input: " + atomString);
	
			if (atom.isInt()) {
				int inletNum = atom.getInt();
				atom = (Atom) args.pop();
				atomString = atom.toString();
				if (isFunction(atomString) && inletNum == 0) {
					// if it's a function (in the first inlet?), call it.
					MaxFunction function = getFunction(atomString);
					Atom[] otherArgs = new Atom[args.size()];
					args.copyInto(otherArgs);
					function.call(otherArgs);
				} else if (inletNum < nInlets){
					// if it's a field, set the new value
					// MaxField field = getField(secondArg);
					// field.setField(args.pop());
					// if it's an input through an inlet, set that field
					atom = AtomUtils.condense(atom, AtomUtils.makeAtomList(args));
					inlets[inletNum].setField(atom.toObject());
				} else {
					System.out.println("error: bad input");
				}
			} else if (atomString.equals(LinkConstants.IO_QUERY_MESSAGE)) {
				announceIOInfo();
			} else {
				System.out.println("unknown input: " + atom.getString());
			}

		} else if (firstArg.toString().equals(LinkConstants.WHO_QUERY_MESSAGE)) {
			// respond to "who" query by sending name, nInlets, nOutlets
			announceApplet();
			announceIOInfo();
		}
		// should try multicasting osc...need Atom->OSC conversion
	}