Jump to content

inmarket

Moderators
  • Posts

    1,280
  • Joined

  • Last visited

  • Days Won

    4

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

inmarket's Achievements

µGFX Guru

µGFX Guru (4/4)

  1. Also check you are not running X. If it is running it will take over the framebuffer device and then ugfx will not be able to set the video mode.
  2. It looks like the "failed to set video mode" was correct. When you turn off USE_SET_MODE it assumes that the video mode has been set correctly before the ugfx application starts. This is obviously not true in your situation. I am surprised it was able to display anything at all. Whilst I haven't had a look at the code recently, from memory it tries to auto-detect the correct mode by looking for a framebuffer mode that matches the pixel format. Some questions here that might help you find the problem: 1. The original pi project was against an early pi hardware model. What model are you using? 2. What Linux variant are you using? Is it the same as the sample project? I suspect not given the differences in compiler flags. Your compiler obviously does not support the flags required by the original pi. 3. Check if the kernel you are using even has the Linux framebuffer compiled into it and what modes it supports. This is the most likely reason it is not working for you.
  3. I have had a decent look at this. Unfortunately it is not easy to fix. The issue is that gwinPrintf is processing the string byte by byte rather than utf8 character by utf8 character. This is completely consistent with the original C standard printf but definitely not what you need. To get around this in the short term gsprintf it into a text buffer and then string print that. Note: even with this, %c will not work for utf8 extended chars but %s will. I am currently deep in implementing generic rotation for text drawing for ugfx v3 so it will probably be a while before I can come back to solve this properly.
  4. Some adjustments are made by the window manager for things like borders. There is also a difference between inner and outer dimensions. The particular details I can't remember off the top of my head. Have a look through the code to see.
  5. Sorry, I have been away and unable to respond. I will be back this coming weekend and will have a good look as soon as I can. The most likely reason is gwinPrintf is processing byte by byte rather than character by character.
  6. A simple way is to just add a timeout value of x seconds instead of gDelayNone. If you get a NULL response then you have a timeout and the screen can be turned off. A non-NULL response can turn the screen back on if it was off.
  7. Hmm. Without looking at the code, it looks like a utf8 encoding problem. The reason I have this suspicion is that for the label you are getting a single character output, for the console you are getting a two character output. I suspect that while the two strings look the same they are actually encoded differently. Both the console and the label use the same underlying font routines so the only way they would give different output for the same input is if perhaps the console is printing byte by byte instead of character by character or string print. Try putting the string into a variable and then using that variable to print both the label and the console. If you get the same result let me know and I will go digging.
  8. Mixing licenses is not usually a problem unless one of the licenses is expansive i.e. it tries to govern source code not explicitly licensed under its own license. The most obvious example here is GPL which says you need to publish source code for the entire project (not just the GPL portion) if you distribute a binary. This is called "copy-left" and is incredibly restrictive particularly for commercial applications or when other source code in the system has intellectual property considerations. LGPL however is perfectly fine. Somewhere on the ugfx site or in the documentation is a good explanation of this particularly with regard to GPL. As always when mixing licenses you need to meet the conditions on each license.
  9. That screen needs to include the directory that has that stm header file. Your start up file, your compiler is complaining that it doesn't understand the assembly language. These are both problems relating to your ide and compiler. While we try to help here, we are not experts on those tools, we are ugfx experts. If the clues above don't help you, you will need to get help on a forum that understands your ide and compiler rather than here.
  10. with regard to your 2nd screen, that looks like you are using the wrong assembly language variant to compile that start up file. Use the start up file that matches your ide compiler, or alternatively, some ide's allow you to specify the assembler you use.
  11. Most likely cause for this is that the include directories path is not correct. I am not sure how to specify these in your ide, probably in the compiler options. These end up as -I directives in the compiler arguments. The -I directives must include the directory containing those stm header files.
  12. BTW, a native image in ugfx terminology is a image that has the same pixel format that the ugfx system uses in an unpacked pixel arrangement (maximum of 1 pixel per byte, word or dword depending on the number of the pixel bits)
  13. You can use the BMP image handling in ugfx. BMP images support a 1 bit per pixel format. The only thing you may need to do is to fabricate a BMP header. Because BMP also support RLE encoded formats you may also be able to compress your 1 bit images and so save rom/ram. Writing a bitblit routine for your driver to handle your "special format" image is probably not the best way to handle this. Similarly with your alpha request, use the image processing support built into ugfx. For example, ugfx handles transparent gif's. It also handles PNG images with an alpha channel although alpha blending is supported to varying degrees based on your display controller.
  14. Ginput handles mouse or touch events and any other input such as keyboard.
  15. It sounds like something is going on with your memory allocator. The uGFX logo is actually not an image. It is a series of rectangles drawn on the screen. It is therefore possible that this call is the first call to the memory allocator. That is something you can test and debug. The other possibility is that the image is corrupt somehow. This is easy to check by looking at the parameters that are going to be used by the palette allocation and seeing if they are reasonable. Another possibility is that you have stack checking turned on in your compile. Many memory allocators are assumed to be single threaded and will hard-fault if running on a thread on a stack other than the main threads. Given you are running FreeRTOS which is multi-thread aware you can assume that its allocator is multi-thread capable however still check that you are compiling without stack checking turned on.
×
×
  • Create New...