Pages: [1]   Go Down
Author Topic: JPEG TTL Camera - Save Image to Device (not SD card)  (Read 2676 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 3
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi folks,

My goal's to have the JPEG camera capture & save an image to a remote device;

- for sandbox purposes, I'd just like to save the image to my computer
[yep, I know I just do this with a webcam. Again, just to get a handle on the code on both ends that would do this as well as eliminate the possibility of other issues in the flow]

- the END goal is to send the captured image over bluetooth to a mobile app to display. Since I'd like to get a handle on the whole process first, I'd *just* like to generalize it to saving the image to the computer.

Right now, I'm using a Duemilanove board with a ATMEGA328P and a BlueSMIRF gold bluetooth module.
I've got the Arduino communicating with my computer through the bluetooth module perfectly right now; able to send commands through the serial terminal and receive a response.


I've been searching all around for an updated example that might point me in the right direction, but I've had no luck so far. I've looked at the Adafruit tutorial for the JPEG TTL Camera module, but I've yet to be able to have the code compile properly. In the Snapshot example code, I remove all of the 'SD' references and attempt to grab the saved binary data from the camera, but I only get compilation errors.

I've also tried Linksprite's example code for the TTL camera they provide (I have both); but it looks as though their code is also out of date. I've changed all of the NewSoftSerial library references to SoftwareSerial, and replaced the mySerial.print(<hex>, BYTE) with mySerial.write(<hex>), but I'm prompted with an 'ambiguous' reference to the write function error. (though I'm not sure which other 'write' function I could be referencing...)


So, my question remains:

Does anyone have an up-to-date example / code sample they can point me to or perhaps advice on how I can accomplish my goal of capturing the image using the JPEG camera and sending it [over bluetooth / serial connection] to a remote device [my computer / mobile device]?

Thanks very much for your time smiley
Logged

SE USA
Offline Offline
Faraday Member
**
Karma: 41
Posts: 3783
@ssh0le
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

so ... where you going to hold this image data until its finished transferring?
Logged


UK
Offline Offline
Shannon Member
****
Karma: 223
Posts: 12630
-
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm prompted with an 'ambiguous' reference to the write function error. (though I'm not sure which other 'write' function I could be referencing...)

The write() function is overloaded to accept different argument types. The error message is probably trying to tell you that the values you're passing do not exactly match any of the overloads and the compiler has not been able to guess which one you are trying to call. Explicitly casting the argument value to one of the types supported by write() should resolve that.
Logged

I only provide help via the forum - please do not contact me for private consultancy.

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 626
Posts: 34183
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I've been searching all around for an updated example that might point me in the right direction, but I've had no luck so far.
Does that not tell you anything?
Either you are on the cutting edge of what an Arduino can do or it is impossible.

Just do some sums and see how long a transfer will take, it might be much longer than you thought.

Quote
I remove all of the 'SD' references and attempt to grab the saved binary data from the camera, but I only get compilation errors.
So that means you are not doing something right. Look at the compiler errors and see where you are going wrong.
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 614
Posts: 49365
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Look at the compiler errors and see where you are going wrong.
Or post the code and the errors, and we'll tell you what you're doing wrong.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 3
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I've been searching all around for an updated example that might point me in the right direction, but I've had no luck so far.
Does that not tell you anything?
Either you are on the cutting edge of what an Arduino can do or it is impossible.

Just do some sums and see how long a transfer will take, it might be much longer than you thought.

Quote
I remove all of the 'SD' references and attempt to grab the saved binary data from the camera, but I only get compilation errors.
So that means you are not doing something right. Look at the compiler errors and see where you are going wrong.

"I've been searching for an updated example..." -- There are examples that show it's possible, and it's certainly not cutting edge. For example:

Grumpy_Mike, although I appreciate any input I can get here, I resorted to posting the question after exhausting resources and research time... NOT before giving it a gentleman's effort. I'd appreciate that if you don't have input beyond non-helpful comments that you just restrain yourself from responding altogether; there are plenty of other threads on this forum that you can give your input on.

Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 614
Posts: 49365
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
"I've been searching for an updated example..."
Updated in what way?
Logged

Offline Offline
Edison Member
*
Karma: 8
Posts: 1341
If you're not living on the Edge, you're taking up too much space!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have done this using a JPG serial camera.  Search the forum for my short code sample.  If you can't find it I will post again here.
Logged

If you fall... I'll be there for you!
-Floor

Skype Brighteyes3333
(262) 696-9619

Offline Offline
Newbie
*
Karma: 0
Posts: 3
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have done this using a JPG serial camera.  Search the forum for my short code sample.  If you can't find it I will post again here.

Is it in here? http://arduino.cc/forum/index.php/topic,118374.0.html

It looks to be the LinkSprite sample code. I'll give this a shot though
Logged

Pages: [1]   Go Up
Jump to: