Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 00:47 10 May 2025 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 : PicoMite V6.00.02 release candidates - all versions

     Page 43 of 44    
Author Message
dddns
Senior Member

Joined: 20/09/2024
Location: Germany
Posts: 259
Posted: 04:10pm 07 May 2025
Copy link to clipboard 
Print this post

Exactly what I ment and I'm using just a simple cat file.bas > /dev/ttyACM0
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10066
Posted: 04:13pm 07 May 2025
Copy link to clipboard 
Print this post

See my updated previous post. I despise Linux so can't help with that
 
dddns
Senior Member

Joined: 20/09/2024
Location: Germany
Posts: 259
Posted: 04:15pm 07 May 2025
Copy link to clipboard 
Print this post

:) Anyway, thank you!

Eureka - works like a charm.
Edited 2025-05-08 03:18 by dddns
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10066
Posted: 05:41pm 07 May 2025
Copy link to clipboard 
Print this post

V6.00.02RC23 is available on

https://geoffg.net/Downloads/picomite/PicoMite_Beta.zip

Fixes editor showing a hidden line when editing a file loaded from disk with continuation lines enabled

Changes AUTOSAVE command to circumvent a caching issue when PSRAM is enabled

Checks incoming line length in AUTOSAVE and aborts the load if a line exceeds 255 characters

Implements driver for ST7796S based 4-wire SPI displays. See here
 
bfwolf
Regular Member

Joined: 03/01/2025
Location: Germany
Posts: 72
Posted: 08:09pm 07 May 2025
Copy link to clipboard 
Print this post

  dddns said  Exactly what I ment and I'm using just a simple cat file.bas > /dev/ttyACM0


I think "simple copying" with "cat file.bas > /dev/ttyACM0" actually overwhelms PicoMite. The data has to go through the tokenizer and then be saved to flash. I already had problems when I tried to transfer a short text (Basic) from TeraTerm to PicoMite via the clipboard. Only garbage ended up in memory. Only after I set a character delay of a few ms and an additional line delay of about 50 ms in TeraTerm did it work without errors.
Unfortunately, like many other terminal programs, you can't set a "wait for <char> at the end of the line" option in TeraTerm. I once had a terminal program (I think under Windows 3.x) that allowed you to do that. If you set the "prompt" character, it worked perfectly even without the character delay.

bfwolf
 
homa

Guru

Joined: 05/11/2021
Location: Germany
Posts: 459
Posted: 08:52pm 07 May 2025
Copy link to clipboard 
Print this post

  matherp said  V6.00.02RC23 is available on

https://geoffg.net/Downloads/picomite/PicoMite_Beta.zip

Fixes editor showing a hidden line when editing a file loaded from disk with continuation lines enabled

Changes AUTOSAVE command to circumvent a caching issue when PSRAM is enabled

Checks incoming line length in AUTOSAVE and aborts the load if a line exceeds 255 characters

Implements driver for ST7796S based 4-wire SPI displays. See here


Hi Peter,

the no screen at startup error behaviour is back. Only a >mode1 or >edit helps. Does the pico really have to be deleted again with the clear-flash tool?

Matthias


> mode 1
> option list
PicoMiteHDMI MMBasic USB RP2350A Edition V6.00.02RC23
OPTION SERIAL CONSOLE COM2,GP8,GP9
OPTION SYSTEM I2C GP20,GP21
OPTION FLASH SIZE 4194304
OPTION COLOURCODE ON
OPTION CONTINUATION LINES ON
OPTION KEYBOARD GR
OPTION RESOLUTION 640x480 @ 315000KHz
OPTION DEFAULT MODE 0
OPTION SDCARD GP22, GP26, GP27, GP28
OPTION AUDIO GP10,GP11', ON PWM CHANNEL 5
OPTION RTC AUTO ENABLE
OPTION MODBUFF ENABLE  192
OPTION PLATFORM HDMIUSB
>
 
homa

Guru

Joined: 05/11/2021
Location: Germany
Posts: 459
Posted: 09:33pm 07 May 2025
Copy link to clipboard 
Print this post

okay, I'll answer myself for once ... clear_flash.uf2 ... has helped!
 
mozzie
Senior Member

Joined: 15/06/2020
Location: Australia
Posts: 109
Posted: 09:39pm 07 May 2025
Copy link to clipboard 
Print this post

G'day,

Volhout, hopefully this will help to diagnose your Wii controller / I2C issue.
I do not have a Wii controller but a PICOmite thats pretending it is one.

Peter, not sure if you are already working on this, you did mention a possible problem with the SDK...
I think there may be a problem with the background or transfer software for the Wii I2C system. It seems the I2C return data from the Wii is working its way up through memory until it over-writes something terminal.
Please see the photo below, the "WII" is incrementing byte 2 in the return variable and it is there in the pixel data, return data is &h0A,&h40,&hXX,&h00,&hFF,&hFF
Possibly the array address is not being reset and is continuing to increment? this where it goes over my head...

This is the code running on a HDMIUSB V6.00.02rc23

Option default integer
Option explicit
Option console serial

Wii open
Timer = 0
CLS

Do
Print DEVICE(wii ry), MM.I2C, Int(Timer / 1000)
Text 0,0,Str$(Int(Timer/1000))
Pause 500
Loop

End

This is what is on the screen, the number in the corner is seconds from Program start:





The "data" appears first, then coloured tiles, then coloured bars before it locks up (Mode 1), this was different runs. Starts at top left and works across and down.

This is fom the "Wii" PICO, it shows the lock up at approx 20mins every time.

> run
A420 0101 Sent   0
started @ 02:34:44
failed @ 02:54:34
> run
A420 0101 Sent   0
started @ 02:54:55
failed @ 03:14:31
> run
A420 0101 Sent   0
started @ 03:14:55
failed @ 03:34:27
>

> option list
PicoMiteHDMI MMBasic USB RP2350A Edition V6.00.02RC23
OPTION SERIAL CONSOLE COM2,GP8,GP9
OPTION SYSTEM I2C GP20,GP21
OPTION FLASH SIZE 4194304
OPTION COLOURCODE ON
OPTION KEYBOARD US, 0, 0, 600, 150
OPTION RESOLUTION 720x400 @ 283200KHz
OPTION DISPLAY 33, 90
OPTION SDCARD GP22, GP26, GP27, GP28
OPTION AUDIO GP10,GP11', ON PWM CHANNEL 5
OPTION RTC AUTO ENABLE
OPTION PLATFORM HDMIUSB
>

Hopefully this provides some diagnostic information, rc20 and rc21 are same.

Thanks again for all the work you put in to this, it is much appreciated.

Regards,
Lyle.
 
mozzie
Senior Member

Joined: 15/06/2020
Location: Australia
Posts: 109
Posted: 11:41am 08 May 2025
Copy link to clipboard 
Print this post

G'day again,
Some further experimentation has shown the minimum to get the fault to occur:

> option list
PicoMiteHDMI MMBasic RP2350A Edition V6.00.02RC23
OPTION SYSTEM I2C GP0,GP1
OPTION FLASH SIZE 4194304
OPTION RESOLUTION 720x400 @ 283200KHz
OPTION DISPLAY 33, 90
OPTION HDMI PINS  1, 3, 5, 7
OPTION RTC AUTO ENABLE
>

RTC must be auto enabled and must exist, screen artifacts start around 940 seconds in.

Regards,
Lyle.
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4854
Posted: 12:08pm 08 May 2025
Copy link to clipboard 
Print this post

  mozzie said  G'day,

Volhout, hopefully this will help to diagnose your Wii controller / I2C issue.
I do not have a Wii controller but a PICOmite thats pretending it is one.

Peter, not sure if you are already working on this, you did mention a possible problem with the SDK...
I think there may be a problem with the background or transfer software for the Wii I2C system. It seems the I2C return data from the Wii is working its way up through memory until it over-writes something terminal.
Please see the photo below, the "WII" is incrementing byte 2 in the return variable and it is there in the pixel data, return data is &h0A,&h40,&hXX,&h00,&hFF,&hFF
Possibly the array address is not being reset and is continuing to increment? this where it goes over my head...

This is the code running on a HDMIUSB V6.00.02rc23

Option default integer
Option explicit
Option console serial

Wii open
Timer = 0
CLS

Do
Print DEVICE(wii ry), MM.I2C, Int(Timer / 1000)
Text 0,0,Str$(Int(Timer/1000))
Pause 500
Loop

End

This is what is on the screen, the number in the corner is seconds from Program start:





The "data" appears first, then coloured tiles, then coloured bars before it locks up (Mode 1), this was different runs. Starts at top left and works across and down.

This is fom the "Wii" PICO, it shows the lock up at approx 20mins every time.

> run
A420 0101 Sent   0
started @ 02:34:44
failed @ 02:54:34
> run
A420 0101 Sent   0
started @ 02:54:55
failed @ 03:14:31
> run
A420 0101 Sent   0
started @ 03:14:55
failed @ 03:34:27
>

> option list
PicoMiteHDMI MMBasic USB RP2350A Edition V6.00.02RC23
OPTION SERIAL CONSOLE COM2,GP8,GP9
OPTION SYSTEM I2C GP20,GP21
OPTION FLASH SIZE 4194304
OPTION COLOURCODE ON
OPTION KEYBOARD US, 0, 0, 600, 150
OPTION RESOLUTION 720x400 @ 283200KHz
OPTION DISPLAY 33, 90
OPTION SDCARD GP22, GP26, GP27, GP28
OPTION AUDIO GP10,GP11', ON PWM CHANNEL 5
OPTION RTC AUTO ENABLE
OPTION PLATFORM HDMIUSB
>

Hopefully this provides some diagnostic information, rc20 and rc21 are same.

Thanks again for all the work you put in to this, it is much appreciated.

Regards,
Lyle.


Hi Lyle,

Thanks for confirming. I have analyzed the I2C communication, and have to re-confirm that all I2C communication is sound. There is no corrupted packets, and the WII Classic response is consistent until the breakdown of the pico. I am testing on a 2040, and the problem shows after 9.2 minutes (between 9.3 and 9.1). Also with corrupted VGA screen.

I tend to agree with you that it looks like the I2C buffer is exceeding it's boundaries, and is writing into VGA screen memory, or some in between screen buffer (because in my case, 30 seconds before crash, there is a clear of the VGA screen, then the program runs fine for another 10 seconds, then corrupted data is shown on screen.)

Tonight I plan to run the program with display of mm.info(system heap) and mm.info(stack). I already know it is not heap, but I did not check system heap.

The RTC on auto mode, also accesses the same I2C bus. And I was afraid for a bus conflict. But in my testing it shows that the RTC is read after power up immediately, and then after 1 hour. But the system crashes at 9 minutes already, so I think that is not the issue here. But it could be something to verify anyway.

Volhout
Edited 2025-05-08 22:12 by Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10066
Posted: 12:12pm 08 May 2025
Copy link to clipboard 
Print this post

Try these

PicoMiteRP2040VGAV6.00.02RC23.zip

PicoMiteHDMIV6.00.02RC23.zip
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4854
Posted: 12:27pm 08 May 2025
Copy link to clipboard 
Print this post

Hi Lyle,

This is on a unit that does not have WII Classic connected.

I used a small program to read the EEPROM on the RTC board, fast enough so there is not enough time to squeeze a AUTO RTC update in between the gap. Just to verify if RTC read would corrupt the constant data transfer to the EEPROM. I had to wait for 1 hour, but then the (AUTO) RTC read happened.



The RCT command is simply embedded in the constant stream of I2C reads, and the details show that no corruption of the transfer takes place. That is good. MMBasic I2C transfer and RTC updates do not corrupt each other.



That does not give any guarantee for the timed interupt driven WII Classic polling, but this shows the AUTO RTC implementation is sound.

Volhout
Edited 2025-05-08 23:32 by Volhout
PicomiteVGA PETSCII ROBOTS
 
mozzie
Senior Member

Joined: 15/06/2020
Location: Australia
Posts: 109
Posted: 01:40pm 08 May 2025
Copy link to clipboard 
Print this post

G'day,
Volhout, a good scope is worth its weight in gold, and with auto-decode double its weight in gold. Everything there looking good  

Peter, happy to report the update to HDMI060002rc23 has now been running for 1.2hrs and no signs of trouble, it would reliably fail around 940 secs so I think that squashed it  

Thanks again.

Regards,
Lyle.
Edited 2025-05-08 23:44 by mozzie
 
Amnesie
Guru

Joined: 30/06/2020
Location: Germany
Posts: 529
Posted: 01:42pm 08 May 2025
Copy link to clipboard 
Print this post

Found another bug / problem:

ST7920 does not work (tried two displays, double checked wiring) If I list the options the display isn't listed at all, which is strange. Yes I tried it multiple times with OPTION RESET.

I used the exact same config as Peter in this thread:

https://www.thebackshed.com/forum/ViewTopic.php?FID=16&TID=17096

  Quote  
This version is tested and working. I think the garbage was because I was clocking the SPI bus too fast.

Connections as tested
GND - 1,15,20
5V - 2,19
GP0 - 4 (RS)
GP1 - 17 (RST)
GP6 - 6 (E)
GP7 - 5 (R/W)









Greetings
Daniel
Edited 2025-05-08 23:46 by Amnesie
 
Amnesie
Guru

Joined: 30/06/2020
Location: Germany
Posts: 529
Posted: 02:09pm 08 May 2025
Copy link to clipboard 
Print this post

On the ST7920 problem I can confirm it is a bug / error in the firmware, because I tested the firmware Peter posted on the above linked thread, which is for the Pico 1. And everything works on this (old!) version. So I think he broke something on the newer iterations...

Greetings
Daniel
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10066
Posted: 02:23pm 08 May 2025
Copy link to clipboard 
Print this post

clear flash and then install rc23 - then report
 
Amnesie
Guru

Joined: 30/06/2020
Location: Germany
Posts: 529
Posted: 02:40pm 08 May 2025
Copy link to clipboard 
Print this post

Yes that works now! Only problem: with the old RP2040 version it was possible to EDIT with font 8 (OPTION LCDPANEL CONSOLE).. now with the RP2350 RC23 it isn't possible anymore:

PicoMite MMBasic RP2350A Edition V6.00.02RC23
OPTION SYSTEM SPI GP6,GP7,GP4
OPTION FLASH SIZE 4194304
OPTION CPUSPEED (KHz) 150000
OPTION LCDPANEL CONSOLE 8,,,,NOSCROLL
OPTION DISPLAY 10, 32
OPTION LCDPANEL ST7920, LANDSCAPE,GP0,GP1
OPTION DEFAULT FONT 8, 1
>
>
>
> edit
Error : Font is too large

Greetings
Daniel
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4854
Posted: 06:51pm 08 May 2025
Copy link to clipboard 
Print this post

  matherp said  Try these

PicoMiteRP2040VGAV6.00.02RC23.zip

PicoMiteHDMIV6.00.02RC23.zip


Hi Peter,

The RP2040 VGA version works great. It has been running in the test for 1 hour, without problems, and I played 1 level of petrobot using the WII classic controller.
It tested several programs including logic analyzer and several larger games, chess, and all work with this version.

Only thing left is the thermal camera. But I am confident that will work also.

Thank you for staying with us, and fixing it.
I assume it was a memory leak after all, right ..?

Volhout

P.S. thanks Lyle. I really started to doubt myself. It was such a great relief someone could duplicate it.
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10066
Posted: 07:01pm 08 May 2025
Copy link to clipboard 
Print this post

  Quote  I assume it was a memory leak after all, right ..?


No, it was the RTC leaving a parameter set which should have been nulled
 
Amnesie
Guru

Joined: 30/06/2020
Location: Germany
Posts: 529
Posted: 07:27pm 08 May 2025
Copy link to clipboard 
Print this post

Hmm, no matter what I am trying, I can't get the ST7920 work with the smallest font in the EDITOR, the interpreter always says:


> edit
Error : Font is too large



PicoMite MMBasic RP2350A Edition V6.00.02RC23
OPTION SYSTEM SPI GP6,GP7,GP4
OPTION FLASH SIZE 4194304
OPTION CPUSPEED (KHz) 150000
OPTION LCDPANEL CONSOLE 8,,,,NOSCROLL
OPTION DISPLAY 10, 32
OPTION LCDPANEL ST7920, LANDSCAPE,GP0,GP1
OPTION DEFAULT FONT 8, 1


With the RP2040 and the old version 5.09.00 it worked fine. Is there something I am missing? Of course this is really small, since the display is only 128x64 but for my application it is enough to edit things on the go... And it worked in the old version. Maybe I am to stupid or there is new syntax?

The problem is also that it now is impossible to EDIT the program when


OPTION LCDPANEL CONSOLE 8,,,,NOSCROLL


is active.

Greetings
Daniel
Edited 2025-05-09 05:31 by Amnesie
 
     Page 43 of 44    
Print this page
The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025