Jump to content

manoj

Members
  • Posts

    45
  • Joined

  • Last visited

Posts posted by manoj

  1. Hi, i remember I got started with ugfx by using some template project file, But now I am trying to build my own PCB to keep the cost at ultimate low I want to eliminate many external component on STM32f7-Discovery board..

    Main concern is I don't know how to make ugfx to only use the internal ram on the MCU it self.

    Anyone has any idea how to go about this ?

  2. Hi @Joel Bodenmann and @inmarket

     

    is this is a spelling error below at the if condition you spell it as logfile in small cap but then the GFILE object is logFile ?

     

    void LogInfo(const char* msg) {
        GFILE* logFile;
        
        logFile = gfileOpen("info.txt", "a");        // Open the file for append
        if (logfile) {
            gfileWrite(logFile, msg, strlen(msg));
            gfileClose(logFile);                    // Close the file again
        }
    }

     

  3. Hii all, I got my fatfs working but when I try sample code it always goes and stuck gfxHalt(), 

    i tried two type gfx.conf but not working 

    First Time :

    #define GFILE_FATFS_EXTERNAL_LIB TRUE 
    #define GFILE_NEED_NOAUTOMOUNT		TRUE
    #define GFILE_NEED_PRINTG			TRUE

    Second Time :

    #define GFILE_NEED_FATFS			TRUE
    #define GFILE_NEED_NOAUTOMOUNT		TRUE
    #define GFILE_NEED_PRINTG			TRUE

    Both ways It ugfx FATFS DEMO don't work for me, I am doing wrong anywhere ? 

  4. Hi, thanks for your reply. I will try to fill the heap with known patter and see. and when I set the gfx_os_heap_size does it mean it's dynamically allocated only for ugfx usage and could not conflict with other code section that uses malloc ?. 

  5. I see, thanks to pointing it out. Is there anyway to monitor my stack and heap real time ?..... I am using the stm32f7 dis board package, so the uGFX only uses the internal ram during code execution and the external ram only for frame buffer ? am I right ?

  6. hi also found out why my own implementation of keyboard don't work but gwin example worked as mentioned last time is because few defination in  ugfx config


    //#define GEVENT_ASSERT_NO_RESOURCE                    FALSE
    //#define GEVENT_MAXIMUM_SIZE                          32 //dEFAULT VALUE: 32
    //#define GEVENT_MAX_SOURCE_LISTENERS                  3 //dEFAULT VALUE: 32

    commenting out the three stuff got my gevent listening to my keyboard, do you mind to tell why it happens

  7. Hi, got it working using the demo file but I noticed the keyboard is only displayed on screen if I define below statement, heap size

    #define GFX_OS_HEAP_SIZE                         2000

    , mind to tell why ?. BTW how to estimate hw much stack and heap size is required for my uGFX GUI implementation ?

    .  

  8. Sorry, I hope someone will help. 

    I do look at demo/modules/gwin/keyboard.

    Below is my code I tried but no luck, moreover I try setting breakpoint at few lines related to keyboard it's did not stop anywhere. Which means my key presses are not listened at all. How do I go about is it uGFX config or bugs or etc. Anyone who have done reading char from keyboard event mind to help ? and is my english bad that most of you guys don't understand what I am talking about ?

     

    Cheers !

     

    if (((GEventKeyboard*)pe)->bytecount >0)
                        {
                            pk = (GEventKeyboard *)pe;
                            for (int x =0; x < 4; x++)
                                {
                                    dynamic_array[x] = (uint8_t)pk->c[x];
                                    dynamic_array[1]++;
                                    //gwinPrintf(ghTextedit1, "ERROR");
                                }

  9. The documentations is quite poor, but I know you are very busy with uGFX dev.. which most likely need to dig down the code to understand what's happening. I am very confused between gwin_keyboard and keyboard.. How do we read a char from gwin_keyboard ? I am only receiving the trigger for GEVENT_GWIN_KEYBOARD in switch statement only when I press return button no reaction when I press characters like a b c d and so on. What I have tried to change the parameter of  source attachers   geventAttachSource(&glistener, gwinKeyboardGetEventSource(ghKeyboard1),GLISTEN_KEYTRANSITIONS|GLISTEN_KEYUP);  GKEYBOARD_ALL_INSTANCES) none of this seems to help me.. I really hope there is a documentations says how to attach the source from gwin_keyboard(virtual) to listener and how to retrieve each character from the virtual keyboard. Can you help me clear this doubt out. I promise I will write a brief explanation a-z for new uGFX comers to use the library with ease.

     

    @Joel Bodenmann @inmarket

  10. @Joel Bodenmann

    Does the code below made sense ? I cast the pe (which is geventWait return ) to a GEventKeyboard but seems I cannot access the byte.. Am I doing anything wrong ?

    pe = geventEventWait(&glistener,TIME_INFINITE );
            switch (pe->type) {
                {
                case GEVENT_GWIN_BUTTON:
                    if (((GEventGWinButton*)pe)->gwin == touch_button_df_pg) {

                            gwinDestroy(ghContainerPage0);
                            guiCreate();
                        //gwinPrintf(ghTextedit1, "fgdfg");
    //                    createPagePage1();
    //                    guiShowPage(1);
                    
                        //(((GEventGWinButton*)pe)->gwin == ghButton1)    
                                
                        break;
                    }
                    
                    else if (((GEventGWinButton*)pe)->gwin == ghButton1)  // main page
                        
                    {
                            gwinHide(ghContainerPage1);
                            gwinDestroy(ghContainerPage1);
                            
                        createPagePage0();
                        guiShowPage(0);
                        break;
                    }
                    
                }
                break;
                case GEVENT_GWIN_KEYBOARD || GEVENT_KEYBOARD:
                {        
                if (((GEventKeyboard*)pe)->bytecount >0)
                        {
                            pk = (GEventKeyboard *)pe;
                            for (int x =0; x < 4; x++)
                                {
                                    dynamic_array[x] = (uint8_t)pk->c[x];
                                    dynamic_array[1]++;
                                    //gwinPrintf(ghTextedit1, "ERROR");
                                }

×
×
  • Create New...