Announcement

Collapse
No announcement yet.

PROBLEM

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

  • PROBLEM

    HI,

    I'm new with DSL SCRIPT LANGAGE , i have my code but i don't understand how i test my programm , how i write it in the card SD and how i can read from SD Card and excute in the Oled 160 G1

    i have the workshop 3 , i compile my code in the run environement ,

    #Run(Goldelox,COM4,9600,5,wrap)#include "4DScript_16bitColours.inc" InituSD$readCSD $openinitautobaudclear ReplaceBackground(Yellow)Line(0, 0, 120, 0, fuchsia)Line(120, 0, 120, 140, fuchsia)Opacity(opaque)string(0,0,2,lime,"Some text")Delay(5000)ClearSetBackground(black) sound(5000,1000)delay(1000)
    i have a problem : G: device not removable


    you can explain me about this in general ?


    THANKS
    AUDI

  • #2


    Don't know why you have chosen the scripting language to 'start with'.

    The language is part of SGC and is being phased out, you can find the commands in the SGC command set manual.

    For new Goldelox work you should consider Designer, ViSi or Serial, read the description tab here http://www.4dsystems.com.au/prod.php?id=172

    The only think I can see wrong with your script is that $OpenInit should be the first 'executable' statement as this is needed to Open the com port and send autobaud('U') and then checks for an ACK. Up to 10
    retries are performed.
    Mark

    Comment


    • #3
      THANKS SO MUCH FOR YOUR REPLY

      I HAVE A PROJECT AND ONE OF MY PARTS CONSISTS IN DISPLAY DATA ON THE OLED 160 G1

      SO I READ MANY DATASHEET AND I UNDERSTAND THAT IF I WILL WRITE MY CODE IN THE MEMOPRY CARD SD , I WILL USE A SCRIPT NOT 4DGL , ITS RIGHT OR NO ?

      I CAN WRITE MY CODE WITH 4DGL LANGUGAGE AND AFTER I WRITE IT IN THE MEMORY CARD ? WHAT IS THE WAY FOR THIS ?

      I WILL YOU USE OLED INDEPENDANT FOR PC OR MICROCONTROLLER , I USE IT ALONE , SO I WANT RUN MY CODE AUTOMATICLY , AND AFTER I USE A FPGA FOR OTHER DATA

      EXCUSE ME IF MY QUESTIONS AND IDEAS ARE BASIC , because its the first time , i use this

      i will now use THE 4D WORKSHOP Last version ( with designer ) but i use in this , my code 4GDL .. so now i don't know what is the way to write my code in SD card , and read it after ( oled alone independing for PC)

      this is my code 4DGL :

      #platform "GOLDELOX" #inherit "4DGL_16bitColours.fnc" func main() gfx_ScreenMode(LANDSCAPE) ; // change manually if orientation change print(" MARCOPOLO4\n\n") ; print(" DONNEES SISMIQUES\n") ; // replace with your code// gfx_Line(0, 0, 0, 127, YELLOW);//gfx_Line(155, 0, 155, 120, YELLOW);gfx_Line(0, 127, 159, 127, YELLOW);// gfx_ChangeColour(BLACK, RED); endfunc repeat // maybe replace forever // this as well endfunc


      THANKS SO MUCH
      AUDI

      Comment


      • #4


        On Goldelox, 4DGL code can only reside in flash memory.

        So you would have to write one program and that program would listen to the serial port and perform 'macros' based on what it receives serially.

        Depending on what you are doing this could be far simpler than SGC Scripts.
        Mark

        Comment


        • #5


          Hi,
          I want write a code in the SD card and run it automaticly independig for PC,

          What i will do for that ?
          AUDI

          Comment


          • #6


            Why must the code live on the uSD card?
            Mark

            Comment


            • #7


              Because my screen oled 160 G1 will be integrated in my remiote controle and i have a communication from FPGA to oled
              So , i program a part of my display on oled ( axe x, axe y ) title .. This things i want to programmed it independently so i want to write this programm that can trace the axe x and axe y and title and a logo image in the card sim ..

              Thx so much

              I'm waiting your reply
              AUDI

              Comment


              • #8


                Yeah, OK, Keep using SCG scripts
                Mark

                Comment


                • #9


                  i use work shop IDE 3 to test my code ?

                  so my code :

                  #Run(Goldelox,COM4,9600,5,wrap)#include "4DScript_16bitColours.inc" InituSD$readCSD $openinitautobaudclear ReplaceBackground(Yellow)Line(0, 0, 120, 0, fuchsia)Line(120, 0, 120, 140, fuchsia)Opacity(opaque)string(0,0,2,lime,"Some text")Delay(5000)ClearSetBackground(black) sound(5000,1000)delay(1000)

                  $openinitautobaud

                  will be before
                  InituSD $readCSD ?


                  you can explain me this way of writing a programm in card sim with SGC Script ?

                  THANKS SO MUCH
                  AUDI

                  Comment


                  • #10


                    The SGC manual has (brief) descriptions of all the commands.

                    There are also examples of all the commands in the samples folders.

                    Please try there and then ask again, if anything is still not clear
                    Mark

                    Comment


                    • #11


                      I WRITE THE FILE autoexec.4DS IN THE CARD SD by attached the adapter to the PC


                      #Compile(Goldelox,COM4,9600,5,Wrap)#include "4DScript_16bitColours.inc" InituSDClearSetAddress(0) Line(0, 0,0 ,127, red)Line(0, 127, 159, 127, red)string(1,0,0,white,"donnees sismiques")string(21,14,0,white,"temps")

                      AND IT WILL BE WRITE INDEPENDLY WHEN I INSTALL THE RUN JUMPER ?
                      AUDI

                      Comment


                      • #12


                        You don't need the InitUsd, or the SetAddress, but yes, the run jumper should cause that to run, make sure you put an exit at the end.
                        Mark

                        Comment

                        Working...
                        X