Picaxe AXE171 Скачать руководство пользователя страница 4

www.picaxe.com/products/axe171 

  

 AXE171 PICAXE-14 Audio Kit © Revolution Education Ltd 2015 v1.1    

May be copied for educational use.  

4

 

 

2.0 SPE035 Kit Contents 

 

 

PCB 

 

 

 

SPE035 pcb 

 

SW1-3   

SEN030  

6mm push switch 

 

R1 

 

RES-1K   

1k resistor 

(brown black red gold) 

 

C1 

 

CAP001  

100nF capacitor 

 

H1 

 

CON042 

5 pin r/a header 

 

SPK1 

 

SPE015  

8 ohm PCB mount speaker 

 

MP3 socket 

CON050 

8 way 2.54mm sockets (optional) 

 

MP3 player 

SPE033  

DFPlayer Mini (or similar clone)   

 

 

 

 

Содержание AXE171

Страница 1: ...ject then allows playback and control of the audio tunes AXE171 Features 1 PICAXE 14M2 Microcontroller 2 Two LED outputs and two spare outputs e g for Serial LCD or Servo 3 Push switch and LDR light s...

Страница 2: ...RES 330 330 resistor orange orange brown gold 3 R2 3 5 RES 10K 10k resistor brown black orange gold 1 R4 RES 22K 22k resistor red red orange gold 1 C1 CAP001 100nF capacitor 1 IC1 ICH014 14 pin IC so...

Страница 3: ...et snaps flat on the PCB 4 Solder the 14 pin IC socket in position noting the pin 1 notch is to the bottom of the board 5 Solder the LEDs and LDR to the board You may wish to leave these with long leg...

Страница 4: ...l use 4 2 0 SPE035 Kit Contents 1 PCB SPE035 pcb 3 SW1 3 SEN030 6mm push switch 1 R1 RES 1K 1k resistor brown black red gold 1 C1 CAP001 100nF capacitor 1 H1 CON042 5 pin r a header 1 SPK1 SPE015 8 oh...

Страница 5: ...move the module from the PCB in the future On the 5 way connector carefully push hard on the corner of the first pin e g with a coin so that the short end slides through the plastic holder therefore m...

Страница 6: ...B to 32GB are supported Many people may already have a surplus micro SD card from an old mobile phone which will be ideal The music filenames must have filenames starting with 0001 mp3 0002 mp3 0003 m...

Страница 7: ...croSD card into the computer an adapter may be required right click over the microSD card drive and select Format Step 2 Make sure Quick Format Is selected Double check that it is definitely the micro...

Страница 8: ...centre switch will increase the volume 7 A long press of the right switch will decrease the volume Note that as with most MP3 players the next previous track push buttons operate on the FAT file syste...

Страница 9: ...B 1 Spare Serial LCD or Servo optional B 2 Top LED B 3 Spare Serial LCD or Servo optional B 4 TX to MP3 player B 5 Bottom LED C 0 Push switch C 1 Spare C 2 BUSY from MP3 player C 3 RX from MP3 player...

Страница 10: ...lours including red yellow green and blue Special ultrabright LEDs are used in safety warning devices such as the flashing lights used on bicycles Infra red LEDs produce infra red light that cannot be...

Страница 11: ...orrect pin number is selected within each PICAXE command The following program will flash one LED on and off every second Blockly Flowchart BASIC do high B 2 LED on pause 1000 wait 1 second low B 2 LE...

Страница 12: ...ike keypads Micro switches are used in burglar alarms to detect if the cover is removed from the alarm box Reed switches are used to detect doors and windows being opened and tilt switches are often u...

Страница 13: ...a switch on Input pinC 0 Therefore make sure the correct pin number is selected within each PICAXE command After connecting the switch it can be tested by a simple program like this This program will...

Страница 14: ...electronic circuits to measure changes in light level 4 3 1 What are LDRs used for LDRs are used in automatic street lamps to switch them on at night and off during the day They are also used within...

Страница 15: ...tal converter ADC which converts the varying voltage signal into a number between 0 and 255 This number can then be stored in a variable and compared against a desired threshold point 4 2 3 Testing th...

Страница 16: ...d which can transmit the value of the variable to the computer screen Using this command you can therefore run an experiment for instance using your hand to cover the LDR to calculate the highest and...

Страница 17: ...n show the value of the light reading In PICAXE Editor 6 the debug panel is found in the Code Explorer on the right hand side of the screen In the Blockly Chrome App the Debug panel can be opened from...

Страница 18: ...f all the most common SPE035 commands Simply drag out the block and select the desired command from the drop down list A number or variable block only needs to be attached to the SPE035 block for the...

Страница 19: ...put pinC 2 Therefore make sure the correct pin number is selected within each PICAXE command To use the SPE035 it is first necessary to issue the initialise command to the module this tells the module...

Страница 20: ...T9600_8 Symbol cmd b0 Symbol arg w1 b3 b2 Symbol arg lsb b2 Symbol arg msb b3 High TX set TX pin high for idle high serial Pause 2000 SerTxd Starting CR LF SerTxd Select microSD Card CR LF cmd 09 arg...

Страница 21: ...is example shows how to play a tune when the light level drops below 100 The end of the previous tune is detected by checking whether the MP3 BUSY signal connected to PICAXE input C 2 is high The BUSY...

Страница 22: ...ymbol arg lsb b2 Symbol arg msb b3 Symbol varA w2 High TX set TX pin high for idle high serial Pause 2000 SerTxd Starting CR LF SerTxd Select microSD Card CR LF cmd 09 arg 0002 Gosub Send Pause 4000 D...

Страница 23: ...e valid values are 1 to 30 and then use a variable varA to play the tunes 0001 mp3 to 0009 mp3 in turn The end of the previous tune is detected by checking whether the MP3 BUSY signal connected to PIC...

Страница 24: ...3 Symbol varA w2 High TX set TX pin high for idle high serial Pause 2000 SerTxd Starting CR LF SerTxd Select microSD Card CR LF cmd 09 arg 0002 Gosub Send Pause 4000 SerTxd Set volume 20 CR LF cmd 06...

Страница 25: ...www picaxe com products axe171 AXE171 PICAXE 14 Audio Kit Revolution Education Ltd 2015 v1 1 May be copied for educational use 25 6 0 Circuit Diagram To be added...

Отзывы: