Forum Rule: Always post complete source code & details to reproduce any issue!
Tab Content
  • mjs513's Avatar
    Today, 11:26 AM
    @defragster Glad you tested it and it seems to be working for you. As I said the only thing changed from the @WMXZ'z MTP_t4 lib to the MTPspiffs_t41 lib was the storage class in order to support spiffs. Which was...
    5 replies | 79 view(s)
  • mjs513's Avatar
    Yesterday, 11:40 PM
    Looking at the Wiki for the display the I2C pins are probably not compatible with the requirement for 3.3v pins on the T4.1. You can use a logic level converter for the I2C pins. Personally I only played with the...
    4 replies | 44 view(s)
  • mjs513's Avatar
    Yesterday, 03:07 PM
    Got it working 99.9%. See this thread: https://forum.pjrc.com/threads/61101-MTP-Responder-for-SPIFFS?p=241196#post241196. Made it separate so won't get this thread too crazy.
    297 replies | 37516 view(s)
  • mjs513's Avatar
    Yesterday, 03:06 PM
    Just finished the initial library for using MTP Responder with SPIFSS on the Teensy 4.1. The library takes the core MTP implementation from @WMXZ MTP_t4 library and reworks the Storage class on the library to use...
    5 replies | 79 view(s)
  • mjs513's Avatar
    05-24-2020, 04:52 PM
    @WMXZ Just thought I would give you all a bit of an update on this. I have to rework the Storage piece for SPIFFs and am at the point where I can see the files that I created on the FLASH using MTPResponder. Still...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-23-2020, 05:38 PM
    @KurtE Very cool hacking :) Going to have to get a castellated board at some point - still working my other distraction :)
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-23-2020, 10:00 AM
    If you are going to just do direct writes to PSRAM with you own implementation you don't need it. There is one cautionary tail about using direct writes at this point, EXTMEM. I you are using EXTMEM along with...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-22-2020, 12:33 PM
    A couple of things. 1. Make sure you select Triple Serial on the dropdown menu for the USB Type 2. if you use SerialUSB2.begin make sure you include the baud SerialUSB2begin(115200). Technically you don't even need...
    13 replies | 169 view(s)
  • mjs513's Avatar
    05-22-2020, 10:24 AM
    @Zane470 - very nice indeed. I have been using the Sparkfun library for the ICM-20948. Yours seems a bit more interesting :)
    3 replies | 142 view(s)
  • mjs513's Avatar
    05-22-2020, 10:17 AM
    @MartyMacGyver - @defragster is correct. One minor correction. Been working on further cleand and auto configuration for FLASH and SPIFFS. The librarys for FLASH and SPIFFS both change the chip clock speeds to 133Mhz....
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-22-2020, 10:12 AM
    What Teensy are talking about? I know on the Teensy 4.0 and the T4.1 support was added for Triple Serial through the usb connection to the PC: Serial SerialUSB1 SerialUSB2 You use SerialUSB1 or SerialUSB2 like...
    13 replies | 169 view(s)
  • mjs513's Avatar
    05-22-2020, 01:19 AM
    Unfortunately no. Was playing with it for the last couple of days. The Adafruit lib is configured for samd boards. Also a different usb desc has to be created from what I see. So it’s not out of the box compatible
    16 replies | 533 view(s)
  • mjs513's Avatar
    05-21-2020, 04:41 PM
    Very cool @KurtE. Another distraction for your list. :)
    111 replies | 2799 view(s)
  • mjs513's Avatar
    05-21-2020, 03:28 PM
    Thanks think I will turn it on to see what its doing and maybe add some more debugging. Also am looking at original implementation in the post #1 just for reference. Well another time consuming project :)
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-21-2020, 03:14 PM
    Got it thanks
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-21-2020, 02:54 PM
    @WMXZ Began to start sorting things out. But do you have a link for the MTP document. There are 2 things with SPIFFS - no sub-directories allowed and second I can get the all the file info with a simple list dir...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-21-2020, 02:03 PM
    @WMXZ I'm going through storage.cpp with the good intention to see if I can get it work with SPIFFS on the external Flash. Doing it function by function but running into some things I need some help with...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-21-2020, 12:01 PM
    Yep. Glad you got it working. That change is mandatory otherwise you are stuck with a max of 450Mhz
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-21-2020, 10:55 AM
    You are getting strange results. Make sure you make the change in usb.c for high speed as you said. Second try it with the MTP_test sketch first before experimenting. If it works with that then it has be something ...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-20-2020, 05:41 PM
    You don’t need delays anymore like they. There implementation is for rip and completely different. Adding delays will do exactly like what you are seeing
    659 replies | 23726 view(s)
  • mjs513's Avatar
    05-20-2020, 05:28 PM
    @KurtE Just pushed some changes to the ILI9488 library to address issues with using EXTMEM examples: https://github.com/mjs513/ILI9488_t3
    659 replies | 23726 view(s)
  • mjs513's Avatar
    05-20-2020, 05:27 PM
    Looks like you may want to do the following but @KurtE can confirm: beginSPITransaction(); setAddr(x, y, x, y); writecommand_cont(ILI9488_RAMWR); /// this ILI9388_RAMWR would be replaced with REG or use LAST...
    659 replies | 23726 view(s)
  • mjs513's Avatar
    05-20-2020, 03:11 PM
    These are the only three libraries you need: Cant upload sdfat lib but just download the latest SDFat-beta library. Heres my config file: That's all you really need. Basically I just redownloaded all the...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-20-2020, 01:28 PM
    @KurtE - Got 2 primary things fixed in the lib but just noticed that the Center-center code hasn't been added. Probably should check Pauls master branch EDIT: I was wrong we added it but forgot to define CENTER in...
    659 replies | 23726 view(s)
  • mjs513's Avatar
    05-20-2020, 01:27 PM
    If you look at the other file in the link you posted (go up one level - think it was call waveshare4.show???) anyway, the max_spi looks like its only 12.5 MHz? So not sure why the speed limit on the that display as...
    659 replies | 23726 view(s)
  • mjs513's Avatar
    05-20-2020, 12:54 PM
    Already on the list but keep getting side tracked :) Besides with all the other rework wanted to make sure everything else worked first :)
    111 replies | 2799 view(s)
  • mjs513's Avatar
    05-19-2020, 04:17 PM
    I agree. Want to give it a try but have a couple of other things in process I need to finish before I get wrapped up in tinyUSB. Was looking out of curiosity so on list :) And yes it would be very useful that was why...
    16 replies | 533 view(s)
  • mjs513's Avatar
    05-19-2020, 04:06 PM
    If you look at the I2C schematic on the hanyazou (https://github.com/hanyazou/BMI160-Arduino) you can change from the default address to the BMI160's alt address by connecting SDO/SA0 pin of the BMI160 to 3.3v I...
    8 replies | 103 view(s)
  • mjs513's Avatar
    05-19-2020, 03:55 PM
    Was actually looking at usb.c this morning as well and didn't see that. I was focusing on whether there was a need to implement buffers for rx and tx. Also noticed if I remember on USB transfers it disable interrupts...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-19-2020, 03:12 PM
    This might be easier if you can share your sketch?
    5 replies | 99 view(s)
  • mjs513's Avatar
    05-19-2020, 02:13 PM
    Ok that's weird but that its working is good at 600Mhz. But need to figure out the bug - unfortunately wouldn't really know where to start. Have to get to beta test thread and check. Know there was some interesting...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-19-2020, 01:09 PM
    Thanks for all the effort to try and get it working at high speed. For now, until Paul has time to work this (he has a long list) I can deal with 450Mhz for MTP. An easy work around is to programmatically change the...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-19-2020, 12:46 PM
    Know a little late here but the Teensy 4.0 bsp support is in the bsp directory of TinyUSB. Do a search on teensy in the tinyUSB repository and you will find it. For the T4.1 would probably have to be modified since...
    16 replies | 533 view(s)
  • mjs513's Avatar
    05-19-2020, 01:41 AM
    No longer a hack. I have a feeling this might come up again since I've seen that before so I just changed spiffs_config.h so it reads like this: //typedef signed int s32_t; //typedef unsigned int u32_t; ...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-18-2020, 10:49 PM
    Yeah - I forgot to read the readme. Anyway don't think there is anyway around it but to hack spiffs_t4 itself. Tried a few things but everything I tried caused other things. Only recourse would be to modified SPIFS...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-18-2020, 09:20 PM
    Ok - getting this error when I try and compile. Have to go do something but will be back: libraries\lwip\src/include/lwip/ip_addr.h:40:22: fatal error: lwip/opt.h: No such file or directory
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-18-2020, 09:04 PM
    Where's the Ethernet lwip_tftpd_SPIFFS posted.
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-18-2020, 07:46 PM
    @beumerjm Actually you can also just do tft.println or tft.print or tft.prinnt at the cursor postion :)
    111 replies | 2799 view(s)
  • mjs513's Avatar
    05-18-2020, 06:51 PM
    I redownloaded all the libraries and reinstalled and made no changes to usb_desc.h or .cpp. By the way prints loop to serial at the slower speeds. Works up to 450Mhz. At 528 and 600Mhz I tend to loose USB connection....
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 02:53 PM
    Not a problem - getting closer - trying to rule out what I am doing differently.
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 02:48 PM
    Can you copy and paste to and from the SDCard?
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 02:47 PM
    This is the latest: https://github.com/WMXZ-EU/MTP_t4?
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 02:35 PM
    I just copied and pasted the files that @JaredReabow sent me: from Arduino libraries used his SDFat-beta, MTP4, usb2 directories and at least now I can see and open the SD Card and see the directory contents but - all...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 02:18 PM
    Nope - first thing I checked. I also did a search for SDFat.h and only version I have in the libraries folder is in the SDFat-beta library. Doublecheck: forgot to check what SD lib used so there is a SDFat.h when SD...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 01:48 PM
    Ok - you all are getting out of my comfort zone again :) Any good references out that explains linker scripts etc. Some I get most not. EDIT: Found some - guess I have some reading to do: ...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-18-2020, 01:32 PM
    @WMXZ Just downloaded and installed the MTP and USB2 directories. I changed the made sure I changed to use SDIO = 1. SDFAT-beta was already set up but no luck. I see teensy as a device but no SDCard? I am using a...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-18-2020, 12:18 PM
    @defragster Ok just spent some quality time with PSRAMS and FLASH again. For now here is what has been implemented: spiffs_t4 library 1. If FLASH is available it uses FLASH for the SPIFFS 2. IF 2 PSRAM's are...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-18-2020, 10:00 AM
    Without fs_unmount I get: 32768 bytes from 0x70800000 flash 779 us 32768 bytes from 0x70800000 flash 68 us about the same. Out of curiosity I added the same code when I before doing anything with the sketch with...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 09:55 PM
    Correct :) Ultimately that would be the idea but don't want to do a library hack until Paul does the final implementation. To play with using KurtE's extmem_malloc is good but don't want to base the lib on that...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 09:47 PM
    Now after you posted there was something I realized. If you do the memcpy at the end of the SPIFFS tests the SPIFFS file system is still mounted. So not sure what that effect would be. To avoid that in the future...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 09:06 PM
    Ok confused on the timings. Where did you put the memcpy's in the sketch and did you specifically call arm_dcache_delete? Have no comment about ERAM/EXTMEM that I don't get?
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 08:42 PM
    @defragster In actuality to SPLIT PSRAM into 2 regions I think I can do (already did it in the past as a test) if I don't get myself confused with configurations :) So if you tell me to reserve 4Mb for extmem in the...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 04:06 PM
    Actually forgot about that maybe better off not doing SPIFFS at all on PSRAM since uses are going to be so varied and spiffs on PSRAM are just going to be confusing the issue EDIT: @KurtE - just thought of...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 03:22 PM
    Got it - now I understand - some how I messed up with GitHub. Just delete extRAM_t4.h and extRAM_t4.cpp. Think I know what I did - just pushed up the change with the deleted files.
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 03:18 PM
    @PaulStoffregen - @manitou - @defragster - @KurtE I'm working on a second half of the PSRAM/FLASH to set up a wrapper for direct writes to the PSRAM or the FLASH but am running into a use case challenge. No issues...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 01:29 PM
    I second that :)
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-17-2020, 12:43 PM
    @manitou One problem I am having is that I am not getting the same errors that you and @defragster are getting when I do a compile - the only difference I see I that you still are using extRAM_t4 - you don't need that...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 12:19 PM
    Looks like you still have extRAM_t4 lib still in you libs folder: Delete that lib and just have SPIFFS_t4 in your lib <EDIT> meant library folder - its all self contained.
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 12:11 PM
    All - SPIFFS_t4 has been updated on GitHub: https://github.com/PaulStoffregen/teensy41_extram/tree/SPIFFS-FLASH-ONLY/SPIFFS_t4
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 11:37 AM
    Thanks Paul. That would simply things. Going to change so the address is always at 0x70800000 But just out of curiosity if I did change it did it do it right?
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 11:21 AM
    @defragster - @manitou Thanks for checking but to answer your questions: Depends on if there is a PSRAM chip installed. If 1 PSRAM then the base address should be 0x7080000 if no PSRAM is installed then I think the...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-17-2020, 12:12 AM
    @wwatson Sorry I didn't answer sooner. Not sure why you are getting those errors. A couple of things. Make sure you have the latest lib and 2 I am attaching this sketch that I just ran without errors: . Let me...
    111 replies | 2799 view(s)
  • mjs513's Avatar
    05-16-2020, 11:37 PM
    Lets see how this works - easy enough to add it back in. I left the underlying addressing there so …. @Paul - @manitou: any thoughts? EDIT: Think the problem is going to be if someone wants to use PSRAM for...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 10:49 PM
    FLASH-ONLY SPIFFS LIBRARY Created a new branch SPIFFS-FLASH-ONLY that removed the PSRAM portion of the old library and renamed to spiffs_t4. EDIT: Only one library needs to be downloaded now. Changes from the...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 09:49 PM
    That's one of things that is in one of the examples I am cleaning up that has to get deleted - not used or needed anymore believe it or not :)
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 09:47 PM
    Thanks everyone. Had a feeling that was going to be the case. My local copy of library has been updated and is working no issues to identify the possible chip combinations (not posted yet). The lib automatically...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 09:01 PM
    Need some help with c++ for using external_psram_size in a #if directive. Right now I have this at the beginning of the sketch: extern "C" uint8_t external_psram_size; static const uint8_t psram_size =...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 06:46 PM
    Only config that I haven't been able test is the one for FLASH only. Any idea for a good library name now that its spiffs flash only. EDIT: Think after I go through the examples I will just merge it with the...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 05:46 PM
    Wont have to hack the core when I get done. Got tired of that also. It will be stand alone and should detect if you have no flash, 1psram and no flash (still need to add code for this config) and 1psram and flash or...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 03:59 PM
    As a heads up the extRAM_t4 lib will be changed to support SPIFFS only on the external FLASH chip. Since I have not heard any differently using PSRAM for SPIFFS will no longer be supported!
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 02:59 PM
    Got it. After the comment on speed I changed the clock speeds: 1. Lower the speed from 528Mhz to 24Mhz I now see it as Teensy but if I click on it don't see the SD Card (it blank) 2, At 600Mhz just see it...
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-16-2020, 02:34 PM
    Sorry for the late question but keep getting sidetracked - so easy to do. If I only put on a FLASH chip the address of the flash would start at ???????, 0x70000000 or 0x7080000? or if in the initialization for flash...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 02:16 PM
    Yep that's pretty much what I get but no files are shown and you can not copy anything to the MTP USB drive
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-16-2020, 01:04 PM
    That was my thinking, i.e., to see if we could use MTP to access the flash or even PSRAM accessible. However, due to issues with MTP and getting it to work again with T4.x had to put it on hold. The flash can use...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-16-2020, 12:17 PM
    Downloaded and installed 1.52 over existing betas with 1.8.12 IDE. Install - no problems with Win10x64 pc. Ran a couple of quick tests: PSRAMmemoryTest and one of my 3dModels on the RA8876, and ILI9488 graphics...
    25 replies | 1281 view(s)
  • mjs513's Avatar
    05-16-2020, 10:48 AM
    That's great news. Was beginning to think something wrong with PSRAM!
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 11:42 PM
    Sounds similar to my problem with win10. Exception is windows sees th t4 as a disk but doesn’t read the disk contents and definitely can’t write to the disk
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-15-2020, 09:49 PM
    Just got up and now at 4560 with no errors with a SD Card in it. @KurtE - great that its working again. Going to stop the test - forgot to solder something onto the breakout board I am using. EDIT:...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 08:42 PM
    Just inserted a SD card at pass2175 lets see what happens. Time for a nap. EDIT: just as note I am testing with a T4.1 with 16Mb PSRAM.
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 08:26 PM
    @defragster Just as a note: uint32_t COUNT_ALLOC = 1250000; This is what we are using for buffersize. EDIT> Up to pass 1650 with no errors
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 08:11 PM
    That's the sketch I am currently running. Wanted to match what you had. for (uint32_t i = 0; i < COUNT_ALLOC; i++) { buffer1 = i & 0xffff; buffer2 = loop_count & 0xffff; buffer3 = buffer1 ^ buffer2; ...
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 08:06 PM
    That's currently in the sketch that @defragster and I posted,
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 08:04 PM
    Up to Pass 809 error count: 0 with no errors?
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 07:29 PM
    @defragster - do a double check on the chip soldering - maybe something not good. As long as you didn't edit the chip size in startup should be good - going to let mine run and see what happens
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 06:39 PM
    @defragster Great that it worked for you :) was busy soldering up a T4.1 with 2 PSRAMs for testing :)
    783 replies | 25928 view(s)
  • mjs513's Avatar
    05-15-2020, 04:28 PM
    Sorry for the late reply- I had to change it to all caps, i.e, MTP.h
    297 replies | 37516 view(s)
  • mjs513's Avatar
    05-15-2020, 04:25 PM
    With some more hacking I managed to getting working from a library just as a quick and dirty test. Anyway seems to have worked. I replace malloc with malloc_extmem and that crazy graphics sketch worked. The issue...
    9 replies | 202 view(s)
  • mjs513's Avatar
    05-15-2020, 03:28 PM
    Tried it @KurtE's ILI9341_t3n lib and the ILI9488 lib by setting the framebuffer to use - DMAMEM uint16_t tft_frame_buffer; Seems to working with no issues with and doing some heavy graphics stuff.
    32 replies | 836 view(s)
More Activity
About mjs513

Basic Information

About mjs513
Location:
New York
Interests:
Robotics, Image Processing
Occupation:
Aerospace Eng (Retired)

Statistics


Total Posts
Total Posts
5,103
Posts Per Day
2.37
Last Post
MTP Responder for SPIFFS Today 11:26 AM
General Information
Last Activity
Today 03:14 PM
Join Date
07-01-2014