Back to Home Page!

TalkBot source files and projects

Source files are the firmware that is loaded into the PIC 16F628 microcontroller on the TalkBotBrain PCB. The TalkBotBrain was already programmed when it was made, it contains the standard TalkBot_Slave1 firmware.

If you have a PIC programmer that can do ICSP (In-Circuit Serial Programming) you can load any of these firmware into your TalkBot to change its operation.

This page contains 3 sections;

  • Official firmware
    These are firmware provided by BlackRobotics, the official firmware versions should be used "as is" and are tested. There are a lot of variations of the Slave firmware, so you can just load the one you need into your TalkBot without needing to change the firmware.

  • User firmware
    These firmware versions can be written by any TalkBot owner and BlackRobotics have not tested them. Please email us at to have your own firmware included on this page.

  • TalkBot projects
    These are projects using a TalkBotBrain. Where possible the firmware and sound libraries are included.

    NOTE! These firmware are for the use of TalkBotBrain owners only! They are not for general distribution or for use on other hardware.

    All TalkBotBrain source code is written in C language using the MikroC for PIC Compiler

    Official TalkBot firmware

    (These .ZIP files contain the firmware, and additional instructions)

    This is the standard firmware installed in all new TalkBots. Slave1 firmware will download Sound Library files from PC via serial at 19200 baud, play up to 256 sounds, control up to 8 RC servos. It accepts 1byte and 2byte serial commands at 19200 baud. See the other TalkBot pages for more information about the standard Slave1 firmware.

    This is identical to the Slave1 firmware but has one difference; It accepts serial commands at 2400 baud (not 19200 baud). This is more suitable when connecting a TalkBot to be controlled by older microcontrollers like BasicStamp1 etc. It is also more suitable when the TalkBot is mounted remotely and the serial commands are sent via very long wires.

    Slave3 is the 8-button slave, sound only. Slave3 does not control RC servos, it is a sound player only. This is a simplified TalkBot which is used when you need something to just play 1 to 8 sounds, controlled by 8 switches or buttons. It requires that 4 pull-up resistors be added to the 4 PORTA pins. Sound Library files can still be downloaded from the PC at 19200 baud (like all these slaves).

    Slave4 is the 4-button slave, sound only. Slave4 is identical to Slave3, but will only play 1 to 4 sounds, controlled by 4 switches or buttons. It does not require pull-up resistors on the 4 buttons as they are on PORTB.

    Slave5 is the parallel binary 8-wire slave, sound only. Slave5 will play up to 255 sounds. It is controlled by a parallel binary command on its 8 pins. You just send a binary number to select the sound you wish to play. It can be controlled by less than 8 pins if you connect the unused pins to ground.

    Slave6 is the random sound player slave. Slave6 is controlled by one switch or button, and will play 1 of 256 sounds. The sound will be randomly chosen from any of the available sounds.

    Slave7 is the sequential sound player slave. Slave7 is controlled by one switch or button, and will play 1 of 256 sounds. The sound will be the next sound, and after all sounds are played it loops back to the first sound.

    User firmware

    * Watch this space *

    TalkBot projects
    This project is a talking thermometer. It senses the temperature using a DS1820 sensor from Dallas Semiconductor. This sensor outputs the temperature in degrees celcius, and the TB_TalkTemp speaks the new temperature every time it changes more than 0.5'C. It also speaks the temperature anytime a button is pressed. It will operate from 6v, 9v or 12v and uses power saving modes so it only consumes about 150uA unless speaking.

    Click here for TB_TalkTemp Schematic.
    The .zip file (see up above) contains the full project; the C source, hex file, sound libraries, schematic etc. All you need is a Talkbot-battery-speaker and a DS1820 sensor and a 10k resistor. The sound library is just a male computer voice but you can load your own voice in if you prefer.
    This project is a talking "Dice". It was made as a Halloween project and also to be used for playing board games. When the skull is pressed it "rolls the dice" and makes a random number from 1 to 6. Then it speaks the number, plays a random scary movie sound, and speaks the number again.

    A cool feature is that it then flashes the skull's eyes for the number that was rolled, ie 1-6 flashes. It does this for 2 minutes after the dice was rolled. This is to reduce arguments haha! It will operate from 6v, 9v or 12v and uses power saving mode when not is use so it only consumes about 150uA unless speaking.

    The skull sculpture was made from modelling clay - the type that bakes hard in the oven. It's a metallic grey colour. After baking It was drilled with two 3mm holes, and two small high-brightnessLEDs glued in for eyes with a 390 ohm resistor glued onto the LEDs.

    The container was a clear plastic screwtop jar. Holes were melted in it in the shape of a skull using a soldering iron, these act as a "speaker grille". More holes were made in the top to mount the little "tact style" pushbutton under the skull and wires to the LED eyes. Some silicone was used to glue it together and still provide some stretch so the skull can move a little to press the button. It was then sprayed with matte black paint.


    Next a 4x AA battery holder was hot-glued into the lid of the jar, (which is now the base). The little speaker was hot-glued on top of that in the direction that faces the speaker grille holes.

    Here is a sound sample of what it says.

    The TalkBot was held in place with blu-tak. Small header plugs were added on all the wires so everything just plugs in to the TalkBot. Likewise the silicone and hot-glue can all be removed later if the TalkBot and battery holder are to be re-used on a different project.

    Click here for TB_TalkDice Schematic.
    The .zip file (see up above) contains the full project; the C source, hex file, sound libraries, schematic etc. All you need is a Talkbot-battery-speaker and an external pushbutton, 2 LEDs and 390 ohm resistor.

    Programming the firmware into TalkBot

    To program a firmware into your TalkBot you need a PIC programmer that can program a PIC 16F628, and an ICSP cable. The source files on this page generally have a .HEX file that can be programmed directly into the PIC, you do not need to modify the source files.

    PIC programmers that will program the TalkBot include;
  • Microchip PICStartPlus
  • Microchip PICKit
  • Microchip PICKit2 and BlueRoom's JuneBug
  • Microchip PICKit3
  • MikroE PICFlash
  • MikroE EasyPIC3
  • MikroE EasyPIC4
  • MikroE EasyPIC5
  • MikroE EasyPIC6
  • -- and MANY others! --

    To connect the programmer to the TalkBot you need to make a 5-wire ICSP programming cable that fits the TalkBot's 4x2 pin header (see bottom right corner);

    Using your own firmware

    You can use any of the Firmware source files on this page as a starting point, and modify the firmware source code to make your TalkBot have the features you want.

    However you should do the following; Immediately use a new name for your firmware so it does not get confused with official firmware or another user's firmware. You should not modify the 3 include files; RBTC.c RI2C.c RSTREAM.c as these are the same for all TalkBot applications. And you should use clear comments in your modified source code showing what you modified and why, and keep the modified parts separate (where possible) from the original source.

    If you do those things it will be easier for other people to use your code or to help you debug your code and fix any problems.

    TalkBot source files are written in C using the excellent MikroC for PIC 16F Compiler from MikroElectronica and you can even download a MikroC Compiler free demo version! (limited to 2K PIC size).

    Page last updated; Oct 19th 2009 - Copyright 2009 -

    Back to Home Page!