Skip to content
Rachel (Qiao) Han edited this page Mar 29, 2017 · 3 revisions

Table of Contents

  • Player/game executable file (proper command to start the game with whistle)
  • Lib/Sound, base ground of why sound receiver works in Nao's
  • Player/detect_whistle.lua, the function that runs the actual auto-correlation detection for whistle noises
  • Config/game, where some of the changeable whistle input parameters can be changed according to the different whistles used during the tournaments
  • Others: script that helps with visualizing the sound waves, soundLog.txt that contains the reading from Sound system on the Nao

Player/game

This has been standardized since RoboCup2016. Inside Player/game script, there's a function run_main_whistle that starts the game including a 6th parallel thread that runs whistle detection. This function can be ran by $./game mainw and checks if there's a thread called whistle after the robot is fully started.

Lib/Platform/NaoV4/Sound

This is the basic group work for enabling and disabling sound receiver and transmitter (combined in sound_comm_thread.cc) that integrates everything else together.

Config/Config_NaoV4.lua

Inside game struct, there are some whistle parameters: such as whistle_pitch, whistle_mag

Player/Detect_whistle.lua

  • Autocorrelate
  • Detect_pitch_autocorrelation
  • Check ++ Helper function to make the code look cleaner
  • Check_period ++ Helper function to make the code look cleaner

Notes

  • Sound data is loaded into the core memory of Nao. Improper memory initialization can result in Seg fault in the sound thread and then robot not being able to hear the whistle during the game.
  • Currently most false positive happens when robots speak themselves.
  • Currently we don't use game communication for whistle detection. i.e., the robot only decides for itself whether it hears the whistle or not.
Clone this wiki locally