TTGO-Camera Plus

Hi! With some help from the community I finally got my TTGO-Camera Plus working stable. I haven’t got the screen to work just yet but for anyone having trouble with it here is my setup! Hope it helps.

esphome:
  name: ttgo
  platform: ESP32
  board: esp-wrover-kit

wifi:
  ssid: "Cool ssid"
  password: "Secret password"
  manual_ip:
    static_ip: "optional"
    gateway: "optional"
    subnet: "optional"
  fast_connect: true
# Enable logging
logger:

# Enable Home Assistant API
api:
  password: "Still secret"

ota:
  password: "still secret"

esp32_camera:
  name: TTGoCam
  external_clock:
    pin: GPIO4
    frequency: 20MHz
  i2c_pins:
    sda: GPIO18
    scl: GPIO23
  data_pins: [GPIO34, GPIO13, GPIO26, GPIO35, GPIO39, GPIO38, GPIO37, GPIO36]
  vsync_pin: GPIO5
  href_pin: GPIO27
  pixel_clock_pin: GPIO25
  resolution: 640x480
  jpeg_quality: 12
  vertical_flip: false
  horizontal_mirror: true
  idle_framerate: 0.1fps
  max_framerate: 5fps
  
spi:
  clk_pin: GPIO21
  mosi_pin: GPIO19
  miso_pin: GPIO22
  id: SDCard

output:
  - platform: gpio
    pin: GPIO0
    id: CS_GPIO0
  - platform: gpio
    pin: GPIO12
    id: CS_GPIO12
  - platform: gpio
    pin: GPIO2
    id: CS_GPIO2
  - platform: gpio
    pin: GPIO15
    id: DC_GPIO15
    
binary_sensor:
  - platform: gpio
    pin: GPIO14
    id: GPIO14
  - platform: gpio
    pin: GPIO32
    id: GPIO32
  - platform: gpio
    pin: GPIO33
    id: GPIO33

switch:
  - platform: restart
    name: "TTGoCam Restart"
    id: restart1
2 Likes

HI,

What was the trick to make it stable?
I mean was it reducing idle frame rate o resolution?

I have a bunch of them and the only way I found was to set an automation (inside the camera firmware) to reboot every 30mins

It was defining all the pins. I rarely have to reboot it now. And also if I add to much like wifi signal and so on it’s like it has to send to much information witch it can’t handle. But the defining of pins help alot with stability!

It should be added that I don’t have the BME sensor on mine.

What do you mean by assigning all the pins?

Oh sorry, in the yaml file in esphome for the camera I added the lines obove. It seems that the ttgo plus is not fully supported and that you manually in the esphome yaml file for the camera need to add extra clarification.

Damn, this config doesn’t help me either.
I’m getting this freaking error:

[09:57:06][E][esp32_camera:091]:   Setup Failed: ERROR

Do you have the bme sensor on your camera?

Mmm your answer do not completely satisfy me :slight_smile:

You have to set all the pins for the camera obviously, but all the rest you set up for “output” or binaries I can’t see how they could be related to camera stability.

Actually you are using more memory and increasing footprint of your firmware hence I would tend to think the opposite :thinking:

It must be said I am just a basic user hence I could be completely wrong.

Where did you read TTGO is not fully supported?

I’m only a basic user too but from what I understand the regular ttgo has library’s in esphome with sketches that tell esphome what pin goes where. The ttgo plus seems not to have that. So the output and binary sensor is me telling esphome where the pins go. Before I did that the camera would only give me an authentication denied error when trying to stream and now it does not. It is still a bit unstable with having to restart it once in a while but it gives a working stream.

So the stability is only telling esphome where everything goes. It is the pins to the screen and SD-card slot. If you have a better way I would love to hear about it!

But I was thinking the same as you at first. I removed all the WiFi signal and connected status and so on to but as little pressure on it as possible but with no luck. So this tip I got from someone here in the community :slight_smile:

No I don’t have a temp sensor. It has just the reset button. It looks exactly like this one

Send me your config from esphome so I can check it :slight_smile: it might be some typo or that the data pins are in the wrong order.

I have the exact same ttgo camera plus board that @joem has and using the yaml given by @alexander.heikkila I got my board to work fine and quickly! The stream is a little slow, but I think that is just a limitation of the board!

Did anyone ever get the screen or mic on the TTGO Camera Plus to work?

Hello! i was wondering if you made any progress regarding the screen, as i can’t manage to make it work. Thank you for sharing your setup! It really helped me a lot

Nah, mine never really worked stable in the end so I didn’t keep working on it :stuck_out_tongue:

I did not unfortunately :confused:

Added this from TTGO-T-Display corrected CS & DC pins (Screens works at T-Display res but camera stops working) also tried Adafruit lib for st7735 and got a full screen display but no colour control, again camera stopped working.


  - id: my_red
    red: 100%
    green: 0%
    blue: 0%
  - id: my_yellow
    red: 100%
    green: 100%
    blue: 0%
  - id: my_green
    red: 0%
    green: 100%
    blue: 0%
  - id: my_blue
    red: 0%
    green: 0%
    blue: 100%
  - id: my_gray
    red: 50%
    green: 50%
    blue: 50%

font:
  - file: "Helvetica.ttf"
    id: helvetica_48
    size: 48
  - file: "Helvetica.ttf"
    id: helvetica_24
    size: 24
  - file: "Helvetica.ttf"
    id: helvetica_S
    size: 14
# put a ttf font called Helvetica.ttf in the esphome folder

display:
  - platform: st7789v
    backlight_pin: GPIO2
    cs_pin: GPIO12
    dc_pin: GPIO15
    reset_pin: GPIO23
    rotation: 0
    lambda: |-'''

Dear Joem, is it worling today as i’ve the same ttgo
regards

I got basically everything working on this board hope it helps someone.

1 Like