121 Commits

Author SHA1 Message Date
Mathieu Parent
8950d00b1f Skinny: Fix the build 2010-04-02 14:25:16 +02:00
Mathieu Parent
c216c722af perl-skinny: Add call test
- more verbose when incomplete message
- guess hostname
- do a basic call to Voicemail:
  + Newcall softkey, wait 5
  + Voicemail button, wait 20
  + EndCall softkey
2010-04-02 12:21:47 +02:00
Mathieu Parent
63f3948d83 Skinny:
- don't force session location (not needed)
- Correct Skinny-Station-Instance event header and log if profile or
  device is not found
2010-04-02 12:15:33 +02:00
Mathieu Parent
5ce2759e70 Skinny: Add the missing api files 2010-04-02 12:14:41 +02:00
Mathieu Parent
54e73c774f Skinny: Check for socket to see if listener is alive
also, use tab to indent
2010-04-01 19:50:55 +02:00
Mathieu Parent
59bb764ff9 Skinny: avoid some crashes
- move api to own file
- really allow several profiles (one thread per profile)
- global pool
- pool per profile
- Remove unused globals.calls
- Check for closed listener before sending data
- use mutex for hashes
2010-04-01 19:41:48 +02:00
Mathieu Parent
b8ac781c05 Skinny: Implement shared lines and more
- Shared lines (same line on several phones)
  + Active lines stored in db
- Separate SQL mutex per profile
- New event skinny::call_state
- Clean port_message
- More protocol understanding:
  + stimulus may have call_id
  + off_hook may have call_id
  + set_ringer may have call_id and line_instance
  + New DisplayPriNotifyMessage
- Use Cisco terms for Call state
  + Congestion -> LineInUse
  + CallRemoteMultiline -> InUseRemotely
- Add line_instance to Lines table (relative position contrary to
  absolute position)
- Less assertions as FS already does some
2010-04-01 14:08:12 +02:00
Mathieu Parent
39c9065e87 perl-skinny: enhance the Testsuite
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@17128 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-29 07:44:25 +00:00
Mathieu Parent
868530fc05 Skinny: split the test into perl lib + bin
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@17124 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-27 22:43:18 +00:00
Mathieu Parent
b769233b76 Skinny: Split ou tables
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@17022 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-17 12:52:08 +00:00
Mathieu Parent
869c221f3a Skinny: more portable printf for sizeof (thanks to bkw)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16961 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-10 17:04:00 +00:00
Mathieu Parent
fa92f47bd1 Skinny: solve compilation on amd64
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16960 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-10 14:37:14 +00:00
Mathieu Parent
3731c4ab91 Skinny:
- allow several instances of the same device on different sockets
- move lines to table skinny_lines, as they need more params
- various small changes



git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16959 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-10 13:49:53 +00:00
Mathieu Parent
54510a372a Skinny: off_hook_message doesn't include call_id on older phones
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16876 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-03 07:49:59 +00:00
Mathieu Parent
76be99c801 Skinny: avoid stack overflow by lowering button_template_helper size
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16875 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-03 07:48:42 +00:00
Mathieu Parent
3fe4d7a3d8 Skinny: test: put config on top
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16850 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-03-01 11:06:47 +00:00
Mathieu Parent
7491bd639c Skinny: sleep to lower CPU consomption
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16825 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-25 18:26:23 +00:00
Mathieu Parent
05048ba11f Skinny: handle ServiceUrl
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16823 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-25 17:36:45 +00:00
Mathieu Parent
adde57cb24 Skinny: handle UnregisterMessage and properly flush listener
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16820 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-25 15:23:11 +00:00
Mathieu Parent
c84d664c6b Skinny: add send Reset/Restart
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16819 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-25 14:34:43 +00:00
Mathieu Parent
3c36d26988 Skinny: answer FeatureStatReqMessage with FeatureStatMessage
'#buggy version!'

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16796 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:06:58 +00:00
Mathieu Parent
32565f50f5 Skinny: previous commit was incomplete
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16795 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:06:47 +00:00
Mathieu Parent
1b988b2267 Skinny: config cleaning and refactorisation
- removed unused globals: codecèprefs, codec_master, codec_rates
- moved global debug to profile
- store button type as id in DB (avoid case-sensitivity problem)
-

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16794 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:06:36 +00:00
Mathieu Parent
9f870bd311 Skinny: API commands (autocompletion included!)
skinny profile <profile_name> device <device_name> send SetRingerMessage <ring_type> <ring_mode>
skinny profile <profile_name> device <device_name> send SetLampMessage <stimulus> <instance> <lamp_mode>
skinny profile <profile_name> device <device_name> send SetSpeakerModeMessage <speaker_mode>
skinny profile <profile_name> device <device_name> send CallState <call_state> <line_instance> <call_id>

Also:
- Correct sended line displayname
- Re-use the line on SoftKey
- Handle Answer SoftKey

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16793 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:06:25 +00:00
Mathieu Parent
a65c6c902d Skinny: avoid some wired scenarii
- Close all sessions without B-leg
- Hold sessions with B-leg
- Currently hold is same as hang up
- Try to guess the best line to choose (use an existing one)

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16792 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:06:16 +00:00
Mathieu Parent
0151d20c97 Skinny: redial
- Allow redial from softKey or stimulus
- Add redial, newcall to on_hook softkeys
- Add endcall to ringing and connected softkeys

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16791 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:06:06 +00:00
Mathieu Parent
139291f917 Skinny: Rework of buttons
- Refactorize line/speed-dial info (with getters)
- Set calling/called party when known
- Don't recreate session on existing
- Lower some debug messages (SQL, messages send/received)

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16790 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:05:56 +00:00
Mathieu Parent
900c50fd91 Skinny: Corrections
- Construct call_id based on simple increment per profile
- close RTP only if needed
- now hanging up while there is no other leg works
- better steps: create_session -> process_dest -> answer

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16789 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:05:45 +00:00
Mathieu Parent
834a28ff7f Skinny: House cleaning
- Print message types and softkey states instead of their code
- Show line number of calling function
- Replace the remaining send_select_soft_keys by skinny_line_set_state (to keep proper state)

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16788 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:05:34 +00:00
Mathieu Parent
afbab7bc7b Skinny: Line state
Avoid the use of TFLAG_WAITING_DEST an replace by a line_state corresponding to the softkey events

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16787 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:05:26 +00:00
Mathieu Parent
99ce7a4b01 Skinny:
- correct speed-dial and line label
- hangup when receiving EndDial softkey

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16786 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:05:16 +00:00
Mathieu Parent
5ca2516bea Skinny: M3: Calls management: handle OffHook then compose
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16785 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:05:06 +00:00
Mathieu Parent
a977bda2e9 Skinny: Split the code
- mod_skinny.c: module, profile, listener, channels
- skinny_protocol.c: skinny messages

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16784 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:04:56 +00:00
Mathieu Parent
8fd52217d9 Skinny: moving to autotools
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16783 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:04:44 +00:00
Mathieu Parent
902991fea8 Skinny: M3: Calls management: ingoing call
Following scenario:
- offhook a specific line
- compose 4 digits

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16782 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:04:36 +00:00
Mathieu Parent
a43f9cea19 Skinny: M3: Calls management: Each line has a session
- Each line as its session
- USER_BUSY if line is busy
- properly guess device and line to ring

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16781 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:04:25 +00:00
Mathieu Parent
a68fef28be Skinny: Milestone 3: Calls management: handle DTMF
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16780 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:04:16 +00:00
Mathieu Parent
847c3a49bb Skinny: Milestone 3: Calls management
As of now, this is only proof of concept. How to test:
- only one phone registred
- call originate skinny/internal/7628 &delay_echo(100) from console
- answer
- test the echo
- hangup

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16779 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:04:08 +00:00
Mathieu Parent
8bbbd88bd7 Skinny: Milestone 4: proper SoftkeyTemplateResMessage
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16778 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:03:59 +00:00
Mathieu Parent
02c092d03d Skinny: Milestone 8: answer ConfigStatReqmessage with ConfigStatMessage
also some cleanup

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16777 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:03:46 +00:00
Mathieu Parent
8850125676 Skinny: Add helper functions
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16776 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:03:04 +00:00
Mathieu Parent
ecd86ec42c Skinny: Milestone 3: Calls management
- House cleaning

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16775 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:01:47 +00:00
Mathieu Parent
90063622cf Skinny: Milestone 8 (partial): TimeDate
- answer TimeDateReqMessage with DefineTimeDate

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16774 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:01:39 +00:00
Mathieu Parent
506517e9ac Milestone 3: Calls management: Add several messages structs
+ KeypadButtonMessage
+ StimulusMessage
+ OnHookMessage
+ OpenReceiveChannelAck
+ SoftKeyEventMessage
+ StartToneMessage
+ StopToneMessage
+ SetRingerMessage
+ SetLampMessage
+ SetSpeakerModeMessage
+ StartMediaTransmissionMessage
+ StopMediaTransmissionMessage
+ CallInfoMessage
+ OpenReceiveChannelMessage
+ SelectSoftKeysMessage
+ CallStateMessage
+ DisplayPromptStatusMessage
+ ClearPromptMessage
+ ActivateCallPlaneMessage
+ DialedNumberMessage

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16773 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:01:31 +00:00
Mathieu Parent
ca3aa27976 Skinny: Milestone 8: Miscellaneous (handle HeadsetStatusMessage)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16772 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:01:21 +00:00
Mathieu Parent
6c7de2c721 Milestone 7: Alarm
- Custom events: skinny::alarm

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16771 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:01:13 +00:00
Mathieu Parent
829a711c72 Skinny: Milestone 5: Speed-dials
- answer SpeedDialStatReqMessage with SpeedDialStatMessage

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16770 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:00:55 +00:00
Mathieu Parent
afc8e79655 Skinny: Milestone 4: Button template, Soft-key template and Soft-key sets
- buttons are now stored in the same table
- answer ButtonTemplateReqMessage with ButtonTemplateMessage: DONE
- answer SoftKeyTemplateReqMessage with SoftKeyTemplateResMessage: WIP (currently empty response)
- answer SoftKeySetReqMessage with SoftKeySetResMessage: WIP (currently empty response)

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16769 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:00:45 +00:00
Mathieu Parent
48aaa884fd Skinny: Milestone 7: handle AlarmMessage
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16768 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:00:35 +00:00
Mathieu Parent
3ed58f15db Skinny: Sanity
- truncate tables on module load
- check for message length

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16767 d0543943-73ff-0310-b7d9-9358b9ac24b2
2010-02-24 12:00:28 +00:00