I sort of started a thread a little bit ago: https://forum.pjrc.com/threads/66338-Many-TLAs-MTP-MSC-FS-SD-SDFat-LittleFS-UsbMSCFat-to-work-with-each-other-8)
Where I was maybe setting up for some...
Type: Posts; User: KurtE
I sort of started a thread a little bit ago: https://forum.pjrc.com/threads/66338-Many-TLAs-MTP-MSC-FS-SD-SDFat-LittleFS-UsbMSCFat-to-work-with-each-other-8)
Where I was maybe setting up for some...
@wwatson - Sounds great.
@all as I mentioned over in the MTP thread (https://forum.pjrc.com/threads/43050-MTP-Responder-Contribution?p=271721&viewfull=1#post271721)
I am playing around with...
@mjs513 - Yep I am also thinking a smaller test with fewer Storage types would be nice and/or split some of them into multiple tabs...
And yes right not I am still playing with the MSC multi...
Glad you found the issue... :D
Wonder what is different between T3.x and T4.x?
Or does something in your interrupts also touch the Analog?
Sounds like maybe need test case to see and maybe...
@all - Sometimes hard to know which thread to discuss things like integration of MTP amd MSC... and the like.
I am going to try doing some additional changes to my branch of the code to add some...
Thanks @mjs513 will probably look more in the morning.
Today I also hacked up that function some more that printed that data, and used digital Write high/low with pin 0 for the whole duration and...
@defragster and @mjs513 I am sort of curious about fragmentation works ;)
For the Fat32 volume:
I mucked up the beginning of the method most all of the class variables
int32_t...
Full current sketch, Note I commented out the earlier calls to get sizes...
Waiting up to 5 seconds for USB drive 1
^^Waiting up to 5 seconds for USB drive 2
^^^^^^^~~~~:(Initialize USB...
So I tried adding in the above test sketch currently just to the FAT16 and FAT32 section code like:
for (uint8_t i = 1; i < 5; i++) {
switch (partitionTable[i - 1]) {
case 11:
...
Maybe the code in the sketch is wrong...
It is not applying the partition... I am going to move those calls into the sections by partition type and see what I get...
Looks like we crossed...
Something does not appear to be working correctly at all with the freeClusterCount:
int32_t FatPartition::freeClusterCount() {
#if MAINTAIN_FREE_CLUSTER_COUNT
if (m_freeClusterCount >= 0) {...
@all - Another quick question: while starting to look at why the free space is TAKING SOOOOOOOO LLLLOOONNNGGG
I noticed in the SDFat code:
...
Quick note: I am thinking it might make sense to add the VolumeName.ino as an example sketch to maybe MscFS.h project. That way we can all keep track of it?
Make sense?
Morning,
Try picking up the latest UsbMSCFat project - I added a hack into it that if you ask for the Used size, twice (or more) it remembers the first call to it, which we do as a debug message...
Thanks @defragster,
I updated to your version.
I ran again, still real slow on my older thumb drives:
Waiting up to 5 seconds for USB drive 1
^^Waiting up to 5 seconds for USB drive 2...
Just an FYI: I updated the Volume name sketch to also print out the total size and used size sort of plus elapsed time to get them for the different partitions:
// VolumeName.ino
// An example...
@mjs513 which code fragment... MSC or MTP... So far in MTP I have not converted the main code to try to do anything with partitions, other than so far I am printing them out and I am able to get the...
Might really help to understand what exactly is your setup?
Windows? Linux? MAC? ... What version of Arduino are you running? What version of Teensyduino are you running?
Anything changed on...
@wwatson - not sure, about NTFS here. It looks like both partitions have type=7 which I believe is exfat. although looking at:https://en.wikipedia.org/wiki/Partition_type
It looks like type of 7...
Any luck?
Looks a bit complicated to jump in... I prefer easier things like MSC and MTP :D
Is it easy to setup and see failure when you don't have the hardware? Steps, and what to see when it...
Updated to fix the Fat16, also implemented a one call to find volume label.
And did some more gratuitous changes to have a function called by loop to process a drive, as to not need to reproduce...
Another quick note: I updated my sketch to the last one @defragster and found it was using the old non working Fat16 code. i.e. the one that was reading the boot sector and appears to always be: NO...
Good morning again:
Just for the fun of it you might try adding the asm("dsb");
somewhere...
The reason I mention it, I have been bit several times where ISR gets triggered multiple times for...
Some More not fleshed out thoughts on MSC and Partitions and FS...
I first off think it will be great all of the pieces in place and part of Teensyduino!
What I am sort of wondering is if it...
Good Morning!
I have not had a good chance to go through all of the code:
I don't see anywhere that you call attachInterruptVector, but if you did, I would probably make sure all of my interrupt...
Good Morning all:
Sounds like we have things coming along well here, to understand some about partitions and getting the volume label. :D
But our test has not handled SD Cards with multiple...
My exfat was failing as well, will look tomorrow unless someone beats me to it.
Have Fat16 working I believe at least for USB, have not tried with SD yet...
// VolumeName.ino
// An example of how to retrieve Fat32 and ExFat volume names using SdFat.
// Works with SD...
Hi @defragster and others...
Thought I would show so more stuff that is not working :D
// VolumeName.ino
// An example of how to retrieve Fat32 and ExFat volume names using SdFat.
// ...
Note: I have been playing some with adding Fat16 maybe stuff and not finding the VolID...
Some output currentlly:
Waiting up to 5 seconds for USB drive
Initialize USB...
@all - Wondering in my above Partition table dump you see:
msc1 Partition Table
part,boot,bgnCHS[3],type,endCHS[3],start,length
1,0,0x4,0x1,0x4,0xB,0xFE,0xC2,0xFF,2048,8192000...
Hi @mjs513,
I slightly hacked up your sketch, by moving a lot of it from setup() to loop() with a wait at the end of loop() for user to enter character.
That way you can hopefully rerun.
I...
@all...
I am winding my way through the different layers and trying to figure out how to get USB Drive partitions to work.
It might be nice to be able to do something like: today the...
Glad you have some building and ready to play :D
Did not get as much done yesterday, but will now try to see if I can get this MSC volume code and the like to read from all 3 partitions on my USB...
Take this with a grain of salt, but what I am planning to look at includes:
In the sketches we have: msController msDrive1(myusb);
Each one of these is for a physical USB drive, I believe it...
Note: the get volume label code was not working for me as probably timing. My USB is connected through HUB and so takes a bit of time before all of the stuff is setup. So I have it check to make...
As far as I know it should work. The code just figures out which Serial port gets passed in to dxlInit:
void dxlInit(long baud, HardwareSerial* pserial, int direction_pin, int tx_pin, int rx_pin )...
Sort of an old thread to resurrect.
But by PMs been asked if I could convert the board to Altium... Not sure if you would gain much. The whole design:
23820
I did try to export the board...
Mtp serial still need the usb_desc.h stuff copied in
Thanks @wwatson - tried the sketch, but the two drives I tried were exfat... Will try again.
Thanks for the hints:
I verified that in my debug outputs, the first calls msReadBlocks is in the...
@wwatson @mjs513 and @all - my eyes are mind is not seeing some things...
For example:
I fixed my USB thumb drive partitions to not use extended partition...
I turned off USBHost_t36 debug (in...
@... I have been playing around and understanding some more with the MSC stuff and partitions...
If you run the sketch SdInfoUSB it will print the partition table stuff (Block 0).
My output is...
I tried formatting a thumb drive to have 3 partitions,
A Fat32 primary
An extended partition table
With a secondary partition with Fat16
and a secondary partition with Fat32
And my MTP with...
@mjs513 an d @wwatson I will try playing some with that.
Have anyone tried doing some of the same type tests on thumb drives or the like? I think I will try to partition a test thumb drive and...
@mjs513 - Not a problem... Hope not too much snow! Here it is raining and upper 40s...
Will play more, but may want to switch gears to see about partitions on USB disks, which is probably more...
For the fun of it, I thought I would see if I could get it to read an ExFat one...
I think this one sort of works for it. Probably a real hack, but...
When you are dumping out the top...
@defragster - Looks great. Interesting with Low memory availability messages, I assume they most use a percentage... As 4K free on an LC would be 50% ;)
I see the changes were pulled in
@...
@mjs513 - tried you sketch above with a few cards. And it looks like it dumps lots of interesting info...
Tried reformat 32gb SD to exFat. As you mentioned not able to read that data...
@mjs513 @wwatson - looks like you are having some fun. Now to figure out how to integrate this with MTP :D I was happy yesterday to be able to plug in USB drive and it shows up and unplug it and it...
I put in a fix for now... Which is during the reset when the host asks for Storage IDS, I check to see if the name has been removed and if so it skips that slot...
So now when I remove the drive it...