![]() |
Forum Index : Microcontroller and PC projects : PicomiteWEB Web File Manger
![]() ![]() |
|||||
Author | Message | ||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
This the latest version of the Pico File Manager I am running the Pico at 250MHz and currently a19 Lessons I have learnt so far: It is possible to crash the server. My method is to connect using a tablet with WiFi turned off to force connections by the WWW. I can then request a large file and turn the tablet off part way through the download. To prevent a total shutdown, I use WATCHDOG 10000 at the start of the BAS program. 10 seconds is long enough for a busy server to not time out with normal use and allows time for me to ^C to get out of any reboot loop. OPTION AUTORUN ON is also required. I prefer to enter this at the command-line, not in the program. If you allow users to change directory, you will loose sight of the fm.html file and any other request for files in the original directory. At a minimum, you need to include fm.html in all folders that can be changed to so you can navigate back. When making the file list, I put a space character at the start of the directory entries to force then to the top if you elect to sort the list. I do my sort with case ignored. fm.zip Jim VK7JH MMedit |
||||
TheMonkeys![]() Regular Member ![]() Joined: 15/12/2022 Location: AustraliaPosts: 59 |
Hi Jim, An interesting little problem. My page seems to terminate early. makelist completes correctly, but the rest of the page goes missing. I added a file count to the end, but after the last file in the list (16)... nothing. In my subdir (2 files), it works fine. The only difference between my makelist and yours is that I tell mine which directory to read, meaning that fm.piml works everywhere. apart from that, I love your work. (my Asyncronous HTTP Request version to come). Cheers, Chris. |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
Hi Chris, I had problems similar to yours with an earlier alpha. The current a19 running at 250MHz seems OK. I have made one change. I changed the default page served when no page is called for to put web-crawlers off a bit. const html_def$ = "notfound.html" ' default landing page Not a problem if you are not exposed to the nasty world. Jim VK7JH MMedit |
||||
TheMonkeys![]() Regular Member ![]() Joined: 15/12/2022 Location: AustraliaPosts: 59 |
133MHz here, perhaps time to try second gear ![]() I have two other servers that do cop the odd scam/n. on one of them, I have a url re-direct to a porn site. They don't seem to come back after that. Chris. |
||||
![]() ![]() |
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |