Touch function slowing me down?

I only have a couple of weeks of Arduino under my belt and only a couple of days playing with a touch LCD...

My goal, which I worked all day on, was to create a simple LCD touch interface to do some limited things with a stepper motor (choose the number of steps, speeds etc...). I have everything working, the only problem is the speed, the stepper will not run very fast, I assume because of the call to Touch_getXY, if there is no touch, the only other thing in the main loop is function is listed below. This must be causing the loop to run slower. Yesterday I created a serial interface using my computer keyboard running the drive at different speeds/steps, etc, and I got it running very fast (5000 maxSpeed).

Is there a way to make the touch screen act as an interrupt? Or some other way to know if a touch happened without slowing down the processor? (Mega)

Here is the function...

bool Touch_getXY(void)
TSPoint p = ts.getPoint();
pinMode(YP, OUTPUT); //restore shared pins
pinMode(XM, OUTPUT);
digitalWrite(YP, HIGH); //because TFT control pins
digitalWrite(XM, HIGH);
bool pressed = (p.z > MINPRESSURE && p.z < MAXPRESSURE);
if (pressed) {
pixelX = map(p.x, TS_MINX, TS_MAXX, 0, 240); //map the touch point x to the screen x
pixelY = map(p.y, TS_MINY, TS_MAXY, 0, 320); //map the touch point y to the screen y
return pressed;

Here is the loop code, I would thin that if there was no press, it would loop pretty quickly, but id does not...

void loop() {

if (Touch_getXY()) {

do all of the pixel mapping to see which button was pushed and set up the motor commands


If anyone can point me in the right direction I would appreciate it.