Connecting the SP03 Speech Module to the PICAXE-28x 

Introduction
One of the methods the SP03 modules uses for communication is the I2C bus . This example shows how to connect the SP03 to the PICAXE-28x. The SDA (data) and SCL (clock) lines are connected to pins Input4 (pin15) and Input3 (pin14) on the PICAXE chip. These are the pins used by the PICAXE-28x for the I2CIN and I2COUT commands. The photograph above shows the SP03 wired up on the PICAXE Experimenter Board.

Circuit Schematic for connecting the SP03 Speech Module to the PICAXE-28x

The schematic above shows 4k7 pull-up resistors on the SCL and SDA lines to Vdd. For greater noise immunity, I recommend pulling up using 1k8 resistors.

Software
The following shows how easy it is to use the PICAXE-28x with the Speech Module, a single line command is all that is required to speak any of the 30 pre-loaded phrases. Your own text strings of up to 80 characters in length may be sent to the synthesizer for conversion to speech.
The sample code below can be downloaded here.


' *************************************************************** 
' * SP03 Example Software Supplied by Revolution Education Ltd. * 
' ***************************************************************

'*** setup i2c *** 
' Define i2c slave address for the SP03 Speech Module 
    i2cslave $C4,i2cfast,i2cbyte

' *** firmware *** 
' read firmware version into b1 and display on screen 
    readi2c 1,(b1) 
    debug b1

main:

' *** message playback *** 
'first play back a pre-recorded message (msg 1) 
'remember to use pause to give message time to play 
    writei2c 0,(1)
    pause 5000

' *** instant speech *** 
' now download text to instantly speak 
' first write text to speak to buffer 
' nop(0), volume(0), pitch(5), speed(1), "text", null(0) 
' note creative spelling makes picaxe sound better!

    writei2c 0,(0,0,5,1,"Hello pickacks user",0)

' now actually say it (with time delay to playback) 
    writei2c 0,(64) 
    pause 5000

goto main

You can find more information on the SP03 here and the PICAXE here