Misc Linux QCMA connection stopped working.

Kiiro_Yakumo

Kitsune
OP
Member
Joined
Apr 14, 2009
Messages
493
Trophies
1
Location
Anor Londo
XP
633
Country
Poland
Hello.

I've bumped into quite a problem recently and after exhausting some options I guess it's time to write it down here.
Until recently, about 22nd of April QCMA on Linux Fedora worked like it should for years. Transferring screenshots by Wi-Fi or USB in the past as well but I believe for about a year it was Wi-Fi only.
Fedora had recently new release so I've upgraded it. I tried to send new screenshots two or so days ago and no luck.

The transfer just ends but no files are being created on PC side. QCMA doesn't even light up as connected either. Trying to use content manager on Vita side to connect gives me "The device has been disconnected" on QCMA side instantly. Attempting to with USB gives a wall of such notifications for a short while. I have tried with OpenSuse Tumbleweed through USB HDD, both Wi-Fi and USB connection to rule out Fedora as the culprit and no dice either. Then again, OpenSuse Tumbleweed is even more of a "rolling" with packages so it may be not enough of a proof. The same happened with OpenSuse Tumbleweed on Virtual Machine.

For the record, I can still sync trophies and do FTP so it doesn't seem like hardware problem on either side at the moment.

To make things more confusing, I have dug up old Windows 7 on Virtual Machine with QCMA and... it worked through USB at least, so it's not faulty cable or port either it seems.
Can't test Wi-Fi on Virtual Machine as it doesn't connect directly to the rest of the network and such.

I have disabled plugin most recently used just in case as well as UCDC as it was giving a specific error through USB so at least that part is ruled out.
I did a bit detoured but successful database rebuild on Vita side.

The Vita itself is on 3.60 with Enso.

Thank you in advance and have a good day~!

EDIT #1 - oh right I forgot, tried to check with terminal what it will output when attempting through USB (I think the Wi-Fi has similar output just once instead of few times over):

PTP: Opening session Vita connected, id: [here is some ID written] vita_info.xml:1: parser error : Extra content at the end of the document ><gameThumb type="0" codecType="17" width="192" height="192"/></VITAInformation> ^

EDIT #2 - got a bit older Fedora (two releases back) to check on Virtual Machine and it worked over USB as well. It seems that it is software problem definitely, not hardware problem. The question is what exactly is failing.
 
Last edited by Kiiro_Yakumo,

Dust2dust

Well-Known Member
Member
Joined
Jun 17, 2010
Messages
2,700
Trophies
2
XP
5,395
Country
Canada
hi. i am experiencing the same issue, what did you do to fix it?
It's a secret. You're not supposed to know. Just kidding. :P In all seriousness, it would be so kind of users who post about a problem, and later find their own solution, to post how they solved it, instead of just posting "I found the solution, topic can be closed". That doesn't help anyone who could face the same issue. I hope OP can help you.
 

Kiiro_Yakumo

Kitsune
OP
Member
Joined
Apr 14, 2009
Messages
493
Trophies
1
Location
Anor Londo
XP
633
Country
Poland
I guess I didn't phrase it properly so here is the proper version.
When I said "everything possible", it was metaphorically really that, everything that popped into my mind, attempted. Since I couldn't find help on the network I wasn't really keeping track of anything done. Stuff included many things that were probably not related to the problem at all but I couldn't know it at that time of course.
When I said "solved the problem somewhat", I should've put emphasis on "somewhat" part. It's not trully solved, it's shaky and about as stable as chaotic energy put into a bottle with a cork.
There is no guarantee this method will work anywhere else, especially that the new user with his first post just wrote the classic "doesn't work for me either" without specifying anything else, even basic info.
Finally when I said "marked as solved", I didn't mean it as "I know what happened and what didn't work", it's only just that, "topic can be closed", nothing deep or poetic about it.
 
Last edited by Kiiro_Yakumo,

kazriko

Member
Newcomer
Joined
Jun 29, 2024
Messages
5
Trophies
0
Age
45
XP
60
Country
United States
I ran into this error, and managed to at least bypass it by making mods to libvitamtp, in the datautils.c file, there's two lines that do "xmlReadMemory", the last parameter to these is a 0. I changed this to a 1 to make it continue after encountering an error, and this allowed me to connect with qcma and download my save game to the vita, after compiling and installing the library to the correct location. (I had to move the files from /usr/local/lib to /usr/lib though.)

I imagine some xml library changed something, got way stricter about parsing, or somesuch nonsense. There's so many garbage libraries around xml parsing... I'm constantly having to fix problems in xml parsing when I move a program from android to linux, or otherwise, just because every last one of them is incompatible in some way.
 
  • Like
Reactions: bonkmaykr

kazriko

Member
Newcomer
Joined
Jun 29, 2024
Messages
5
Trophies
0
Age
45
XP
60
Country
United States
I have it working quite well in Artix here. At some point I'll fork the project and apply my fixes to it, once I've confirmed exactly why it's actually failing instead of bandaiding around it. What I suspect happened is that there's a null value at the end of the string, and they must have changed the parser so that it actually cares about an extra null character on the end of the input string.
 

Kiiro_Yakumo

Kitsune
OP
Member
Joined
Apr 14, 2009
Messages
493
Trophies
1
Location
Anor Londo
XP
633
Country
Poland
I ran into this error, and managed to at least bypass it by making mods to libvitamtp, in the datautils.c file, there's two lines that do "xmlReadMemory", the last parameter to these is a 0. I changed this to a 1 to make it continue after encountering an error, and this allowed me to connect with qcma and download my save game to the vita, after compiling and installing the library to the correct location. (I had to move the files from /usr/local/lib to /usr/lib though.)

I imagine some xml library changed something, got way stricter about parsing, or somesuch nonsense. There's so many garbage libraries around xml parsing... I'm constantly having to fix problems in xml parsing when I move a program from android to linux, or otherwise, just because every last one of them is incompatible in some way.
So it would be libvitamtp fault in the end not QCMA itself? That could possibly explain why I was circling around with no proper fix, I will try to test your method and report back. To make things more interesting I will try to apply it on Raspberry Pi. From what you are saying it would make sense because I recall there was some xml "file" failing in the process, well non-existing file - probably only temporary in the RAM - so if the parser would be somewhat at fault it could be the reason stuff exploded in unexpected way.
 
  • Like
Reactions: kazriko

kazriko

Member
Newcomer
Joined
Jun 29, 2024
Messages
5
Trophies
0
Age
45
XP
60
Country
United States
From what you are saying it would make sense because I recall there was some xml "file" failing in the process, well non-existing file - probably only temporary in the RAM - so if the parser would be somewhat at fault it could be the reason stuff exploded in unexpected way.

Yeah, if you turn on the verbose debugging, you actually see the file being transferred from the Vita before being parsed. There's two of them that are retrieved, and both of them exhibit the same error. That's why you have to turn on error tolerance on two calls of the xml parser. It was also through the debug mode that I noticed that there was a null terminator at the end of the files being transferred from the Vita.
 

The_Dizzy_Vizzy

Cara Delevingne
Member
Joined
Jul 3, 2018
Messages
863
Trophies
0
Location
Hanksville, Mernith County
XP
1,901
Country
United States
Hi guys, while I'm a bit late to the party, this very thing happened to me as well, albeit I am on Windows 10 and not Linux.
I had recently replaced my router, and after that, NO QCMA, no CMA, NO NOTHING. Took me a day to realized this, not having connected the dots until the next day.

Turns out that when I got the router hooked up (internet was fine and wi-fi too), WINDOWS, for some really stupid reason, switches your network to "PUBLIC" instead of "PRIVATE". So when I finally discovered this, I set it to PRIVATE and immediately CMA & QCMA were both working. Probably this isn't the root of your problem but I figured I'd mention it anyway.
 

kazriko

Member
Newcomer
Joined
Jun 29, 2024
Messages
5
Trophies
0
Age
45
XP
60
Country
United States
Hi guys, while I'm a bit late to the party, this very thing happened to me as well, albeit I am on Windows 10 and not Linux.
I had recently replaced my router, and after that, NO QCMA, no CMA, NO NOTHING. Took me a day to realized this, not having connected the dots until the next day.

Turns out that when I got the router hooked up (internet was fine and wi-fi too), WINDOWS, for some really stupid reason, switches your network to "PUBLIC" instead of "PRIVATE". So when I finally discovered this, I set it to PRIVATE and immediately CMA & QCMA were both working. Probably this isn't the root of your problem but I figured I'd mention it anyway.
Nope, that's a different, though known issue.
 
  • Like
Reactions: The_Dizzy_Vizzy

Kiiro_Yakumo

Kitsune
OP
Member
Joined
Apr 14, 2009
Messages
493
Trophies
1
Location
Anor Londo
XP
633
Country
Poland
Yeah, if you turn on the verbose debugging, you actually see the file being transferred from the Vita before being parsed. There's two of them that are retrieved, and both of them exhibit the same error. That's why you have to turn on error tolerance on two calls of the xml parser. It was also through the debug mode that I noticed that there was a null terminator at the end of the files being transferred from the Vita.

The good news is, QCMA did connect after your fix.
The bad news is, it still refused to copy pictures so at least on my end this seems to not be sufficient yet. Perhaps I have "even newer" (TM) XML library which flipped something else (from QCMA point of view that is).
Still that's a step in a right direction to make it proper fix instead of hacky madness.

No worries, it's all good.

Don't get me wrong but no, it's not "all good". This is about n+1 post in Linux related problem "works on Windows". I have to deal with at least one like that practically every time so my patience is put into test. Tell me how it would look like if I would start posting in EVERY Windows related topic "works on Linux" ? Not very nice, am I right? This is exactly what I have to deal with, EVERY single time.
 
  • Like
Reactions: The_Dizzy_Vizzy

kazriko

Member
Newcomer
Joined
Jun 29, 2024
Messages
5
Trophies
0
Age
45
XP
60
Country
United States
The good news is, QCMA did connect after your fix.
The bad news is, it still refused to copy pictures so at least on my end this seems to not be sufficient yet. Perhaps I have "even newer" (TM) XML library which flipped something else (from QCMA point of view that is).
Still that's a step in a right direction to make it proper fix instead of hacky madness.
Yeah, if you put it in verbose debug mode, and try to transfer files you might see some information that could help troubleshoot it. I actually ran into some similar issues later on, but just went around it a different way, so I haven't been back to troubleshoot further. (Downloading from qcma seems to be working fine, but uploading anything, pictures or game saves, is a little unstable.)
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    The Real Jdbye @ The Real Jdbye: or at best loosen and fall on my face