Comments (5)
Without having tested anything, I would try the follwing:
- Add the resolution in gfx.c to the enum DISPLAY_MODE_DEFINITION, e.g. replace element 7 with {800,600,8}.
- Send esc[=7h to the Pi
from pigfx.
I just gave this a test. It would be easy to include 1024x768 mode. Graphics are quite slow though and the text is quite small.
from pigfx.
Thanks, I had found initialize_framebuffer in pigfx.c and altered that to 800x600 which seems to work fine - is that reasonable?
from pigfx.
That's probably fine.
from pigfx.
I've added a simple 3 byte command that allows me to select any 1 of 16 resolutions from 320x240 to 1920x1080 - I use the card purely for graphics so all the escape sequences have been replaced with short binary packets. - My screen res routine is below, once tested fully (along with now using a PS/2 kbd) I hope to offer it up for others.
/*Function to allow Z80 to change screen mode by sending 3 bytes only. Added Sept 14 2021.
Command string: 0xff,0xe3,0x40+mode (where mode is 0-f only). */
int state_set_screen_resolution( char ch, scn_state *state ) //function E3
{
static unsigned char mode;
lineparms[parm]=ch & 0x0f; //;low 4 bits contain mode data
mode=lineparms[0];
switch (mode)
{
case 0x01:
initialize_framebuffer(400,300,8);
break;
case 0x02:
initialize_framebuffer(320,240,8);
break;
case 0x03:
initialize_framebuffer(640,480,8);
break;
case 0x04:
initialize_framebuffer(800,600,8);
break;
case 0x05:
initialize_framebuffer(1024,768,8);
break;
case 0x06:
initialize_framebuffer(1280,800,8);
break;
case 0x07:
initialize_framebuffer(1600,900,8);
break;
case 0x08:
initialize_framebuffer(1920,1080,8);
break;
}
state->cmd_params_size = 0;
state->next = state_fun_normaltext;
return 1;
}
from pigfx.
Related Issues (20)
- replaceLFwithCR + sendCRLF don't do anything HOT 21
- Compiling Error HOT 5
- Command for filled/empty shapes resulting in the same filled shape?
- How to load custom fonts? HOT 2
- [Feature request?] Change baudrate interactively HOT 4
- Feature request: Screen saver/blanker
- Bypass PIGFX card without removing it? HOT 1
- Compile fail. HOT 2
- unable to correctly set baudrate. HOT 14
- USB keyboard feature not working. HOT 11
- Pi/KBD freezes after several hours. HOT 8
- Having troubles with Pi Zero W HOT 1
- Composite output HOT 4
- Something not right, with apps that request number input and do not recognize enter key. HOT 3
- New Line/Enter not working in certian situations. HOT 5
- Resolution 800x480
- Pi pico ? HOT 5
- Hotswap USB keyboard...is this possible? HOT 2
- Qemu instructions and scripts out of date HOT 2
- Screen resolution of 1920*1080 possible
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pigfx.