Dyson has put a camera inside a toothbrush. The CameraJet went on sale Tuesday for $499, combining a 100,000-pixel macro camera in the brush head with a small jet that sprays mouthrinse between the teeth. The company says it has spent six years developing the product.

The camera is there mainly to help the toothbrush figure out where to aim, rather than simply to give users a close-up view of their teeth.

It captures 28 images a second and uses them to identify gaps between teeth within 100 milliseconds, directing the jet towards the areas it detects.

Behind that system are 16 million lines of code and 470,000 dental images used to train the software. Dyson calls the technology Gap Optical Targeting, and it is the main reason the company believes the CameraJet can command a $499 price tag.

“Flossing is an awkward and time-consuming chore,” said James Dyson, the company’s founder and chief engineer.