Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 11:30 28 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 : PICO PETSCII

     Page 15 of 38    
Author Message
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 11:42am 16 Oct 2023
Copy link to clipboard 
Print this post

Volhout,
just so you're up to date, so that our development environment doesn't differentiate too much.
Here the Version with Intro/Start Menu

Start      works,
Map Select works
DIFFICULTY and Controls  --  Not yet.


Pet18ji.zip
Edited 2023-10-16 22:16 by Martin H.
'no comment
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4247
Posted: 07:40pm 16 Oct 2023
Copy link to clipboard 
Print this post

@Martin,

Combined your start screen with my bug fixes..
The start menu works nice !! Compliments....

Volhout

pet18m.zip

Edit: new upload with significantly more bug fixes. Ignore pet18l.bas
Edited 2023-10-17 07:02 by Volhout
PicomiteVGA PETSCII ROBOTS
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 07:23am 17 Oct 2023
Copy link to clipboard 
Print this post

Since I'm in the office all day, I'm not going to test the new version until tonight.

Have you noticed the changes with the new RC?

  matherp said  V5.07.08RC9

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

I was doing the manual and trying to think how to document the differences between BLIT MEMORY and BLIT COMPRESSED on the VGA version vs the LCD versions and decided it was easier to equalise the firmware so...

BLIT COMPRESSED address, x, y [,col]
and
BLIT MEMORY address, x, y [,col]

Now work on all framebuffers and physical displays including transparent colours on the TFTs.

As on the VGA version "col" is a number between -1 and 15. -1 indicates there is no transparent colour and is the default. 0 to 15 correspond to the 16 RGB121 colours supported by framebuffers and the VGA display

Couldn't test it jet but it looks that I will repaint all Sprites the 3rd Time   , as we now can use Black in the Sprites


Edited 2023-10-17 17:25 by Martin H.
'no comment
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9129
Posted: 07:27am 17 Oct 2023
Copy link to clipboard 
Print this post

How are you guys on memory usage?

Reason I ask is that I have a sneaky idea that could allow the PicoMite to function almost identically to the VGA version.

Idea

FRAMEBUFFER CREATE
FRAMEBUFFER LAYER
FRAMEBUFFER MERGE BACKGROUND [,colour]

The last command would set up a continuously running process on the second CPU that takes the F buffer, overlays it with the L buffer with pixels of the specific "colour" in the L buffer considered transparent.

From the point of view of the programmer your static/semi-static images would then be on the F buffer and anything moving on L. You wouldn't have to do anything to get them to the display and all drawing commands would be working on memory so very fast.

This isn't very difficult to implement. Thoughts?

Would the equation change if I gave you an extra 20K of memory on the PicoMite with the downside that performance would then be the same as the PicoMiteVGA (up to 7% slower in programs with large numbers of functions)?
Edited 2023-10-17 18:29 by matherp
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9129
Posted: 12:28pm 17 Oct 2023
Copy link to clipboard 
Print this post

I'm out of date with the latest releases but the VGA version now runs on a LCD using my experimental firmware with trivial changes. Get rid of the MODE command, create the framebuffer, Change all FRAMEBUFFER WRITE N to FRAMEBUFFER WRITE F. Do all the SDcard I/O before starting the continuous update and then it just runs perfectly

 'petrobot testbed picomite VGA V50708RC4


 ' system setup -----------------------------------------------------

 'MODE 2
 Option default integer
 FRAMEBUFFER layer
 FRAMEBUFFER create
 'startup screen show on N
 Play stop:Play modfile "Music\metal_heads.mod"
 Load image "images/introscreen.bmp",0,20   'startup screen show on N
 'to do --- the menu stuff and so on
 Do :Loop Until Inkey$=" "
 preload_SFX
 CLS

 'get world map
 loadworld
 loadindex



 's
Edited 2023-10-17 22:29 by matherp
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4247
Posted: 12:56pm 17 Oct 2023
Copy link to clipboard 
Print this post

On the VGA version 50708RC8 and pet18m.bas

program uses 28k (32k on disk)
library uses 86k
saved variables: not used
RAM: 26k (20%) variables
    62k (48%) general
    40k (32%) free

I am sure we will need at least 10k more ram to implement saving and restore, and 10k on arrays during AI procesing. So we would have sufficient RAM as I see it now.
Program space is plenty. I guess we will end up around 60-70k. The AI section is huge (the core is small and complex, but there are so many exemptions), and only the beginning is implemented.

Volhout
Edited 2023-10-17 23:00 by Volhout
PicomiteVGA PETSCII ROBOTS
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 06:33pm 17 Oct 2023
Copy link to clipboard 
Print this post

Volhout
for the new function in  BLIT COMPRESSED address, x, y [,col] here is the new Spriteset with Magenta (255,0,255) as transparent color.
Now they got Black in it.Look even better for my taste.
Now almost as good as on the PSP   



Sprites3.zip

For those who are interested...
my simple helper tool in MMB4Windows.. which scans the Bitmap and generates the *.spr files :

'--------------------
'Information of Source here
FN$="spritesMix_bearbeitet.bmp"
W=24
H=24
num=86
'--------------------
'
Dim Col(15):Restore colors:For f%=1 To 15:Read Col(f%):Next f%
cls
load bmp FN$
 x=0
 y=0
For TNR=0 to num-1

  tn$="sprites3\SP3"+hex$(tnr,3)+".SPR"
  open tn$ for output as #1
  print #1,str$(W);",1,";STR$(H)
  for y1=y to y+H-1
     WT$=""
       for x1=x to x+W-1
         C=Pixel(x1,y1):cl=0
         for n= 0 to 15:if C=col(n) then cl=n
         Next
         wt$=wt$+hex$(cl,1)
       Next
     ?#1, wt$
   next
   box x,y,w,h,,rgb (white)
 close #1
inc y,h:if y>383 then y=0:inc x,w
next TNR


colors:
'--Colorscheme accordung to Spritecolors
Data RGB(BLUE),RGB(GREEN),RGB(CYAN),RGB(RED)
Data RGB(MAGENTA),RGB(YELLOW),RGB(WHITE),RGB(MYRTLE)
Data RGB(COBALT) ,RGB(MIDGREEN),RGB(CERULEAN),RGB(RUST)
Data RGB(FUCHSIA),RGB(BROWN),RGB(LILAC)

Edited 2023-10-18 04:56 by Martin H.
'no comment
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4247
Posted: 08:03pm 17 Oct 2023
Copy link to clipboard 
Print this post

Martin ?

It’s it worth going all this way. I like your dedication, but think it is a sh*tload of work,
And, since N doen not hide.this color, you cannot use the same sprite on N and L ???
What happens when you do CLS? Do you need to use black on L, or pink?

Volhout
P.s. I ask this because I was not able to solve similar problem with the logic analyzer.
There was a change in foreground and background in tiles, and it resulted in the only graphical element (a BMP) being displayed inverse. And no way to fix it.
I have to redraw the bmp, which has not happened yet.
P.p.s that is also the reason I am not using flash yet. Keep using library. That works well. Everything is build around it.
Edited 2023-10-18 06:14 by Volhout
PicomiteVGA PETSCII ROBOTS
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 08:28pm 17 Oct 2023
Copy link to clipboard 
Print this post

  Volhout said  Martin ?

It’s it worth going all this way. I like your dedication, but think it is a sh*tload of work,
And, since N doen not hide.this color, you cannot use the same sprite on N and L ???
What happens when you do CLS? Do you need to use black on L, or pink?

Volhout

hmm, Since I've been busy with pixel pushing until now, I haven't gotten around to trying out your last version with the last RC version yet. I'll test it tomorrow and see if I can get the new sprites integrated (just the sprites,which are allways on L, not the tiles or items. Then I can answer the questions
Edited 2023-10-18 06:31 by Martin H.
'no comment
 
Amnesie
Guru

Joined: 30/06/2020
Location: Germany
Posts: 396
Posted: 08:42pm 17 Oct 2023
Copy link to clipboard 
Print this post

  Martin H. said  
Now they got Black in it.Look even better for my taste.


This looks really amazing! Great work!

Greetings
Daniel
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 08:52am 18 Oct 2023
Copy link to clipboard 
Print this post

  Volhout said  Martin ?

It’s it worth going all this way. I like your dedication, but think it is a sh*tload of work,

was not THAT much, just Layer has to be Magenta now to be Trasparent.
here the version with those Sprites
needs RC10 to run correct as black was always transparent on Layer in the previous Versions. Peter was kind enough to include this.
Needs to load the new Sprites csub to Library and the new Index (included in  the Zip File)
Pet18m1.zip

you are right, the ingame music works but is partly to load ..will fix this
Edited 2023-10-18 19:52 by Martin H.
'no comment
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4247
Posted: 11:56am 18 Oct 2023
Copy link to clipboard 
Print this post

Hi Martin,

Tonight I will try the changes. I am excited to see the improvement.
If this is the way forward, I will issue a new "complete" package under pet19.
Including a new library.

What MOD files do you want in the package? All music files, and the combined MOD file?
Do you still want to add the individual SFX files ?

Volhout
PicomiteVGA PETSCII ROBOTS
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 12:17pm 18 Oct 2023
Copy link to clipboard 
Print this post

there was a a missing magentabox when moving parts ..I fixed it
also I added a smooth Fade in and Out (kind of) to and from the startmenu
Something like this is fadeScreen in the original source code :-)

Pet18m2.zip

The Mod files, as we have are without the SFX, I still have to fit all together in 125 k ..
I have to be in the mood to make music and be quiet accordingly. I will gradually create the 3 changed in-game songs and add the beep to the intro song.
Win and Lose Mod dont need SFX

here a cleaned versipn of
sfcmetallicbop.zip
Edited 2023-10-19 02:17 by Martin H.
'no comment
 
Bleep
Guru

Joined: 09/01/2022
Location: United Kingdom
Posts: 512
Posted: 04:54pm 18 Oct 2023
Copy link to clipboard 
Print this post

Hi,
I've got a working LCD version, Martin, this should work on your GameMite, it's working on mine. :-)
I have updated all of my library to latest and this is Martins latest Pet18m2.bas with a couple of changes for LCD.
In short all I have done and I'm not sure it is a full answer, is to modify lines around 165, also the writeplayer_m subroutine; In there I have made the player write directly to the n layer, and removed the CLS and Box... lines, otherwise that's about it, but as I say, I'm unsure it is a final answer.
Regards Kevin.

lcdpet.bas.zip
 
lizby
Guru

Joined: 17/05/2016
Location: United States
Posts: 3150
Posted: 05:11pm 18 Oct 2023
Copy link to clipboard 
Print this post

  Bleep said  I have updated all of my library to latest

Can you provide that library .bin file?
PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed
 
Bleep
Guru

Joined: 09/01/2022
Location: United Kingdom
Posts: 512
Posted: 05:23pm 18 Oct 2023
Copy link to clipboard 
Print this post

Just noticed what I've done will stop animations, so I'll have another look. :-)
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 05:49pm 18 Oct 2023
Copy link to clipboard 
Print this post

  lizby said  
  Bleep said  I have updated all of my library to latest

Can you provide that library .bin file?

yes please :-D  
'no comment
 
Bleep
Guru

Joined: 09/01/2022
Location: United Kingdom
Posts: 512
Posted: 06:51pm 18 Oct 2023
Copy link to clipboard 
Print this post

Hi Martin,
I assumed you would have an up to date library?
Anyway, here is a new LCD basic version, and library. It now uses all of Peters new layers and background merges and appears to be working on a GameMite as far as I can tell.
Regards, Kevin.


petrobot.zip

Just realised in game sounds are not working right, maybe I need Peters, very latest?
Edited 2023-10-19 04:55 by Bleep
 
Martin H.

Guru

Joined: 04/06/2022
Location: Germany
Posts: 1114
Posted: 07:10pm 18 Oct 2023
Copy link to clipboard 
Print this post

Hi Kevin..
On the Gamemite, after updating to the latest Firmware ..
This happens:

library delete
> library disk load "LCDLIB.BIN
Error: Invalid address - resetting
PicoMite MMBasic Version 5.07.08RC10
Copyright 2011-2023 Geoff Graham
Copyright 2016-2023 Peter Mather

in an endless loop
'no comment
 
Bleep
Guru

Joined: 09/01/2022
Location: United Kingdom
Posts: 512
Posted: 07:22pm 18 Oct 2023
Copy link to clipboard 
Print this post

Hi Martin,
Don't know, I've literally just reloaded Peters very latest and then loaded the lib file fine. I'll repack the zip for you below, in case.
To get over the mod file playback problem, remove the 'b' from the framebuffer merge on line 173, I'll report the problem to Peter.
PS. I've just found that if you leave it running long enough it eventually resets itself!
Regards Kevin.

PS, just noticed, it should be "pet_lib.lib" not .bin but that should not cause a crash.

petrobot.zip
Edited 2023-10-19 05:25 by Bleep
 
     Page 15 of 38    
Print this page
© JAQ Software 2024