Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 15:25 04 May 2024 Privacy Policy
Jump to

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 : Armmite - STM32H7: Developments

     Page 9 of 11    
Author Message
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 03:41pm 10 Aug 2018
Copy link to clipboard 
Print this post

Just rewired my own daughter board to use sdcard as SPI and the loadimage fault is the same as your daughter board using latest Armmite issue. This eliminates a board fault and anyhow gui test lcdpanel works flawlessly.

I feel it's got to be SPI probs at my end although I realise yours and Tassyjim's seem to be OK.

I'm lost!!!!

Trevor.


 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 03:54pm 10 Aug 2018
Copy link to clipboard 
Print this post

Have you got some other cards you can try?

The attached has the SDcard access slowed down from 19.2MHz to 16MHz

2018-08-11_015332_Armmite1.3.zip

 
gadgetjack
Senior Member

Joined: 15/07/2016
Location: United States
Posts: 127
Posted: 08:44pm 10 Aug 2018
Copy link to clipboard 
Print this post

Try decreasing color count to 256 with same resolution as your panel. Sounds like
the problems I was having. Just a thought.
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 11:46pm 10 Aug 2018
Copy link to clipboard 
Print this post

Got it, Load image can't load a file bigger than 320x240pixels.

Trevor.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 07:22am 11 Aug 2018
Copy link to clipboard 
Print this post

  Quote  Got it, Load image can't load a file bigger than 320x240pixels.


It can, I load images 800x480 all the time. This suggests that your images are different in some way. Please try the following:

Set up a ili9341 display
Load an image 320x240 and confirm it works OK
Load an image 800x480 - you should see the top left 320x240 part of the image without any issues.

If this doesn't work send me a PM with your email address and I'll send you one of my working 800x480 images and you can send me one of your broken ones
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 11:43am 11 Aug 2018
Copy link to clipboard 
Print this post

Hi Peter,

the SD card slot on the ILI9341 doesn't respond so unable to test that way, but I have something curious on the SSD1963 display.
All bmps up to 340x2** load perfectly OK, 342x228 it loads half a picture from bottom up then trashes the rest.
345x230 loads quarter of pic then trashes, 350x233 loads about eighth and then goes wrong, anything bigger it fails completely.
I am using the same bmp picture each time resized in Irfanview.

I don't know why the sd card in small display is playing up(checked all conns and soldering).

I have noticed that some programs produce 'Different' BMP files which is why I use Irfanview.

Trevor.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 12:05pm 11 Aug 2018
Copy link to clipboard 
Print this post

Please try the following:

Create something on the display using standard graphics and text commands. You can use the following which is the GUI TEST LCDPANEL algorithm:


Option explicit
option default NONE
dim t%, i%, x%, y%, r%, red%, green%, blue%, c%
t% = MM.HRES \ 7
timer=0
for i%=1 to 1000
x%= rnd()*10000 MOD MM.HRES
y%= RND()*10000 MOD MM.VRES
r%= RND()*10000 mod t% + t%\5
red%= RND()*255
green%= RND()*255
blue%= rnd()*255
c%= (red%<<16) + (green%<<8) + blue%
circle x%,y%,r%,1,,rgb(black),c%
next i%
text mm.hres\2, mm.vres\2,"Completed in "+STR$(timer/1000)+" Seconds",CM,2,2,rgb(white),-1
end



save the image - SAVE IMAGE "TEST"
CLS
load the image - LOAD IMAGE "TEST"

report the result

Edited by matherp 2018-08-12
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 12:53pm 11 Aug 2018
Copy link to clipboard 
Print this post

It loads a corrupted image.
The image on the SD card is OK when viewed on PC.

Trevor.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 01:09pm 11 Aug 2018
Copy link to clipboard 
Print this post

Please try attached V5.04.28 and report findings. I found an SDcard which wouldn't work on the Armmite but would on the MMX and have made some changes to make it work on the Armmite. These shouldn't have been necessary but suggest some cards have flaws in continuous reading even when the read rate is below the official specification

2018-08-12_044808_Armmite1.3.zip Edited by matherp 2018-08-13
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 02:26pm 12 Aug 2018
Copy link to clipboard 
Print this post

Hi Peter,

that has had no effect. I think I need to summarise findings.

Edit:-I have just dug out a PNY 2gb card and tried that, "SD card not present"

The sandisk SD cards I use work with everything else I have used (Arduino,Teensy,Micromite,E100,Mikroelectronica) even worked flawlessly with the previous 4bit SD incarnation on the Armmite for ME anyway.

The only other 'unknown' is the displays, but these also work with other platforms
including Micromite but the ILI9341 (A Quality display) still fails to load bigger pictures on the Armmite.

Dare I ask?? Would it be possible to have 4bit interface as well as SPI (one cancelling the other if chosen?

This still leaves Touch problems unanswered (maybe these Sainsmart displays do have a touch problem, the Arduino camp think so).

Trevor.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 03:20pm 12 Aug 2018
Copy link to clipboard 
Print this post

  Quote  Dare I ask?? Would it be possible to have 4bit interface as well as SPI (one cancelling the other if chosen?


Not really possible. Can you loan me a card and a display so I can try and get to the bottom of the problem(s)?Edited by matherp 2018-08-14
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 03:30pm 12 Aug 2018
Copy link to clipboard 
Print this post

I can do that. Tell me what you need exactly and PM me with details.

PS I have strapped up the existing SD card to be SPI and is now working (still with existing probs).

Trevor.Edited by TrevorH 2018-08-14
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 03:56pm 12 Aug 2018
Copy link to clipboard 
Print this post

Just to be clear, I have been using the back of display SD card slots which work fine apart from the loading probs and have now altered the daughter board to enable the SD slot on it to use SPI.

OK??

Trevor.

Will get my 5" and a card posted in the morning
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 10:13am 13 Aug 2018
Copy link to clipboard 
Print this post

Just had a thought, are these problems happening because our Nucleo boards are different?

You said:-
  Quote  Note the full set of shorting links I have removed is as follows:

JP4, SB13, SB160, JP6, SB127, SB125, SB164, SB178, SB181, JP7, SB183, SB182


Is this still the case or is there more we have forgotten?

Trevor.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 11:47am 14 Aug 2018
Copy link to clipboard 
Print this post

Your card and display arrived safely and the news is good or bad depending on how you look at it

The display and SD card work perfectly on my Nucleo and daughter card. Suggest you look at things like power supply, common ground between supply and USB etc.



The touch implementation on the Sainsmart seems to be a problem. The issue is noise on T_IRQ which looks like a mechanical switch bouncing. What they have done I have no idea. However, I have put some software debouncing into the calibration code without impacting normal operation and this makes it just about workable

2018-08-14_214613_Armmite1.3.zip






Edited by matherp 2018-08-15
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 03:50pm 14 Aug 2018
Copy link to clipboard 
Print this post

Hi Peter,

just done a bit of testing with the new issue 28, and pictures load perfectly now, BUT touch appears to no longer work.

If I run calibrate, message and top left corner appears but when touched nothing happens (actually T_IRQ drops when touched but program doesn't move on).

So what did you do??

PS I have done nothing to my set up here to get these results.

Trevor.Edited by TrevorH 2018-08-16
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 04:11pm 14 Aug 2018
Copy link to clipboard 
Print this post

Press each calibration point for about a second and the point should then step on.
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 04:14pm 14 Aug 2018
Copy link to clipboard 
Print this post

Tried holding it for up 5 seconds, no joy.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8592
Posted: 05:50pm 14 Aug 2018
Copy link to clipboard 
Print this post

Eureka - I hope

All Armmite H7 users

Please download and install ST-LINK and use it to program the Nucleo rather than STM32CubeProgrammer.

It takes a little longer but it correctly programs the chip. My uploads are all done through the development environment which uses ST-LINK. I've just tested the most recent posted binary with both STM32CubeProgrammer and ST-LINK and it only works properly with when programmed with ST-LINK.

I suspect that STM32CubeProgrammer is missing one of the flash pages or something similar.

Trevor - please tell me this sorts things for you
 
TrevorH
Senior Member

Joined: 06/04/2018
Location: United Kingdom
Posts: 142
Posted: 08:47pm 14 Aug 2018
Copy link to clipboard 
Print this post

I have found my Stupid mistake with the touch, I was setting touch to 114,115 instead of 56,123, which is why it was totally unresponsive,

Right back to business, pictures load on small and large screen as they should.

Touch now works but not 100%, I still get calibration error of x=49ish and y=98ish,
it varies on different runs but only by a few pixels, so it IS better.

I've also tried loading elfs with cube and hex with ST-Link with no noticeable difference.

I think we have moved forward.

My only other displays are CPLD Controller displays(these are NOT Sainsmart),
as this only requires the simplest of setup, could we have a driver that utilises the SSD1963 backroom routines (ie Write_CMD_DATA, DrawRectangle and DrawBitmap).
The connections and requirements are identical. Would need couple of extras to deal with paging.
I have them working in Basic but can't test touch because of "LCDpanel not configured" error.
I did get CFunctions to work with the E100.

Trevor.
 
     Page 9 of 11    
Print this page
© JAQ Software 2024