@m5mpy microcode is very low level, I like how these MCU bring back old memories and old hacks like I used to do on Amiga. And how in general they force into better programming habits.
So what I'm trying to do is general purpose signal camera. At the moment, a sound camera will do. From what I was told on eevblog, I need one FFT per microphone to calculate inter-mic delay. So far Arduino FFT switched to uint32 (faster on esp32 than uin8 I'm told) I'm getting 512 bins at 12 ms, which is't very zippy as I'll need 4 cameras at least. Not that big a deal because I don't need 60fps refresh but ... well, that would be nice :D
As for the frequency, at the moment I'm interested in detecting the origin of low frequency sound as they're notoriously difficult to locate by ear. Eventually I'd like to expand into an EMF camera.
Concise code for sure. I need all the speed I can get so it'll be Arduino for now.
I'm surprised you wouldn't see any flicker on the display since you print every frame, also surprised that there is no clearScreen preceding the print. I'm thinking the python print has a background.
Sorry I didn't get a chance to look into that further - was busy with github stuff etc. Glad you found the problem. These things can be very particular !!
Also glad the link was useful....... the SAM menu is fantastic.... with the included I2C scanner and other features.
There are also two other excellent menu systems... You can easily add your own apps to the "M5Stack-SD-Updater" menu (more are being added over time) and the other "M5Stack_MultiApp _Firmware" has a number of useful tools included.... including I2C scanner, voltmeter, etc.....
@jimit Many thanks for the reply, it is sad as it was the example I wished to include in my M5Stack YouTube review. Glad you liked it anyway! For those who are interested the video is here: M5Stack Review
Here is a little report on my progression. In short : it still doesn't work!
I checked that the pin "works" correctly by connecting a relay to test in OUTPUT mode, and a push button (to test in INPUT) : it works!
I checked, double checked and triple checked the setup (wires, connections,...), everything is good.
I ran the same code on a Wemos D1 Mini (ESP8266) : it works.
At this point, I'm lost? The pin and the code seem good, but it can't detect the sensor.
One thing I notice is that this weird whistling sound coming out of the board (not sure if it comes from the speaker or not) when the OneWire lib bitbangs the OneWire protocol on the pin.
So, I made another test program that toggles the pin rapidely (at the speed of the onewire lib - ~50µs) : I hear the sound!
I'll try to find an oscilloscope to check the signal on the pin, as I suspect that "something" is going wrong when the pin is driven at "high" speed.
In the meantime, I hope that someone with more electronical knowledge will help me find a solution!