code structure problem

i’ve tried to run this code on the arduino uno card and can’t run it.
I got it to run manually by Serial.println(); but it still doesn’t go beyond the setup and doesn’t print any thing on the lcd. is it due to the many begins?

#include "VoiceRecognitionV3.h"
#include <SoftwareSerial.h>
#include "TFT9341.h"
#include <Servo.h>
#include "SPI.h"
#include <SD.h>

/*-------------------DEFINES_START-------------------*/
//MUSIC_NOTE_DEFINES_START
#define spekerPin 5 //set pin 5 as speaker pin
#define t 250 // sets time
#define C 523 // sets musical note
#define D 587 // sets musical note
#define E 657 // sets musical note 
#define F 698 // sets musical note
#define G 784 // sets musical note 
#define A 880 // sets musical note
#define B 987 // sets musical note
//MUSIC_NOTE_DEFINES_END

//ISD4004_PIN_DEFINES_START
#define EOM A2 
#define SS 6
#define MOSI 7
#define SCLK A5
//ISD4004_PIN_DEFINES_END

//VRM_VOICE_COMMANDS_START
#define openwin    (0)
#define closewin   (1)
#define music      (2)
#define ac         (3)
#define light      (4)

#define OPEN_WINDOW  0
#define CLOSE_WINDOW 40
#define AC           80
#define MUSIC        125
#define LIGHT        165
//VRM_VOICE_COMMANDS_END

//TFT_START
#define SD_CS 4
//TFT_END
/*-------------------DEFINES_END-------------------*/

/*-------------------GLOBAL_DECLARATION_START-------------------*/
//VRM_VARIABLE_START
VR myVR(2,3);    
uint8_t buf[64];
int ret;
//VRM_VARIABLE_END

//WINDOW_VARIABLE_START
Servo window;
//WINDOW_VARIABLE_END
/*-------------------GLOBAL_DECLARATION_END-------------------*/

/*-------------------FUNCTION_PROTOTYPES_START-------------------*/
void command(char *pic, int posx, int posy, int record);
void bmpDraw(char *filename, uint16_t x, uint16_t y);
void printVR(uint8_t *buf);
//void checkVRConnection();
//void loadVRCommands();
void playMusic();
/*-------------------FUNCTION_PROTOTYPES_END-------------------*/

void setup() {
  Serial.begin(9600);
  SPI.begin(); 
  
  //isd4004_pinset_start
  pinMode(SS, OUTPUT); // we use this for SS pin
  pinMode(EOM,INPUT);
  //isd4004_pinset_end

  //servo_pinset_start
  window.attach(A7);
  //servo_pinset_end

  Serial.println("before myvr");
  myVR.begin(9600);
  Serial.println("after myvr");
  Serial.println("before checkVRConnection");
   if(myVR.clear() == 0){
    Serial.println("Recognizer cleared.");
  }//if
  else{
    Serial.println("Not find VoiceRecognitionModule.");
    Serial.println("Please check connection and restart Arduino.");
    while(1);
  }//else
  Serial.println("after checkVRConnection");
  Serial.println("before loadVRCommands");
  if(myVR.load((uint8_t)openwin) >= 0){
    Serial.println("openwin loaded");
  }//if
  if(myVR.load((uint8_t)closewin) >= 0){
    Serial.println("closewin loaded");
  }//if
  if(myVR.load((uint8_t)music) >= 0){
    Serial.println("music loaded");
  }//if
  if(myVR.load((uint8_t)ac) >= 0){
    Serial.println("ac loaded");
  }//if
   if(myVR.load((uint8_t)light) >= 0){
    Serial.println("light loaded");
  }//if
  Serial.println("after loadVRCommands");
  //lcd.begin();

/*
  Serial.println("Initializing SD card...");
   if (!SD.begin(SD_CS)) {
   bmpDraw("sdout.bmp",0,0);
   delay(3000);
   return;
 }//if
  bmpDraw("sdin.bmp",0,0);
  delay(1000);
  lcd.clrscr();
  */
}//setup

void loop() {
  ret = myVR.recognize(buf, 50);
  if(ret>0){
    switch(buf[1]){
      case openwin: {
        command("open.bmp",0,0,OPEN_WINDOW);
        window.write(90);
        lcd.clrscr();
      }//openwin
        break;
      case closewin: {
        command("close.bmp",0,0,CLOSE_WINDOW);
        window.write(0);
        lcd.clrscr();
      }//closewin
        break;
      case music:{
        command("music.bmp",0,0,MUSIC);
        playMusic();
        lcd.clrscr();
      }//music
        break;
      case ac:{
        command("fan.bmp",0,0,AC);
        delay(2000);
        lcd.clrscr();
        //turn A/C off
      }//ac
         break;
      case light:{
        command("light.bmp",0,0,LIGHT);
        delay(2000);
        lcd.clrscr();
        //turn light off
      }//light
         break;
      default:
        Serial.println("Record function undefined");
        break;
    }
    printVR(buf);
  }//switch
}//loop

//add GSM interrupt

You have 6 #includes in your program. Have you written test programs to get each of the different parts working on its own?

When you can get them working all working separately then you can try two of them together and see if there is a problem and continue extending and testing.

But when you have several things any of which could be causing a problem it is impossible to find the culprit.

Also be aware that there is no guarantee that Arduino libraries can work together - two of them may be trying to use the same piece of hardware or they may interfere with each other's timing.

...R

Needs more F() macro.

Can you please provide links to the VoiceRecognitionV3 and TFT9341 libraries. Be aware that the Uno only has 2k RAM; what does the IDE say about memory usage when you compile?

I notice you have an SPI.begin() in there. Which devices are SPI devices? If there is more than one, you need to make sure that they play nicely on the SPI bus. They each need their own Slave Select pin and you may need to verify that the clock speed is compatible with all of them.