No announcement yet.

uCAM-TTL with uLCD-43PCT

  • Filter
  • Time
  • Show
Clear All
new posts

  • uCAM-TTL with uLCD-43PCT

    Hi I have problem communicating my uLCD43-PCT with the uCAM-TTL camera module. I have used the camera demo program and my camera works fine.

    However, when I connected the uLCD43 to the uCAM-TTL with the following connection,
    uLCD43_Pin 20 - uCAM_VCC
    uLCD43_Pin 11 - uCAM_GND
    uLCD43_Pin 30 - uCAM_TX
    uLCD43_Pin 28 - uCAM_RX

    and try to write a simple code to sync with the camera, the data received is -1 all the time.

    I have tried to connect the uLCD43_Pin 12 to the uCAM_VCC, but the data received is still -1

    The code is as follow,
    com_SetBaud(COM1, 11520 );
    stat := com_SetBaud(COM1, 11520);
    if (stat)
    putstr("COM1 set to 115200 BAUD\n");
    pause (500);

    for (n:=0; n<6; n++)
    print ("The data sent is ", sBuf[n], "\n");

    // pause (30);

    for (n:=0; n<6; n++)
    print ("Data received is ", s, "\n");


    I connected the COM1_TX and COM1_RX together and my uLCD43 can receive whatever it sends out. Previously my uLCD43 can talk with my PIC MCU with no problem as well.

    I have also swap the COM1 to COM0 but still no data received from the camera, which is -1.

    Can I know whether there is something wrong?

  • #2

    All seems fine from what you have shown...

    What's in sBuf?


    • #3

      Duh, Don't think serin1 works the way you are expecting it to


      • #4

        Hi the sBuf is

        byte sBuf 0xAA, 0x0D, 0x00, 0x00, 0x00, 0x00

        EEemm, can you give some hints on the serin1

        I have tried to use the

        com1_Init (buf, 6, 0);
        until (com1_Full()); // or until (com1_Count() == 6);

        but still never receive any data from the camera


        • #5

          Serin1() .... Returns: -1 if no character is available

          So you need to 'loop' until you get a +ve value....

          Or maybe check com1_Count....

          But also remember that you may need to send the 'Sync' several times.

          Have you looked at the uCam demo in Anna's Sandbox? It's was written for 'old Goldelox' but it still might help you a bit


          • #6


            Yes, I have read through the Anna's sandbox code for uCAM several times and most my code are also based on the demo code as well.

            But now I am stick in the 1st phase where the camera won't talk to my uLCD43 at all (in terms of synchronization). So I just wrote the basic code to try to sync with the camera.

            I have also followed the uCAM data sheet and sync for more than 25 times before trying to poll the data from the uCAM TX pins, but all I get is still -1. Then I just add 60, 100, 200, 500 times of keep sending the sync data to the camera, before trying to poll for the ACK data from the camera.

            I also follow some of the topics that having a small pause after sending the sync data, before trying to poll the data from the TX pin, but still -1. I have tried many time delay, like 1ms, 5ms, 10ms, 30ms, 50ms, 100ms etc.

            Then I just repeated the code forever, and waited for almost an hour but I still cannot get any data from the camera at all. I have tried the camera with the demo program and it just works fine.

            I have also tried to use the com1_Count() and com1_Full() together with the com1_Init(), but there is also no data received from the camera as well.

            Thank you for helping me to solve the problem coz the camera is driving me crazy now as I tried to talk to it for a few days now.


            • #7

              Besides, I have also tried different baud rate in the code, where the uCAM can detect automatically like 14400, 57600 but it still won't talk to me.

              I suspect whether there is any voltage level problem since the max voltage output for uCAM_TTL TX pin is 2.4V from the datasheet, whereas the input voltage for uLCD43 RX pin is 0.8VCC. So I connect the 5.0V VCC pin from uLCD43 to the uCAM VCC but still didn't receive any data.

              I tried to measure the output voltage from uCAM_TX pin and it's around 3V. Too bad I don't have an analyzer to plug into the TX and RX pins to check whether there are any communication between the uLCD43 and uCAM_TTL.


              • #8

                Yes, I used the multimeter to check before and the input into the camera is 3.3V when it's connected to the uLCD43_Pin20 which supply an output voltage of 3.3V.


                • #9

                  Without an analyzer you could always connect the RX of the cable to both TX and RX (separately) and monitor it using the terminal program


                  • #10

                    I have used the Terminal 115200 from the 4D system to check, and I saw there is output from the TX pin of the uLCD but I never receive any input data from the camera into the uLCD RX pin at all


                    • #11

                      Have you tried it at 57600? (or maybe the uCam Demo program at 115200)


                      • #12

                        Yes, I have tried a few baud rate 11400, 57600 and 115200.

                        The uCAM demo program works just fine, it can sync, initialize and take picture at different baud rate 11400, 56000, 57600 and 115200. I can get picture in either JPEG and raw types, with different resolution as well.

                        Just that now I tried to connect to the uLCD43, it will not send out any data.


                        • #13

                          Hi, do I need a level shifter between uCAM_TTL TX Pin and uLCD43 RX pin ? Or can you guys confirm whether uLCD43 can communicate with uCAM_TTL with no problem?


                          • #14

                            No level shifting is required.

                            Whilst we have not tried the uLCD43 several other Picaso series displays have been used in the past.

                            I'm hoping to get the time to try it myself tomorrow


                            • #15

                              After changing some connectors and breadboard, they are talking to each others flawlessly

                              Silly me, thanks for the support !!!!!!