I'm getting the error deprecated conversion from string constant to 'char*'

So I’m trying to make the project from http://www.instructables.com/id/Playing-Wave-file-using-arduino/ but every time I try and upload the code it gives me this error:
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino: In function ‘void setup()’:
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino:22:21: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
** tmrpcm.play(“1.wav”); //the sound file “1” will play each time the arduino powers up, or is reset**
** ^**
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino: In function ‘void loop()’:
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino:32:26: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
** tmrpcm.play(“6.wav”);**
** ^**
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino:34:26: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
** tmrpcm.play(“4.wav”);**
** ^**
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino:36:26: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
** tmrpcm.play(“5.wav”);**
** ^**
D:\Documents\Arduino\WavSW_ino\WavSW_ino.ino:38:26: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
** tmrpcm.play(“3.wav”);**
I’ve tried to search up the problem but I couldn’t find any solutions, it would be great if someone could help.
Here’s the code aswell.

#include <SD.h> // need to include the SD library
#define SD_ChipSelectPin 4 //using digital pin 4 on arduino nano 328
#include <TMRpcm.h> // also need to include this library…

TMRpcm tmrpcm; // create an object for use in this sketch
int SW1;
int SW2;
int SW3;
int SW4;
void setup(){
pinMode(14,INPUT); //Define A0 as digital input.
pinMode(15,INPUT); //Define A1 as digital input.
pinMode(16,INPUT); //Define A2 as digital input.
pinMode(17,INPUT); //Define A3 as digital input.

tmrpcm.speakerPin = 9; //11 on Mega, 9 on Uno, Nano, etc

if (!SD.begin(SD_ChipSelectPin)) { // see if the card is present and can be initialized:
return; // don’t do anything more if not
}
tmrpcm.volume(1);
tmrpcm.play(“1.wav”); //the sound file “1” will play each time the arduino powers up, or is reset
}

void loop(){
SW1=digitalRead(14);
SW2=digitalRead(15);
SW3=digitalRead(16);
SW4=digitalRead(17);

if (SW1 == LOW) { //if SW1 pressed then play file “6.wav”
tmrpcm.play(“6.wav”);
} else if(SW2 == LOW){ //if SW2 pressed then play file “4.wav”
tmrpcm.play(“4.wav”);
} else if(SW3 == LOW){ //if SW3 pressed then play file “5.wav”
tmrpcm.play(“5.wav”);
} else if(SW4 == LOW){ //if SW4 pressed then play file “3.wav”
tmrpcm.play(“3.wav”);
}

}

I see no errors. I only see

warning

Those are all warnings. They're not stopping your code from working. If your code doesn't work then you've got some other problem. Posting the code and describing how what you see happening differs from what you expected might get you a lot more help.

EDIT: The post I was responding to was deleted after I started typing. Don't you just hate that?

The warnings can be dealt with. You don't think that you are the first one to see those messages, do you?

The warning is because the library author declared the function argument as "char *" rather than the more specific "const char *". Maybe they are an old-school C programmer that learned their trade before the 'const' keyword was added to the language. By leaving out the 'const' keyword they are reserving the right to store data at the address you pass (which they almost certainly don't need to do). The compiler warns you that your string constant might get written over. That can cause all sorts of errors, especially if that string constant is used more than once. Library functions should use the 'const char *' type if the function is not going to modify the string.

You can fix the library by adding the 'const' keyword if the warnings bother you.

#include “SD.h”
#include <pcmConfig.h>
#include <pcmRF.h>
#define SD_ChipSelectPin 4
#include “TMRpcm.h”
#include “SPI.h”
TMRpcm tmrpcm;

int main(void){
//void setup(){//
Serial.println(“main”);
tmrpcm.speakerPin = 9;
Serial.begin(9600);
if (!SD.begin(SD_ChipSelectPin)) {
Serial.println(“SD fail”);
return 0 ;
}

tmrpcm.setVolume(5);
tmrpcm.play(“1.wav”);
}

got the warning as C:\Users\kammatisai\Documents\Arduino\sd_card\sd_card.ino: In function ‘int main()’:

C:\Users\kammatisai\Documents\Arduino\sd_card\sd_card.ino:20:20: warning: ISO C++ forbids converting a string constant to ‘char*’ [-Wwrite-strings]

tmrpcm.play(“1.wav”);

issue: cannot listen to music & didn’t understand what went wrong also

kammatisai: got the warning as C:\Users\kammatisai\Documents\Arduino\sd_card\sd_card.ino: In function 'int main()':

C:\Users\kammatisai\Documents\Arduino\sd_card\sd_card.ino:20:20: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]

tmrpcm.play("1.wav");

issue: cannot listen to music & didn't understand what went wrong also

See reply #4. That warning should not prevent the playing of a sound file. Do you have your speaker/amplifier/headphones connected to the right pin? Pin 9 on an UNO. Look at https://github.com/TMRh20/TMRpcm/wiki to make sure you are using the library correctly.

Can you try casting it as a char *?:

.
.
.
    tmrpcm.play( (char *)"1.wav");
.
.
.

Blackfin: Can you try casting it as a char *?:

.
.
.
    tmrpcm.play( (char *)"1.wav");
.
.
.

Thanks, it worked