major revision of the ewkino code