/1320GroupProject

This is our code of smart watch and home terminal(smart radar)

Primary LanguageC++

1320GroupProject

To make the fan have the ability to detect existence and position of human as well as work on ability-limited board like Arduino, we use a Supersonic and Inferated ray based self-learning radar mechanism to achieve this target. We use the idea of dynamic memory allocation, created two domain restricted arrays to timely save the average distance datas and their system errors in every degree of the detecting sector. Also,we use concept of standard deviation as a reference of error detection.After learning the environment, the detection procedure will work. Once the current distance data sent by supersonic sensor has larger error than the respect system error as well as the inferated ray switch is on it means there is a person standing in front of the fan instead of something else. In this condition the smart fan will execute avoid task to avoid the human in front of the device. This is the sample code of a new branch