How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

35
How to Build an Embedded Asterisk IP- PBX rowetel.com/ucasterisk

description

How to Build an Embedded Asterisk IP-PBX rowetel.com/ucasterisk. Contents. Free Telephony Project Why Embedded Asterisk Motivation Open Hardware Open Hardware Hacking Credits Products Demo. Free Telephony Project 1. many people working in open software we are working in open hardware - PowerPoint PPT Presentation

Transcript of How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Page 1: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

How to Build an Embedded Asterisk IP-PBX

rowetel.com/ucasterisk

Page 2: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Contents

• Free Telephony Project• Why Embedded Asterisk• Motivation• Open Hardware• Open Hardware Hacking• Credits• Products• Demo

Page 3: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Free Telephony Project 1

many people working in open software

we are working in open hardware

professional telephony hardware designs

that we give away

to improve the world a little

Page 4: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Free Telephony Project 2

designs can be copied modified, re-used

without restriction

we encourage cloning of our products

trend: functionality shifting from hardware to

(free) software

trend: total system costs constantly dropping

Page 5: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Free Telephony Project 3 falling hardware costs are a good thing

(especially for the developing world) so rather than protecting IP we leverage these

trends

by giving away free hardware designs

and encouraging cloning!

Page 6: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Why Free Telephony Project?

• Hardware designs are free as in speech• Use FOSS and Open Hardware to drive

system costs to $0• Lower the cost of telephony for everyone on

the planet• A phone call should be a human right, not a

privilege

Page 7: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Why Embedded Asterisk

• Small size (DSL router)

• Low power 3W (battery, solar)!

• No moving parts (fans or disks)

• Quiet

• Reliability (parts count, connectors)

• Low cost (few hundred $)

• Just plain cool!

Page 8: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

IP-PBX and Asterisk

• A open source PABX (PBX) that can route calls between the PSTN and VOIP

• Usual FOSS advantages – low cost and open• VOIP experiencing massive growth• Primary sponsor Digium but many

contributors• Hence alternatives such as FreeSwitch,

CallWeaver, etc, etc

Page 9: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Introduction

• Typical installation x86 PC plus PCI card to connect to the telephone lines/telephones.

• Paradigm shift away from x86/PCI cards

• History: Embedded = IP-only and no DSP (Echo cancellation and codecs not possible)

• Analog Devices Blackfin Processor has challenged this paradigm!

Page 10: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Blackfin Processor

• A powerful DSP (1 GMAC)

• AND runs uClinux

• Breaks the two processor (host/DSP) paradigm

• Low cost ($5 - $15 each)

• Well supported by vendor and community

• Open hardware and software

Page 11: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

IP-PBX Hardware 101

PCI Bridge

FXO Port

x86 CPUDSP

hardware

Asterisk

Ethernet Card

FXS Port

Host PC PCI Card

Device Driver

Page 12: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

IP-PBX Hardware 101

FXO Port

Blackfin CPU

DSP software

Asterisk

Device Driver

FXS Port

Embedded PBX

Page 13: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

IP-PBX Hardware 101

• Many redundant parts removedLower costSmaller sizeLower powerEnhanced reliability

• Don’t need “hardware” DSP – Blackfin CPU is a DSP

Page 14: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Challenges

• Complex development environment– Cross compiler & tool-chain – Customized kernel and apps

• Learning Curve

• Low memory ~64MB

• uClinux (offset by partial MMU)

• Care and feeding of the cache

Page 15: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Motivation 1

• Various motivations across the people and companies involved in the project.

• Obvious business potential in a $200 IP-PBX with multiple ports.

• Enabler for service models.

• My motivation is Social & Geeky rather than Business.

Page 16: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Motivation 2

• I like building stuff• Would like to use my hardware/DSP skills

to improve the world a little• Open software like Linux and Asterisk has

been a great thing for the World.• Craig Newmark (Craigslist) : Nerd values

“Get yourself comfortable, then do something fun to change the world a little”

Page 17: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Open Hardware 1 reference designs that anyone is free to copy,

re-use, modify

CAD files, prototypes

differences from open software

atoms cost more than bits

you need a factory

Page 18: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Open Hardware 2

many advantages over closed development

similar to open software

many eyes

low bug count

dramatic reduction in R&D cost and time

Page 19: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Open Hardware 3

CVS/SVN for version control of designs

re-using hardware building blocks

helping each other get strange parts

blog instead of log book – share experience

chat to help debug hardware

Page 20: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Open Hardware 4

normal hardware costs include 70% overhead

exciting new business models, e.g. OLPC

dramatic price reductions

local manufacture

customisation, localisation, e.g. solar, wireless

Page 21: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

How to Hack Telephony Hardware in Linux

• Schematic Entry (gschem)

• PCB Design (PCB)

• Verilog HDL (Icarus)

Page 22: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Port Asterisk to Blackfin

(gcc)

Design Schematics (gschem)

Design PCBs (PCB)

Assemble Prototype Hardware

Debug and Test Hardware

Write Verilog Code (Icarus)

Integrate and Test system

Design Process Flow

Page 23: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

gschem Schematic Entry

Page 24: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Analog Hardware Example

Page 25: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Hardware Hacking is Getting Easier!!

• Build sophisticated surface mount circuits.• Order strange parts on-line e.g. Digikey• Prototype PCB costs dropping• Stereo Microscope + soldering tools < $500• Open hardware designs• Free CAD tools• Help from on-line communities

Page 26: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk
Page 27: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Open Hardware IP-PBX Products

• IP04 4-port Analog IP-PBX (production)

• IP08 8-port Analog IP-PBX (prototype)

• E1/T1 PRI-Appliance (prototype)

• BRI-Appliance (prototype)

Page 28: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Case Study - IP04 Switches analog and VoIP calls fanless, low power (5W), rugged, compact open hardware and software easy to customise, e.g. simple UI potential for very low cost ($100), compared to

$2,000 retail for similar products stable but not feature complete (CID, GUI)

Page 29: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Case Study – IP04

Page 30: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

PRI Appliance (Astfin Team)

Page 31: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

BRI Appliance (Astfin team)

Page 32: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

'Free” Phone Call

• between Adelaide and Beijing using two IP04's

• open hardware design• designed with open CAD software• running uClinux and Asterisk• using VOIP ($0 call cost)• Freest phone call ever?

Page 33: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Demo

• Boots from a Battery• phone call• telnet, asterisk CLI• GUI

Page 34: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Credits

In no particular order:• Atcom (China) for putting the IP04 into mass

production• Astfin team for developing build system, PRI

and BRI-ISDN hardware• Analog Devices for Blackfin and great

uClinux support• Linux and Asterisk communities• Many others who contributed (e.g. drivers,

software fixes)

Page 35: How to Build an Embedded Asterisk IP-PBX rowetel/ucasterisk

Questions?

For more information

rowetel.com/ucasterisk