FlashLight that uses Camera Flash

Discussion in 'Android Devices' started by lobe50, Nov 7, 2009.

  1. Spirix

    Spirix Member
    5

    Nov 8, 2009
    8
    0
    5
    Looking forward to this app. Let us know when one has been developed!
     

    Advertisement

  2. Gilgamesh11

    Gilgamesh11 Member
    16

    Nov 12, 2009
    17
    3
    16
    I do not have a droid so I cannot test, but I have been reading around and people want the camera flash thing to light up to use as a flashlight so this might work. I just found this app today.

    DroidLight v1.0 Application for Android | Tools

    I am not sure if this has been posted so if it has please delete. Just trying to help! :)
     
  3. CRPercodani

    CRPercodani OFWGKTA
    VIP Member
    213

    Oct 24, 2009
    2,940
    564
    213
    Real Estate Agent
    M A dub'l dolla sign
    It was in a previous thread but it seems to have found its way to the back of the bunch so I will leave this up so people can learn about the app because with the droid camera sucking so much right now (focus wise) atleast we can have some good use for that insane dual LED.
     
  4. BLOWNCO

    BLOWNCO Well-Known Member
    38

    Nov 7, 2009
    129
    22
    38
    citrus heights
    so where the app at?
     
  5. Fronc

    Fronc Well-Known Member
    15

    Nov 6, 2009
    47
    0
    15
    J.D./M.B.A. Candidate, Seton Hall Law
    Newark, NJ
    Hey guys, just an idea, but perhaps we can collaborate? Care to share your code, and then we can put it on the market as a joint venture? It'll be OUR project.

    Just an idea. And we can use google wave somehow to work on it? I'm new to wave, but it looks like it has potential.
     
  6. link1305

    link1305 Active Member
    16

    Nov 9, 2009
    41
    3
    16
    Software Developer
    From what 1033 said, it seems like the Droid does not currently support the necessary flash mode (so called "torch") for this to be possible.
     
  7. Fronc

    Fronc Well-Known Member
    15

    Nov 6, 2009
    47
    0
    15
    J.D./M.B.A. Candidate, Seton Hall Law
    Newark, NJ
    Actually, I believe he meant the exact opposite conclusion. The API supports it. Its an implementation thing we have to work out, and if we shared the code it might be much easier to do. I have a feeling I'm pretty close with a barebones app, but I am still learning the syntax. Luckily, it seems to be modeled right after Java.

    I'm certain I can get the app working, I just need a little guidance.
     
  8. link1305

    link1305 Active Member
    16

    Nov 9, 2009
    41
    3
    16
    Software Developer
    I agree that the API supports it, but that doesn't necessarily mean the Droid hardware/drivers support it. I think the whole point of calling getSupportedFlashModes() is to identify which modes the current hardware supports.

    Anyway, has anyone gotten a chance to try it on the hardware? I didn't have time last night...
     
  9. eclipsed4utoo

    eclipsed4utoo Well-Known Member
    43

    Nov 12, 2009
    435
    27
    43
    Software Developer
    Florence, SC
    I am trying it right now. I can get access to the camera (I hear the 3 clicks just like when you open the camera), but can't get the flash to turn on.

    This is the code I am trying...

    Code (Text):
    1.  
    2. camera = Camera.open();
    3.  parameters = camera.getParameters();
    4.  List<String> list = parameters.getSupportedFlashModes();
    5.  
    6.  if (list != null)
    7.  {
    8.      /*for(int i = 0; i < list.size(); i++)
    9.      {
    10.          Toast.makeText(context, list.get(i), Toast.LENGTH_LONG).show();                     
    11.      }*/
    12.      
    13.      parameters.setFlashMode(Camera.Parameters.FLASH_MODE_ON);
    14.      camera.setParameters(parameters);
    15.      camera.startPreview();
    16.      Toast.makeText(context, "LED IS ON", Toast.LENGTH_SHORT).show();
    17.  }
    18.  
    I just added the startPreview() to see if it helped, but it didn't.
     
  10. eclipsed4utoo

    eclipsed4utoo Well-Known Member
    43

    Nov 12, 2009
    435
    27
    43
    Software Developer
    Florence, SC
  11. MarshyTheKid

    MarshyTheKid New Member
    5

    Nov 13, 2009
    3
    0
    5
    Nice, I was looking for an app like this. Hopefully the kinks get worked out so it will work.
     
  12. Droidood

    Droidood Well-Known Member
    46

    Nov 3, 2009
    180
    1
    46
    Looks like Motorola still hasn't responded... :(
     
  13. Spirix

    Spirix Member
    5

    Nov 8, 2009
    8
    0
    5
    Any news on when we ill be able to use the LED flash on the droid as a flashlight?
     
  14. galt

    galt Well-Known Member
    36

    Oct 26, 2009
    153
    2
    36
    Florida, USA
    Won't this kill the battery in like 20 minutes? or less ?
     
  15. Silverwing

    Silverwing Well-Known Member
    15

    Nov 15, 2009
    77
    0
    15
    I don't know about those LEDs, but LEDs in general are pretty power efficient. I guess, if they are not cranked up all the way.
     
  16. johnlgalt

    johnlgalt Antidisestablishmentarian
    VIP Member
    333

    Oct 28, 2009
    9,416
    1,922
    333
    Male
    Graduate Research Assitant | That part time IT guy
    3rd Rock
    Yeah, I doubt using the HILEDs will kill the battery that fast - but it will surely take a toll on overall battery life every time it is enabled.
     
  17. sohc sti

    sohc sti Well-Known Member
    36

    Nov 6, 2009
    154
    3
    36
    Subscribed. Id definatly pay for it. It was a pretty handy feature on my storm.
     
  18. eclipsed4utoo

    eclipsed4utoo Well-Known Member
    43

    Nov 12, 2009
    435
    27
    43
    Software Developer
    Florence, SC
    Doubt it, but nobody really knows until it's done.
     
  19. virtus

    virtus Well-Known Member
    38

    Doubt it... but who would have their LED's on for that long? I had an app on my old WM phone that turned the LED on - it would automatically turn it off after 120 seconds.
     
  20. Maverick9110E

    Maverick9110E New Member
    5

    Nov 17, 2009
    2
    0
    5
    BMC Performance Rep
    northern NJ
    Hope this app comes to market!! That screen LCD light is crap, but we have a DUAL led flash, it would be awesome to get that baby cranking as a flashlight! Wish i could help figure out the code but i'd be useless!! lol. Good luck gang!
     
  21. hdsixhundred

    hdsixhundred Well-Known Member
    18

    Nov 11, 2009
    58
    13
    18
    Eau Claire, WI
    I had the exact same program on my WinMo phone. Good stuff.
     
  22. drpull

    drpull Member
    15

    Nov 17, 2009
    24
    0
    15
    Apparently there was a silent update to the camera app... or camera hardware drivers... over the last couple of days. Perhaps the torch flash mode has been enabled as a consequence? Bears looking into.
     
  23. eclipsed4utoo

    eclipsed4utoo Well-Known Member
    43

    Nov 12, 2009
    435
    27
    43
    Software Developer
    Florence, SC
    I was thinking the same thing. I will be trying this out in a little while. Left my USB cable at home. running home for lunch to pick it up.
     
  24. eclipsed4utoo

    eclipsed4utoo Well-Known Member
    43

    Nov 12, 2009
    435
    27
    43
    Software Developer
    Florence, SC
    Just tested it. Still the same three modes available(On, Off, Auto).
     
  25. drpull

    drpull Member
    15

    Nov 17, 2009
    24
    0
    15
    When its on Auto, it fires the flash for a few seconds in dark situations while it auto-focuses. I'm wondering if there's some way to leverage that. Is there an event that fires when auto focus is complete? is there a way to force it to keep retrying? Just some thoughts... though that would probably burn through the battery quickly while you're forcing the camera to keep retrying.
     

Share This Page

Loading...