I'm documenting here a few tricks I'm using to record guitar tracks.
I'm learning with the great Yousician app, running on my Android phone, which provides a huge library of popular tracks. So from time to time, I'm recording my rendition on the guitar.
I'm recording with a Focusrite Scarlett 2i2, on which the guitar is plugged, as a USB sound card. Then, I'm using Audacity on GNU/Linux to record the audio input from that Scarlett over USB. I'm usually using Jack for doing so.
The backing track being played by Yousician on the Android phone, I'm plugging the phone to the Scarlett with a male-male jack cable, which I plugged to a diameter changer Jack adapter (the scarlett has only 6.5 mm jack).
But as the Scarlett will only record mono from its jack, and the phone plays stereo tracks, I need some more conversion. I have then purchased a a jack adapter that is not only a diameter changer (3.5 to 6.5 mm), but also a stereo to mono adapter.
But the sound rendition of that passive stereo to mono conversion by the adapter is crappy. But there's an option in Android that allows to convert stereo sound to mono sound, from the source. It's in the accessibility features, and can be used by Yousician, hopefully. The end results is not so bad : mono input from the guitar plugged on one of Scarlett's inputs, and another mono input for the Yousician backing track on the second Scarlett input.
I just have to normalize, mix the two in Ardour, and voilà, I have my recordings.