Difference between revisions of "Super Mario on floppy-drive"
Eagle00789 (talk | contribs) |
Eagle00789 (talk | contribs) |
||
Line 19: | Line 19: | ||
pinMode(3, OUTPUT); | pinMode(3, OUTPUT); | ||
} | } | ||
− | + | ||
void loop() | void loop() | ||
{ | { | ||
Line 27: | Line 27: | ||
digitalWrite(2, LOW); | digitalWrite(2, LOW); | ||
} | } | ||
− | + | ||
void reset() | void reset() | ||
{ | { |
Revision as of 21:02, 24 April 2012
Interfacing the Floppy Drive with Arduino
Connect the 2nd header of the floppy drive cable to connect to the floppy drive itself.
Then, on the end that you normaly connect to your motherboard, find pin 1 (see the red wire)
Connect pin 11 & 12 together.
Connect pins 17 & 19 to ground.
Connect pin 18 to digital 2 on the arduino
Connect pin 20 to digital 3 on the arduino
Basic Code
void setup() { pinMode(13, OUTPUT); pinMode(2, OUTPUT); pinMode(3, OUTPUT); } void loop() { reset(); digitalWrite(2, HIGH); delay(20); digitalWrite(2, LOW); } void reset() { digitalWrite(3, HIGH); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(2, HIGH); digitalWrite(2, LOW); digitalWrite(3, LOW); }