PIONEERS Lenny Is Back!

lthown

New Member
Joined
Nov 15, 2007
Messages
16
Reaction score
8
Great list of places to route telemarketers on DSL Reports this week.


So provided we dug up the file somewhere, how would I go about integrating lenny with the Gotcha-Free PBXIAF on RaspberryPi2 that I just set up? I've been using freePBX for years, this is my first exposure to AsteriskGUI and I'm still figuring out where everything is.
 

dandy_don

Member
Joined
Sep 27, 2010
Messages
173
Reaction score
11
Hi Ithown.

Lenny appears to be working fine right out the box on my Gotcha-Free Raspberry Pi 2 pbx. I have not tried this yet, but I'm sure I could transfer a caller to Lenny (extension 53669). Hes a real hoot! Just waiting for Larissa to make it through Grad School!
 

lakecoder

Guru
Joined
Jan 13, 2010
Messages
52
Reaction score
3
Can anyone confirm if IncrediblePBX12 (Ubuntu) Lenny is working for them? As a test I routed a DID to Lenny's extension but just get "congestion" tones.

Lenny's ext is set to dial: SIP/[email protected]
 

lakecoder

Guru
Joined
Jan 13, 2010
Messages
52
Reaction score
3
Hmmm. No dice. Just rings about 5 times before giving up....

-- Executing [s@macro-dial-one:43] Macro("SIP/9200 Home-00000017", "dialout-one-predial-hook,") in new stack
-- Executing [s@macro-dialout-one-predial-hook:1] MacroExit("SIP/9200 Home-00000017", "") in new stack

-- Executing [s@macro-dial-one:44] Dial("SIP/9200 Home-00000017", "SIP/[email protected],,Ttr") in new stack
-- Called SIP/[email protected]
> 0x25db420 -- Probation passed - setting RTP source address to 208.100.39.53:10704

[2015-03-27 11:29:58] WARNING[2173]: chan_sip.c:4103 retrans_pkt: Retransmission timeout reached on transmission [email protected]:5061 for seqno 102 (Critical Request) -- See https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions
Packet timed out after 32000ms with no response
[2015-03-27 11:29:58] WARNING[2173]: chan_sip.c:4132 retrans_pkt: Hanging up call [email protected]:5061 - no reply to our critical packet (see https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions).
-- SIP/sip2sip.info-00000018 is circuit-busy
== Everyone is busy/congested at this time (1:0/1/0)
 

lthown

New Member
Joined
Nov 15, 2007
Messages
16
Reaction score
8
So I was able to integrate Lenny back in to the Gotcha Free pbx for Raspberry PI. I used the instructions for the first page with some slight modifications.
  1. the lenny.tgz is now gone, I was able to find Lenny.zip on DSL reports
  2. Files 1-9 need to be renamed, Lenny1.ulaw needs to be named Lenny01.ulaw 02, 03 etc...
  3. The instructions assume the extensions_custom.conf has a "BEGIN Lenny Remake" section, well it doesn't anymore. Instead there's a [CallingRule_SIP_URI] section that has the SIP dialplan for Lenny. You can use that and bag the whole endevor... unless you want the recordings of Lenny, then you need to put the contents of lenny.txt into that section, replacing the SIP stuff that's there
  4. So skip the two lines in the instructions that start with "sed" since you did the same thing manually in #3
  5. If you want the recordings emailed to you, you're going to need to "apt-get install mime-construct" because it's missing, also it gets installed to /usr/local/sbin/mime-construct
 

Mango

www.toao.net
Joined
Aug 10, 2013
Messages
46
Reaction score
13
Here's a 26-minute conversation between Lenny and an astonishingly unkind telemarketer:

 

Aurock

New Member
Joined
Jul 15, 2015
Messages
1
Reaction score
0
So I was able to integrate Lenny back in to the Gotcha Free pbx for Raspberry PI. I used the instructions for the first page with some slight modifications.
  1. the lenny.tgz is now gone, I was able to find Lenny.zip on DSL reports
  2. Files 1-9 need to be renamed, Lenny1.ulaw needs to be named Lenny01.ulaw 02, 03 etc...
  3. The instructions assume the extensions_custom.conf has a "BEGIN Lenny Remake" section, well it doesn't anymore. Instead there's a [CallingRule_SIP_URI] section that has the SIP dialplan for Lenny. You can use that and bag the whole endevor... unless you want the recordings of Lenny, then you need to put the contents of lenny.txt into that section, replacing the SIP stuff that's there
  4. So skip the two lines in the instructions that start with "sed" since you did the same thing manually in #3
  5. If you want the recordings emailed to you, you're going to need to "apt-get install mime-construct" because it's missing, also it gets installed to /usr/local/sbin/mime-construct

I came across Lenny recently on Reddit, and immediately began searching for a way to set up an instance of my own. With the help of this post, the Incredible PBX for raspberry Pi 2 guide, and simonics GV gateway, I have gotten close, but not quite all the way. I've got a running instance of incredible PBX, which if I connect to it with Yate Client and dial 53669 I can converse with Lenny. I've also got it connected to google voice and the auto attendent answers when I call my GV number. I'd like to get incoming calls to be answered directly by lenny though. I've been fiddling with the incoming call rules and such, but Lenny is stubborn and no matter what I do he won't answer the main line, only calls directly to his number.

What do I need to change to make lenny answer calls that go to my GV number?

Thanks!
 

tycho

Guru (not...)
Joined
Aug 9, 2011
Messages
652
Reaction score
272
The reboot of this thread prompted me to add "Native Lenny" to one of my PBXs, rather than a "referral" to someone else's SIP URI. I got it working seemingly pretty easily by generally following the script on the very first page of this thread, substituting in the ULAW files from the .zip file found on DSLReports. Works flawlessly when I call the Lenny extension from my main 701 extension on the same box.

But, for the life of me, I can't route incoming, external calls to Lenny. I'm probably doing something very noobish with regard to inbound routes...

This is on an Incredible PBX 12.7.1 for Ubuntu 14 box with Asterisk 12.7.1 and FreePBX 12.0.12 (although the admin splash page indicates FreePBX 12.0.38) running on Ubuntu 14.04.1 LTS.

I have a DID registered to the box. If I use a general Inbound Route, all calls, any DID/CID, and set the destination as Extension 701, calls to that DID reach ext. 701 if it is registered with the PBX, and go to VM if the extension is not registered. So, all of that is working.

However, if I instead set the destination of the general Inbound Route, all calls, any DID/CID to 53669 -- the Lenny extension -- the call rings and rings and rings ... it goes nowhere.

Can't make it work either by creating a separate inbound route based on CID or DID with a destination set to 53669. Calls just ring.

If I take the easy route and make the Lenny extension nothing more than a SIP URI call to, for example, SIP/[email protected], that works just fine.

I've looked at logs comparing an inbound route directed to the lenny extension, and an inbound route directed to 701 registered but not answering. It looks like the logic can't find a dialstring for poor Lenny, and sets DIALSTATUS: NOANSWER:

Code:
Working inbound call with inbound route set to extension 701:
 
[2015-07-20 18:38:45] VERBOSE[29105][C-0000011b] pbx.c:    -- Executing [dstring@macro-dial-one:10] NoOp("SIP/IPComms1-in-0000010d", "Debug: Found PJSIP Destination PJSIP/701, updaing with PJSIP_DIAL_CONTACTS") in new stack
[2015-07-20 18:38:45] VERBOSE[29105][C-0000011b] pbx.c:    -- Executing [dstring@macro-dial-one:11] Set("SIP/IPComms1-in-0000010d", "THISDIAL=PJSIP/701/sip:701@[MY IP ADDY]:52389;rinstance=[STRING THAT LOOKS LIKE A MAC ADDY]") in new stack
[2015-07-20 18:38:45] VERBOSE[29105][C-0000011b] pbx.c:    -- Executing [dstring@macro-dial-one:12] Set("SIP/IPComms1-in-0000010d", "DSTRING=PJSIP/701/sip:701@[MY IP ADDY]:52389;rinstance=[STRING THAT LOOKS LIKE A MAC ADDY]&") in new stack
[2015-07-20 18:38:45] VERBOSE[29105][C-0000011b] pbx.c:    -- Executing [dstring@macro-dial-one:13] Set("SIP/IPComms1-in-0000010d", "ITER=2") in new stack
[2015-07-20 18:38:45] VERBOSE[29105][C-0000011b] pbx.c:    -- Executing [dstring@macro-dial-one:14] GotoIf("SIP/IPComms1-in-0000010d", "0?begin") in new stack
[2015-07-20 18:38:45] VERBOSE[29105][C-0000011b] pbx.c:    -- Executing [dstring@macro-dial-one:15] Set("SIP/IPComms1-in-0000010d", "DSTRING=PJSIP/701/sip:701@[MY IP ADDY]:52389;rinstance=[STRING THAT LOOKS LIKE A MAC ADDY]") in new stack
 
Broken inbound call with inbound route set to Lenny extension:
 
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:10] NoOp("SIP/IPComms1-in-0000010a", "Debug: Found PJSIP Destination PJSIP/53669, updaing with PJSIP_DIAL_CONTACTS") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:11] Set("SIP/IPComms1-in-0000010a", "THISDIAL=") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:12] Set("SIP/IPComms1-in-0000010a", "DSTRING=&") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:13] Set("SIP/IPComms1-in-0000010a", "ITER=2") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:14] GotoIf("SIP/IPComms1-in-0000010a", "0?begin") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:15] Set("SIP/IPComms1-in-0000010a", "DSTRING=") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [dstring@macro-dial-one:16] Return("SIP/IPComms1-in-0000010a", "") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [s@macro-dial-one:27] GotoIf("SIP/IPComms1-in-0000010a", "1?nodial") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Goto (macro-dial-one,s,49)
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [s@macro-dial-one:49] ExecIf("SIP/IPComms1-in-0000010a", "1?Set(DIALSTATUS=NOANSWER)") in new stack
[2015-07-20 18:06:08] VERBOSE[26606][C-00000118] pbx.c:    -- Executing [s@macro-dial-one:50] NoOp("SIP/IPComms1-in-0000010a", "Returned from dial-one with nothing to call and DIALSTATUS: NOANSWER") in new stack

Anything jump out at anyone?
 

petez69

New Member
Joined
Jan 25, 2014
Messages
17
Reaction score
3
Hi Tycho

I have Lenny working on a previous version with unattended transfer I cant find the installer to test on the latest raspberrypi. Could I get a copy of the tgz/zip file, I'd like to get it working myself and then we can compare notes :)

Thanks..Pete
 

tycho

Guru (not...)
Joined
Aug 9, 2011
Messages
652
Reaction score
272
Hi Tycho

I have Lenny working on a previous version with unattended transfer I cant find the installer to test on the latest raspberrypi. Could I get a copy of the tgz/zip file, I'd like to get it working myself and then we can compare notes :)

Thanks..Pete

Are you looking for the Lenny audio files? I do indeed have them. How can I get them to you? they are small enough to email so perhaps PM me with an address.

Other than that I have no "installer" file. I followed the script posted by wardmundy in the very first post in this thread. That script downloads, and then deletes, "Lenny.tgz":

Code:
wget http://pbxinaflash.com/Lenny.tgz
tar zxvf Lenny.tgz
rm Lenny.tgz
 

petez69

New Member
Joined
Jan 25, 2014
Messages
17
Reaction score
3
Hi Tycho

Ok I found that script on my box though I'm not sure it was the one I used to get mine working. In looking at the script, there are a large number of entries in extensions_custom.conf that you wont have.....

[from-internal-custom]
;# // BEGIN Lenny Remake
; version 0.3.2 copyright: none claimed. Enjoy!
exten => 53669,1,Answer
exten => 53669,n,Set(TIMEOUT(absolute)=600)
exten => 53669,n,Set(MACHINE=0)
exten => 53669,n,Set(OPTION=5)
exten => 53669,n,Set(TALK_DETECTED=0)
exten => 53669,n,Set(RECORDING=${UNIQUEID})

exten => 53669,n,MixMonitor(/tmp/Lenny/${RECORDING}.wav)
exten => 53669,n,NoOp(Recording will be available: /tmp/Lenny/${RECORDING}.wav)
;exten => 53669,n,Playback(en/this-call-may-be-monitored-or-recorded)

exten => 53669,n,Gosub(playit(Lenny01))
exten => 53669,n,Gosub(playit(Lenny02))
exten => 53669,n,Gosub(playitonce(Lenny03))
exten => 53669,n,Gosub(playitonce(Lenny04))
exten => 53669,n,Gosub(playitonce(Lenny05))
exten => 53669,n,Gosub(playitonce(Lenny06))
exten => 53669,n,Gosub(playitonce(Lenny07))
exten => 53669,n,Gosub(playitonce(Lenny08))
exten => 53669,n,Gosub(playitonce(Lenny09))
exten => 53669,n,Gosub(playitonce(Lenny10))
exten => 53669,n,Gosub(playitonce(Lenny11))
exten => 53669,n,Gosub(playitonce(Lenny12))
exten => 53669,n,Gosub(playitonce(Lenny13))
exten => 53669,n,Gosub(playitonce(Lenny14))
exten => 53669,n,Gosub(playitonce(Lenny15))
exten => 53669,n,Gosub(playitonce(Lenny02))
exten => 53669,n,Gosub(playitonce(Lenny03))
exten => 53669,n,Gosub(playitonce(Lenny06))
exten => 53669,n,Gosub(playitonce(Lenny08))
exten => 53669,n,Gosub(playitonce(Lenny09))
exten => 53669,n,Gosub(playitonce(Lenny10))
exten => 53669,n,Gosub(playitonce(Lenny14))
exten => 53669,n,Playback(en/tt-monkeys)
exten => 53669,n,Hangup

exten => 53669,n(playit),NoOp(Lenny speaks and repeats until reponse)
exten => 53669,n,Set(LOCAL(lennyclip)=${ARG1})
exten => 53669,n(oncemo),Set(TALK_DETECTED=0)
exten => 53669,n,Background(lenny/${lennyclip})
exten => 53669,n,AMD(2500,1500,800,5000,100,50,3,256)
exten => 53669,n,NoOp(${AMDCAUSE})
exten => 53669,n,GotoIf($["${AMDCAUSE:0:17}"="INITIALSILENCE-25"]?reststop)
exten => 53669,n(mach),WaitForSilence(700,3)
exten => 53669,n,Goto(humn)

exten => 53669,n(reststop),WaitForSilence(800,2)
exten => 53669,n,Goto(oncemo)
exten => 53669,n(humn),Return

exten => 53669,n(playitonce),NoOp(Lenny speaks once)
exten => 53669,n,Set(LOCAL(lennyclip)=${ARG1})
exten => 53669,n(noresponse),Background(lenny/${lennyclip})
exten => 53669,n,AMD(2500,1500,800,5000,100,50,3,256)
exten => 53669,n,NoOp(${AMDCAUSE})
;exten => 53669,n,GotoIf($["${AMDCAUSE}"="INITIALSILENCE-2500-2500"]?noresponse)
;exten => 53669,n,GotoIf($[${AMDSTATUS}=HUMAN]?humn2:mach2)
;exten => 53669,n(mach2),WaitForSilence(2000,1)
exten => 53669,n(mach2),WaitForSilence(1000,1)
exten => 53669,n(humn2),Return


Think we will have to ping Ward to see if we can get a copy of the tarball....as the install script removes it :)

Pete
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,168
Reaction score
5,199
All of the stuff in the page 1 script appears to be correct. The script tries to first remove the existing dialplan code in extensions_custom.conf, and then it puts back the new stuff. The only thing you'll be missing are the recordings.
 

tycho

Guru (not...)
Joined
Aug 9, 2011
Messages
652
Reaction score
272
Hi Tycho

Ok I found that script on my box though I'm not sure it was the one I used to get mine working. In looking at the script, there are a large number of entries in extensions_custom.conf that you wont have.....

Pete

You've left me confused.

See my earlier post. I =did= get Lenny working and to do so I used the script posted at the very beginning of this looong thread. I do indeed have all of those entries in my extensions_custom.conf. That's not the issue that I raised.

What I pointed out was my inability to forward incoming external calls to the Lenny extension. I can call the Lenny from a local extension just fine, but if I try to terminate an incoming call from a specific DID, CID, or -- heck -- =ANY= incoming trunk to the Lenny extension it fails. I posted the verbose listings of those call flows in my earlier missive.

So, that's the problem that -I- am trying to fix. No suggestions have been offered.

Regarding -your- problem you said (I think...) that you needed the audio files. I have them, and I offered to get them to you if you get me an email address or somesuch via PM. That offer still stands but I haven't heard from you in that regard...
 

MGD4me

Guru
Joined
Feb 3, 2009
Messages
505
Reaction score
109
I'm certainly no expert with PJSIP, but I noticed in your log capture that THISDIAL and DSTRING do not contain the necessary data.

Can you re-run the incoming call again, and show the complete call details leading up to what you have shown in post #158. Are there any other clues that may have been inadvertently snipped off before the call reached that first "Debug:" statement?
 

tycho

Guru (not...)
Joined
Aug 9, 2011
Messages
652
Reaction score
272
I'm certainly no expert with PJSIP, but I noticed in your log capture that THISDIAL and DSTRING do not contain the necessary data.

Can you re-run the incoming call again, and show the complete call details leading up to what you have shown in post #158. Are there any other clues that may have been inadvertently snipped off before the call reached that first "Debug:" statement?

Thanks for the reply, MGD4me.

Yes; that's exactly the quandary. THISDIAL and DSTRING contain noting when the call comes in from the outside. Ever. By comparison, those variables contain the expected values when a call from a local extension is made to the Lenny extension. I'll re-run and post but (can't see as I type this what I'd initially posted) I'd thought that I'd served-up the whole relevant enchilada. Let me try again to be sure...
 

Members online

Forum statistics

Threads
25,778
Messages
167,504
Members
19,198
Latest member
serhii
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top