Here is how to run hardware diagnostic tests on OnePlus and Oppo handsets using service code. Dialing the service code will enter your OnePlus and Oppo into service mode or engineering mode. In this mode, you can diagnose Wi-Fi problems, back and front camera issues, flashlight issues, check battery charging, Bluetooth, Gyroscope, Proximity sensor, GPS, LCD brightness issue, see usage statistics of your phone, and many more, but with caution. Making unwanted changes are dangerous. If you are an interested person, just dial the code *#808# in the phone app, you can access hardware diagnostic mode or engineering mode on your OnePlus runs OxygenOS and Oppo runs Color OS handsets and then perform a variety of tests.
Run Hardware Diagnostic Tests on OnePlus and Oppo phones
*#801# - Engineering switch test mode *#802# - Enter automatically engineering TTFF GPS test mode *#803# - Enter engineering network test mode *#804# - Automatic disconnect test mode *#805# - Engineering Bluetooth test mode *#806# - Engineering aging test mode *#807# - Enter engineering test mode *#808# - Enter manual engineering test mode *#809# - Enter engineering echo test mode *#888# - View hardware pcb version *#900# - Test photograph RGB Note that you can also create shortcut on the home screen for individual test using Nova Launcher or Action Launcher 3. If you are using any of these launcher, just go to Widgets > Activities > and then scroll down to Engineer Mode. Select required test mode.