I am already familiar with python and socket usage and can send strings of text over these. But how would i go about sending, say, an MP3 file?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The following code would do what you literally ask (assuming
thesocketis a connected stream socket):but of course it’s unlikely to be much use without some higher-level protocol to help the counterpart know how much data it’s going to receive, what type of data, and so forth.