Stationary bike record .GPX data help need

Hello.
I have an old stationary bike with cyclometer broken also.
Any idea how to use the cadence sensor (a simple switch) with a development board and from the final project to get a valid like .GPX to import in Strava or any other riding android app?

I am not interested about GPS points, of course (I am pedaling in my house), only cadence, speed, time.

Anyone can help me with a general idea of what I need for this?

For now I have an ESP8266+Wifi board and I have knowledge about the hardware+software part, this means I know how to read the sensor input and write the info on file, via WiFi, on a local web server.
But making a valid .GPX file, which will be accepted on import in a like-Strava app, is beyond my power.

Any help would be very appreciated! Thank you.

(deleted)

Thanks. I was there. Didn't found info about my particular project which not involve GPS but only distance and speed.

Hello,

There is a work around that I was able to export txt/csv file off a web page

the file actually holds records of sensor readings and date/time, and this is a JS script that I did use (hosted on the ESP)

function downloadFile(fileName, fileContent , fileExtension ) {  // TXT/CSV
  var element = document.createElement('a');
  element.setAttribute('href', 'data:text/' + fileExtension + ';charset=utf-8,' + encodeURIComponent(fileContent));
  element.setAttribute('download', fileName);
  element.style.display = 'none';
  document.body.appendChild(element);
  element.click();
  document.body.removeChild(element);
}  // end

for your case your content will populate all your needed data and well formatted as per this sample here GPS Exchange Format - Wikipedia

and your fileFormat should be gpx(GPX)

Give it a shot, It might just work

Thank you very much, but I am not advanced enough to understand how this work. But I will study. Any clues what to learn will be greatly appreciated!

Ok, I can send data from Arduino to my PC. In a text file.
But I am not a Web programmer and dont know how to get data from that text file and put in a .GPX file recognozible by a fitness app to Import.
Any clues?
Someone here using a modern stationary bike or treadmill which export data on USB?
I need to see how a .GPX file look in this particularly case, with no locations.
Thank you, please help.

aidept:
Ok, I can send data from Arduino to my PC. In a text file.
But I am not a Web programmer and dont know how to get data from that text file and put in a .GPX file recognozible by a fitness app to Import.
Any clues?
Someone here using a modern stationary bike or treadmill which export data on USB?
I need to see how a .GPX file look in this particularly case, with no locations.
Thank you, please help.

post your sketch please, within code tags