Search found 18 matches

by cspwcspw
Fri Nov 23, 2018 8:19 am
Forum: ESP-IDF
Topic: (resolved) handling GPIO interrupts
Replies: 18
Views: 40691

Re: handling GPIO interrupts - I can now see why its happening...

The interrupt triggers when the logic level of the GPIO pad changes from 1 to 0 (in the above case). So what would happen if we simply readDigital() on that line, as fast as possible? Well it goes 01010101010 as the source comes through the climbing part of my curve. So the problem is that the sourc...
by cspwcspw
Fri Nov 23, 2018 6:18 am
Forum: ESP-IDF
Topic: (resolved) handling GPIO interrupts
Replies: 18
Views: 40691

Re: handling GPIO interrupts

Hi. Can someone in this forum of expertise explain this ESP32 interrupt behaviour, please? I can work around the problem I have, but I obviously have something misunderstood. [/code] 20181123_070851.jpg I'm counting fairly slow pulses (a flashing LED which I sense with a light-dependent resistor). M...
by cspwcspw
Fri Nov 16, 2018 2:53 pm
Forum: Report Bugs
Topic: SPIFFS file.size() wrong on newly created file
Replies: 0
Views: 4849

SPIFFS file.size() wrong on newly created file

To get the file size one has to open the file and call f.size(). That works. But if opening the file also creates it, the size is wrong. File f = SPIFFS.open("/test.txt", "a"); // this creates the file if it does not exist. Opens for appending data. size_t sz = f.size(); f.size() works if the file a...
by cspwcspw
Tue Oct 02, 2018 3:45 am
Forum: ESP32 Arduino
Topic: Can I write to an INPUT GPIO pin?
Replies: 7
Views: 11047

Re: Can I write to an INPUT GPIO pin?

@ESP_sprite - thanks, was not aware that digitalWrite was Arduino specific.

Is there a preferred way to set individual pins high or low on the ESP32, other than the port-at-a-time w1ts / w1tc manipulation?

Thanks
Peter
by cspwcspw
Sun Sep 30, 2018 4:02 pm
Forum: Showcase
Topic: Yet Another OV7670 Cam to LCD with some differences...
Replies: 2
Views: 7179

Yet Another OV7670 Cam to LCD with some differences...

Hi Release of my latest project: I now send camera pixel data directly from the OV7670 to my LCD screen, so the pixel data bypasses the ESP32, and I don't need to use ESP32 I2S or DMA. The ESP32 has to coordinate everything. My demo is at 25 frames per second at 320x240. And the LCD has a touchscree...
by cspwcspw
Fri Sep 28, 2018 10:16 am
Forum: ESP32 Arduino
Topic: Can I write to an INPUT GPIO pin?
Replies: 7
Views: 11047

Re: Can I write to an INPUT GPIO pin?

@bobtidey - thanks, we live and learn! Makes sense that it works like this.

Peter
by cspwcspw
Fri Sep 28, 2018 10:14 am
Forum: ESP32 Arduino
Topic: Can I write to an INPUT GPIO pin?
Replies: 7
Views: 11047

Re: Can I write to an INPUT GPIO pin?

@ESP_sprite. Hi - I'm not sure why my topic was moved to Arduino forum. Did I miss something about where this should have gone in the first place?

I'm specifically wanting to know what happens on the ESP32 where I am running this code ...

Thanks
Peter
by cspwcspw
Thu Sep 27, 2018 4:58 pm
Forum: ESP32 Arduino
Topic: Can I write to an INPUT GPIO pin?
Replies: 7
Views: 11047

Can I write to an INPUT GPIO pin?

In some touch-screen detection software I found this code: pinMode(_yp, INPUT); pinMode(_ym, INPUT); digitalWrite(_yp, LOW); digitalWrite(_ym, LOW); Does it mean anything to write to a pin configured for INPUT? Is it possible to make a pin OUTPUT while ensuring its initial value. For example, I want...
by cspwcspw
Fri Sep 21, 2018 5:17 pm
Forum: Hardware
Topic: How to undo gpio_matrix_out?
Replies: 1
Views: 4591

How to undo gpio_matrix_out?

There is a nice example at https://github.com/espressif/esp-idf/blob/5401a75badcfc9c20f7818fdf3c683e3da8b2547/components/esp32/spiram_psram.c#L540 that shows how an input GPIO pin can be routed through a pad (with optional inverting of the signal) to another I/O pin. This code sets up such a routing...
by cspwcspw
Fri Sep 21, 2018 4:43 pm
Forum: Sample Code
Topic: OV7670 camera to LCD, 25 fps at 320x240 RGB565
Replies: 3
Views: 9906

Re: OV7670 camera to LCD, 25 fps at 320x240 RGB565

On the OV7670 camera, I think I've partially understood the HSTART and HSTOP registers. In the I2S camera code, (and indeed on a few different solutions working with the camera), the authors typically say frameControl(196, 52, 8, 488); //no clue why horizontal needs such strange values So here is a ...