Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.
|
Forum Index : Microcontroller and PC projects : using a macbook pro
Page 3 of 3 | |||||
Author | Message | ||||
macmite Newbie Joined: 12/09/2023 Location: AustraliaPosts: 23 |
Hi, Why can't I copy a file to the SDCard? The sd card is FAT16 and empty. > files A:/ <DIR> . <DIR> .. 00:00 01-01-2000 4 bootcount 00:23 05-10-2023 54852 bu1retic.bas 00:07 01-01-2000 7381 config.html 00:08 01-01-2000 6739 index.html 00:17 25-09-2023 48934 newretic.bas 23:56 24-09-2023 36 picotest1.bas 00:55 05-10-2023 54904 retic.bas 00:08 01-01-2000 48934 sc_retic.bas 15:42 15-09-2023 766 settings.dat 00:08 01-01-2000 6880 setup.html 2 directories, 10 files, 368640 bytes free > copy a2b "A:/retic.bas" to "B:/retic.bas" Error : SD Card not found > option list WebMite MMBasic Version 5.07.07 OPTION WIFI xTimeCapsule, ************* OPTION TCP SERVER PORT 80 OPTION TELNET CONSOLE ON OPTION SDCARD GP9, GP14, GP15, GP12 OPTION COUNT GP10,GP6,GP7,GP8 > Connection closed by foreign host. mack@macmini2018 ~ % telnet 192.168.100.176 23 Trying 192.168.100.176... Connected to webmite.fritz.box. Escape character is '^]'. > mm.info$(sdcard) Error : Unknown command > MM.INFO$(CARD) Error : Unknown command > print MM.INFO$(SDCARD) Ready > CHDIR "B:" Error : Only valid on current drive > drive "B:" > files Error : SD Card not found > |
||||
phil99 Guru Joined: 11/02/2018 Location: AustraliaPosts: 2135 |
Is this on a breadboard? If so check continuity of all connections from the top of the Pico pins to the top of the SD module pins. Plenty of people have had issues with breadboard connections. Some SD cards are very fussy about the power supply, as they can draw high peak current causing the voltage to dip too low. Some have found 100uF from 3.3V to Gnd. fixes it. Others use a 10uF ceramic cap soldered directly to the SD socket pins and a 2.2 ohm resistor in series with the 3.3V supply to the socket helps. The resistor prevents voltage dips affecting the Pico. If you have cards from a variety of manufacturers try them all. Some are less fussy about the voltage than others. |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6798 |
Can you rule out that the SD card pins aren't used by the wi-fi? Is this problem only with the console connected via telnet? Can you test the SD card (and preferably the same connector) on a non-wi-fi Pico? Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
JohnS Guru Joined: 18/11/2011 Location: United KingdomPosts: 3802 |
You need PRINT (or ?) or similar. That's it. That suggests the MM.INFO$(...) returned little or nothing. John |
||||
macmite Newbie Joined: 12/09/2023 Location: AustraliaPosts: 23 |
Hi, I have changed the CS pin but the same result. Option list shows no GPxx used by wifi. Wiring is gold plated silicon dupont connectors. I have not used this particular 3.3V SD device previously so perhaps it is ???. I will now try a 100uF cap. This is before a 100uF cap mack@macmini2018 ~ % telnet 192.168.100.176 23 Trying 192.168.100.176... Connected to webmite.fritz.box. Escape character is '^]'. > OPTION SDCARD GP13,GP14,GP15,GP12 Error : SDcard already configured > option list WebMite MMBasic Version 5.07.07 OPTION WIFI xTimeCapsule, ************* OPTION TCP SERVER PORT 80 OPTION TELNET CONSOLE ON OPTION SDCARD GP13, GP14, GP15, GP12 OPTION COUNT GP10,GP6,GP7,GP8 > save "B:/retic.bas" Error : A hard error occurred in the low level disk I/O layer > |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6798 |
Looks like the SD card system is configuring ok. Does this work? drive "b: files You may have a bad card. It has to be 32GB or less in capacity and formatted to FAT 16 or FAT 32. Also, what SD card socket are you using? Some include series resistors and/or a voltage regulator and those rarely work properly. Edited 2023-10-08 00:48 by Mixtel90 Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
JohnS Guru Joined: 18/11/2011 Location: United KingdomPosts: 3802 |
I see he posted that the latter fails. John |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6798 |
Oh yes.... The trouble is that I can't really help here as I don't have a mac or a Webmite. Others seem to have used SD cards with the Webmite so I can only assume it's a fault with the SD card, it's socket or the fact that the console is via telnet (or in the way the mac is using it). Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
macmite Newbie Joined: 12/09/2023 Location: AustraliaPosts: 23 |
Hi, 100uf cap 3.3V to Gnd on SD board does not change the hard error. I have tried a couple of SD card modules including both at 5V (the modules have a 3.3/5V level shifter built in) The 256MB FAT16 SD card works ok on my Mac (using a SD card reader). Sometimes I can get a response from B: using FILES. Once I was able to LOAD a 36byte .bas file from the B: and run it but usually I get Error : A hard error occurred in the low level disk I/O layer What exactly is the error? I have also reformatted the SD card. Does the 5V input to the SD reader need a 100uF cap? > files A:/ <DIR> . <DIR> .. 00:00 01-01-2000 4 bootcount 00:23 05-10-2023 54852 bu1retic.bas 00:07 01-01-2000 7381 config.html 00:08 01-01-2000 6739 index.html 00:17 25-09-2023 48934 newretic.bas 23:56 24-09-2023 36 picotest1.bas 00:55 05-10-2023 54904 retic.bas 00:08 01-01-2000 48934 sc_retic.bas 15:42 15-09-2023 766 settings.dat 00:08 01-01-2000 6880 setup.html 2 directories, 10 files, 368640 bytes free > B: > files B:/ 13:32 20-09-2023 36 PICOTES2.BAS 31:63 31-15-2107 -1 ???????X. 0 directories, 2 files > files B:/ 13:32 20-09-2023 36 PICOTES2.BAS 31:63 31-15-2107 -1 ???????X. 0 directories, 2 files > load " picotes2.bas" Error : Could not find the file > files B:/ 13:32 20-09-2023 36 PICOTES2.BAS 31:63 31-15-2107 -1 ???????X. 0 directories, 2 files > load "PICOTES2.BAS" > run 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 > files B:/ 13:32 20-09-2023 36 PICOTES2.BAS 31:63 31-15-2107 -1 ???????X. 0 directories, 2 files > A: > load "retic.bas" > save "B:/retic.bas" Error : A hard error occurred in the low level disk I/O layer > save "B:/RETIC.BAS" Error : SD Card not found > files A:/ <DIR> . <DIR> .. 00:00 01-01-2000 4 bootcount 00:23 05-10-2023 54852 bu1retic.bas 00:07 01-01-2000 7381 config.html 00:08 01-01-2000 6739 index.html 00:17 25-09-2023 48934 newretic.bas 23:56 24-09-2023 36 picotest1.bas 00:55 05-10-2023 54904 retic.bas 00:08 01-01-2000 48934 sc_retic.bas 15:42 15-09-2023 766 settings.dat 00:08 01-01-2000 6880 setup.html 2 directories, 10 files, 368640 bytes free > B: > files Error : SD Card not found > telnet> ^C mack@macmini2018 ~ % |
||||
matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 9122 |
My bet would be on power supply. The card is mounting OK when SPI is clocked slowly but can't be read or written at normal speed. Either that or the usual issues with series resistors/pullups/level changers etc. but we haven't been given enough info to really help Edited 2023-10-08 02:05 by matherp |
||||
macmite Newbie Joined: 12/09/2023 Location: AustraliaPosts: 23 |
I am now using the VBUS pin on the pico W to power the SD reader. ie direct from a 12W USB PSupply but it still gives the "hard error" so it is still a mystery. |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6798 |
I'd suggest that you don't even consider using a SD socket that isn't a straight-through one. Not unless you can find someone who has been using the same module with a PicoMite successfully anyway. SD cards are all 3V3 and will connect directly to a Pico without regulators or level shifters. You are asking the level shifter to work with a 3V3 input and output, which may not be stable. Edited 2023-10-08 02:50 by Mixtel90 Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
macmite Newbie Joined: 12/09/2023 Location: AustraliaPosts: 23 |
Hi The SD readers which I initially used were used with Arduinos to write one text string at a time to a .CSV file. I am now using a new SD reader which has no inbuilt level shifters. Powered by 3.3V from the pico W and no 100uF cap. It now works correctly. Thanks matherp for your comments. > B: > files B:/ 13:32 20-09-2023 36 picotest1.bas 0 directories, 1 file > load "picotest1.bas" > run 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 > A: > files A:/ <DIR> . <DIR> .. 00:00 01-01-2000 4 bootcount 00:23 05-10-2023 54852 bu1retic.bas 00:07 01-01-2000 7381 config.html 00:08 01-01-2000 6739 index.html 00:17 25-09-2023 48934 newretic.bas 23:56 24-09-2023 36 picotest1.bas 00:55 05-10-2023 54904 retic.bas 00:08 01-01-2000 48934 sc_retic.bas 15:42 15-09-2023 766 settings.dat 00:08 01-01-2000 6880 setup.html 2 directories, 10 files, 368640 bytes free > B: > files B:/ 13:32 20-09-2023 36 picotest1.bas 0 directories, 1 file > A: > load "retic.bas" > B: > save "retic.bas" > files B:/ 13:32 20-09-2023 36 picotest1.bas 00:02 01-01-2000 54904 retic.bas 0 directories, 2 files > |
||||
Page 3 of 3 |
Print this page |