No announcement yet.

SANDBOX-0001 uCAM with uOLED

  • Filter
  • Time
  • Show
Clear All
new posts

  • SANDBOX-0001 uCAM with uOLED

    ID: SANDBOX-0001
    STATUS: 90% complete

    uCAM demo with uOLED-xxx-G1(GFX)

    This project integrates the 4D TTL camera functionality onto the uOLED-xxx-G1(GFX) series, configured with the GFX2 PmmC and loaded with the attached .4dg file. Apart from as a normal camera, it has various uses, such as a video intercom, a baby monitor, or as part of a security system. You can see it in action in the following link:

    The hardware required are:
    4D uCAM TTL ( uOLED-xxx-G1(GFX) (e.g. uOLED-160-G1(GFX) DEVBOARD-G1 (

    Circuit diagram software:
    PEBBLE schematic program ( circuit diagram code (attached)

    The PEBBLE circuit diagram shows one way to connect the uCAM with the uOLED via the DEVBOARD. Copy & paste the contents of the attached *circuit.txt file into the dialog box that appears when you press Save/Load on the PEBBLE website.

    Software Tools:
    PmmC Program Loader Tool ( Workshop2 IDE (

    Device configuration PmmC file:
    GOLDELOX-GFX2 PmmC (device dependant):
    uOLED-96-G1(GFX) or uOLED-128-G1(GFX) oruOLED-160-G1(GFX)

    uCAM .4dg file (attached)

    This demo shows how to communicate between a uOLED display and the uCAM. The 4DGL code attached includes the following functionality:
    A text-based menu system on the uOLED, displaying the various initialisation parameters for the uCAMThe uOLED initalising communication with the uCAMThe uOLED blitting the received picture information from the uCAM directly onto the screen

    Suggested hardware extensions
    Connect the uCAM directly to the uOLEDWireless connection between the uCAM and the uOLED
    Suggested software extensions
    The following extensions will complete the demo (i.e. change the 90% status to 100% complete)
    Show the appropriate menu option according to the uOLED display it's loaded onAllow the user to go back to the menu system by pressing FIRE on the joystickMake the uOLED save pictures onto the uSD card (requires a uSD card hardware)

    That's all for now!


    Attached files (7.2 KB)

  • #2

    Thanks Anna. With the pebble wiring diagram and your working code, I think even I could get the uCAM working. At the very least, I would know that the camera was working as advertised. That's not always an easy thing to do with a piece of gear that you've never used before.

    Thanks for the peek into your sandbox and I look forward to what's next.

    Any technology, sufficiently developed, is indistinguishable from magic. A.C. Clark(RIP)

    NEW! Lower prices on all 4D Systems products for 2009 and continuing into 2010!


    • #3

      Bought all the parts, tried putting it together, and nothing is working. Maybe this was a bit advanced for a first project with no experience. So is there some "hello world" "getting started" application that I could work with to see where I'm going wrong to get this to work?


      • #4

        Well you could describe a bit more how you came to say " nothing is working". I would hope you would at least be seeing a splash screen of some kind.

        Click on File, Open Samples in Workshop and have a look at some of the 'Goldelox GFX2' (tests) samples.


        • #5


          The first issue is the 4D DEVBOARD-G1. WHen I have the uOLED-160-G1(GFX) on the 4D DEVBOARD-G1 and hooked up to my computer with either the uUSB MB5 or the uUSB CE5 I can not gey either the PmmC Program Loader or the 4DGL Workshop2 IDE to detect the uOLED-160-G1(GFX). If I put the uOLED-160-G1(GFX) directly on either the uUSB MB5 or the uUSB CE5 I can get the PmmC Program Loader and the 4DGL Workshop2 IDE to detect the uOLED-160-G1(GFX). So I hooked the uOLED-160-G1(GFX) to the uUSB CE5 and then loaded both the uOLED-160-G1GFX-R21.pmmc and the code in your zip file onto the uOLED-160-G1(GFX), then tried plugging it back into the 4D DEVBOARD-G1 and then using the uUSB, trying to get it to run. And it does nothing, except the power light on the 4D DEVBOARD-G1 does come on. I'm wondering if I have the jumpers on the 4D DEVBOARD-G1 set wrong or if I could have burnt something out or what. I sort of wish I knew how to get the uOLED-160-G1(GFX) back to it's original configuration or if there is a way to go a function check on it, and if there is a way to do a function check on the 4D uCAM TTL and the 4D DEVBOARD-G1. Right now I'm not getting anything other than the power light on the 4D DEVBOARD-G1. I could take the uOLED-160-G1(GFX) off of the development board and re-connect it to a uUSB and see if I can get the PmmC loader or the 4DGL Workshop2 IDE to connect with it but then what? So if you have a way to take the uOLED-160-G1(GFX) back to its original configuration and to do a function check on it and the 4D uCAM TTL and the 4D DEVBOARD-G1, please let me know. Or if you can walk me through by the number to get the camera demo from this thread to work...Any suggestions to get me moving in some direction would be appreciated.


          • #6

            To get the uOLED-160-G1, which seems fine, back to its original condition, all you need to do is reload the PmmC, which you appear to have worked out. One you have loaded a program, which you also appear to have worked out, you can load another program in the same way, there is no need to reload the PmmC.

            So the issue appears to be with the Devboard, which isn't completely dead, because the power light is coming on. Strip it back to 'as supplied' install the RX and TX Jumpers as per the manual, connect the CE5, plug in the uOLED-160G1 and switch on so the LED is on. You should see the splash on the OLED (assuming there hasn't been a program loaded since the flash was written). If you don't, it looks like there is some sort of wiring error on the devboard, which seems weird.

            By installing the RX and TX Jumpers you should also be able to program the OLED from Workshop.


            • #7

              OK I reloaded the uOLED-160-G1GFX-R21.pmmc without problem but the screen is black: no splash. I also placed the uOLED-160-G1(GFX) on the 4D DEVBOARD-G1 and this time the 4DGL Workshop2 IDE recognized the uOLED-160-G1(GFX) and I was able to load the program but the screen is still completely dark.


              • #8

                Is there some way to do a function check on the uOLED-160-G1(GFX)?

                Well anyway I bought a uOLED-160-G1(GFX) on an Arduino shield at the same time that I bought the uOLED-160-G1(GFX) and the 4D DEVBOARD-G1. Is there some downloadable program that I could run so I could try to get the camera to work with the 4D DEVBOARD-G1 on the Arduino Shield?


                • #9

                  One question I have is that when I recieved the uOLED-160-G1(GFX) it had a jumper on it but I took the jumper off so I could put the uOLED-160-G1(GFX) on the 4D DEVBOARD-G1, do you know what the leads the jumber was on, should I have replaced the jumper before I took the uOLED-160-G1(GFX) off the 4D DEVBOARD-G1 to load the uOLED-160-G1GFX-R21.pmmc?


                  • #10

                    Anyway, I found out what the problem was when I was originally trying to program the uOLED-160-G1(GFX) on the 4D DEVBOARD-G1...I had the camera plugged into the Rx and Tx on the 4D DEVBOARD-G1 next to the breadboard.

                    OK so I'm a novice, but this is all about learning and that is why I got the uOLED-160-G1(GFX)...Anyway, now the problem is to get some life back into the uOLED-160-G1(GFX).


                    • #11

                      Oleds tend to look 'off' when they are not displaying anything.

                      The GFX splash only displays for a few seconds after power up and then blanks out.

                      Apply power to the display whilst watching the top left corner closely for 5 seconds and see if anything appears and then disappears


                      • #12

                        still no response from the display on that unit. I'm going to test to see if the unit is bad. I think that there is a test for the SGC configuration with the "FAT Controller". If I can get it to run with the SGC configuration then I can test it with the FAT controller, and if that does not work then maybe the unit is bad.


                        • #13

                          By all means try the SGC PmmC, its spash is much more in your face. The spash should be enough to tell, no splash, no go.


                          • #14

                            Good news, the uOLED-160-G1(GFX) is still alive

                            Now to get it to load the program

                            When I compile the program from the zip file I get

                            for line 554, "err :- take_pic();" "Error: Statement has no effect"

                            I was worried that I had somehow damaged the uOLED-160-G1(GFX) but I got it to display the splash


                            • #15

                              The program was written for GFX and used an earlier version of the compiler that did not report as many errors as the latest compiler.

                              So you need to change the platform to 'Goldelox-GFX2' and then fix the syntax errors