question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

iOS devices heating up

See original GitHub issue

Description We are using the plugin for scanning barcodes. Usually it is used in warehouses. We noticed that after a couple of minutes the camera and eventually the device itself get heated up and it is very obvious. You can feel it is overheated after five minutes. Although I never experienced it is reported that sometimes it ends up with application crashing.

It is very obvious on iPhone X and iPhone Xr. It is also observable in iPhone SE (2020) devices.

I forked the repo and changed discoverCaptureDevices function only to have builtInWideAngleCamera by changing the line to this: return AVCaptureDevice.DiscoverySession(deviceTypes: [ .builtInWideAngleCamera ], mediaType: .video, position: .unspecified).devices from this: return AVCaptureDevice.DiscoverySession(deviceTypes: [.builtInTripleCamera, .builtInDualCamera, .builtInTelephotoCamera, .builtInTrueDepthCamera, .builtInUltraWideCamera, .builtInDualWideCamera, .builtInWideAngleCamera], mediaType: .video, position: .unspecified).devices

I thought opening triple camera for simple barcode reading may be unnecessary and that is the reason why device was heating up. But it didn’t help.

Our app is a replacement of an old NativeScript app and that app doesn’t have this problem on barcode scanning. I tried some other Cordova/Phonegap plugins. Most of them has this issue except one. We are in no position of switching plugins right now. I wonder if there are any solutions to fix this issue or if I misconfigured something.

Steps to reproduce

  1. Open the camera
  2. Leave the device for 5 minutes
  3. Check the camera with your hand. Observe it is heated up
  4. Leave for another 10 minutes
  5. Check the whole device is heated up.

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
thegnuucommented, Sep 30, 2022

It should yes, you can just add the branch to your package.json and change the calls according to the interfaces (there is no more single-scan function) just a start, pause, resume and stop.

https://github.com/capacitor-community/barcode-scanner/blob/ml-kit/src/definitions.ts

It is not finished, for example checking the permissions aso. is missing, but it should work in general for this testing purpose.

0reactions
thegnuucommented, Nov 24, 2022

I was now able to merge the android version into the branch, this is a big step for the ml-kit version.

I still needs cleanup and my time is kinda limited at the moment unfortunately, but I will do my best to make progress as fast as possible.

Read more comments on GitHub >

github_iconTop Results From Across the Web

If your iPhone, iPad, or iPod touch gets too hot or too cold
iOS and iPadOS devices have built-in protections to prevent overheating. If the interior temperature of your device exceeds the normal operating ...
Read more >
How to Stop Your iPhone From Overheating - Business Insider
How to stop your iPhone overheating · 1. Close all apps · 2. Restart your iPhone · 3. Switch to an official Apple...
Read more >
How to fix iPhone overheating issue - Setapp
Aside from the previously mentioned reasons, your phone may overheat due to faulty hardware components. And the battery may be the main cause....
Read more >
iPhone or iPad Getting Hot? Learn Why and How to Fix It
Sometimes, a bad network connection can heat up your device while it's searching for signal. It can happen in areas with poor network...
Read more >
5 ways to fix iPhone overheating Why does my iPhone get hot ...
Your phone could heat up if you have too many apps active and running in the background simultaneously. It can even heat up...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found