How to add footsteps sound effect to player by using joystick??

Hello, so basically am working on a mobile game, I watched literally every footsteps sound efffect tutorial videos in youtube, and I didn’t find what I was looking for, I know a very simple way to add it by using WASD but its a mobile game so I want it for joystick here is the code that I use for pc:

public AudioSource footsteps;

void Update()
{

if(Input.GetKey(KeyCode.W) || Input.GetKey(KeyCode.A) || Input.GetKey(KeyCode.S) || Input.GetKey(KeyCode.D))
{
footsteps.enabled = true;

}else{
footsteps.enabled = false;
}

}

I want a simple code as above for joystick one, Thanks…

If I may ask, what is the code for your joystick? Seeing that would be helpful.