Sorry, there is not much of checking in this code. Like most of the commands in that sketch, it runs off of the currently selected drive.
SO in Command prompt after comes up if you use the 1 command
1<cr>
It will...
If you are curious about MTP:
The main document I look at when doing this, can be downloaded from: https://www.usb.org/document-library/media-transfer-protocol-v11-spec-and-mtp-v11-adopters-agreement
This gives you a...
@wwatson @mjs513 @defragster and all
I hacked up the USB_MTP-logger.ino sketch and added a write file test. Pretty primitive:
void test_write_file(int ch) {
test_file_write_size = CommandLineReadNextNumber(ch,...
Sorry, I am just trying to be pragmatic here and go with the flow.
As I mentioned, I have tried to keep things within the ways that Paul has used in some of these areas. And with the case you mentioned, tried to...
Again I am not a MAC person, but have pulled mine out of the cupboard, and going to update it now... was 2.0.3...
Easy parts: What version of Teensyduino are you running?
With Arduino 2.x:
You can see it a...
I understand what you are saying, but at least in many of these cases it may depend on who and how these methods are called. For example if you look in Serial.cpp,
where the txTimer is used.
Whenever we start or...
Maybe one of us (me?) may have left a debug line uncommented.
Look in the USBHost_t36 directory.
And look in hid.cpp for:
void USBHIDParser::out_data(const Transfer_t *transfer)
{...
I am still sort of curious on the speed of these drives:
So put an elapsedMillis into the sendObject code, and at the end (debug >= 1)
printf("SendObject complete size:%u dt:%u\n", size, (uint32_t)emSendObject);
...
It works on mine:
Note: if it does not work, try to make sure it is trying to write to the Teensy port code and not the generic Arduino port code.
You should see it in the tools menu:
Also should make sure...
Personally I would only send one device reset event, after you have changed the file or file(s).
What it does is it tells the host to end the current session, the host will send MTP a new begin session, at which...
Note: As for the not seeing the last lines... There was a fix since the last released version.
You can download from the main arduino.cc software page.
As mentioned there are still many issues with the Serial...
Again I don't use the MAC, except at times for MAC specific issues. I mostly use Windows (main machine has W11), secondary machine Ubuntu 22.04 (or W10)...
Note: At times I think of Ubuntu in the same way that Paul...
Quick update:
The problem child (SDCZ73-032G-G46) that "works now"
https://www.amazon.com/dp/B01FTQP7ZM?psc=1
I was able to transfer a 6.44mb file to it, but it took probably over a minute to complete.
As...
Note: I am not much of a MAC person, but have older MAC laptop that I use to debug stuff on from time to time.
On it I was using some version of MTP like you mentioned, that had a 10 day trial period...
But then...
@wwatson @mjs513 - I tried the change and as mentioned it appears to fix the issue with at least the problem child I picked up. I ran the MTP USB example and was able to both have it create the log file on the drive. ...
@mjs513 @wwatson
@PaullStoffregen (if you are watching) - thread shows last look about a week ago.
Some of this lower level USB stuff is above my pay grade (of $0) ;)
Stalls - I have looked a little bit...
Another simpler option for you maybe to try:
That is if you call begin() before it is there, maybe we should still try to use that baud rate when it does connect:
If you go into the USBHost project sources on your...
Strong guess, FTDI cable is buffing the stuff...
If you output your 82 bytes to userial1 and then do userial1.flush();
Does it work? My guess maybe not.
The cable probably has some logicai IOCTL that tells the...
Sorry, it has been awhile since I looked at the USB Host Serial code.
I think there is sort of a chicken and the egg problem.
It does appear like the code does default to 115200 when the object first connects. ...
Sorry I am not sure exactly what you are asking, So will try to give some generic information.
The Serial object, tries to fill up a USB buffer and then sends a USB packet to the host. Things that control how USB...
Will have to take a look at those.
But first I am curious about the failure:
File "annie3 - Copy.bmp" size:230454 Created:641d6f21 Modified:61e3a02e
read consumed all data (TODO: how to check ZLP)...
For me, the AD_B1_ is the pin name, the GPIO number is closer to the PORTA, B, C, D of the AVR processors.
For example if you look at my excel sheet in GPIO pin order.
You will see a column with name... the AD_B1_...
Quick note, I picked up my delivery of 4 of the Sanddisk ulta Flair 32gbs...
Looks more or less identical to what @mjs513 showed yesterday...
I did also try reformatting it on PC to FAT32 and no differences. MTP...
Many/Most of the HID drivers keep a back pointer to the USBHIDParser object.
This is passed to you in the claim_collection method.
Many use it to restrict their object to only dealing with one HID parser.
And...
Sorry, I am distracted as I am trying to debug some of my own not related code.
Count of devices really only impacts as you mentioned amount of memory. And maybe in few cases where it walk the list of objects.
Probably. It is probably with the DNS that I am using. I think I still have it hard coded at my connection to my provider as something like: 1.1.1.1
Or might have been googles: 8.8.8.8
Was earlier having problems...
C:\Users\kurte>ping pjrc.com
Pinging pjrc.com with 32 bytes of data:
Reply from 162.254.150.250: bytes=32 time=506ms TTL=42
...
C:\Users\kurte>ping forum.pjrc.com
Pinging forum.pjrc.com with 32 bytes of data:...
That is the normal way the HID parser code works.
However there is a hook that some of the client code, like the RAWHID and for example some cases the Keyboard and maybe some others use.
That is, when the message...
Sorry, I was not doing much monitoring up here yesterday... Sort of off doing different things.
I have found with some of the Wireless Mice or keyboards, that yes, they can consume several objects.
For example,...
I am wondering if this display has a display driver chip on it or if it might be something like the KeDei display we were playing with a few years ago.
Which was another RPI 3.5" display, but it did not do standard SPI...
Is there anything that we should be looking for?
That is, was this a "simple" server change or was there other things that changed as well?
My guess is simple is never simple!
I noticed recently that you...
Note: I looked up at amazon, and they have a few Kingston Datatraveler G2 drives, but none look like the one in picture. So not sure if they would be apple to apple...
And if they are all different not sure worth...
Note: I am a software guy... But..
If you look at the T4.1 schematic it shows a voltage regulator that in main part says range up to 5.5v, but in the spec part it says absolute max 6v.
So you might be able to live...
Sorry, I know sometimes less is more...
If you look at the memory section of the T4.1 product page:
https://www.pjrc.com/store/teensy41.html#memory
everything except RAM1 (DTCM/ITCM) uses the cache.
The DTCM/ITCM...
Yes you should be able to do 8E1. Don't remember if you need to enable 9 bit support within HardwareSerail or not, probably not.
By default, the support for 9 and 10 bit and more is disabled within the source code...
Sorry, I missed seeing the DMAMEM on your example.
To me, the keyword DMAMEM translates to, almost the worst place to do DMA ;)
External memory can be worse :D
The issue: These areas of memory are configured to...
Paul has a github project to track issues about the website.
Did a quick look, and sure enough, I opened up an issue about this, about a year ago:
https://github.com/PaulStoffregen/Website_Updates/issues/26
Side comments to self:
Part of the write9 code that currently runs, I have wondered if it still fails at times:
while (tx_buffer_tail_ == head) {
int priority = nvic_execution_priority();
if (priority <=...
I was playing around with some different stuff, and ran into an interesting issue.
And I am trying to decide if it is worth fixing.
Here is some quick typed in code (probably has errors) that will likely hang a...
Sorry, I am not sure who the "maintainers" are?
The only person who can merge in any changes to this library is the Paul. @wwatson, who did most of the original MasStoreage work, has been very active on this...
In case anyone has not noticed:
Arduino released version 2.0.4. A few days ago.
I have not had any new issues with it, but have seen some reports up on Arduino forum, where some people have run into issues, like...
Couple of thoughts here:
I have had times where the crash is very near to startup code and kept in an endless beep reset, beep reset.
So sometimes I put code in like:
if (CrashReport) {
while (!Serial &&...
If you are going to muck with the register, I would do it right after you did any/all SPI.begin() (including SPI1 and/or SPI2...) as they all use the same underlying clock.
Note: the code was setup to try to avoid...
Note: The SPI library is setup to allow you to choose a different Clock setting for base of it.
It is all controlled by the clock register: CCM_CBCMR
Which the SPI library inits each time you call SPI.begin()...
You might try to use some built-in hardware support...
For Encoder: not sure if it is a quadrature encoder? if So you might want to look at:
https://github.com/mjs513/Teensy-4.x-Quad-Encoder-Library
For Analog...
Sorry, you may need to explain more about what you are doing or wanting to do.
For example you are sampling Analog. Are you using the analog capabilities of the Teensy to do this, or are you using some external ADC...
I am saying in particular the logical output flush (tcdrain) on the linux machine, mainly SBC like RPI, or UP, would stay in this function for an extended period of time.
So my setup code to talk to the Dynamixel...
Sorry, I am probably not much help here. But with USB latency, when talking with PC/RPI...
When I have worked on different simple robots in the past, where I used a Teensy or other board as a Servo controller and the...
Note: I posted the code I tried, plus output, that at least in the simple case the hardware and digitalWriteFast is working
And potentially if you have a logic analyzer or Oscilloscope, you maybe could try to see if...
I don't see that issue: Here is a complete sketch:
#define GATE_OUT_1 39
#define GATE_OUT_2 38
#define GATE_OUT_3 37
#define GATE_OUT_4 40
void setup() {
pinMode(GATE_OUT_1, OUTPUT);
pinMode(GATE_OUT_2,...
Sorry, other distractions.
Yes - if I remember correctly (year plus ago) - that github project was where I had done some rawhid host code to test the rawhid 512 stuff.
There is an Open PR on core:...
Sorry, I know off topic, probably should take to another thread, but:
Earlier I was playing with Two Teensy 4.x talking to each other using RAWHID, with the version I made that supports 512 byte transfer. But so far...
Thought I would mention, I was able to build it using W11 sort of using your guide. My first attempt using Visual code, the cmake stuff failed.
Started over and used the Command line. stuff and there I saw the...
Sorry have no idea if the sketch can or can not work on ESP32.... We don't see the actual sketch.
But the error:
C:\Users\Tom\Documents\Arduino\LEDmetronome\MetroD rumv1.19\MetroDrumv1.19.ino: In function 'void...
For what it is worth, @mjs513 and I were playing with a picture viewer sketch, which is up at: https://github.com/KurtE/mtp_tft_picture_view
It cycles through pictures on a storage and displays them on a display.
It...
Sorry I am not a platformerIO user, but your simple images/code do not show you including <SD.h>
You have some other <dbSD.h> which I don't know what that is.
It does show in your platform.ini file stuff that it...
Sorry, throwing darts...
How are these Teensy boards being powered? Is it through USB? Or through VIN? If VIN, what is the voltage?
Just wondering if it could be differences in which VR or the like...
Again...
The QSPI memory does not use LPSPI it instead uses: FLEXSPI controller (Chapter 27) - There are two of these, one for main memory and second for those bottom chips.
Pins 48-54 - Mode 8 If my quick look is correct.
...
@luni - I was thinking the same thing in my earlier post.
Maybe it is one interrupt interfering with the other.
...
inline void TriggerGenerator::PeriodicCallback()
...
prepare_message(type_, seconds_, micros_,...
LPSPI - I know somewhere in the PDFs, it says like LPSPI should not exceed something like 25 or was it 30mhz.
The QSPI is a setting on LPSPI so would have the same speeds. However, I am pretty sure that there are...
Maybe it is one interrupt interfering with the other.
That is, if you have code like this:
inline void TriggerGenerator::PeriodicCallback()
{
digitalWriteFast(pin_, HIGH);
// REVIEW: need no interrupt?
...
I would definitely go more by what Paul says here, but earlier I did query on Digikey and Mouser and found what looked like sevaral available.
In the last search I restricted my search to TQFP type as the other types...
So you added the json file to the preferences. That is if you bring up the preferences and click on the list yours should include:
Your list includes the one I highlighted in green:
Note: Just to be sure I often...
Like the others, I am pretty sure that is simply two connectors. that is there are 2 groups of 4 pins, which probably match the 4 pins of our one connector where then the 5th pin would connect up the shield...
If you...
I would double check the udev rule, as when I install teensyduino directly for Arduino IDE, on Ubuntu, I have to manually copy the file to the right location.
Edit, and I would also maybe see what the linux tells you...
Did you install the udev.rules on this machine?
https://www.pjrc.com/teensy/td_download.html
Maybe try different USB cable. Maybe it is a power only one?
Quick note: I personally try not to make any assumptions about the experience levels of different members up here, unless of course if they mention it. To me it is often more, a matter of what your current project is,...
Everything is a tradeoff... There used to be code in place, that would remember if the last output was 8 bit or 16 bit and if the next one is different it changes the setting. Which in isolation worked great.
...