Announcement

Collapse
No announcement yet.

problem reading last image data package

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • problem reading last image data package

    Hi, I recently bought two uCAM-ttl cameras and i'm having some problems receiving a complete picture from the uCAM-ttl.
    Here's an example of an image transfer that i made with the uCAM-ttl with 115200 baud rate (i followed an example posted in the forum with exception of set package size set to 506 bytes)

    Everything seems normal until the last data package that never is send.

    SYNC [AA 0D 00 00 00 00] ------>
    .
    .
    .
    SYNC [AA 0D 00 00 00 00] ------>





  • #2


    Can't see anything wrong with what you have presented.

    Does the demo software work?

    Could it be that your code has some bug handling the last packet?
    Mark

    Comment


    • #3


      @ Ricardo

      I have the same issue all the jpeg markers are in the image data but it seems to short the eoi end marker, thus the last package gets chopped or never arrives. How did you solve it.
      Planning is half the battle

      Comment


      • #4


        Have you answered/checked my last comments?
        Mark

        Comment


        • #5


          Yes, I did im just out of options

          But most code related stuff is under your nose.... so I will have another hack at it.

          Thx
          Planning is half the battle

          Comment


          • #6


            My error was that i'm was always expecting to receive packages with the same legth.In the last package you will just receive the remain bytes of jpeg picture. The last package length will be different from others (determined in SET PACKAGE SIZE command). So, you have to read data size field to determine the amount of bytes sent from the uCAM-ttl in the last package.

            Comment


            • #7


              Ok but... The last package will never be longer than 64byte (if used as default) so when data is send from the camera. the array will only fill up half way through. But you will still be able to send all the data back to the computer if you cycle through the entire array 0 - 63 byte. Does this make sense ?
              Planning is half the battle

              Comment

              Working...
              X