![]() |
Forum Index : Microcontroller and PC projects : Game for PicoMiteVGA: Pico Frog
Page 1 of 2 ![]() ![]() |
|||||
Author | Message | ||||
Martin H.![]() Guru ![]() Joined: 04/06/2022 Location: GermanyPosts: 1270 |
Because of the clarity and if that got lost in the other thread. The playable version of a Fogger style game for the PicoMite VGA. The concept of Frogger is simple. Just get that frog from A to B. Yet it’s a challenge to execute. The Game: Move your frog carefuly. Avoid the moving vehicles. On the river, jump across the logs to get your frog to its “frog home”. There are five of these homes, so you have to repeat this four more times. ![]() The Program: This is the basic structure of the game. What is missing in this Version are levels, lady-frog, crocodiles, Beaver, Flies and diving Turtles. So there is a lot of room for improvement. Developed on PicoMite Version 5.07.05RC.. Tested on Firmaware 5.07.06 and 5.07.07RC6 Actually there are 2 versions of this Game: On for Mixtel90s Pico Game Console, which supports Atari joysticks, NES controllers and/or PS2 keyboard. (many thanks to thwill) picofrog_Game.zip And a Keyboard only Version, for PS2 and Terminal Keyboard control. (thanks to Volhout) picofrog_keyb.zip Thanks to everyone who supported me in this project, matherp and Geoffg for keeping BASIC uptodate Take care Mart!n Edited 2023-04-22 17:34 by Martin H. 'no comment |
||||
Turbo46![]() Guru ![]() Joined: 24/12/2017 Location: AustraliaPosts: 1642 |
Martin, have you considered a version for the Game*Mite and possibly the CMM2? I have fond memories of playing this game on the C64 with my daughter way back when. Bill Keep safe. Live long and prosper. |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
@Martin, Please find attached versions that have been patched to run on Picomite MMBasic 6. Tested on 6.01.00 on both RP2040 and RP2350. I had to "assume" a game speed that is determined by variable h_beat% Change to value to your liking. This was introduced since Peters speed improvements, and the 2350 caused the game to be unplayable (too fast). I have not tested all controllers in the controller version since I do not own a Atari joystick. I will patch up something tonight and confirm that also works (or issue an update to this release). The keyboard version is fully tested. picofrog_6.zip The game is (even without all the added finesse) fun to play... Volhout P.S. Martin, can I persuade you to add some of the finesse (i.e. flies, diving turtles, crocodiles) now. ?? P.P.S. below is a partial patch that runs on Game*Mite. It has achitectural changes because FRAMEBUFFER MERGE needed for LCD corrupts music (delays settick). The game can only be controlled from console keyboard (like the VGA game). Next task is supporting the Game*Mite buttons. picofrog_GM_6b1.zip Edited 2025-08-21 04:13 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Martin, Tom, Below is a port that runs on Game*Mite. It has achitectural changes because FRAMEBUFFER MERGE needed for LCD corrupts music (delays settick). The game can be controlled from console keyboard, or Game*Mite keys picofrog_GM_6b2.zip Volhout Edited 2025-08-21 04:44 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
thwill![]() Guru ![]() Joined: 16/09/2019 Location: United KingdomPosts: 4318 |
Thank you @Volhout, some many interesting things to do and look at, and so little time ![]() Tom MMBasic for Linux, Game*Mite, CMM2 Welcome Tape, Creaky old text adventures |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Hi Tom, It runs fine on GM with RP2350 as is. If you want to run it at GM with RP2040, it is better to change the CPUSPEED to 300MHz. Reason is that at 300MHz, the SPI speed to the LCD is increased from 42 to 50MHz, which makes the FRAMEBUFFER MERGE fit in 23ms. And 23ms is the "tick" of the melody playing. So the tune sounds as good as possible (*). I tried 200MHz as well (also SPI=50MHz) but then the ARM is too slow to process al the data. CPUSPEED = 378MHz also works. Volhout (*) although the tune is very close to original (compliments to Martin) there is at least 1 location where a note comes too early. Could be perfected. Maybe I will. And .. maybe I'll add "the fly" myself. Seems do-able. And I am beginning to find my way in Martin's code. His code is very compact, and only has minor comments. The other features (crocodiles and diving turtles) require additional sprites. And Martin is already using 31 sprites (the max for Pico). More levels..? Maybe... Edited 2025-08-21 19:28 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Martin H.![]() Guru ![]() Joined: 04/06/2022 Location: GermanyPosts: 1270 |
Cant realy test. I still havethe problem that my display often freeses while FRAMEBUFFER MERGE, I tested it with several Displays so I think I have to replace the Pico with another one or Pico2 'no comment |
||||
Mixtel90![]() Guru ![]() Joined: 05/10/2019 Location: United KingdomPosts: 8043 |
Wow..... One of the early programs I typed into a Nascom was Lollypop Lady Trainer. It was a version of Frogger written in Z80 assembler (although it might well have been hand coded at that time). It was rather cool as when the lollypop lady had been hit an ambulance came across to remove the body. :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Hi Martin, Do you have a display that does NOT have touch ? All displays on my 3 Game*Mite's do not have a touch chip (2 x 3.2" and 1 x 2.8"). Maybe that touch chip causes problems at 50MHz SPI bus (although the touch chip is not driven at 50MHz, it is attached to that fast bus). If you run at 252MHz and a 2040, you would only have irregular audio, but it should run. The SPI speed is then lower (default for game mite) I run version 6.01.00b9 on it, and used the 1.31 install package and instructions from this thread to install the Game*Mite on version 6.00.02 and later (in stead of the 6.00.02 in that post, use the last 6.01.00b9 image in the 6.01.00 thread). Instructions Instructions 1.31 install package Volhout Edited 2025-08-21 20:35 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
@Martin, Do you think it would be possible to bring the ADSR from 10 to 5 ,6, or 7 steps ? That would allow a slower SETIICK (from 23ms to 46/38/33ms) which is less CPU intense in relation to the FRAMEBUFFER MERGE. It may be able to run on a GM at 252MHz then. Volhout EDIT: I tried ADSR of 5, and it sounds a bit raw, but runs perfect at a Game*Mite 2040 at 252MHz. So maybe I'll keep this as an Game*Mite options (platform based select). Edited 2025-08-22 19:59 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Martin H.![]() Guru ![]() Joined: 04/06/2022 Location: GermanyPosts: 1270 |
These were values used to approximate the envelope curve. It therefore describes the volume of a tone over time as it is played. The fewer values you use, the closer you get to a simple rectangle, but you can try this if it makes music run more smoothly. ![]() Edited 2025-08-22 21:33 by Martin H. 'no comment |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Please find attached version that uses a 7 stage ADSR for the main music for RP2040, and 10 stage for RP2350. This works well for sound on both Game*Mite platforms. Both platforms use the default Game*Mite CPUSPEED = 252000. picofrog_GM_6b3.zip Volhout Edited 2025-08-22 21:45 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Martin H.![]() Guru ![]() Joined: 04/06/2022 Location: GermanyPosts: 1270 |
Volhout thank you,Game and Music timing works verry well, ![]() Game*Mite doesn't freeze ![]() good job ![]() Edited 2025-08-23 22:09 by Martin H. 'no comment |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Slowly progressing.... Added a fly at random home position, atm it shows half way the game, and remains until time is up. When you nest with the fly, you gain 1 live (max 4 lives). Now I need to find out how to convert the lady-frog sprites to sinking turtles (mini animation) and crocodile (no animation). I think sinking turtles adds more to the game than a lady frog. picofrog_GM_6b4.zip This version is game*mite/LCD(*) only. VGA conversions will follow once this one matures further. Volhout (*) Auto detect : LCD screen console keyboard control, Game*Mite = console control AND Game*Mite buttons. PicomiteVGA PETSCII ROBOTS |
||||
Bleep Guru ![]() Joined: 09/01/2022 Location: United KingdomPosts: 659 |
Hi Harm, I've been trying PicoFrog on my new LCD Pico, it's working fine, but I've found a problem, that may well need reporting officially. When my frog dies for the third time, always my screen turns white and stops functioning, until I power off and on. I have traced it to Sub GameOver, I am having to put a Pause 300 or a Framebuffer Sync in just before you do the Framebuffer Write N, I'm assuming that at this point the background merge is still going on and changing anything to do with the Framebuffer is causing the screen to lock up? I've not had this sort of problem on previous firmware, but have been noticing it quite a lot recently, especially if I Ctl. C out of a program. My setup is a little unusual, in that I am driving the LCD from its own SPI bus. PicoMite MMBasic USB RP2350A Edition V6.01.00b10 OPTION SERIAL CONSOLE COM2,GP8,GP9 OPTION SYSTEM SPI GP18,GP19,GP16 OPTION LCD SPI GP26,GP27,GP28 OPTION SYSTEM I2C GP20,GP21 OPTION FLASH SIZE 4194304 OPTION COLOURCODE ON OPTION KEYBOARD UK OPTION CPUSPEED (KHz) 252000 OPTION LCDPANEL CONSOLE 7,,, 50,NOSCROLL OPTION DISPLAY 40, 80 OPTION LCDPANEL ST7796S, LANDSCAPE,GP12,GP13,GP14,GP15 OPTION LCD BACKLIGHT 50 OPTION TOUCH GP17,GP7 OPTION SDCARD GP22 OPTION AUDIO GP10,GP11', ON PWM CHANNEL 5 OPTION RTC AUTO ENABLE OPTION DEFAULT FONT 7, 1 Any thoughts? Regards Kevin. Edited 2025-08-27 02:03 by Bleep |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Hi Kevin, I experienced this too.But did not investgate it Further. Please bring it to Peters attention. I am interested in your fix, but Peter might have a direct fix, without needing a work around. It happened on the 2040, not on 2350, but if is a critica’s race problem, the faster cpu may hide it. It has nothing to do with your lcd connection since the gamemite Uses system spi for lcd. Volhout Edited 2025-08-27 04:52 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Martin H.![]() Guru ![]() Joined: 04/06/2022 Location: GermanyPosts: 1270 |
picofrog_GM_6b4.zip Hello Harm, I had a chance to briefly try out your new version. It runs great and nearly without freezing the screen on my Game*mite 2040. You've probably noticed that the frog no longer stays in the nest. You can use the same nest over and over again. This makes it impossible to complete the “level.” Is this a bug or a feature? Cheers Martin Edited 2025-08-27 19:03 by Martin H. 'no comment |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
Hi Martin, Oops. I missed that one. That is a major issue. I should have play-tested a bit more. Volhout PicomiteVGA PETSCII ROBOTS |
||||
Martin H.![]() Guru ![]() Joined: 04/06/2022 Location: GermanyPosts: 1270 |
I let picofrog_GM_6b3 run for over 24 houers in endless loop, without freezing the screen. In picofrog_GM_6b4 it sometimes somehow stops to update the screen so you have to play blind. After gameover the startscrean reapears but the "Animation" stops after a short Time 'no comment |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5196 |
@Martin, Thanks for the report. Maybe it is related to Kevin's observation. It won't be before thursday night that I can dive into it. I appreciate you testing. So in essence I have: - crash when GameOver, can be fixed with FRAMEBUFFER SYNC or PAUSE 300 - clearing of all homes when frog reaches a home, so cannot win (5 homes filled). - update screen stops after a while, so you need to play blind (seen on 2040). How do you run the game 24 hours ? What is the trick ? Just let it stand there, restarting each time when all 3 lives are ended ? I may not have waited long enough for it to happen. Volhout P.S. Martin, could I persuade you for designing the diving turtle sprites and the croco ? I imagine 3 sprites for submerged turtles, and 1 croco (similar length to the truck, or 1 block longer). I imagine the tail and the nose of the croco to be relatively narrow, so you die if you stand on them, but the belly would be wider, and could be used to jump on. Or do I divert too much from the original ? For both I would have a new character in the lanes. The croco would just be there in a certain level, and rotate with the logs (as if it was a log). The diving turtles would (like the animations in Petscii) be just a timed pointer change per turtle lane. Edited 2025-08-27 21:34 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
Page 1 of 2 ![]() ![]() |
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |