Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
fabricademy2017:students:anamaria.martinlopez:project_5 [2018/03/14 16:28]
anamaria.martinlopez
fabricademy2017:students:anamaria.martinlopez:project_5 [2018/06/27 09:29] (current)
anamaria.martinlopez
Line 23: Line 23:
 • 1 piece for the circuit • 1 piece for the circuit
  
-{{http://anakaze.com/​wp-content/​uploads/​2018/​03/​IMG_1396-300x225.jpg?​nolink&​300x225|img_1396-300x225.jpg}}+{{:fabricademy2017:​students:​anamaria.martinlopez:​proyecto_final:​img_1396.jpg?​nolink&​300x225|img_1396-300x225.jpg}}
  
 ===== Files ===== ===== Files =====
Line 30: Line 30:
  
 We start with the circuit. We start with the circuit.
 +
 +{{  :​fabricademy2017:​students:​anamaria.martinlopez:​proyecto_final:​estrella.png?​nolink&​832x632 ​ }}
  
 {{  http://​anakaze.com/​wp-content/​uploads/​2018/​03/​estrella.png?​nolink&​832x632 ​ }} {{  http://​anakaze.com/​wp-content/​uploads/​2018/​03/​estrella.png?​nolink&​832x632 ​ }}
Line 41: Line 43:
  
 In mBlock the creation of music is simple, we can create it with the block “play tone” we will be able to select a note in Anglo-Saxon notation of the five scales of a piano. On the other hand we will be able to establish the duration of the note. In mBlock the creation of music is simple, we can create it with the block “play tone” we will be able to select a note in Anglo-Saxon notation of the five scales of a piano. On the other hand we will be able to establish the duration of the note.
 +
 +{{  :​fabricademy2017:​students:​anamaria.martinlopez:​proyecto_final:​notas.png?​nolink&​794x341 ​ }}
  
 {{  http://​anakaze.com/​wp-content/​uploads/​2018/​03/​notas.png?​nolink&​794x341 ​ }} {{  http://​anakaze.com/​wp-content/​uploads/​2018/​03/​notas.png?​nolink&​794x341 ​ }}
  
 In this part we will put the duration of the note. Ask for help from a friend who practices music and experiences,​ it’s very easy. In this part we will put the duration of the note. Ask for help from a friend who practices music and experiences,​ it’s very easy.
 +
 +{{  :​fabricademy2017:​students:​anamaria.martinlopez:​proyecto_final:​duracia_n_de_la_nota.png?​nolink&​794x371 ​ }}
  
 {{  http://​anakaze.com/​wp-content/​uploads/​2018/​03/​duración-de-la-nota.png?​nolink&​794x371 ​ }} {{  http://​anakaze.com/​wp-content/​uploads/​2018/​03/​duración-de-la-nota.png?​nolink&​794x371 ​ }}
Line 62: Line 68:
 double angle_deg = 180.0/PI; double angle_deg = 180.0/PI;
  
-void setup(){\\ +void setup(){ 
-  \\ + 
-  pinMode(5,​OUTPUT);​\\ +<​code>​ 
-  ​pinMode(6,​OUTPUT);​\\ + 
-\\+pinMode(5,​OUTPUT);​ 
 +</​code>​ 
 + 
 } }
  
-void loop(){\\ +void loop(){ 
-  pinMode(6,HIGH);\\ + 
-  tone(5,​262,​500);​ // write to buzzer\+<​code>​ 
-  delay(500);\\ +pinMode(5,HIGH); 
-  tone(5,​262,​500);​ // write to buzzer\+tone(5,​262,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​262,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​440,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​440,​500);​ // write to buzzer\+tone(5,​440,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​392,​1000);​ // write to buzzer\+tone(5,​440,​500);​ // write to buzzer\ 
-  delay(1000);​\\ +delay(500);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​392,​1000);​ // write to buzzer\ 
-  delay(500);\\ +delay(1000);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​294,​500);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​294,​500);​ // write to buzzer\+tone(5,​294,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​262,​1000);​ // write to buzzer\+tone(5,​294,​500);​ // write to buzzer\ 
-  delay(1000);​\\ +delay(500);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​262,​1000);​ // write to buzzer\ 
-  delay(500);\\ +delay(1000);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​294,​1000);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(1000);​\\ +delay(500);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​294,​1000);​ // write to buzzer\ 
-  delay(500);\\ +delay(1000);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​294,​1000);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(1000);​\\ +delay(500);​ 
-  tone(5,​262,​500);​ // write to buzzer\+tone(5,​294,​1000);​ // write to buzzer\ 
-  delay(500);\\ +delay(1000);​ 
-  tone(5,​262,​500);​ // write to buzzer\+tone(5,​262,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​262,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​392,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​440,​500);​ // write to buzzer\+tone(5,​392,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​440,​500);​ // write to buzzer\+tone(5,​440,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​392,​1000);​ // write to buzzer\+tone(5,​440,​500);​ // write to buzzer\ 
-  delay(1000);​\\ +delay(500);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​392,​1000);​ // write to buzzer\ 
-  delay(500);\\ +delay(1000);​ 
-  tone(5,​349,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​349,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​330,​500);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​294,​500);​ // write to buzzer\+tone(5,​330,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​294,​500);​ // write to buzzer\+tone(5,​294,​500);​ // write to buzzer\ 
-  delay(500);\\ +delay(500);​ 
-  tone(5,​262,​1000);​ // write to buzzer\+tone(5,​294,​500);​ // write to buzzer\ 
-  delay(1000);​\\ +delay(500);​ 
-  \\ +tone(5,​262,​1000);​ // write to buzzer\ 
-  _loop();\\+delay(1000);​ 
 + 
 +_loop(); 
 +</​code>​ 
 } }
  
-void _delay(float seconds){\\ +void _delay(float seconds){ 
-  long endTime = millis() + seconds * 1000;\\ + 
-  while(millis() < endTime)_loop();​\\ +<​code>​ 
-\\+long endTime = millis() + seconds * 1000; 
 +while(millis() <​endTime)_loop();​ 
 +</​code>​ 
 + 
 + 
 +
 + 
 +void _loop(){ 
 + 
 +<​code>​ 
 + 
 +</​code>​ 
 } }
  
-void _loop(){\\ +Back [[http://​wiki.textile-academy.org/​fabricademy2017/​students/​anamaria.martinlopez/​final_project|http://​wiki.textile-academy.org/​fabricademy2017/​students/​anamaria.martinlopez/​final_project]]
-  \\ +
-}\\+