Menu
JAQForum Ver 19.10.27

Forum Index : Microcontroller and PC projects : Waveshare Pico Toys

   Page 5 of 5    
Posted: 07:54am
07 Dec 2021
Copy link to clipboard
matherp
Guru

  Quote  I was not able to get anything except of white/black screen on PicoMite MMBasic V5.07.00  


Correct set up for this display is:


OPTION SDCARD GP22
OPTION SYSTEM SPI GP10,GP11,GP12
OPTION LCDPANEL ILI9488W, LANDSCAPE,GP8,GP15,GP9,GP13
OPTION TOUCH GP16,GP17
GUI CALIBRATE 0, 3946, 211, -1287, 853


Works perfectly on V5.07.01. For all displays with multiple things on the SPI bus you MUST enable all of them
 
Posted: 02:45pm
08 Dec 2021
Copy link to clipboard
Volhout
Guru

I looked at the waveshare pico toys, and stumbled upon this "beauty".

https://www.waveshare.com/pico-relay-b.htm

Bad thing, it has no inputs, only outputs, but more important:

There is a design fault in this box. There is an isolated powersupply (5V 1watt) that powers the relays. But these consume 0.36W each. So if you switch on more that 3 relays you will run out of power.
Edited 2021-12-09 00:48 by Volhout
 
Posted: 03:40pm
08 Dec 2021
Copy link to clipboard
darthvader
Regular Member

  matherp said  
  Quote  I was not able to get anything except of white/black screen on PicoMite MMBasic V5.07.00  


Correct set up for this display is:


OPTION SDCARD GP22
OPTION SYSTEM SPI GP10,GP11,GP12
OPTION LCDPANEL ILI9488W, LANDSCAPE,GP8,GP15,GP9,GP13
OPTION TOUCH GP16,GP17
GUI CALIBRATE 0, 3946, 211, -1287, 853


Works perfectly on V5.07.01. For all displays with multiple things on the SPI bus you MUST enable all of them


To be able to use SDCard i was to be more specific on the option  

OPTION SDCARD GP22, GP5, GP18, GP19


Cheers.
 
Posted: 12:57pm
31 Dec 2021
Copy link to clipboard
Kabron
Regular Member


  darthvader said  
To be able to use SDCard i was to be more specific on the option  

OPTION SDCARD GP22, GP5, GP18, GP19


Cheers.

Only in case if you change JUMPERS H1-H6 to position B SDIO.
Default settings A SPI.
 
Posted: 02:19pm
31 Dec 2021
Copy link to clipboard
Kabron
Regular Member


Something wrong happened with SDCARD on my Picomites with WaveShare 3.5 touch board.

As could be seen from the logic capture, at least 2 strange things observed:
1. Clock begins far before CS
2. Clock frequency is 25 kHz
3. No MOSI activity

All works fine before. Now the same problem on two Picomites,
regardless FW version.

LCD and TOUCH works fine.




Edited 2022-01-01 00:24 by Kabron
 
Posted: 06:29pm
31 Dec 2021
Copy link to clipboard
Volhout
Guru

Try cpu speed 126Mhz.
 
Posted: 06:39pm
31 Dec 2021
Copy link to clipboard
matherp
Guru

  Quote  1. Clock begins far before CS
2. Clock frequency is 25 kHz
3. No MOSI activity


This is completely correct

STATUS disk_initialize (
BYTE pdrv /* Physical drive nmuber (0) */
)
{
BYTE n, cmd, ty, ocr[4];


if (pdrv != 0) return STA_NOINIT; /* Supports only single drive */
SD_SPI_SPEED=SD_SLOW_SPI_SPEED;
SPISpeedSet(SDSLOW);
deselect(); /* Initialize memory card interface */
for (n = 10; n; n--) xchg_byte(0xFF); /* 80 dummy clocks */
ty = 0;

if (send_cmd(CMD0, 0) == 1) { /* Enter Idle state */
Timer1 = 1000; /* Initialization timeout of 1000 msec */
if (send_cmd(CMD8, 0x1AA) == 1) { /* SDv2? */
for (n = 0; n < 4; n++) ocr[n] = xchg_byte(0xFF); /* Get trailing return value of R7 resp */

if (ocr[2] == 0x01 && ocr[3] == 0xAA) { /* The card can work at vdd range of 2.7-3.6V */
while (Timer1 && send_cmd(ACMD41, 0x40000000)); /* Wait for leaving idle state (ACMD41 with HCS bit) */
if (Timer1 && send_cmd(CMD58, 0) == 0) { /* Check CCS bit in the OCR */
for (n = 0; n < 4; n++) ocr[n] = xchg_byte(0xFF);
ty = (ocr[0] & 0x40) ? CT_SD2|CT_BLOCK : CT_SD2; /* SDv2 */
}
}
} else { /* SDv1 or MMCv3 */
if (send_cmd(ACMD41, 0) <= 1) {
ty = CT_SD1; cmd = ACMD41; /* SDv1 */
} else {
ty = CT_MMC; cmd = CMD1; /* MMCv3 */
}
while (Timer1 && send_cmd(cmd, 0)); /* Wait for leaving idle state */
if (!Timer1 || send_cmd(CMD16, 512) != 0) /* Set read/write block length to 512 */
ty = 0;
}
}
CardType = ty;
deselect();
if (ty) { /* Function succeded */
SDCardStat &= ~STA_NOINIT; /* Clear STA_NOINIT */
SD_SPI_SPEED=Option.SDspeed*1000000;
SPISpeedSet(SDFAST);
}

return SDCardStat;
}

Edited 2022-01-01 04:42 by matherp
 
Posted: 09:46pm
31 Dec 2021
Copy link to clipboard
phil99
Guru


Is this a problem with all SD cards or just one? One of mine responds with "SD card not found" the first time you type FILES but works perfectly thereafter.
Is an iffy plug/solder connection a possibility?
 
Posted: 10:29pm
31 Dec 2021
Copy link to clipboard
Kabron
Regular Member


  matherp said  

This is completely correct


Too complicate for my simple mind.
You mean that is the goal reached?
 
Posted: 10:30pm
31 Dec 2021
Copy link to clipboard
Kabron
Regular Member


  Volhout said  Try cpu speed 126Mhz.

Ofcourse I tryed.
 
Posted: 10:31pm
31 Dec 2021
Copy link to clipboard
Kabron
Regular Member


  phil99 said  Is this a problem with all SD cards or just one? One of mine responds with "SD card not found" the first time you type FILES but works perfectly thereafter.
Is an iffy plug/solder connection a possibility?

No matter.
 
Posted: 11:39pm
31 Dec 2021
Copy link to clipboard
Kabron
Regular Member


And if
  Quote  This is completely correct

why SD card not found?
 
Posted: 08:29am
01 Jan 2022
Copy link to clipboard
matherp
Guru

  Quote  why SD card not found?


Not sure what we can suggest. You state

  Quote  Something wrong happened with SDCARD on my Picomites with WaveShare 3.5 touch board.
All works fine before. Now the same problem on two Picomites,
regardless FW version.


The key is that it no longer works with any firmware. Are you using the same Waveshare board for your tests? Perhaps there is a dry joint or the SD card socket contacts are damaged


 
Posted: 10:18pm
22 Jun 2022
Copy link to clipboard
pwillard
Senior Member

Same issue here.
Everything works but the SDCARD on the PICO-RESTOUCH-LCD 3.5

SD Card not found

I thought I read the options right...

OPTION SYSTEM SPI GP10,GP11,GP12
OPTION SYSTEM I2C GP6,GP7
OPTION LCDPANEL ILI9488W, LANDSCAPE,GP8,GP15,GP9,GP13
OPTION TOUCH GP16,GP17
GUI CALIBRATE 0, 3985, 275, -1278, 881
OPTION SDCARD GP22, GP5, GP18, GP19
 
Posted: 05:54am
23 Jun 2022
Copy link to clipboard
BishopXXL
Newbie

Hi pwillard,

this work´ for me.....

-------- Waveshare 3.5 Touch Display + SDCARD
OPTION SYSTEM SPI GP10,GP11,GP12
OPTION COLOURCODE ON
OPTION DISPLAY 40, 140
OPTION LCDPANEL ILI9488W, LANDSCAPE,GP8,GP15,GP9,GP13
OPTION TOUCH GP16,GP17
GUI CALIBRATE 0, 3993, 232, -1275, 848
OPTION SDCARD GP22

BishopXXL
 
Posted: 06:20am
23 Jun 2022
Copy link to clipboard
Kabron
Regular Member


Try to play with series resistors in SD signals paths.
 
Posted: 06:27am
23 Jun 2022
Copy link to clipboard
Mixtel90
Guru


Tried a new SD card?
(Don't be tempted to use a high capacity one - MMBasic has sensible limits! And be wary of very cheap cards on ebay as you might end up with 256k having paid for 16GB)


Handy note - but max size for MMBasic is 32GB
When you format a card be careful. Windows 10 will, by default, format cards bigger than 32GB as exFAT, which is a Microsoft special and is no good for some things. You have to either format from command line or use an external program to force a format to extended FAT32. I usually use rufus, but there are others.
 
Posted: 08:16am
23 Jun 2022
Copy link to clipboard
matherp
Guru

AFAIK extended FAT32 works by increasing the block size from 512bytes. This is not supported by the PicoMite firmware/FatFS so the maximum card size supported by the PicoMite is 32GB in standard FAT32
Edited 2022-06-23 18:17 by matherp
 
Posted: 11:13am
23 Jun 2022
Copy link to clipboard
pwillard
Senior Member

Will try a smaller card.  Was using 16GB though.  and... 4GB Fat32... "Error: SD Card not found"  :(

FYI: I use a PUTTY terminal variant called PUTTY-ND that understands that USB COM PORTS can go away and come back.  It says "fatal error" when the pico resets... then says "trying to restart session" and then... without you doing anything else... you hit the ENTER key and you are back on the PICO command prompt.  It can save some steps... when using PUTTY.  The new TERATERM version 5 alpha handles this ok as well.  So, Update your terminal software... :)


And then... for reasons unknown... it just started working. I can see files.
Edited 2022-06-23 21:50 by pwillard
 
Posted: 02:35pm
24 Aug 2022
Copy link to clipboard
pwillard
Senior Member

dang it.  It's always something.

I finally started to mess with screen brightness on the waveshare pico-res-touch-3.5 and I am using the setting:

  Quote  OPTION LCDPANEL ILI9488W, LANDSCAPE,GP8,GP15,GP9,GP13


But issuing a

  Quote  BACKLIGHT 10
seems to have no effect and I expected the BL to dim.


OH GEEZE!  Nevermind... it matters *WHERE* in your code you issue the BACKLIGHT command.
Edited 2022-08-25 00:37 by pwillard
 
   Page 5 of 5    


To reply to this topic, you need to log in.

© JAQ Software 2024