示例#1
0
 @Override
 public void run() {
   while (true) {
     if (textToTransmit != null) {
       String text = textToTransmit;
       textToTransmit = null;
       try {
         bpskModulator.convertStringToSymbols(text);
       } catch (LineUnavailableException e) {
         // TODO Auto-generated catch block
         e.printStackTrace();
       } catch (IOException e) {
         // TODO Auto-generated catch block
         e.printStackTrace();
       }
     }
     try {
       Thread.sleep(50);
     } catch (InterruptedException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     }
   }
 }
示例#2
0
 public void setFrequency(double frequency) {
   bpskModulator.setFrequency(frequency);
 }