Talk:TCP Loader

From WiiBrew
Jump to navigation Jump to search

*nix way of doing this?

Hi, I was wondering about the protocol of this loader.
If it's just "client sends size of file to load, client send file" how is that size represented? Bytes, bits, kbytes, mbytes?

I'm currently not able to test this by a trial-and-error progress, but would this work:

ls -la <filename> | awk '{print $5}' | nc <Wii IP> 8080 && cat <filename> | nc <Wii IP> 8080

--jlor (sorry for not signing originally)

This just sends the bytesize of the file to the Wii IP at port 8080, then sends the data afterwards.

Please sign your comments. I do not think that would work, you need to send it during the same connection, not during two connections.--henke37 06:04, 22 April 2008 (PDT)

So write the bytesize and then the data to a file and send that. 198.166.12.229 15:05, 22 April 2008 (PDT)
or
( ls -l <filename> | awk '{print $5}' ; cat <filename> ) | nc <Wii IP> 8080
130.237.152.216 21:56, 22 April 2008 (PDT)
I doubt this would work since the code reads it into an uint32 (big endian too..), and nc would just send it as a character string.. I put together a small c-program that should work. --heanol