Replace L298N with pololu a4990 Shield driver in program

Hello,
I have the code below, it is not mine, it is from webondevices.com and I want to modify it so I can use the Pololu a4990 driver shield. The problem is that the code is generated with the L298n driver and I can not modify it so I can even move a wheel. Could you please help me?
Thank you very much and have a nice evening.
Below the code and also the source of it :

#include <SPI.h>
#include <RF24.h>
#include <RF24_config.h>

// Radio pin setup
#define cePin 9
#define csnPin 10

#define joyX A0
#define joyY A1

// Init RF24 radio
RF24 radio(cePin, csnPin);
const uint64_t pipe0 = 0xF0F0F0AA;
uint8_t p0 = 0;

// Variables
int chr[1];
int terminateChar[1];
String dataToSend = "";

void setup() {
Serial.begin(9600);
radio.begin();
radio.openWritingPipe(pipe0);
}

void loop() {
dataToSend += map(analogRead(joyX), 0, 1023, 0, 9);
dataToSend += map(analogRead(joyY), 0, 1023, 0, 9);
int stringSize = dataToSend.length();
for (int i = 0; i < stringSize; i++) {
int charToSend[1];
charToSend[0] = dataToSend.charAt(i);
radio.write(charToSend,1);
}
terminateChar[0] = 2;
radio.write(terminateChar, 1);
dataToSend = "";
}

The source:
http://www.webondevices.com/arduino-robot-car-obstacle-avoidance/

The code you posted appears to have nothing to do with a motor driver shield of any kind.

You are right. That is the code for the remote control. The code with the motor driver is below.
#include <SPI.h>
#include <RF24.h>
#include <RF24_config.h>

// Radio pin setup
#define cePin 9
#define csnPin 10

// US sensor pin setup
#define trigPin 14
#define echoPin 2
#define accuracy 4

// Motor pin setup
#define enableLeft 6
#define leftForward 4
#define leftBackward 3

#define enableRight 5
#define rightForward 8
#define rightBackward 7

// Init RF24 radio
RF24 radio(cePin, csnPin);
const uint64_t pipe0 = 0xF0F0F0AA;
uint8_t p0 = 0;

// Variables
String receivedMessage = "";
int chr[1];
int joyX = 4;
int joyY = 4;
int speedCoeff = 0;
int left = 0;
int right = 0;

void setup(){
// Setup RF24 radio
Serial.begin(9600);
radio.begin();
radio.openReadingPipe(p0, pipe0);
radio.startListening();

// Setup US sensor
pinMode(trigPin, OUTPUT);
pinMode(echoPin, INPUT);

// Setup LEFT whel
pinMode(enableLeft, OUTPUT);
analogWrite(enableLeft, 255);

pinMode(leftForward, OUTPUT);
digitalWrite(leftForward, LOW);

pinMode(leftBackward, OUTPUT);
digitalWrite(leftBackward, LOW);

// Setup RIGHT wheel
pinMode(enableRight, OUTPUT);
analogWrite(enableRight, 255);

pinMode(rightForward, OUTPUT);
digitalWrite(rightForward, LOW);

pinMode(rightBackward, OUTPUT);
digitalWrite(rightBackward, LOW);
}

void loop(){
// Get Distance sensor
float duration, distance;
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
digitalWrite(trigPin, HIGH);
delayMicroseconds(10); // Added this line
digitalWrite(trigPin, LOW);
duration = pulseIn(echoPin, HIGH);
distance = (duration / 2) / 29.1;

// Watch control messages
while(radio.available()){
radio.read(chr, 1);
char receivedChar = chr[0];

if (chr[0] != 2){
receivedMessage.concat(receivedChar);
} else {
joyX = receivedMessage.substring(0,1).toInt();
joyY = receivedMessage.substring(1,2).toInt();

if(distance < 15){
joyX = 4;
joyY = 4;
}

if(joyY < 4){
// Backward
digitalWrite(rightBackward, HIGH);
digitalWrite(rightForward, LOW);
digitalWrite(leftBackward, HIGH);
digitalWrite(leftForward, LOW);
speedCoeff = map(joyY, 0, 4, 255, 0);
speedCoeff = speedCoeff < 0 ? 0 : speedCoeff;
speedCoeff = speedCoeff > 255 ? 255 : speedCoeff;
} else if(joyY > 4){
// Forward
digitalWrite(rightBackward, LOW);
digitalWrite(rightForward, HIGH);
digitalWrite(leftBackward, LOW);
digitalWrite(leftForward, HIGH);
speedCoeff = map(joyY, 4, 9, 0, 255);
speedCoeff = speedCoeff < 0 ? 0 : speedCoeff;
speedCoeff = speedCoeff > 255 ? 255 : speedCoeff;
}

right = map(joyX, 4, 9, 255, 0);
right = right < 0 ? 0 : right;
right = right > 255 ? 255 : right;

right = (right + speedCoeff) / 2;
analogWrite(enableRight, right);

left = map(joyX, 0, 4, 0, 255);
left = left < 0 ? 0 : left;
left = left > 255 ? 255 : left;

left = (left + speedCoeff) / 2;
analogWrite(enableLeft, left);

if(joyY == 4){
// Stopped
if(joyX < 4){
// Left
digitalWrite(rightBackward, LOW);
digitalWrite(rightForward, HIGH);
digitalWrite(leftBackward, HIGH);
digitalWrite(leftForward, LOW);

right = map(joyX, 0, 4, 255, 0);
right = right < 0 ? 0 : right;
right = right > 255 ? 255 : right;
analogWrite(enableRight, right);

left = map(joyX, 0, 4, 255, 0);
left = left < 0 ? 0 : left;
left = left > 255 ? 255 : left;
analogWrite(enableLeft, left);

} else if(joyX > 4){
// Right
digitalWrite(rightBackward, HIGH);
digitalWrite(rightForward, LOW);
digitalWrite(leftBackward, LOW);
digitalWrite(leftForward, HIGH);

right = map(joyX, 4, 9, 0, 255);
right = right < 0 ? 0 : right;
right = right > 255 ? 255 : right;
analogWrite(enableRight, right);

left = map(joyX, 4, 9, 0, 255);
left = left < 0 ? 0 : left;
left = left > 255 ? 255 : left;
analogWrite(enableLeft, left);

} else if (joyX == 4){
// Stopped
digitalWrite(rightBackward, LOW);
digitalWrite(rightForward, LOW);
digitalWrite(leftBackward, LOW);
digitalWrite(leftForward, LOW);
analogWrite(enableRight, 0);
analogWrite(enableLeft, 0);
}
}
receivedMessage = "";
}
}
}

Thank you!