Thank you very much, PaulStoffregen, for interesting example.
AFAIK, receiving on many software serial is the key problem, and I cannot sync my slave esp32 so that they send data at the same time....
Type: Posts; User: was-ja
Thank you very much, PaulStoffregen, for interesting example.
AFAIK, receiving on many software serial is the key problem, and I cannot sync my slave esp32 so that they send data at the same time....
Hello,
I am planning to build a system where I have many (14 pcs) esp32 boards connected to one Teensy 4.1. I need a possibility to reprogram each esp32 from Teensy 4.1 on fly (each has the same...
Hello,
I'm wondering if I am writing to GPIO6_DR - it takes one cycle, but if I am reading from GPIO6_PSR - it takes 9 cycles. Can you please tell me if there is a faster way to read from GPIO6?
...
Thank you very much, Rezo and PaulStoffregen, for your kind comments!
Yes, seems that FlexIO3 is still doable. I will probably mix my numerics with FlexIO, probably I can save interrupts here, to...
Thank you very much for the replays. Ok, it seems that it will be easy for me to use alternative external ADC with shorter parallel bus to fit into FlexIO2 with DMA, as, for example, afe5401 (12...
Hello,
I have an ADC like https://www.microchip.com/en-us/product/MCP37D31-80 with parallel CMOS and want to collect data from this ADC into Teensy 4.1 and perform computations on fly. I have...
mainly Altera, Cyclone, Stratix of different size. For example, on small cyclones it is doable to make similar with some additional delays on latches at 0.3ns, so, 10 times better than directly on...
Thank you very much for pointing out. Yes, sure. I know that it is not possible to play with GPIO very fast, but, I have such a sequence of data that generate ca. 30MHz on/off sequence on each port,...
I really cannot understand the reason why my previous version with "unsigned short" does not compile. When I used uint16_t as you suggested - everything compile, but it is still slow.
Below I...
yes, I see it before, but it is 7 times slower than 32-bits write, if we discussing about:
a = (GPIO6_DR) & 0x0000ffff; GPIO6_DR = a | (((unsigned int) A0)<<16);
and direct operation like you...
Thank you very much, manicksan, for the replay!
Yes, I am using teensy 4.1, and want to update only 16-31 bits. Please, advice my how to make it by one tact, I tried to unsigned short, but it...
I understand that I need to place A0...A13 into registers, in this case the main loop will take one tact to one data transaction.
Actually, I was unable to do this using "register" before...
Hello,
I am pushing consequently several (14) integer words into GPIO6 in a loop. Right now one GPIO6 update takes two clocks, and I would like to do it in one clock. Data in these integer words...
Thank you very much, manicksan! It is exactly what I am searching for, I will try it right now!
Hello,
I am trying to use CLAPACK inside teensy 4.1, and need an advice how to compile it.
I created a new directory src in ~/arduino-1.8.19/hardware/teensy/avr/cores/teensy4
and saved all...
Please, find below the simple test program that fail on boundary access.
#pragma GCC push_options
#pragma GCC optimize ("Ofast")
#include <stdio.h>
super, it is even simpler.
Either statically allocate variables in EXTMEM, or statically allocate a buffer in EXTMEM and port any malloc realization that works with buffer, so that you will allocate memory practically with...
about 1.3MS/s at 12bits, 1.5MS/s at 10bits, 1.8MS/s at 8 bits. It seems that it may be also tuned for 20-30% more but I do not know how. But even at 1.3MS/s at 12bits if, running both ADC it leads to...
I am achieving ca. 15 CPU clocks per 16 bit read on overcklocked up to 816MHz Teensy 4.1, that gives me almost 1GBit/s traffic. In case if you send data over GPIO, it is doable on 2 CPU clocks per 16...
It is not so simple: I wrapped my code with
due to performance.
To test FASTRUN I tried the following options:
Thank you very much FrankB for your kind answer!
Happy viewing and good night!
Thank you very much, FrankB, for your answer!
I am using TD1.56, and I found 2 entries of FASTRUN at:
where, at the first file (WProgram.h) it is defined as
#define FASTRUN __attribute__...
Thank you very much, FrankB!
Yes, however, if I mark every function in my files as FASTMEM, all of then are present in the elf (executive file). Otherwise, with standard method, many small...
Thank you very much, FrankB!!!
Yes, it works as it is on my t4.1.
It moved almost all functions to flash memory having some 192 bytes still in ITCM.
Actually, it is not exactly what I...
Hello,
I have 2 Teensys 4.1 and want to connect #1 by its USB Host directly to #2 at its USB Device. The critical is to transfer large 16K-64K datablocks from device to host by DMA, so that both...
Thank you very much, Frank! Please, suggest me what I am doing wrong, I cannot go to your link, github reports me that it is 404. I also searched in your project, but probably, did not carefully, so...
Hello,
my project becomes more complicated, and require more program memory. I already optimized everything that I can in my code: wrapped my code and SPI, DMA and interrupts files with pragma...
Thank you very much for your comments! Since you helped me to understand that it is not normal situation, I start to search in the configuration.
Finally, the problem was in the ~/.arduino15 - it...
I had similar behavior if previous sketch run some complicated math and take a lot of power resources that my laptop's USB cannot feed. I see it already when T4.1 consume 0.2A and more from USB. I...
Hello,
I would like to place some debugging information into several functions in ~/arduino-1.8.19/hardware/teensy/avr/cores and ~/arduino-1.8.19/hardware/teensy/avr/libraries
If I rebuild...
Hello,
I played with interrupts and print them from all possible corners. I made a small print utility, may be somebody can also use it.
class PrintInterruptsClass
{ public:
void ...
Thank you, defragster, for your comment.
I forget to mention that SPI DMA (#1) running at normal (not DMAMEM) FASMEM. If I am using DMAMEM for 125000 isr/sec with 19 bytes, it already produce...
Thank you very much, Frank B,
I found _VectorsRam and it seems that it contain corresponding function pointers, so, probably with your suggestion regarding to add2line it will be the simplest...
Thank you very much, PaulStoffregen and Frank B for your kind information and assistance!
I printed interrupt priorities just after inicialization and during my main loop and figured out that at...
Hello,
I have a project where I am using:
SPI DMA read by external interrupt, (each interrupt occurs ca. each 8us, and I am starting to read 19 bytes, this transfer is finishing over...
Thank you very much, defragster, for the info. I tried to uncomment USB version since my Serial4 is busy by GPIO. Hope to get more info now, but it will be not very easy - the program does not crash...
Thank you very much, KurtE for your kind suggestion.
I edited appropriate files, did make in ~/arduino-1.8.19/hardware/teensy/avr/cores/teensy4 and recompiled my sketch, but seems that nothing...
Thank you very much, Frank B,
yep, I searched for addr2line, but it was arm-none-eabi-addr2line. Got it, and found the line where it is occurs, hope to find the reason.
Thank you very much for...
Finally got the problem:
CrashReport:
A problem occurred at (system time) 22:59:22
Code was executing from address 0x2E52
CFSR: 82
(DACCVIOL) Data Access Violation
(MMARVALID)...
Thank you very much, PaulStoffregen, for your kind advise! I have placed it into my sketch and waiting now for the failure.
Hello,
I have strange behavior in my Teensy 4.1 program that I have not been able to fix for a week. I suppose there is a bug, out of memory, or something illegal somewhere in my program. In my...
Thank you very much, FrankB!
Just found that I can change void AnalogBufferDMA::processADC_DMAISR() and place what I need into this function.
Hello,
I have small test that is based on adc_dma, where I am collecting data from 2 ADC simultaneously. I would like to call a call_back function after each successfull measuring of each my 16K...
The first my question
is fixed, I played with many possible variants for readPin_adc_0 and readPin_adc_1 and figured out that I did not set ADC_SAMPLING_SPEED::HIGH_VERY_HIGH_SPEED for the second...
Hi,
my best season greeting to all forum participants and PJRC Team!
Let me please, ask you regarding to the maximum possible ADC speed on Teensy 4.1 by using DMA and two channels.
To get it...
Oh, super! Thank you very much, PaulStoffregen, for detailed info regarding USB communications!
Finally, let me shortly asking the difference in the speed and latency between
USB-USB and...
Thank you very much, joepasquariello, for your kind answer!
exactly what I have searched for, thank you very much!
Yes, they are free. I am trying to search web, but did not clearly...
Hello,
I am planning to develop a device with two Teensy 4.1 boards and need your kind suggestions how to proceed.
The first board (#1) will be connected to the external world over the...
Thank you very much, luni! Your kind advice finally solved my issue!
By using your suggestion, the total code size dropped from 101K to 63K that saved me two 32K blocks in ITCM, and, in addition...