Jump to content




[N00B] Download audio files onto computer for Computronics


4 replies to this topic

#1 AyScorch

  • Members
  • 8 posts

Posted 11 June 2018 - 08:33 PM

Im trying to download a .wav file onto a computer to encode it onto a Computronic Cassete.

i mean, how to do it :)

#2 Luca_S

  • Members
  • 361 posts
  • LocationGermany

Posted 11 June 2018 - 09:12 PM

Check out this wiki link for a program to convert your wav into an appropriate format: https://wiki.vexatos...mputronics:tape
(The download link has changed but the wiki apparently isn't updated. Use the download link you can find in the Readme in the github repo: https://github.com/gamax92/LionRay )
To write the resulting file to a tape use this code(Untested):
local drive = peripheral.wrap("left") --Replace left with the side of the tape drive
local f = fs.open("yourfile.dfpwm", "rb") --Replace yourfile with the filename
local byte
repeat
  byte = f.read()
  if byte then drive.write(byte) end
until not byte
f.close()

Edited by Luca_S, 11 June 2018 - 09:13 PM.


#3 AyScorch

  • Members
  • 8 posts

Posted 11 June 2018 - 09:33 PM

View PostLuca_S, on 11 June 2018 - 09:12 PM, said:

Check out this wiki link for a program to convert your wav into an appropriate format: https://wiki.vexatos...mputronics:tape
(The download link has changed but the wiki apparently isn't updated. Use the download link you can find in the Readme in the github repo: https://github.com/gamax92/LionRay )
To write the resulting file to a tape use this code(Untested):
local drive = peripheral.wrap("left") --Replace left with the side of the tape drive
local f = fs.open("yourfile.dfpwm", "rb") --Replace yourfile with the filename
local byte
repeat
  byte = f.read()
  if byte then drive.write(byte) end
until not byte
f.close()
i am on 1.12.2, it does not work due to a index null error with F

#4 KingofGamesYami

  • Members
  • 2,956 posts
  • LocationUnited States of America

Posted 11 June 2018 - 11:23 PM

Have you spelled fs correctly?

#5 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 6,945 posts
  • LocationTasmania (AU)

Posted 11 June 2018 - 11:33 PM

Assuming you have, make sure the file name you're specifying actually exists on your computer's drive. "yourfile.dfpwm" won't work unless that's the actual name you used when re-encoding your audio with LionRay!

If you're still having trouble, post the exact error message you receive. Approximations aren't helpful.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users