Good to hear the new cable worked out for you. Yeah..., tight!!! Just don't trip over it. You're gonna fall before that cable lets go. Also good to know CNC Tech has not lost the magic.
Had a quick look at the schematic for the OLED, and I don't think you should be powering it by 5v at VIN. The i2c lines are connected to VIN via a resistor, and I'm pretty sure the Teensy won't like that. That OLED can be powered by 3.3v (at VIN)...
Hello,
I notice some pretty bad distortion from audio shield headphone output, when setting the volume at low level.
Please compare this to sketches and tell me if you notice the difference.
sketch 1 => distortion
#include <Audio.h>
#include...
What I believe he was suggesting, is to try out using the Adafruit SSD1306 driver, which even if that is not the driver you wish to use
it will help isolate the issues.
Looks like the display is setup to be 3.3v compatible.
Might help if you...
Defragster, I am not sure I understand your comment 'this isn't the driver seen in use'. Sorry, limited background on this on my end. Is there more to the demo code I can use to trouble shoot? I have had success using the 128x32 OLED screen with...
Thank you all for your responses! Submo and Defragster, I will try out your suggests ASAP! Submo, the SW vs. HW was not intended (I was literally going down the line of options in the example code). Will double back and try HW as well. I have...
I made two new timer setup functions with different divider settings. One that works down to 10Hz and one that is more accurate at higher frequencies that I will use later in my program as I will be using 40kHz. Seems to work. Maybe someone finds...
Normally you can't get exactly 20 MHz because the timers run at 150 MHz and they can only create waveforms that are an integer division of 150 MHz. And to get exactly 50% duty cycle, that integer must be an even number, because you need the same...
How can I generate a 20MHz clock wave (50% duty cycle) with PWM using Teensy 4.1. I don't understand at all the Pulse Width Modulation page.
Thank you.
I had set the divide in the timer incorrectly. I can get down to 18Hz with the highest divider.
Here is the output now which seems more appropriate considering the frequency is set to 20Hz.
Values:
2255, 2246, 2020, 2240, 2243, 2021, 2236...
If I disable the timer the ISR is not triggered again and neither are the ADC's (keep printing the same value). I guess it's the timer. I have to look into setting the timer properly. I had chatGPT do it for me, probably why it's not working...
Well you know how to disable the timer:
TMR4_ENBL &= ~(1 << 0); // Disable Timer
So if you do that in the ADC_ETC IRQ handler, does it retrigger?
If it doesn't: you know the IRQ is being cleared correctly, it's just recurring constantly because...
Well you know how to disable the timer:
TMR4_ENBL &= ~(1 << 0); // Disable Timer
So if you do that in the ADC_ETC IRQ handler, does it retrigger?
If it doesn't: you know the IRQ is being cleared correctly, it's just recurring constantly because...
Hmmm... I could trigger the ADC_ETC from software. However I'd have to spend several days to figure out how to do that. I have never done this stuff and just getting this far took 3 weeks.
I have this:
// Debug output to verify timer setup
Serial.printf("Timer started with calculated period: %lu ticks\n", (uint32_t)(F_BUS_ACTUAL / (frequency * 2)));
Serial.flush();
It prints: Timer started with calculated period...
I would start by checking how frequently the timer is triggering.
The quad timers only have 16-bit comparison registers, you're probably going to need to chain two of them together for low frequencies.
(Optionally, connect the xbar to an IO pin...
I would start by checking how frequently the timer is triggering.
The quad timers only have 16-bit comparison registers, you're probably going to need to chain two of them together for low frequencies.
(Optionally, connect the xbar to an IO pin...
If I write this in the ISR function:
IMXRT_ADC_ETC.TRIG[0].CTRL = ADC_ETC_DONE0_1_IRQ_TRIG_DONE0(0);
Then it only interrupts once as it should but then it never interrupts again. This was a mistake but it stops it.
Thanks, I guess that they mean:
f16: float 16 bits
f32: float 32 bits
f64: float 64 bits
q31: signed int 64 bits ?
q15: signed int 32 bits ?
q7: signed int 8 bits ?
Am I correct?
In the manual there are the DONE0_1_IRQ registers. Those are sending the interrupt I believe. Those need to be reset I think.
In the imxrt.h file there is this:
IRQ_ADC_ETC0 = 118,
IRQ_ADC_ETC1 = 119,
IRQ_ADC_ETC2 =...
@PaulStoffregen What I'm suspecting is that the settings for interrupts in the ADC_ETC have some kind of continuous signal for the interrupt and that the ISR is resetting it but it keeps firing or something like that. But I haven't been able to...
Oh sorry, I was using DMA before but couldn't get it to work so I repurposed the isr function but forgot to change the name of it. It does no difference though.
Here is a new version with the ISR function name updated...
That isn't the driver seen in use - and that code doesn't show the i2c address (which is always confusing as 0x3c or 0x3d)
Found a sketch used here with a PJRC i2c demo board that starts like this:
#include <Wire.h>
#include <Adafruit_GFX.h>...
Do you have a link to the OLED display that you have? Might be a powering issue.
You're also using software i2c (SW_I2C), not hardware (HW_I2C). Is that intended?
Also:
Pin 18 is usually data.
Pin 19 is usually clock.
Not sure if that would...
I have recreated it. This is how it was connected to the Teensy. The other picture shows the array I had it connected to. The power source was the USB it was connected to. The code I was using only had 56 lights (one strip). Thanks
Yes (in KiCAD 7), the clearances can be adjusted in the "Board Setup" menu, specifically the settings under "Design Rules" then "Net Classes", either by adjusting the "Default" (for all traces, if that's all that you are using), or by adjusting...
@jmarsh p#37 notes details on the cache - ideally the 32KB cache is designed to most effectively afford efficient access with minimal overreading and only writing back changed blocks. Profiling and use case might show the cache being less than...
Hi all,
I am one of the teammates designing the PCBs with @General_Hex.
For the capacitors, I've added 4 ceramic capacitors on the bottom board and 2 on the top board - all of which are 0.1uF. I am currently looking into Electrolytic...
I am trying to run a monochrome OLED 128x64 screen from adafruit on a teensy4.1. While this is part of a larger project, I am having trouble running even the simple example code as part of the u8g2lib package "hello world". I do not consider...
It is (mostly) transparent; when you fetch a byte from PSRAM, the entire 32-byte cacheline containing that byte will be fetched into the cache. Subsequent reads/writes will use the cache until the cacheline is evicted, either manually or by being...
Either newlib or the newer version of gcc (I forget which is responsible) uses 64-bits for time_t, because we're getting pretty close to the point in time where a signed integer count of the number of seconds passed since the beginning of 1970...
Any idea how this cache works? I'm assuming it would only cache specific memory that it has accessed.
My completely untested theory (and probably wrong) was if you were even accessing only 50% of the items out of order in the array on psram it...
First quick look, I don't understand why this?
Normally with DMA usage you would have the ADC or ADC_ETC trigger DMA only, and then DMA generates the interrupt when transfer is complete.
Yes, though I'm not sure in which version the change occurred. If I understand correctly, it's a configuration choice in the tools, but perhaps the default configuration changed in 11.
I added a line to my test program to print the sizeof(time_t). It returned 8, so you are correct that the something in the current compiler or libraries is setting time_t to a long-long 64-bit variable type. All the versions of time.h...
Oh yes so much more readable. Sorry was my first post, I'll make sure I use that function.
In essence I want a clockwise turn to be a button press, and a counterclockwise to be another different button press, so when I make a full rotation I...
After searching through the forums here, it appears that there isn't a dedicated Teensy development Discord/Slack. In reading these threads, I saw a good number of people running off to the Adafruit Discord, and a number of project-specific...
Most information can be found on this thread, and that's the ideal place to go for support as any answers I give will be fairly easily found by future Seekers of Knowledge. The thread started out with me checking I wasn't about to re-invent the...