I am using the following dialplan to record fifo call, the fifo name is queue, and the fifo number is 2001.
When user 1002 dials 2001, and fifo member 1001 answers the phone, the cdr received from freeswitch doesn't contain the recordingUrl value. I will get call number 1002, destination number 1001, and no recordingUrl from the cdr record. From the recording file name, I will get call number 1002, fifo number 2001 and no fifo member number 1001.
I want to update the recordingUrl value. Is it possible to let freeswitch send the recordingUrl value when using fifo application, or is it possible to make the record_session application get the fifo member number? Thanks.
<extension>
<condition expression="^2001$" field="destination_number">
<action application="record_session" data="$${base_dir}/recordings/${strftime(%Y%m%d%H%M%S)}_${caller_id_number}_${destination_number}.wav"/>
<action application="fifo" data="queue in"/>
</condition>
</extension>
Related
I have an issue in being unable to recive the URC message from the modem whenever it receives an SMS.
I know that it receives them since i can find and read them if I use AT+CMGL but, i don't receive any notification when the modem gets them. I played around with the URC related commands but I've been unable to get it to work (other URCs work fine).
The modem is a BG600L M3 from Quectel and following is the sequence of commands i'm sending ("AT" is always omitted and the first command is literally "AT\r", basically an empty one).
//general config
AT\r
CFUN=1,0
E1
+QCFG=\"urc/ri/other\",\"pulse\",8,1
H0
&F
V1
+CMEE=1
&D0
E1
+CREG=2
+CGREG=2
+CEREG=2
//sms config
+CPMS=\"ME\",\"ME\",\"ME\"
+QINDCFG=\"smsincoming\",1
+CMGF=1
+CSDH=0
+CSCS=\"GSM\"
+CNMI=2,2,0,2,0
//doing some deleting and reading
+CMGD=1,3
+CPMS?
//getting the gps fix
+QGPS=1
+QGPSCFG=\"gnssconfig\",3
+QGPSLOC=1
+QGPSEND
//resetting the gms connection
+CFUN=0
+CFUN=1,0
//setting up the gsm connection
+QICFG=\"dataformat\",0,0
+QICFG=\"viewmode\",0
+QICFG=\"recvind\",1
+QICFG=\"tcp/retranscfg\",3,600
+QISDE=0
+QCFG=\"band\",0xf,0x80085,0x80085,1
+QCFG=\"nwscanmode\",1,1
+QCFG=\"nwscanseq\",010101,1
+QCFG=\"iotopmode\",2,1
// checking if it's connected
+CREG?
+QNWINFO
+COPS?
//Getting the time
+CTZU=3
+CTZR=0
+QLTS
+CCLK?
You can set AT+CNMI=2,1,2,0,0 , that should do the trick.
According to specification ETSI TS 127 005 V11.0.0 (2012-10)
+CNMI: <mode>,<mt>,<bm>,<ds>,<bfr>
by keeping <mt> value to 1 we should get indication when message is stored in ME/TA
<mt>: integer type (the rules for storing received SMs depend on its
data coding scheme
0 No SMS-DELIVER indications are routed to the TE.
1 If SMS-DELIVER is stored into ME/TA, indication of the memory location is routed to the TE using unsolicited result code:
+CMTI: <mem>,<index>
I modified the erlagen.rou.xml using duarouter to get the random routes for the vehicles. It looks like this:
<vehicle id="0" depart="0.00"><route edges="31401017#0 4006688#0 4006688#1 4006688#2 4006688#3 4006688#4 29900561#0 29900561#1 32270595 33174302#0 33174302#1 4686970#0 4686970#1 122161381 30350448 30350449 4047309 30751813 -35842306#1 -35842306#0 -4900741 -4900739#2 -4900739#1"/>
</vehicle>
<vehicle id="1" depart="1.00">
<route edges="19796637 122161381 30350448 8364476 30350450#0 30350450#1 30350450#2 4006702#0 31255203#0 -31241851#2 -31241851#1 -31241851#0 31241816#3 31241835#1 31241834#0"/>
</vehicle>
<vehicle id="2" depart="2.00">
<route edges="31401017#0 4006688#0 4006688#1 4006688#2 4006688#3 4006688#4 29900561#0 29900561#1 32270595 33174302#0 33174302#1 4686970#0 4686970#1 122161381 30350448 8364476 30350450#0 30350450#1 30350450#2 4006702#0 31255203#0 31255203#1"/>
</vehicle> .......
In the original erlangen.rou.xml of VEINS, I could control the number of vehicles either by using " *.manager.numVehicles" in the omnetpp.ini file or by using the "number =198" inside " erlangen.rou.xml". But when i use only 5 vehicles using " *.manager.numVehicles = 5" in omnetpp.ini file, there are multiple vehicles generated from the "erlangen.rou.xml". How can I use the desired number of vehicles.
Thank you.
Veins 4.6 creates a new network node for every (eligible) vehicle created by SUMO (where eligibility can be limited by vehicle type and region of interest).
In addition, the numVehicles parameter of the TraCIScenarioManager classes of Veins 4.6 takes care of ensuring that at least this many vehicles are present in a simulation after every time step (click here to see the source code responsible for this behavior).
Thus, the numVehicles parameter cannot be used to limit the number of vehicles. For this, either SUMO needs to be instructed to create fewer vehicles -- or SUMO needs to be instructed to define some routes but to create no vehicles at all (thus letting the numVehicles parameter take over creation of vehicles)
you can get approximate number of vehicles by increasing the end time in python command while you are generating the traffic in CMD like in following commands end time is 200 ,so you may get around 100 vehicles.
python c:\sumo\sumo25\tools\randomTrips.py -n map.net.xml -e 200 -l
python c:\sumo\sumo25\tools\randomTrips.py -n map.net.xml -r map.rou.xml -e 200 -l
I need to call 4 web services asynchronously and aggregate the results to a single message.If one of the service takes more time to respond than the specified timeout(3sec) then the remaining responses which have arrived should be aggregated and the late coming messages should be discarded . For this i used the below snippet in spring configuration file
<int:aggregator input-channel="aggregatorInputChannel" group-timeout="3000" send-partial-result-on-expiry="true" expire-groups-upon-completion="true" output-channel="aggregatorOutputChannel" ref="responseAggregator" method="populateResponseHeader" >
</int:aggregator>
When one of the web service(lets say service4) call takes more time than the timeout value, then the thread for service4 keeps running in the background and the server send a 202 response. Any suggestions on how i should modify my aggregator to ignore the messages which arrive later than the timeout and get the response?
First of all you should take a look into the Scatter-Gather pattern.
Looks like it is fully sufficient for your use-case.
You should use expire-groups-upon-timeout="false":
<xsd:attribute name="expire-groups-upon-timeout">
<xsd:annotation>
<xsd:documentation>
Boolean flag specifying, if a group is completed due to timeout (reaper or
'group-timeout(-expression)'), whether the group should be removed.
When true, late arriving messages will form a new group. When false, they
will be discarded. Default is 'true' for an aggregator and 'false' for a
resequencer.
</xsd:documentation>
</xsd:annotation>
<xsd:simpleType>
<xsd:union memberTypes="xsd:boolean xsd:string" />
</xsd:simpleType>
I am trying to get the number of label formats remaining in the print buffer of a Zebra printer. The printer is being accessed using the Zatar cloud service. To achieve this I am:
putting the printer in a paused state
calling the ^HS command
looking at the 5th field in string 1 of the response
According to the ZPL documentation this field is the
number of formats in receive buffer
However, this value does not appear to be correct. Each subsequent time we call it whilst the printer is paused the value in the field increases. No other jobs are being sent to the printer.
Here is same output of the response:
DEVICE_COMPLETED_SUCCESSFULLY - 030,0,1,0834,003,0,0,0,000,0,0,0
000,0,0,0,0,2,6,0,00000001,1,001
1234,0
Then this after a short interval:
DEVICE_COMPLETED_SUCCESSFULLY - 030,0,1,0834,026,0,0,0,000,0,0,0
000,0,0,0,0,2,6,0,00000001,1,001
1234,0
And so on:
DEVICE_COMPLETED_SUCCESSFULLY - 030,0,1,0834,028,0,0,0,000,0,0,0
000,0,0,0,0,2,6,0,00000001,1,001
1234,0
The initial response of 003 is correct. However I do not understand why it is then incrementing to 26 and then to 28.
Why is the response not providing the correct value for the formats remaining in the receive buffer?
The reason for the discrepancy in the number of formats in the receive buffer was due to how the printer was being accessed. The Zatar cloud service was used rather than any direct method such as USB.
The Zatar cloud service uses a device called an Edgebox to communicate with the printer. The Edgebox was periodically sending commands to the printer and it was these commands that were accumulating in the receive buffer.
I am trying to setup a group dial for a given extension.
The bridge command I pass data specifying two call groups.
group/support|group/sales
Inside the directory I have users assigned to these call groups, some of which which are configured using only cellphone numbers by overriding the dial string parameter (no sip device).
However, when I try to call, the given user is not dialed as they are not registered (Originate Failed. Cause USER_NOT_REGISTERED. ) How can I configure a given user xml so that freeswitch will not skip over it for not being registered?
Thanks,
Matt
you can define dial-string in the user entry in the directory so that it dials the user's external number. In this example, I used loopback endpoint, and you can also define a string with the sofia gateway:
<param name="dial-string" value="[group_confirm_key=1,leg_delay_start=15]loopback/0794070224/${context}"/>
group_confirm_key defines that the user has to press 1 to accept the call -- this way you can be sure that the call does not land in voicemail.
leg_delay_start=15 is done because I have a SIP desktop phone, and I let it ring for the first 15 seconds.