changed to new packgram API