Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 06:20 02 Jul 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 : in wich topics are examples of mathematic graphics with picomite ?

Author Message
amiga
Newbie

Joined: 08/05/2025
Location: Belgium
Posts: 21
Posted: 02:39pm 28 Jun 2025
Copy link to clipboard 
Print this post

Hi,

i don't remember in wich topics are examples of mathematic graphics with picomite .
i will be very  happy if someone refresh my 1 bit memory,and fun to run them in my new olimex pico(with WS rp2350).

Nice day or nice night

@+

Alfa (from Belgium near Francorchamp .. the wonderful circuit of Race car .. this week race of 24H)
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5023
Posted: 03:36pm 28 Jun 2025
Copy link to clipboard 
Print this post

Hi amiga,

Can you explain. Are you interested in 3D rotation? Or just graphing a mathematical formula.

Volhout
PicomiteVGA PETSCII ROBOTS
 
mathom
Newbie

Joined: 15/02/2025
Location: United States
Posts: 4
Posted: 03:39pm 28 Jun 2025
Copy link to clipboard 
Print this post

Perhaps this?
https://www.thebackshed.com/forum/ViewTopic.php?FID=16&TID=17161#224850
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2522
Posted: 06:32pm 28 Jun 2025
Copy link to clipboard 
Print this post

I'm interested in 3d rotation, any examples in mmbasic please?
 
amiga
Newbie

Joined: 08/05/2025
Location: Belgium
Posts: 21
Posted: 02:49pm 29 Jun 2025
Copy link to clipboard 
Print this post

  Volhout said  Hi amiga,

Can you explain. Are you interested in 3D rotation? Or just graphing a mathematical formula.

Volhout


Just graphing some mathematical formula ... make a demo of Picomite for kids 12-14 years old ..

@+
Amiga
 
amiga
Newbie

Joined: 08/05/2025
Location: Belgium
Posts: 21
Posted: 02:51pm 29 Jun 2025
Copy link to clipboard 
Print this post

  mathom said  Perhaps this?
https://www.thebackshed.com/forum/ViewTopic.php?FID=16&TID=17161#224850



yes that's .. now i can make a demo .. pictures better than words ..

Thanks

@+

Amiga
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 5023
Posted: 01:29pm 01 Jul 2025
Copy link to clipboard 
Print this post

  stanleyella said  I'm interested in 3d rotation, any examples in mmbasic please?


This is Peter's demo for 3D rotation. It is amazing how fast PicoMite can do this (below program is tested on RP2040 VGA (mode 2) but should also work on other resolutions. There is an explanation how things work in the CMM2 graphics manual.
This is just to show that the same it works on pico.

I already played with a "Cobra" from the game "Elite"... but that is not finished yet. the goal was to adjust yaw pitch and roll from a Nunchuck controller (it has built in acceleration sensors).


'rotating cube
 'some changes where made to remove a face, and create a "hollow" cube.
 MODE 2
 FRAMEBUFFER create

 Dim FLOAT vertices(2,7) = (-1,1,-1, 1,1,-1, 1,-1,-1, -1,-1,-1, -1,1,1, 1,1,1, 1,-1,1, -1,-1,1)

'  Dim INTEGER facecount(4)=(4,4,4,4,4) '1 face less
 Dim INTEGER facecount(5)=(4,4,4,4,4,4)

'  Dim INTEGER faces(19)=(0,1,2,3, 1,5,6,2, 0,4,5,1, 5,4,7,6, 2,6,7,3) '1 face less
 Dim INTEGER faces(23)=(0,1,2,3, 1,5,6,2, 0,4,5,1, 5,4,7,6, 2,6,7,3, 0,3,7,4)

 Dim INTEGER colours(6)=(RGB(blue), RGB(green), RGB(yellow), RGB(cyan), RGB(red), RGB(magenta), RGB(yellow))

'  Dim INTEGER edge(4)=(6,6,6,6,6) '1 face less
 Dim INTEGER edge(5)=(6,6,6,6,6,6)

'  Dim INTEGER fill(4)=(0,1,2,3,4) '1 face less
 Dim INTEGER fill(5)=(0,1,2,3,4,5)

'  Dim n=1, nv=8, nf=5, camera=1   '1 face less
 Dim n=1, nv=8, nf=6, camera=1    

 'enlarge to visible proportions
 Math SCALE vertices(), 100, vertices()

 Draw3D CREATE n, nv, nf, camera, vertices(), facecount(), faces(), colours(), edge(), fill()

 Dim FLOAT yaw=Rad(1), pitch=Rad(2), roll=Rad(0.5)
 Dim FLOAT q(4)
 Dim INTEGER viewplane=300

 Draw3D camera n, viewplane

 Dim INTEGER x=0, y=0, z=500
 FRAMEBUFFER write f

 Draw3D SHOW n, x, y, z

 Do
   Math Q_EULER yaw, pitch, roll, q()
   Draw3D ROTATE q(),n
   Draw3D show n,x,y,z
   Inc yaw,Rad(1)
   Inc pitch,Rad(2)
   Inc roll,Rad(0.5)
   FRAMEBUFFER copy f,n
 Loop

Edited 2025-07-01 23:41 by Volhout
PicomiteVGA PETSCII ROBOTS
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2522
Posted: 04:07pm 01 Jul 2025
Copy link to clipboard 
Print this post

thanks for the code Volhout, it works. I had to put pause 20 in the do loop cos it was too fast to see.!
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2522
Posted: 04:57pm 01 Jul 2025
Copy link to clipboard 
Print this post

better than no example but not an easy thing to understand. the example is filled colour not just wired points.
thanks again. stan
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2522
Posted: 06:57pm 01 Jul 2025
Copy link to clipboard 
Print this post

looks good hdmi OPTION RESOLUTION 1024x768 mode 3
 
Print this page


To reply to this topic, you need to log in.

The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025