Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 10:36 24 Nov 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 V6.00.00 release candidates - all versions

     Page 7 of 24    
Author Message
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 6778
Posted: 07:17am 09 Oct 2024
Copy link to clipboard 
Print this post

I wonder if it could be added to MM.INFO(OPTION nnnnn) to read the option string for OPTION AUDIO?
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9105
Posted: 08:36am 09 Oct 2024
Copy link to clipboard 
Print this post

Jim: I increased the size of the audio buffers from 8K *2 to 16k *2 while trying to diagnose a problem with the VS1053 on the RP2350 and forgot to put them back. The next RC will fix this.

The actual problem was bizarre. Since forever with the RP2040 I have set the drive strength of pins to the maximum 12mA when used as outputs. On the RP2350 the SPI clock to the VS1053 was going wrong with this setting. Normally of course the clock should be either 0V or 3.3V. On the RP2350, when used with the VS1053, the clock was as expected for a few seconds and then changed to oscillate between about 2.5V and 3.3V. My suspicion is that this could be to do with the RP2350 latchup bug.
I then randomly played with a bunch of the pin settings (fast edge, schmidt trigger on inputs etc.) until I discovered that changing the drive strength to anything other than 12mA fixed the problem. I have therefore changed MMBasic throughout to limit the pin drive to 8Ma on output.

The next RC will also have a great improvement to the VS1053 support. Up until now there was a timer interrupt which triggers the output of data to the VS1053 as required. The sdk only supports SPI used in a blocking mode so the interrupt currently sits and waits for the SPI transmission to complete before returning.
I've managed to set up the SPI transmission under DMA so that it can now run asynchronously and the interrupt can return immediately. A DMA completion interrupt then sets a flag to tell the system that it is ready to output more data if required by the VS1053. This massively decreases the CPU overhead of using the VS1053 and makes it more efficient than even the standard PWM audio. This will also be in the next release. I'm trying to think if the idea can be extended to the DAC audio but this is more difficult as it only outputs 4 bytes and has to toggle the chip select between the first and second pairs.
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6096
Posted: 08:54am 09 Oct 2024
Copy link to clipboard 
Print this post

You are certainly having to deal with plenty of strange problems.
One of our politicians once said "Life wasn't meant to be easy"

Jim
VK7JH
MMedit   MMBasic Help
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1113
Posted: 08:58am 09 Oct 2024
Copy link to clipboard 
Print this post

]play Flac [/B returns an error : Not enough Heap Memory
  Quote  > memory
Program:
 32K (31%) Program (967 lines)
  6K ( 4%) 1 Embedded C Routine
  1K ( 0%) 1 Embedded Fonts
 61K (65%) Free

Saved Variables:
 16K (100%) Free

RAM:
 13K (10%) 29 Variables
  9K ( 7%) General
106K (83%) Free

> option list
PicoMiteVGA MMBasic Version 6.00.00RC6
OPTION COLOURCODE ON
OPTION KEYBOARD GR, 0, 0, 0, 0
OPTION CPUSPEED (KHz) 378000
OPTION DISPLAY 30, 53
OPTION SDCARD GP10, GP12, GP11, GP13
OPTION AUDIO GP6,GP7', ON PWM CHANNEL 3
OPTION MODBUFF ENABLE  180

Edited 2024-10-09 19:01 by Martin H.
'no comment
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9105
Posted: 09:18am 09 Oct 2024
Copy link to clipboard 
Print this post

See above
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4222
Posted: 10:38am 09 Oct 2024
Copy link to clipboard 
Print this post

Hi Peter,

There may be an issue when 8mA drive strength is used with PWM audio (220 ohm resistors) and VGA video (270 ohm resistors). Not sure what the effect will be.

Volhout
PicomiteVGA PETSCII ROBOTS
 
electricat

Senior Member

Joined: 30/11/2020
Location: Lithuania
Posts: 161
Posted: 11:24am 09 Oct 2024
Copy link to clipboard 
Print this post

PicoMiteVGAUSBRP2040V6.00.00RC6
Keyboard->USB
Editor->Inbuilt editor

Just poking arround and:
entering -> ? MM.Info(PS2)
returns-> Error: Syntax

If it is normal behavior, please ignore
 
phil99

Guru

Joined: 11/02/2018
Location: Australia
Posts: 2135
Posted: 11:38am 09 Oct 2024
Copy link to clipboard 
Print this post

  Quote  There may be an issue when 8mA drive strength is used with PWM audio (220 ohm resistors) and VGA video (270 ohm resistors).
For VGA max. brightness for each input is about 9mA so 8mA is a little short for red and blue. Green has 2 pins so resistor values may need adjusting for white.
It isn't a deal breaker.
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 6778
Posted: 12:20pm 09 Oct 2024
Copy link to clipboard 
Print this post

If you could use anywhere close to 8mA per pin on the RP2350B there'd be smoke. ;)

48 x 8mA = 384mA

Maximum Total
IOVDD current

IIOVDD_MAX 100 mA
Sum of all current being sourced by GPIO pins

Maximum Total
VSS current
due to GPIO
(IOVSS)

IIOVSS_MAX 100mA

Sum of all current being sunk into GPIO pins

.
Edited 2024-10-09 22:21 by Mixtel90
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
electricat

Senior Member

Joined: 30/11/2020
Location: Lithuania
Posts: 161
Posted: 05:29pm 09 Oct 2024
Copy link to clipboard 
Print this post

PicoMiteVGAUSBRP2040V6.00.00RC6

Print MM.INFO(OPTION KEYBOARD)
Prints nothing

Print MM.INFO(ID)
Prints nothing
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9105
Posted: 05:47pm 09 Oct 2024
Copy link to clipboard 
Print this post

Thanks - will fix. The first one wasn't possible until sdk2.0 because the function for unique ID was in the USB client header - bizarre

  Quote  I wonder if it could be added to MM.INFO(OPTION nnnnn) to read the option string for OPTION AUDIO?


Will add MM.INFO(OPTION AUDIO) returns PWM, or SPI, or VS1053, or NONE
Edited 2024-10-10 03:54 by matherp
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2119
Posted: 06:37pm 09 Oct 2024
Copy link to clipboard 
Print this post

option resolution in option list?
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9105
Posted: 06:53pm 09 Oct 2024
Copy link to clipboard 
Print this post

Just use mm.vres
 
electricat

Senior Member

Joined: 30/11/2020
Location: Lithuania
Posts: 161
Posted: 08:38pm 09 Oct 2024
Copy link to clipboard 
Print this post

PicoMiteVGAUSBRP2040V6.00.00RC6

Auto adjusted monitor while being inside of inbuilt EDITOR

now if I would tray simple program like

for a=1 to 800
line 1,a,1024,a
next a


it would fill screen with lines, but not first 12 lines from top


If I would Autoadjust monitor, all moves up 12 lines.
If I enter EDITOR, now I miss those 12 lines at bottom.
If I would press Autodajust monitor, all looks good again.

And repeat.


I also ran testcard.bas TassyJim test card for Picomite VGA and HDMI
testcard


MODE1 Ratio 1.000
640x480

I see missing 12 lines from top (black)

Mode 2 and Mode 3 looks perfect
Edited 2024-10-10 06:38 by electricat
 
electricat

Senior Member

Joined: 30/11/2020
Location: Lithuania
Posts: 161
Posted: 08:44pm 09 Oct 2024
Copy link to clipboard 
Print this post

Forgot to mention.
If I run something printed, then all looks OK
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9105
Posted: 09:52pm 09 Oct 2024
Copy link to clipboard 
Print this post

  Quote  now if I would tray simple program like


Your report makes no sense. Why are you writing 1024 pixel long lines to a 640 pixel wide display. Why are you writing 800 lines to a 480 line high display?

What CPU speed?

Sounds like a monitor issue. Mode 2 and 3 use the same underlying video feed as mode 1 with no difference in timing
 
electricat

Senior Member

Joined: 30/11/2020
Location: Lithuania
Posts: 161
Posted: 05:18am 10 Oct 2024
Copy link to clipboard 
Print this post

Peter,

I am looking at one monitor, typing to another, and in rush. So I make mistakes, sory, yes it should be 640x480 .

PicoMiteVGAUSBRP2040V6.00.00RC6
CPU SPEED 252000000

If I run PRINTED GRAPHICS based program, display works PERFECTLY from top to bottom, from left to right.

If I draw using LINES and it will fail like I described before (I use 640x480)

Line  1,1,640,1,1
Line 640,1,640,480,1
Line 1,480,640,480,1
Line 1,1,1,640,1


if I change first line Line  1,12,640,12,1 (one character 8x12 size)
It draws.

-==========================================
I TRY ON ANOTHER mite 2040 VGA + PS/2

PicoMiteVGARP2040V6.00.00RC4
CPU SPEED 252000000

Same monitor and LINE command works perfectly.
How it could be display problem?  

Thank you.
Edited 2024-10-10 15:42 by electricat
 
JanVolk
Senior Member

Joined: 28/01/2023
Location: Netherlands
Posts: 144
Posted: 07:54am 10 Oct 2024
Copy link to clipboard 
Print this post

Did some tests with RP2040
Unstable after Version 6.00.00RC3 regarding Reset and USB connection.
After one or two resets, the USB connection is disconnected and must be reconnected manually.

> option list
PicoMite MMBasic Version 6.00.00RC4
OPTION COLOR CODE ON
OPTION DISPLAY 43, 96

> memory
Program:
  0K ( 0%) Program (0 lines)
132K (100%) Free

Saved Variables:
 16K (100%) Free

RAM:
  0K ( 0%) 0 Variables
  0K ( 0%) General
160K (100%) Free

Programs crash with PicoMite RP2040 MMBasic Version 6.00.00RC6.
Have program example PID loaded and works after RUN.
The green LED on the Raspberry Pi Pico stops flashing after a few seconds.
The program can still be allowed to run until "Test over". The program can also be stopped with Ctrl+C. After this, operation with TeraTerm but LED stopped.
After a Reset no more communication. The LED on the Raspberry Pi Pico flashes again.  
Only then no more communication with TeraTerm and after Reset the connection is no longer restored (pullup with Cannot open COM4. Not found.)
This can only be fixed manually in TeraTerm.

Jan.
 
electricat

Senior Member

Joined: 30/11/2020
Location: Lithuania
Posts: 161
Posted: 08:25am 10 Oct 2024
Copy link to clipboard 
Print this post

@JanVolk
I had some instabilities with lightning keyboard.
Unexpected disconnections/reconnections and all kind of instabilities on every run/editing etc.
Good stable external power source solved them all. (VSYS on pin 39)
Edited 2024-10-10 18:27 by electricat
 
guma1975
Newbie

Joined: 13/01/2023
Location: Poland
Posts: 7
Posted: 08:48am 10 Oct 2024
Copy link to clipboard 
Print this post

Hello. In the tested rp2350 HDMI in mode 3 I wanted to find out what r,g,b is and read one byte from MAP(15). When I enter this
> mode 3
> ? map(15)
8437888
> ? peek(BYTE MAP(15))

then rp2350 rc6 hangs... What am I doing wrong? is this an rc6 error or my poor attempt at reading?
sorry for my english it's from translator
 
     Page 7 of 24    
Print this page
© JAQ Software 2024