mirror of
https://repository.entgra.net/community/device-mgt-plugins.git
synced 2025-09-16 23:42:15 +00:00
Merge pull request #795 from ruwany/master
Fix for Virtual Fire Alarm stats not displaying in MT mode
This commit is contained in:
commit
021aad47da
@ -199,8 +199,11 @@ public class VirtualHardwareManager {
|
||||
try {
|
||||
sequence = MidiSystem.getSequence(audioSrc);
|
||||
sequencer = MidiSystem.getSequencer();
|
||||
sequencer.open();
|
||||
sequencer.setSequence(sequence);
|
||||
if(sequencer != null) {
|
||||
sequencer.open();
|
||||
sequencer.setSequence(sequence);
|
||||
sequencer.setLoopCount(Clip.LOOP_CONTINUOUSLY);
|
||||
}
|
||||
} catch (InvalidMidiDataException e) {
|
||||
log.error("AudioReader: Error whilst setting MIDI Audio reader sequence");
|
||||
} catch (IOException e) {
|
||||
@ -208,8 +211,6 @@ public class VirtualHardwareManager {
|
||||
} catch (MidiUnavailableException e) {
|
||||
log.error("AudioReader: Error whilst openning MIDI Audio reader sequencer");
|
||||
}
|
||||
|
||||
sequencer.setLoopCount(Clip.LOOP_CONTINUOUSLY);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -21,5 +21,5 @@
|
||||
<property name="topic">${tenant-domain}/virtual_firealarm/+/temperature</property>
|
||||
</from>
|
||||
<mapping customMapping="disable" type="json"/>
|
||||
<to streamName="org.wso2.iot.virtualfirealarm" version="1.0.0"/>
|
||||
<to streamName="iot.per.device.stream.virtualfirealarm" version="1.0.0"/>
|
||||
</eventReceiver>
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "org.wso2.iot.virtualfirealarm",
|
||||
"name": "iot.per.device.stream.virtualfirealarm",
|
||||
"version": "1.0.0",
|
||||
"nickName": "virtual_firealarm",
|
||||
"description": "Temperature data received from the virtual_firealarm",
|
||||
@ -338,13 +338,13 @@
|
||||
<Description>Unlock the device</Description>
|
||||
</Feature>
|
||||
</Features>
|
||||
<TaskConfiguration> //Name needs to be decided <!--DeviceMonitoring-->
|
||||
<TaskConfiguration>
|
||||
<Enable>true</Enable>
|
||||
<Frequency>60000</Frequency> //Name needs to be decided <!--Period-->
|
||||
<Frequency>60000</Frequency>
|
||||
<Operations>
|
||||
<Operation>
|
||||
<Name>DEVICE_INFO</Name>
|
||||
<RecurrentTimes>1</RecurrentTimes> //Name needs to be decided <!--PeriodFactor-->
|
||||
<RecurrentTimes>1</RecurrentTimes>
|
||||
</Operation>
|
||||
<Operation>
|
||||
<Name>APPLICATION_LIST</Name>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user