Announcement

Collapse
No announcement yet.

Help a beginner jin a simple project please :(

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    Hello Mark,

    i am attaching the project i am trying all this days as you requested.
    I also attach a small sample gif,similar to the one i work.I cant attach the one i work yet because its huge.

    I would like when the screen will power up to start with a welcoming gif and a sound and then the next gif to play for ever.
    Can you please correct my mistakes and modify this code for me to do this?

    Thank you!!
    Kind Regards
    George
    Attached Files

    Comment


    • #32
      Here it is, have a look at the differences to what you sent, there wasn't much wrong, you should try and understand the differences

      Attached Files
      Mark

      Comment


      • #33
        Hello Mark..i am not winning at all ...having a hard time and getting sad with this..once i got your zip and tried to use it..i must have done something and the program was crashing
        I had to uninstal it , delete all files because something was upseting it and reinstal it
        It now works fine So today i had to start all over.I am expirementing all day with no luck …now I'm tired and must sleep.
        As i said previusly i would like to have ,a starting image for 4 sec with a starting sound, and then a gif to play for ever.

        I attach you the zip file again because all changed.
        Once you unzip you should find the "my new test try 30march.ImgData" which contains the starting image and the gif movie ,the 4Dg and 4DViSi and the staring wav sound i want to be heard ..

        For the code you will see i have done the following steps:
        1-I stared fresh with the UserImages.zip you attached me in your post #12
        2-In order to play gif i changed in line 24 the ( iUserImages1; ) to ( iVideo1; )
        3-the gif did not change orientantion so on line 42 i added ( gfx_ScreenMode(LANDSCAPE) ; // change manually if orientation change ) as you say in post #23
        4-for the starting image i add an image as an object, and use 'paste code' after the 'file_LoadImageControl()' ...dont know if its been paste and where
        5- i added line 62 and paste 'pause(4000) ; to show the starting image for 4sec
        6- to play a starting sound i added line 20 file_PlayWAV("fname1.wav");

        I get errors and its not working. .
        could you please have a look ,correct what have done wrong and attach it back for me please?
        I would like to have this project tomorrow for my presents to the family….also i have bought and two uLCD-28PTU that i would like to use the same code you will attach..
        it should be compatible …?

        Thank you in advance my friend,
        Goodnight from Greece
        Regards
        George

        Attached Files

        Comment


        • #34
          I've fixed the file again and attached the only one that is different.

          Please look at this carefully and compare it to what you had and try and understand the differences and where the file goes.

          You seem to be running around in circles.

          For the 28PTU just change it in Project, Display
          Attached Files
          Mark

          Comment


          • #35
            Hello Mark,
            thank you! thank you! thank you!
            My eyes are not trained to read the code as this is my first time ..but now i compare and i can see the deferences !


            Now i am playing the starting image , and i can control the sec of delay, and then i can play the gif for ever !

            But the sound insist not to play and the orientation does not change
            I only want to change the orientation because of the place i will put this screens the best viewing angle is portrait reverse.
            It seems that this command gfx_ScreenMode(LANDSCAPE) ; // change manually if orientation change locks the orientation to landscape.

            And with out this command screen shows to portrait…what would be the command for portrait reverse?
            Maybe gfx_ScreenMode(PORTRAIT REVERSE) ; // change manually if orientation change

            Regarding the sound…i have tried the other five screens just in case the speaker is not working but they r all the same..
            In which folder i should place the sound file for the program to pick it up during upload?…or i just paste it in the micro sd?

            Thank you again!
            Kind Regards
            George

            Comment


            • #36
              Sorry, You need to 'also' change the orientation in the project. Go into Project, Display, change the orientation there and click OK.

              The Wav file you included in your project was called "track1.wav" and it plays just fine for me.

              It needs to be manually copied to the root folder on the uSD.

              If you are using a different wav file, then maybe that is the problem. a) the name in the program will need to be changed and b) the format will need to be correct, this can be easily checked by creating a Dummy Genie project and adding the WAV to a sound object, it will tell you if it is compatible when you add it.
              Mark

              Comment


              • #37
                Hello Mark,
                yes i manually pasted the sound file in the usd and plays fine now.. didn't know thank you!.

                Regarding the orientation i do change it but it makes no deference.I confirm the change in the program but not on the screen.
                The only deference is that with out this command i get portrait and with the command i get landscape.

                In visigeni the orientation works normally….any ideas?
                Thank you!
                Attached Files

                Comment


                • #38
                  Have a look at the program. When you use ViSi it needs changing in two places, once in Workshop and once in the program.

                  If you have the program similar to what I sent you, you will see
                  Code:
                      gfx_ScreenMode(LANDSCAPE) ; // change manually if orientation change
                  Just after main, just change it to be
                  Code:
                      gfx_ScreenMode(PORTRAIT) ; // change manually if orientation change
                  or maybe PORTRAIT_R, whatever you have set in your Project
                  Mark

                  Comment


                  • #39

                    Regarding that "pause" does it control only the duration of the starting image and the duration of the sound?
                    Or the sound just plays once ?

                    Thank you Mark…going to test orientation now!

                    Comment


                    • #40
                      Pause just pauses the program, and since the image display is just prior it causes the image to be displayed for 4 seconds

                      The sound will keep playing through a pause.
                      Mark

                      Comment


                      • #41
                        Yep reverse portait works ...everything is fine
                        Thank you for your time Mark,your help was priceless ...i was right i chosen 4D products !
                        All left for me now is to work the gif i want to load...they show litle slow...so i will play around with photoshop to se if i can improve speed..maybe the file is big..
                        Thanx again for everything!

                        Comment


                        • #42
                          It won't have anything to do with photoshop.

                          At faster speeds It's mostly to do with the size of the image, the Picaso processor can render 650,000 pixels per second from uSD.

                          If the .GCI file is fragmented then this will slow things down a bit.

                          Of course at the moment, your code says
                          Code:
                              var private speed := 1000;
                          Which will mean 1 second per image, you can lower this if you like.
                          Mark

                          Comment


                          • #43
                            Hello there Mark,
                            hope everything is well your end.

                            I got some more uLCD-24PTU and working on the same project i described in the previews posts here (one starting image and after playing gif for ever)

                            I download the final file from your post #34 , and i copy the picaso designer code and paste it to picaso visi .

                            I add a video and an image object but at end after trying to compile i get compiler error "compiler appears not to have created any output"

                            ..what am i doing wrong?
                            Thank you

                            Kind Regards
                            George



                            Comment


                            • #44
                              Hello,

                              If possible, can we have the zip file of the project that you're trying to run with this error so that we can pinpoint the problem.

                              Best regards
                              Bern

                              Comment


                              • #45
                                Hello there Bern,
                                ok i fixed it..

                                Guys...if i may make a comment .. i am at no meanings an experience programmer .Actually with 4D i made my first tries.
                                But this Visi program ... its just NOT user friendly.Why there is an auto-save.
                                I was working on "user image" open from samples ...and i messed up the code and wanted to start fresh.
                                So i just hit X to close my work. When i tried opening again ...all my previous (mistakes ) where saved in result to lost the original "user image" sample.

                                So i had to uninstall the hole program and re download it to reach the original sample..
                                Please at least remove this "auto save function"


                                Thank you very much for all your support and specially to Mark
                                Kind Regards
                                George

                                p.s. watching the news about australia ... wish you all be safe
                                Last edited by george1; 6th February 2019, 01:34 AM.

                                Comment

                                Working...
                                X