added subwired functionality