示例#1
0
 /// <summary>
 /// Method for starting and stopping scanning. Updates text on scan button as well
 /// </summary>
 public void ToggleScanning()
 {
     if (scanButtonText.text == "START SCANNING")
     {
         awe_estimote.StartScan();
         scanButtonText.text = "STOP SCANNING";
     }
     else
     {
         awe_estimote.StopScan();
         scanButtonText.text = "START SCANNING";
     }
 }
示例#2
0
文件: compass.cs 项目: npict/AR3
    // Update is called once per frame
    void Update()
    {
        heading  = Input.compass.trueHeading;
        txt.text = heading.ToString();

        if (awe_estimote.beacons == null)
        {
            awe_estimote.StartScan();
            txt.text += "(X)";
        }
        else
        {
            txt.text += "(" + awe_estimote.beacons.Count + ")";
        }
        txt.text += ":" + GetLoc().ToString();
    }