Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 15:20 27 Apr 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 : PicoMite/PicoMiteVGA V5.07.03 release candidates

     Page 1 of 9    
Author Message
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8579
Posted: 09:10am 31 Dec 2021
Copy link to clipboard 
Print this post

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

PicoMite/PicoMiteVGA

V5.07.03RC1

Tidied up system response when OPTION LCDPANEL has an error
Improved files command
FILES [fspec$] [, sort]
Lists files in any directory on the SD card.
'fspec$' (if specified) can contain a path and search wildcards in the filename.  Question marks (?) will match any character and an asterisk (*) will match any number of characters.  If omitted, all files will be listed.  
For example:
* Find all entries
*.TXT Find all entries with an extension of TXT
E*.* Find all entries starting with E
X?X.* Find all three letter file names starting and ending with X
mydir/* Find all entries in directory mydir
NB: putting wildcards in the pathname will result in an error

'sort' specifies the sort order as follows:
size by ascending size
time by descending time/date
name by file name (default if not specified)
type by file extension
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 04:56pm 31 Dec 2021
Copy link to clipboard 
Print this post

Thank you for the fix Peter.

I went back to "PicoMite firmware V5.07.01" from Geoff's website and confirmed that FILES with argument/wildcard was working then too ... so on this occasion I wasn't losing my mind .

I also appreciate the OPTION LCDPANEL CONSOLE as it makes debugging my serial connection from MMB4L to the PicoMite much easier.

Best wishes,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
mobluse

Newbie

Joined: 10/02/2013
Location: Sweden
Posts: 24
Posted: 05:46pm 31 Dec 2021
Copy link to clipboard 
Print this post

* Option Color VGA on and off gives Error, but if you change to Colour it works.
* F1 does not type files and Enter; at least not from PuTTY serial or Minicom and Picocom.
* Ctrl-F doesn't work to enter find mode in editor, but Ctrl-R does.
* Ctrl-S doesn't work to enter mark/select mode, but Ctrl-T does, but this might be an error in the manual since Ctrl-S is also an alternative to Left.
* Shift-F3 doesn't work in xterm/LXTerminal with Minicom or Picocom in Raspberry Pi OS Buster, but works in PuTTY.
* F5 doesn't work in xterm/LXTerminal with Minicom in Raspberry Pi OS Buster, but F6-F9 does, and F5-F9 works in PuTTY and in xterm/LXTerminal with Picocom.

I run Minicom with:
minicom --device /dev/ttyACM0 --color=on
and Picocom with:
picocom /dev/ttyACM0


My setup:
PicoMiteVGA MMBasic Version 5.07.03RC1                  
Copyright 2011-2021 Geoff Graham                        
Copyright 2016-2021 Peter Mather                        

> option list
OPTION MONO VGA ON
OPTION COLOURCODE ON
OPTION SDCARD GP15, GP10, GP11, GP12
OPTION Audio GP18,GP19, on PWM channel 1
OPTION F5 files

Edited 2022-01-01 04:02 by mobluse
Maker Pi Pico Rev1.2, DuinoMite-Mini, Raspberry Pi 0-4, iCE40HX8K, Arduino Uno, VM111, STK500, ZX81
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8579
Posted: 06:12pm 31 Dec 2021
Copy link to clipboard 
Print this post

  Quote  Option Color VGA on and off gives Error, but if you change to Colour it works.


Correct - that is how you spell colour  

  Quote  F1 does not type files and Enter; at least not from PuTTY serial or Minicom and Picocom.


Manual error. FILES is only available if the SDcard is enabled so I am not implementing F1. You have already found the workaround

  Quote   Ctrl-F doesn't work to enter find mode in editor, but Ctrl-R does.
* Ctrl-S doesn't work to enter mark/select mode, but Ctrl-T does, but this might be an error in the manual since Ctrl-S is also an alternative to Left.
*


Thanks, manual error - it is correct in the table of control keys but not in the text

  Quote  Shift-F3 doesn't work in xterm/LXTerminal with Minicom or Picocom in Raspberry Pi OS Buster, but works in PuTTY.
* F5 doesn't work in xterm/LXTerminal with Minicom in Raspberry Pi OS Buster, but F6-F9 does, and F5-F9 works in PuTTY and in


This is not a firmware issue but a limitation in those terminal emulators. Use Ctrl-G and Ctrl-Y as in the table of control keys. Both also work fine with an attached PS2 keyboard.
Edited 2022-01-01 04:12 by matherp
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 08:53pm 31 Dec 2021
Copy link to clipboard 
Print this post

Hi Peter,

It looks possible that AUTOSAVE has become non-functional:

> ? Mm.Info(Device)
PicoMite
> ? Mm.Info(Version)
5.0703
> files
A:
  <DIR>  cmm2-basic-challenge
  <DIR>  cmm2-forth
  <DIR>  cmm2-fun
  <DIR>  sptools
  <DIR>  zmim
00:07 01-01-2000         64  buzz.bas
00:07 01-01-2000       1922  fileview.bas
00:02 01-01-2000       3483  spi_led.bas
5 directories, 3 files
> autosave
abc
def
ghi
Saved 26 bytes
> save "foo.bas"
Error : A hard error occurred in the low level disk I/O layer
> files
A:
  <DIR>  cmm2-basic-challenge
  <DIR>  cmm2-forth
  <DIR>  cmm2-fun
  <DIR>  sptools
  <DIR>  zmim
00:07 01-01-2000         64  buzz.bas
00:07 01-01-2000       1922  fileview.bas
00:12 01-01-2000          0  foo.bas
00:02 01-01-2000       3483  spi_led.bas
5 directories, 4 files
> autosave
Print "Hello World"
Saved 23 bytes
> save "hello.bas"
Error : A hard error occurred in the low level disk I/O layer
> files
A:
  <DIR>  cmm2-basic-challenge
  <DIR>  cmm2-forth
  <DIR>  cmm2-fun
  <DIR>  sptools
  <DIR>  zmim
00:07 01-01-2000         64  buzz.bas
00:07 01-01-2000       1922  fileview.bas
00:12 01-01-2000          0  foo.bas
00:02 01-01-2000       3483  spi_led.bas
5 directories, 4 files
>


When I subsequently popped the SD card and put it into Windows and Linux machines it read as empty, and when put back into the PicoMite it also said it was empty.

There have been no past problems with this newish SD card or with this particular Pico and SD reader, at least not since the very early PicoMite SD card teething issues.

Best wishes,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 09:25pm 31 Dec 2021
Copy link to clipboard 
Print this post

In anticipation of some of your requests I hard reformatted the SD card and experimented some more. It seems that it is just the act of using SAVE that is broken, you don't need to use AUTOSAVE at all.

My options are:

OPTION CPUSPEED (KHz) 133000
OPTION LCDPANEL CONSOLE
OPTION DISPLAY 20, 40
OPTION LCDPANEL ILI9341, RLANDSCAPE,GP20,GP21,GP17
OPTION TOUCH GP14,GP15
OPTION SDCARD GP22
OPTION SYSTEM SPI GP18,GP19,GP16


In case it was a hardware problem with the card or reader I tried downgrading to 5.07.01 and the SD card and SAVE command work fine with that version.

I then restored the 5.07.03 beta and SAVE again started to fail and also this time buggered up the SD card so even the PicoMite couldn't read it.

Happy New Year - no irony intended,

Tom
Edited 2022-01-01 07:26 by thwill
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5904
Posted: 09:36pm 31 Dec 2021
Copy link to clipboard 
Print this post

SAVE (and AUTOSAVE) work for me with the latest beta/rc1.

option list
OPTION CPUSPEED (KHz) 250000
OPTION LCDPANEL ILI9341, LANDSCAPE,GP7,GP8,GP9
OPTION TOUCH GP14,GP15
GUI CALIBRATE 0, 250, 504, 925, 747
OPTION SDCARD GP13
OPTION SYSTEM SPI GP10,GP11,GP12
>


Jim
VK7JH
MMedit   MMBasic Help
 
mobluse

Newbie

Joined: 10/02/2013
Location: Sweden
Posts: 24
Posted: 09:39pm 31 Dec 2021
Copy link to clipboard 
Print this post

This example demonstrates that F1 cannot be defined even though it's unused by MMBasic, and that the definitions for F6-F9 doesn't remain after reset (RUN button):
> option f1 "files"+chr$(13)
Error : Invalid Option
> option f5 "files"+chr$(13)
> option f6 "files"+chr$(13)
> option f7 "files"+chr$(13)
> option f8 "files"+chr$(13)
> option f9 "files"+chr$(13)
> option list
OPTION MONO VGA ON
OPTION COLOURCODE ON
OPTION SDCARD GP15, GP10, GP11, GP12
OPTION Audio GP18,GP19, on PWM channel 1
OPTION F5 files
OPTION F6 files
OPTION F7 files
OPTION F8 files
OPTION F9 files
PicoMiteVGA MMBasic Version 5.07.03RC1
Copyright 2011-2021 Geoff Graham
Copyright 2016-2021 Peter Mather

> option list
OPTION MONO VGA ON
OPTION COLOURCODE ON
OPTION SDCARD GP15, GP10, GP11, GP12
OPTION Audio GP18,GP19, on PWM channel 1
OPTION F5 files
>


"The default for commands that require a colour parameter can be set with the COLOUR command (can also be spelt COLOR)." p. 47 in PicoMite User Manual.

I believe it is Xterm (and compatibles) more than TeraTerm that is the modern standard terminal emulator. I think you should support both. That F5 doesn't work in Minicom is probably some bug in Minicom, since it works in Picocom in the same terminal emulator. I think both Microsoft and Apple follows the standard set by xterm in their terminal emulators, but I should test.

I run PicoMiteVGA on Maker Pi Pico Rev1.2. I've not yet connected a PS/2 keyboard and VGA screen. They might need to be configured to other pins here since there is a button and headphone jack using the default pins.
Maker Pi Pico Rev1.2, DuinoMite-Mini, Raspberry Pi 0-4, iCE40HX8K, Arduino Uno, VM111, STK500, ZX81
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 10:56pm 31 Dec 2021
Copy link to clipboard 
Print this post

  TassyJim said  SAVE (and AUTOSAVE) work for me with the latest beta/rc1.

option list
OPTION CPUSPEED (KHz) 250000
...

Jim


Thanks Jim, that gets the investigation a little further forward, with:
OPTION CPUSPEED 133000

SAVE fails as I reported.

But with:
OPTION CPUSPEED 250000

It succeeds.

So is this a firmware bug ? a feature ? something in my hardware setup ? the curse of the pharaohs ?

Note that after flashing with the latest firmware (yes, I did use 'Clear_flash.uf2' first) OPTION CPUSPEED 133000 is automatically set - is this expected ?

Happy New Year,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8579
Posted: 11:53pm 31 Dec 2021
Copy link to clipboard 
Print this post

  Quote  This example demonstrates that F1 cannot be defined even though it's unused by MMBasic, and that the definitions for F6-F9 doesn't remain after reset (RUN button):
> option f1 "files"+chr$(13)
Error : Invalid Option
> option f5 "files"+chr$(13)
> option f6 "files"+chr$(13)
> option f7 "files"+chr$(13)
> option f8 "files"+chr$(13)
> option f9 "files"+chr$(13)
> option list
OPTION MONO VGA ON
OPTION COLOURCODE ON
OPTION SDCARD GP15, GP10, GP11, GP12
OPTION Audio GP18,GP19, on PWM channel 1
OPTION F5 files
OPTION F6 files
OPTION F7 files
OPTION F8 files
OPTION F9 files
PicoMiteVGA MMBasic Version 5.07.03RC1
Copyright 2011-2021 Geoff Graham
Copyright 2016-2021 Peter Mather

> option list
OPTION MONO VGA ON
OPTION COLOURCODE ON
OPTION SDCARD GP15, GP10, GP11, GP12
OPTION Audio GP18,GP19, on PWM channel 1
OPTION F5 files
>


"The default for commands that require a colour parameter can be set with the COLOUR command (can also be spelt COLOR)." p. 47 in PicoMite User Manual.

I believe it is Xterm (and compatibles) more than TeraTerm that is the modern standard terminal emulator. I think you should support both. That F5 doesn't work in Minicom is probably some bug in Minicom, since it works in Picocom in the same terminal emulator. I think both Microsoft and Apple follows the standard set by xterm in their terminal emulators, but I should test.

I run PicoMiteVGA on Maker Pi Pico Rev1.2. I've not yet connected a PS/2 keyboard and VGA screen. They might need to be configured to other pins here since there is a button and headphone jack using the default pins.


With respect you get what you pay for - take it or leave it I don't care
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5904
Posted: 06:19am 01 Jan 2022
Copy link to clipboard 
Print this post

  thwill said   with:
OPTION CPUSPEED 133000

SAVE fails as I reported.

But with:
OPTION CPUSPEED 250000

It succeeds.

So is this a firmware bug ? a feature ? something in my hardware setup ? the curse of the pharaohs ?

No problems here with 133000 speed.
I only tested a sample of one...

Jim
VK7JH
MMedit   MMBasic Help
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8579
Posted: 08:21am 01 Jan 2022
Copy link to clipboard 
Print this post

  Quote  SAVE fails as I reported.

But with:
OPTION CPUSPEED 250000

It succeeds.

So is this a firmware bug ? a feature ? something in my hardware setup ? the curse of the pharaohs ?


Tom

There has been no change in this code. The only change I made was to make the default CPU speed 133000 instead of 125000. Please report if you see the issue at 125000.

The SDcard routines put in extra wait states but not until the CPU speed equals or exceeds 200000

I've just tested near worst case with the CPU set at 198000 and I can read and write the SDcard perfectly (and of course no issue at 133000). What is your H/W setup?

I always run this program to soak test SDcard changes. If this runs to completion there isn't much wrong - takes a while!

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

V5.07.03RC2 posted - fixes bug in loading user definitions for F6-F9
Edited 2022-01-01 19:38 by matherp
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 06:14pm 01 Jan 2022
Copy link to clipboard 
Print this post

Thanks for taking an interest Peter.

  matherp said  Please report if you see the issue at 125000.


Intermittent failure at that speed compared with always failing at 133000.

Note that whilst you've changed the initial value to 133000, it appears you haven't changed the default that determines whether OPTION CPUSPEED is shown in the OPTION LIST or not.

  matherp said  I've just tested near worst case with the CPU set at 198000 and I can read and write the SDcard perfectly (and of course no issue at 133000). What is your H/W setup?


I'm using one of Mixtel90's Pico backpacks with the SD card reader built into the ILI9341. I've also got a Cytron Maker Pi Pico board and an alternative SD card. I'll gather some failure statistics (with RC2) to see if I can isolate the issue and report back.

Best wishes,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
phil99

Guru

Joined: 11/02/2018
Location: Australia
Posts: 1783
Posted: 07:39pm 01 Jan 2022
Copy link to clipboard 
Print this post

" the SD card reader built into the ILI9341"
This has 1k resistors in series with all the lines. Others have said these should be either replaced with much lower values or shorted out for reliable operation. Though I have not had any problems.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8579
Posted: 07:59pm 01 Jan 2022
Copy link to clipboard 
Print this post

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

V5.07.03RC3 posted

Added FORMAT$() function as per CMM2
Minor change to DIR$() function to allow use with a single parameter in which case the type defaults to FILE
Changes to FILE command to deal with relative paths from a sub-directory

zmim tested
 
mobluse

Newbie

Joined: 10/02/2013
Location: Sweden
Posts: 24
Posted: 08:21pm 01 Jan 2022
Copy link to clipboard 
Print this post

option color vga on seems to hang serial communication over USB on Maker Pi Pico Rev1.2; I then have to reinstall Clear_flash.uf2 and PicoMiteVGAV5.07.03RC3.uf2. option color vga off works.

My configuration:
PicoMiteVGA MMBasic Version 5.07.03RC3
Copyright 2011-2021 Geoff Graham
Copyright 2016-2021 Peter Mather

> option list
OPTION MONO VGA ON
OPTION COLOURCODE ON
OPTION SDCARD GP15, GP10, GP11, GP12
OPTION Audio GP18,GP19, on PWM channel 1
OPTION F5 files
OPTION F6 files
OPTION F7 files
OPTION F8 files
OPTION F9 files


I also noticed that option f1 "files"+chr$(13) doesn't give an error, but F1 doesn't work and is not listed.
Edited 2022-01-02 07:16 by mobluse
Maker Pi Pico Rev1.2, DuinoMite-Mini, Raspberry Pi 0-4, iCE40HX8K, Arduino Uno, VM111, STK500, ZX81
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8579
Posted: 10:13pm 01 Jan 2022
Copy link to clipboard 
Print this post

  Quote  option color vga on seems to hang serial communication over USB on Maker Pi Pico Rev1.2;


It is because you have the VGA pins GP18 and GP19 set to audio. The firmware should give an error when you try and set it. I'll fix this in the next version
Edited 2022-01-02 08:23 by matherp
 
led-bloon

Senior Member

Joined: 21/12/2014
Location: Australia
Posts: 202
Posted: 10:32pm 01 Jan 2022
Copy link to clipboard 
Print this post

Peter
Nuked the Pico, then loaded RC3
Entered simple loop printing "hello world", ran it ok, then saved to
flash slot 1 (of the 7 available).

flash list shows slot 1 AND slot 2 in use.
slot 1 has the first line of code displayed - ok
slot 2 shows "in use" with no other text.
(Loading/running slot 2, eventually gives "invalid address error"
and a reboot. Same happens with slots 3 & 4)

led

PS Thanks once again for great software to you and Geoff
  and
  HAPPY NEW YEAR to ALL shedders!!!!!
Edited 2022-01-02 08:36 by led-bloon
Miss you George
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 12:12am 02 Jan 2022
Copy link to clipboard 
Print this post

  phil99 said  " the SD card reader built into the ILI9341"
This has 1k resistors in series with all the lines. Others have said these should be either replaced with much lower values or shorted out for reliable operation. Though I have not had any problems.


Thanks Phil, to investigate that I replaced the resistors with links* and it *may* now be working even at CPUSPEED 133K; more testing is required.

* actually I made a complete hash of it; I wanted to just put some links in parallel with the resistors but it was all too fiddly and I ended up removing them. Then I couldn't make deliberate solder bridges for love nor money; the solder mask on the PCB is too bloody good, does anyone have any advice in that regard? Then I managed to burn off two of the solder pads and had to scrape down to the copper. I finally bridged them with some fine wire links. I didn't need this object lesson in just how hamfisted I can be  . I think I may buy myself some 0R SMD resistors in case I have to do this again.

Can someone explain in simple terms (a) why these resistors are present in the first place, and (b) why Peter and the Pico(Mite?) hold them in such disdain ?

Best wishes,

Tom
Edited 2022-01-02 10:49 by thwill
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3841
Posted: 12:26am 02 Jan 2022
Copy link to clipboard 
Print this post

  matherp said  zmim tested


Neat, though at ~150 instructions per second it will be barely playable. IIRC on the CMM2 it achieves in excess of 1000 instructions per second.

Given the output it looks like you are running the CMM1 version ? This was slow because it had to use a virtual memory implementation.

Does the transpiled CMM2 version not work https://github.com/thwill1000/cmm2-zmim/blob/master/zmim.bas ?

I really hope I can find time to revisit Z-MIM some time soon as it would benefit from being updated to use some of the more recent MMBasic features.

Best wishes,

Tom
Edited 2022-01-02 10:27 by thwill
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
     Page 1 of 9    
Print this page
© JAQ Software 2024