modified to hack around phenogrid