ultrasonic dog bark

Hello, please help me. I love my dog ​​a lot. Sometimes he barks his neighbors complaint.

At the time I had to buy a mini arduino it is possible to program to send a signal when it barks?

If it is possible what is the code to put? I have to feed with how much volt? And I have to use what as another component?

Thank you for your help..

If you love your dog, you should put in the time and effort to train it not to bark.
Or at least buy a ready-made bark collar.

Playing a sound when it barks isn't going to train it not to bark. That's not how dog brains work.

I understand you. I do not want to use an anti-bark electrical collar. We can do it nicely with a sound ultrasonic ?

Search this forum, I believe this has been talked about before.

.

A sound will do nothing. There is nothing magical about ultrasonic sounds.If a bell rang every time your dog barked, would you expect it to stop barking for some reason? Sound alone is not a deterrent.