Family BASIC Data Recorder: Difference between revisions

From NESdev Wiki
Jump to navigationJump to search
m (describe hardware, provide link to NES equivalent schematic, add same references as on Family basic keyboard)
m (→‎References: enri's website moved)
 
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
"Manufactured by Matsushita/Panasonic for Nintendo, the recorder was released in 1984 only in Japan as an addition to the [[Family basic keyboard|Family BASIC Keyboard]] to save data from BASIC programs created by users. Also, Castle Excellent, Excitebike, Mach Rider and Wrecking Crew can use this device in order to save tracks/stages created by users." — [[wikipedia:Famicom Data Recorder|from wikipedia]]
"Manufactured by Matsushita/Panasonic for Nintendo, the recorder was released in 1984 only in Japan as an addition to the [[Family BASIC Keyboard]] to save data from BASIC programs created by users. Also, Castle Excellent, Excitebike, Mach Rider and Wrecking Crew can use this device in order to save tracks/stages created by users." — [[wikipedia:Famicom Data Recorder|from wikipedia]]


== Hardware interface ==
== Hardware interface ==
The [[Family basic keyboard|Family BASIC Keyboard]] provides two ⅛" (3.5mm) monaural phone jacks which can be plugged into the data recorder. [http://nesdev.org/tapedrv.PNG This circuit] will provide the same interface on the NES.
The [[Family BASIC Keyboard]] provides two ⅛" (3.5mm) monaural phone jacks which can be plugged into the data recorder. [http://nesdev.org/tapedrv.PNG This circuit] will provide the same interface on the NES.
=== Input ($4016 write) ===
=== Input ($4016 write) ===
  7  bit  0
  7  bit  0
Line 18: Line 18:
         |
         |
         +-- 1-bit ADC audio from audio cassette
         +-- 1-bit ADC audio from audio cassette
Because of how magnetic tape works, playing back the tape will produce a signal that is the lowpassed derivative of the original. Then this audio from the cassette recorder goes through a highpass with corner frequency of 800Hz before being discretized. In simulation, at least square waves of frequency 1200 to 2400 Hz appear to be recovered by this processing.
Because of how magnetic tape works, playing back the tape will produce a signal that is the lowpassed derivative of the original. Then this audio from the cassette recorder goes through a highpass with corner frequency of 800Hz before being discretized. In simulation, square waves of frequency 600 Hz up to the bandwidth of the tape appear to be recovered by this processing.
 
For an emulator, just play back the same bit stream as it was emitted.


== Software ==
== Software ==
It is not known whether Family BASIC uses [[wikipedia:Kansas City Standard|Kansas City Standard]] encoding, [[wikipedia:Bell 103 modem|Bell 103]] or [[wikipedia:Bell 202 modem|202]], or some other arbitrary home-grown convention for encoding the audio on the tape.
It is not known whether Family BASIC uses [[wikipedia:Kansas City Standard|Kansas City Standard]] encoding, [[wikipedia:Bell 103 modem|Bell 103]] or [[wikipedia:Bell 202 modem|202]], or some other arbitrary home-grown convention for encoding the audio on the tape.
Castle Excellent's recorder handling code mostly exists between $8000 and $80FE, and provides save games using the 1200 baud variant of Kansas City Standard.
Castle Excellent's recorder handling code mostly exists between $8000 and $80FE, and provides save games using the 1200 baud ('CUTS') and ''bit-reversed'' variant of Kansas City Standard.
Wrecking Crew uses the [https://original.sharpmz.org/tapeprob01.htm tape format] from the [[wikipedia:Sharp MZ|Sharp MZ]] personal computer.
 
For homebrew use, Chris Covell wrote a set of KCS [http://www.chrismcovell.com/TapeDump_Controls.html -generating] and [http://forums.nesdev.org/viewtopic.php?p=111232#p111232 -decoding] routines, which could easily be adapted to work with the data recorder.


== References ==
== References ==
Reverse-engineered schematics by [http://www2.odn.ne.jp/~haf09260/index.htm Enri]:
Reverse-engineered schematics by [http://cmpslv2.starfree.jp/ Enri]:
* http://www2.odn.ne.jp/~haf09260/Famic/Fambas.htm
* http://cmpslv2.starfree.jp/Famic/Fambas.htm
* Also available [http://atariusa.com/Famicom_Schematics/FC%20Family%20Basic%20Keyboard%20and%20Sound%20Circuit%20Schematic.png here] and [http://atariusa.com/Famicom_Schematics/FC%20Keyboard%20Key%20Schematic.png here]
* Also available [http://atariusa.com/Famicom_Schematics/FC%20Family%20Basic%20Keyboard%20and%20Sound%20Circuit%20Schematic.png here] and [http://atariusa.com/Famicom_Schematics/FC%20Keyboard%20Key%20Schematic.png here]
* [http://forums.nesdev.org/viewtopic.php?p=109242#p109242 ccovell identified Wrecking Crew's encoding]

Latest revision as of 22:03, 9 November 2023

"Manufactured by Matsushita/Panasonic for Nintendo, the recorder was released in 1984 only in Japan as an addition to the Family BASIC Keyboard to save data from BASIC programs created by users. Also, Castle Excellent, Excitebike, Mach Rider and Wrecking Crew can use this device in order to save tracks/stages created by users." — from wikipedia

Hardware interface

The Family BASIC Keyboard provides two ⅛" (3.5mm) monaural phone jacks which can be plugged into the data recorder. This circuit will provide the same interface on the NES.

Input ($4016 write)

7  bit  0
---- ----
xxxx xExS
      | |
      | +- 1-bit DAC audio to audio cassette
      +--- When 0, force audio readback to always read as binary 0 (5V)

The audio to the cassette recorder goes through a first-order highpass at 100Hz and is attenuated to 5mVPP at the input to the recorder.

Output ($4016 read)

7  bit  0
---- ----
xxxx xxAx
       |
       +-- 1-bit ADC audio from audio cassette

Because of how magnetic tape works, playing back the tape will produce a signal that is the lowpassed derivative of the original. Then this audio from the cassette recorder goes through a highpass with corner frequency of 800Hz before being discretized. In simulation, square waves of frequency 600 Hz up to the bandwidth of the tape appear to be recovered by this processing.

For an emulator, just play back the same bit stream as it was emitted.

Software

It is not known whether Family BASIC uses Kansas City Standard encoding, Bell 103 or 202, or some other arbitrary home-grown convention for encoding the audio on the tape. Castle Excellent's recorder handling code mostly exists between $8000 and $80FE, and provides save games using the 1200 baud ('CUTS') and bit-reversed variant of Kansas City Standard. Wrecking Crew uses the tape format from the Sharp MZ personal computer.

For homebrew use, Chris Covell wrote a set of KCS -generating and -decoding routines, which could easily be adapted to work with the data recorder.

References

Reverse-engineered schematics by Enri: