Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 04:42 22 Apr 2026 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 Firmware Release Version 6.02.01

     Page 5 of 7    
Author Message
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 4304
Posted: 12:30pm 05 Apr 2026
Copy link to clipboard 
Print this post

  terekgabor said  Now it’s time to learn how to compile picomite files.
Is there any instructions somewhere how to do it?

Follow the details of the RPi folks for the SDK, including checking you can build their examples, then grab Picomite files from github and it'll be obvious.

Quite an exercise if you've not done such things before.

John
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 8769
Posted: 02:56pm 05 Apr 2026
Copy link to clipboard 
Print this post

Huh...  I've never found compiling *anything* to be "obvious". lol
Mick

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

Joined: 13/02/2015
Location: United States
Posts: 602
Posted: 03:50pm 05 Apr 2026
Copy link to clipboard 
Print this post

  terekgabor said  Now it’s time to learn how to compile picomite files.
Is there any instructions somewhere how to do it?

Thx,
G@bor


Here are instructions for Linux (I use the Linux subsystem in Windows)

INSTALL PICO SDK
sudo apt update && sudo apt install -y cmake gcc-arm-none-eabi libnewlib-arm-none-eabi build-essential git

mkdir -p ~/pico && cd ~/pico
git clone https://github.com/raspberrypi/pico-sdk.git
cd pico-sdk
git checkout tags/2.2.0 -b sdk2.2.0
git submodule update --init

echo 'export PICO_SDK_PATH=~/pico/pico-sdk' >> ~/.bashrc
source ~/.bashrc



SETUP PICOCALC FIRMWARE

mkdir -p ~/picocalc && cd ~/picocalc
git clone https://github.com/madcock/PicoMiteAllVersions.git
cd PicoMiteAllVersions
mv ~/pico/pico-sdk/src/rp2_common/hardware_gpio/gpio.c ~/pico/pico-sdk/src/rp2_common/hardware_gpio/gpio.bak
ln -s ~/picocalc/PicoMiteAllVersions/gpio.c ~/pico/pico-sdk/src/rp2_common/hardware_gpio/gpio.c
mv ~/pico/pico-sdk/src/rp2_common/hardware_gpio/include/hardware/gpio.h ~/pico/pico-sdk/src/rp2_common/hardware_gpio/include/hardware/gpio.bak
ln -s ~/picocalc/PicoMiteAllVersions/gpio.h ~/pico/pico-sdk/src/rp2_common/hardware_gpio/include/hardware/gpio.h


EDIT ~/picocalc/PicoMiteAllVersions/CMakeLists.txt TO CHOOSE TARGET
set(PICOCALC true)

# Compile for PICO 1 Board
#set(COMPILE PICO)

# Compile for PICO 2 Board
#set(COMPILE PICORP2350) or, for Web version
set(COMPILE WEBRP2350)


BUILD PICOCALC FIRMWARE
cd ~/picocalc/PicoMiteAllVersions
mkdir build
cd build
cmake ..
make

Edited 2026-04-06 01:51 by toml_12953
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 11:12am 09 Apr 2026
Copy link to clipboard 
Print this post

@Peter, Geoff,

Since V6.02.02 is dropping the CAMERA support for the OV7670 in RP2040/WEB builds, I wanted to upgrade my camera to the latest V6.02.01 that supports CAMERA.

But in V6.02.01 the camera does not work.
- the LCD picture is square (not 160x120 or 320x240 as in versions starting V5.08.00), and full of noise. As if the timing is completely wrong.

Pico was run at 252MHz in 5.08.00 and 6.02.01.

I hope this can be repaired, alternatively remove the command form the manual.

Volhout
Edited 2026-04-09 21:13 by Volhout
PicomiteVGA PETSCII ROBOTS
 
terekgabor
Regular Member

Joined: 02/01/2026
Location: Hungary
Posts: 50
Posted: 11:18am 09 Apr 2026
Copy link to clipboard 
Print this post

Thanks Tomi! I will try!
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 11215
Posted: 11:45am 09 Apr 2026
Copy link to clipboard 
Print this post

Volhout. Please try setting OPTION SYSTEM I2C sdpin,sclpin,SLOW. There are no obvious differences in the camera code between 5.08.00 and 6.02.01 other than an I2C timeout setting.
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 12:12pm 09 Apr 2026
Copy link to clipboard 
Print this post

Hi Peter,

Changing system I2C speed has no impact.

Measured on  V6.02.01
XCLK = 12MHz
PCLK = 3MHz
VSYNC = 15Hz ... ?
HSYNC = 1.9kHz

Volhout
Edited 2026-04-09 22:16 by Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 11215
Posted: 12:16pm 09 Apr 2026
Copy link to clipboard 
Print this post

Are you using exactly the same H/W for both versions and does the change happen each time you swap firmware back and forward?
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 12:21pm 09 Apr 2026
Copy link to clipboard 
Print this post

Peter,

Yes, same hardware. Connect USB, FIRMWARE UPDATE, program the same options (manual).
I do not move a wire. All happens behind the console. Below is test 60201rc8 (is fastest 60201)

> option list
PicoMite MMBasic RP2040 V6.02.01RC8
OPTION SYSTEM SPI GP18,GP19,GP16
OPTION SYSTEM I2C GP14,GP15, SLOW
OPTION COLOURCODE ON
OPTION CPUSPEED (KHz) 252000
OPTION LCDPANEL ILI9341, LANDSCAPE,GP20,GP21,GP22
OPTION SDCARD GP17
OPTION F5 flash run 2
> RUN

> list
'demo for OV7670 camera on PicoMite 6.02.01
'OPTION SYSTEM I2C GP14,GP15

'details    XCLK PCLK HSYN VSYN REST D0base
Camera open  GP8, GP9,GP10,GP11,GP12, GP0

'display colorbars
Camera test 2
Camera capture 2
Pause 1000

'display picture
Camera test 0
Do
Camera capture 2
Loop
>


On 5.08.00 I used BITBANG CAMERA.

Volhout

P.S. is the camera code using memory that is not completely in heap ? Memory map has changed I recall.
Edited 2026-04-09 22:27 by Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 11215
Posted: 02:25pm 09 Apr 2026
Copy link to clipboard 
Print this post

There are no relevant changes to the memory handling. Can you try with a RP2350 just out of interest?
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 02:58pm 09 Apr 2026
Copy link to clipboard 
Print this post

Peter,

I can try tonight, when I get access to a Game*Mite with 2350. At work atm.
Not sure if dupont wires will cause problems.

Volhout
PicomiteVGA PETSCII ROBOTS
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 06:40pm 09 Apr 2026
Copy link to clipboard 
Print this post

Hi Peter,

The RP2350 CAMERA works correct.
It is only the RP2040 that behaves weird.

In the RP2040 it looks as if only 240 or 255 of the 320 pixels are shown (square picture), and there is noise. Lot of noise. But when you use SCALE 1 (should be 160x120) also a small square picture is shown, same noise level. It is not "truncating" the picture as if horizontal is a byte in stead of a 16 bit value.

The camera signals (XCLK,PCLK,HS,VS) look the same on the 2350, so it is not in the signals to/from the pico (I guess pico only outputs XCLK, camera generates the rest).

Regards,

Volhout
Edited 2026-04-10 04:49 by Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 11215
Posted: 06:44pm 09 Apr 2026
Copy link to clipboard 
Print this post

So the code is correct and the RP2040 is now somehow too slow in some part of the processing. This is all about this issue of cache hit rates and how tiny code changes affect specific routines depending on their exact location in memory relative to 4 or 16K boundaries
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 06:54pm 09 Apr 2026
Copy link to clipboard 
Print this post

Peter,

Yes, that must be it. When I run the 2350 at 150MHz, I get the same behaviour.
At 200MHz it is correct. I don't have the 2040 wit me at home, so I can't confirm, but I estimate your are correct.

What should Geoff do ? Remove CAMERA from the 2040 manual ? Or (I still have to test that) indicate you need at least 300MHz CPU speed ?

Volhout
Edited 2026-04-10 04:59 by Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 11215
Posted: 06:59pm 09 Apr 2026
Copy link to clipboard 
Print this post

Try the RP2040 at 378MHz - be interested to know the result
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 07:02pm 09 Apr 2026
Copy link to clipboard 
Print this post

Peter,

Will do so tomorrow.

RP2350 in Game*Mite
CPUSPEED      LCD
150000       1/2 picture + noise
160000       2/3 picture + noise
180000       full picture with lines
190000       full picture with some lines
200000       full picture OK

Volhout
Edited 2026-04-10 05:04 by Volhout
PicomiteVGA PETSCII ROBOTS
 
mozzie
Senior Member

Joined: 15/06/2020
Location: Australia
Posts: 278
Posted: 03:28am 10 Apr 2026
Copy link to clipboard 
Print this post

oops, wrong thread  
Edited 2026-04-10 13:41 by mozzie
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 07:07am 10 Apr 2026
Copy link to clipboard 
Print this post

Peter,

RP2040 V6.02.01 CAMERA command.

CPUSPEED       PICTURE
252000       3/4 screen noisy picture
272000       5/6'th screen, noisy picture
280000       Camera configuration error (*)
288000       OK
290000       invalid clock frequency
300000       OK
315000       OK
350000       invalid clock frequency
360000       OK
372000       OK
378000       Camera configuration error (*)

The invalid clock frequency is an error message from the MMBasic core. You simply can't set these clock frequencies.
The "Camera configuration error" shows (repeatable) when opening the camera. Maybe the 12MHz cannot be generated ?  It is not I2C related since it is not an I2C error.

Anyway... 378MHz does not work, but 372MHz works.


EDIT: At frequencies where the picture is okay (i.e. 288/300MHz) the pico shows a white screen on LCD after few minutes. This can only be fixed by a restart. At 252MHz (where the picture is corrupted) the system still runs after 20 minutes. I will investigate a bit further.

EDIT2: I checked the original camera configuration (before I tried converting it to V6.02.01) and confirm this morning again. The old config (V5.08.00) ran at 133MHz flawless. This is just to confirm the white screen is not a result of my setup.

Volhout
Edited 2026-04-10 17:40 by Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 11215
Posted: 08:44am 10 Apr 2026
Copy link to clipboard 
Print this post

Volhout
Please try the attached and let me know if it works

PicoMite.zip
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5859
Posted: 10:06am 10 Apr 2026
Copy link to clipboard 
Print this post

Hi Peter,

Has been running for 15 minutes now. Stable picture at 2040 252MHz

200MHz is 2/3 screen
230MHz has lines in the picture.
252MHz is fine

Will leave this running (at 252) for the rest of the afternoon.

What has changed ?

Volhout
PicomiteVGA PETSCII ROBOTS
 
     Page 5 of 7    
Print this page
The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2026