Page 1 of 5 12345 LastLast
Results 1 to 15 of 72
  1. #1
    offline MOTOCAKER
    Join Date
    Aug 2008
    Posts
    302
    Thanks
    93
    Thanked 997 Times in 145 Posts
    Downloads
    32
    Uploads
    0

    Apliciones Nativas y Bash en su Construccion

    A pedido de un Usuario empiezo esta guia, estaria bueno que el que sabe mas que yo ( no es muy dificil ) vaya aportando lo suyo y lo pondre en el Primer Post!!!

    Esta guia es una ayuda para el que quiera empezar a programar...

    _ _ _ ANTES DE EMPEZAR _ _ _

    Requisitos!

    -Saber Telnetear
    -Saber SAMBA
    -PACIENCIA
    -NO HACER SPAM
    -Saber Algo de BASH


    _ _ _ PRIMEROS PASOS_ _ _

    Antes que nada vamos a tener que saber que es Bash? Como se hacen scripts, como se ejcutan y cual es la diferencia entre el Bash de Linux y el Bash de Nuestro Celular.

    Que es Bash???

    Bash es un shell de Unix (intérprete de órdenes de Unix) escrito para el proyecto GNU. Su nombre es un acrónimo de bourne-again shell (otro shell bourne) — haciendo un juego de palabras (born-again significa renacimiento) sobre el Bourne shell (sh), que fue uno de los primeros intérpretes importantes de Unix.

    Como se Ejecutan??

    Bueno esto es lo mas facil! Cuando terminen de hacer un script lo tienen que guardar asi: nombredelscript.lin, lo suben a la tarjeta de memoria del celular y lo ejecutan ahi!

    Tambien lo Pueden Hacer por Telnet, el cual recomiendo, porque por ahi se ven todos los procesos del sistema!

    Cual es La Diferencia entre Bash en Linux y en Nuestros Celulares??

    Existen algunos Comandos, como por ejemplo "echo", Que cuando uno lo ejectua en Linux tiene una salida a la consola, pero en nuestro celular no se muestra nada...

    El Comando Echo, en el linux muestra lo quie nosotros queremos que muestre en la consola, pero en el celular, nosotros en la pantalla no vemos absolutamente nada, salvo si entramos por telnet que ahi si se ven ( SOLO EN EL TELNET)

    Por eso Existe el SDK del Z6, Que lo vamos a ver a Continuacion

    Si no entienden nada hasta ahora no se preocupen y sigan leyendo, muy dificil empezar no es, cuando se torna mas dificil es querer hacer algo que no existe! jaja

    Como se hacen Scripts

    Cuando uno hace un Script, es recomendable el uso del programa Notepad++ en windows ya que con el podemos seleccionar el lenguaje con el que vamos a trabajar!

    Cuando ejecuten el Notepad++ por primera vez tienen que ir a:
    -Configurar
    -Preferencias

    Se va a abrir un cuadro, eligen la pestaña DOCUMENTO NUEVO
    Ahi seleccionan en formato, UNIX y en leguaje SHELL

    Ya tienen el programa y su configuracion!

    Ahora vamos a empezar!!!

    A continuacion dejo para que se descarguen el Script del zEcualizer, creado por mi, DEMASIADO BASICO, asi les explico parte de los comando!

    zEcualizer

    Abrano en el Notepad++

    A continuacion veran esto:

    #!/bin/sh
    #######################
    # Linuxmod #
    # LinXtend #
    #######################
    if [ "" != "true" ]
    then
    . /ezxlocal/LinXtend/etc/initenv
    fi


    showQ "Hecho Por" "Z6modding.mywebcommunity.org" 2


    showRadio "zEcualizador" "Seleccione uno:" "Desactivado" "BassBoost" "Classical" "Country" "Dance" "HipHop" "Latin" "Oldies" "Pop" "RBSoul" "Reggae" "Rock" "SmallSpeaker" "SpokenWord" "Techno" "TrebleBoost" "VocalBooster" "VocalReducer"
    RADIORES=$?

    if [ -eq 0 ]
    then
    exit
    elif [ -eq 1 ]
    then
    OPCION="Desactivado"
    elif [ -eq 2 ]
    then
    OPCION="BassBoost"
    elif [ -eq 3 ]
    then
    OPCION="Classical"
    elif [ -eq 4 ]
    then
    OPCION="Country"
    elif [ -eq 5 ]
    then
    OPCION="Dance"
    elif [ -eq 6 ]
    then
    OPCION="HipHop"
    elif [ -eq 7 ]
    then
    OPCION="Latin"
    elif [ -eq 8 ]
    then
    OPCION="Oldies"
    elif [ -eq 9 ]
    then
    OPCION="Pop"
    elif [ -eq 10 ]
    then
    OPCION="RBSoul"
    elif [ -eq 11 ]
    then
    OPCION="Reggae"
    elif [ -eq 12 ]
    then
    OPCION="Rock"
    elif [ -eq 13 ]
    then
    OPCION="SmallSpeaker"
    elif [ -eq 14 ]
    then
    OPCION="SpokenWord"
    elif [ -eq 15 ]
    then
    OPCION="Techno"
    elif [ -eq 16 ]
    then
    OPCION="TrebleBoost"
    elif [ -eq 17 ]
    then
    OPCION="VocalBooster"
    elif [ -eq 18 ]
    then
    OPCION="VocalReducer"
    fi
    Resumo el codigo para que no sean tan largo!

    Ahora vamos a anaizarlo por partes

    #!/bin/sh
    Que es esto??? Si todavia no sabes nada de Bash, este la primer linea que se debe poner, todos los scripts tienen esta linea!!

    if [ "" != "true" ]
    then
    . /ezxlocal/LinXtend/etc/initenv
    fi
    Esta Condicion ( asi se llama cuando aparece If y Fi ) debe tambien aparecen en la segunda linea del Script OBIGATORIAMENTE, con ella le avisamos que estamos trabajando en el Ambiente LinXtend!!!

    TODO AQUELLO QUE ESTE ENTRE #### SON COMENTARIOS QUE EL SISTEMA A LA HORA DE EJECUTAR EL SCRIPT NO LEE!!!

    showQ "Hecho Por" "Z6modding.mywebcommunity.org" 2
    Esto es parte del SDK que le hablaba antes y ahora lo vamos a desplegar!!!

    while :
    do

    ## showTextEntry
    ## function :Enter text
    ## alias : showSingleCapture
    ## usage : showTextEntry flag caption prompt
    ## flag : 0 = General; 1 = Password box; 2 = Multi-Input
    ## flag Can be combined. Ifflag=3 (1+2)On behalf of the multinational firms password box
    ## caption Title text input
    ## prompt Text input messages
    ## return: $? = 0 Cancellation
    ## $? = 1 Determined
    ## printfReturn the internal text

    while :
    do
    TEXTNAME=`showTextEntry 0 "showDemo-Text Box" "Porfavor escriba su nombre"`
    if [ $? != 0 ] && [ "" != "" ]
    then
    break
    fi
    done

    ## showNotify
    ## function : Showing the middle text messages
    ## alias : [none]
    ## usage : showNotify caption text icon [time]
    ## caption Heading messages
    ## text Text messages
    ## icon : 0 = Check mark icon; 1 = Information icon; 2 = No icon
    ## time : Tip time information display,In seconds flat, by default2Sec.
    ## return: $? = 100 To automatically shut down
    ## $? = 101 Users button closure

    showNotify "Hello " "Bienvenido a showdemo ver funciones disponibles" 1 4


    ## showRadio
    ## function : Showing single box
    ## alias : [none]
    ## usage : showRadio caption text opt1 opt2 opt3....
    ## caption Heading messages
    ## text Text messages
    ## optx Preferences
    ## return: $? = x(x>=0) Users choose the first option x -
    ## $? = 0 Users Cancel button or hang up keys from
    showRadio "showDemo-Single box" "Por favor, seleccione el botón " Opcion1 Option2 Option3
    RADIORES=$?
    if [ -eq 0 ]
    then
    showNotify "Feedback" " choices" 1 3
    else
    showNotify "Feedback" "" 1 3
    fi

    ## showMultiSelect
    ## function : Show check box
    ## alias : [none]
    ## usage : showMultiSelect caption text opt1 opt1state opt2 opt2state opt3 opt3state ...
    ## caption Heading messages
    ## text Text messages
    ## optx Preferences
    ## optxstate Options initial state
    ## 0 = Not check; 1 = Have check;
    ## return: $? = x(x>=0) Users choose the x box
    ## $? = 0 Users choose0Options or use Cancel button or hang up keys from
    MULSELDETAIL=`showMultiSelect "showDemo-Check box" "Por favor seleccione" Option1 0 Option2 1 Option3 0`
    MULSELRES=$?
    if [ -eq 0 ]
    then
    showNotify "Feedback" " of the options or what has not elected" 1 3
    else
    MULSELDETAIL=`echo -e "n"`
    showNotify "Feedback" ". SON: " 1 3
    fi

    ## showProgress
    ## function : Show of progress
    ## alias : [none]
    ## usage : showProgress command caption [text]
    ## command At the same time the need to run programs or scripts
    ## caption Progress of the Title
    ## text Progress of the text, the default value Please Wait....
    ## return: $? = 1 Users mandatory disqualification
    ## $? = 0 Procedures or completion of the implementation of automatic return to the script
    showProgress "sleep 10s" "showDemo-Progress of the" "Por favor espere 10 segundos"
    if [ $? -eq 0 ]
    then
    showNotify "Feedback" " Really have patience"
    else
    showNotify "Feedback" " a Jixingzi"
    fi

    showNotify "showDemo- Digital Box" "Select figures" 0 3

    ## showNumPicker
    ## function : Showing figures selection box
    ## alias : [none]
    ## usage : showNumPicker min max [cur]
    ## showNumPicker cur
    ## min Minimum values (min>0)
    ## max The maximum value
    ## cur The default value for the initial valuesmin
    ## If you use the second form, mimeRecognitionmin=0 max=99
    ## return:
    ## printf
    ## Cancel! Users cancelled
    ## x (A figure) Users to choose the number of
    NUMPICKERDETAIL=`showNumPicker 1 20 10`
    if [ "" = "Cancel!" ]
    then
    showNotify "Feedback" " choices"
    else
    showNotify "Feedback" " the digital"
    fi

    ## showDatePicker
    ## function : Show date selection box
    ## alias : [none]
    ## usage : showDatePicker [yyyy mm dd]
    ## yyyy Initial Year
    ## mm Initial month
    ## dd Initial Date
    ## The default is to use the current date
    ## return:
    ## printf YYYYMMDD The date format
    ## Cancel no return value
    DATEPICKERDETAIL=`showDatePicker`
    if [ "" = "" ]
    then
    showNotify "Feedback" " choices"
    else
    showNotify "Feedback" " a date."
    fi

    ## showTimePicker
    ## function : Show time selection box
    ## alias : [none]
    ## usage : showTimePicker hh mm
    ## hh Initial hours
    ## mm Initial minutes
    ## The default is to use the current time
    ## return:
    ## printf HHMM Format time
    ## Cancel no return value
    TIMEPICKERDETAIL=`showTimePicker`
    if [ "" = "" ]
    then
    showNotify "Feedback" " choices"
    else
    showNotify "Feedback" " of time."
    fi

    ## showColoricker
    ## function : Color selection box
    ## alias : [none]
    ## usage : showColoricker color1 color2 color3 color4 ....
    ## colorx RGBColor,The metric system that,Up to thecolor30
    ## return:
    ## printf SelectedRGBColor,The metric system that
    ## Cancel no return value
    COLORPICKERDETAIL=`showColorPicker 255 65280 16711680 16711935 16776960 65535`
    if [ "" = "" ]
    then
    showNotify "Feedback" " choices"
    else
    showNotify "Feedback" " of colorsRGBValue."
    fi

    ## showFilePicker
    ## function : File selection box
    ## alias : filelist
    ## usage : showFileicker
    ## return:
    ## printf Selected papers full path
    ## Cancel no return value
    FILEPICKERDETAIL=`showFilePicker`
    if [ "" = "" ]
    then
    showNotify "Feedback" " choices"
    else
    showNotify "Feedback" " of paper"
    fi

    ## showTextContent
    ## function : The text content of the document
    ## alias : [none]
    ## usage : showTextContent filename
    ## return:
    ## nothing
    showNotify "showDemo-Text preview" "Below here is that the demo code" 1 3
    SELFNAME=`busybox which "$0"`
    showTextContent ""

    ## showMsg
    ## function : Information shows that the high-boxes
    ## alias : showQ, showmessagedlg
    ## usage : showMsg caption text type
    ## caption Heading messages
    ## text Text messages
    ## type Information boxes button type
    ## 0 = OkCancel; 1 = YesNo; 2 = Yes; 3 = None
    ## return: $? = 1 OkOrYes
    ## $? = 0 Cancel No Cancellation or hang up button Close

    showMsg "showDemo" "Quieres volver a intentar showDemo" 0
    if [ $? != 1 ]
    then
    showNotify "Farewell" "Gracias por usar showDemo linuxmod ..." 1 3
    break
    else
    showNotify "showDemo" "Por favor espere..." 1 2
    #goto name
    fi

    done
    echo "EXITED"

    Copien lo que esta adentro del ultimo quote al notepad++ y van a entenderlo mejor

    Tambien para enter mejor el SDK vayan al siguiente POST

    [Guia] Scripts con Interfaz de Usuario nativa desde Bash

    Bueno, Ahora seguimos Analizando el Codigo!!

    showRadio "zEcualizador" "Seleccione uno:" "Desactivado" "BassBoost" "Classical" "Country" "Dance" "HipHop" "Latin" "Oldies" "Pop" "RBSoul" "Reggae" "Rock" "SmallSpeaker" "SpokenWord" "Techno" "TrebleBoost" "VocalBooster" "VocalReducer"
    RADIORES=$?
    Como se Explica en el SDK arriba cuando uno escribe showRadio, hace que en la pantalla aparezaca una lista y el usuario tiene que elegir UNA y SOLO UNA opcion! Las opciones son todas aquellas que estan entre ""

    if [ -eq 0 ]
    then
    exit
    elif [ -eq 1 ]
    then
    OPCION="Desactivado"
    elif [ -eq 2 ]
    then
    OPCION="BassBoost"
    elif [ -eq 3 ]
    then
    OPCION="Classical"
    elif [ -eq 4 ]
    then
    OPCION="Country"
    elif [ -eq 5 ]
    then
    OPCION="Dance"
    elif [ -eq 6 ]
    then
    OPCION="HipHop"
    elif [ -eq 7 ]
    then
    OPCION="Latin"
    elif [ -eq 8 ]
    then
    OPCION="Oldies"
    elif [ -eq 9 ]
    then
    OPCION="Pop"
    elif [ -eq 10 ]
    then
    OPCION="RBSoul"
    elif [ -eq 11 ]
    then
    OPCION="Reggae"
    elif [ -eq 12 ]
    then
    OPCION="Rock"
    elif [ -eq 13 ]
    then
    OPCION="SmallSpeaker"
    elif [ -eq 14 ]
    then
    OPCION="SpokenWord"
    elif [ -eq 15 ]
    then
    OPCION="Techno"
    elif [ -eq 16 ]
    then
    OPCION="TrebleBoost"
    elif [ -eq 17 ]
    then
    OPCION="VocalBooster"
    elif [ -eq 18 ]
    then
    OPCION="VocalReducer"
    fi

    Bueno, en este ultimo pedazo, estamos diciendo que pasa si elegimos tal opcion,
    acuerdense que cuadno uno escribe "ALGO=" esta creando una viarible, entonces, si yo eligo, desactivado, el programa crea una variable llamada "desactivado" la cual ejecuta el script Siguiente:

    if [ = "Desactivado" ]
    then
    showNotify "Ecualizador" "Espere..." 1 5
    setconfig /setup/ezx_mp.cfg EqSettingBassBoost 0
    setconfig /setup/ezx_mp.cfg EqSettingClassical 0
    setconfig /setup/ezx_mp.cfg EqSettingCountry 0
    setconfig /setup/ezx_mp.cfg EqSettingDance 0
    setconfig /setup/ezx_mp.cfg EqSettingHipHop 0
    setconfig /setup/ezx_mp.cfg EqSettingLatin 0
    setconfig /setup/ezx_mp.cfg EqSettingOldies 0
    setconfig /setup/ezx_mp.cfg EqSettingPop 0
    setconfig /setup/ezx_mp.cfg EqSettingRBSoul 0
    setconfig /setup/ezx_mp.cfg EqSettingReggae 0
    setconfig /setup/ezx_mp.cfg EqSettingRock 0
    setconfig /setup/ezx_mp.cfg EqSettingSmallSpeaker 0
    setconfig /setup/ezx_mp.cfg EqSettingSpokenWord 0
    setconfig /setup/ezx_mp.cfg EqSettingTechno 0
    setconfig /setup/ezx_mp.cfg EqSettingTrebleBoost 0
    setconfig /setup/ezx_mp.cfg EqSettingVocalBooster 0
    setconfig /setup/ezx_mp.cfg EqSettingVocalReducer 0
    /phone/vibrateprocess
    showNotify "Ecualizador" "Modificado"
    fi
    Aca dice lo siguiente, si eligen desactivo voy a mostrar un cartel que dice espere... el cual dura 5 segundos y tiene un signo de admiracion (por eso el 1), Despues de esperar 5 segundos coy a ir a la carpeta "ftp://192.168.16.2/ezxlocal/download/appwrite/setup/" voy a buscar el archivo ezx_mp.cfg y en el voy a modificar las siguientes lineas (SETCONFIG), cuando termine, voy a vibrar, luego de vibrar voy a mostrar un cartel que diga modificado!


    Bueno, Mi idea era seguir con mas scripts pero realmente stoy cansado, si alguien quiere agregar algo, o decir que no se entiede bienvenido sea.

    Todas las consultas seran anaizadas!!!

    Un Saludo!

    Agrego!!! Si alguien quiere explicar el C++ pero no solo como compilar si no tambien e SDK por lamarlo de alguna manera nos haria un favor enorme!

    SaludoS!
    Last edited by racinglocura07; 10-29-2008 at 06:18 AM. Reason: Automerged Doublepost

  2. 33 Users Say Thank You to racinglocura07 For This Useful Post

    Av3LaR (08-08-2009), CepiPerez (08-24-2009), cool_connor (10-31-2008), c_ro87 (10-29-2008), Dark Hawk (10-31-2008), darkquicksilver (10-29-2008), disckjockey (10-29-2008), Facneo (10-29-2008), Felipe_z6 (08-06-2009), FeRoL (10-29-2008), FFede (08-05-2009), iferlive (11-02-2008), ignacio1 (10-29-2008), jloayza (10-29-2008), Lacman (10-30-2008), leito_sipalki (10-29-2008), luis20 (10-29-2008), marcaregis (10-30-2008), mauriciof_2010 (11-06-2008), MigueL6 (11-18-2008), morpheus_mtx (02-15-2010), negrostmthws (10-29-2008), Neriton Djonne (11-17-2008), painkiller_88 (11-06-2008), pauloknz (09-14-2009), RzL!! (10-29-2008), santiago123 (08-10-2009), santiagofene (10-29-2008), sparvoli2 (08-10-2009), szypd (10-29-2008), vladyvista (10-29-2008), votram (10-29-2008), zapataso (11-02-2008)

  3. #2
    c_ro87's Avatar
    offline MOTOCAKER
    Join Date
    Jan 2008
    Location
    Argentina
    Posts
    848
    Thanks
    678
    Thanked 4,294,967,295 Times in 400 Posts
    Downloads
    16
    Uploads
    0
    POR FAVOR NO HAGAN SPAM!!! borren el post de votram arriba del mio...

    bueno yo aca dejo una aplicacion en bash que renombre fotos y videos y los comandos de voz de acuerdo a la fecha, pero no anda... dejo dos variantes a ver si entre todos logramos que funcione:
    Opcion 1:
    #!/bin/sh
    #######################
    # Linuxmod #
    # LinXtend #
    #######################
    if [ "$LX_ENV" != "true" ]
    then
    . /ezxlocal/LinXtend/etc/initenv
    fi

    showQ "zFotoren" "Desea renombrar?" 0 ||
    {
    find /mmc/mmca1/MyPhoto /ezx_user/download/mystuff/Pictures -name 'LM_*' -printf "mv %p %h/%TY.%Tm.%Td_%TH%TM%TS.jpg\n" | sh
    sleep 1
    find /mmc/mmca1/MyVideo /ezxlocal/download/mystuff/Video -name 'LM_*' -printf "mv %p %h/%TY.%Tm.%Td_%TH%TM%TS.3gp\n" | sh
    sleep 1
    find /mmc/mmca1/MyVoice /ezxlocal/download/mystuff/Voice -name 'Voice*' -printf "mv '%p' '%h/%TY.%Tm.%Td_%TH%TM%TS.amr'\n" | sh
    sleep 1
    showNotify "" "Listo!" 0
    **

    Opcion 2:
    #!/bin/sh
    #######################
    # Linuxmod #
    # LinXtend #
    #######################
    if [ "$LX_ENV" != "true" ]
    then
    . /ezxlocal/LinXtend/etc/initenv
    fi

    showQ "zFotoren" "Desea renombrar?" 0 ||
    {
    find /mmc/mmca1/MyPhoto /ezx_user/download/mystuff/Pictures -name 'LM_*' printf "%d%m%Y_%H%M%S.jpg\n" | sh
    sleep 1
    find /mmc/mmca1/MyVideo /ezxlocal/download/mystuff/Video -name 'LM_*' -printf "mv %p %h/%TY.%Tm.%Td_%TH%TM%TS.3gp\n" | sh
    sleep 1
    find /mmc/mmca1/MyVoice /ezxlocal/download/mystuff/Voice -name 'Voice*' -printf "mv '%p' '%h/%TY.%Tm.%Td_%TH%TM%TS.amr'\n" | sh
    sleep 1
    showNotify "" "Listo!" 0
    **

  4. 6 Users Say Thank You to c_ro87 For This Useful Post

    disckjockey (10-30-2008), Facneo (10-29-2008), kakashiambu (10-30-2008), Neriton Djonne (12-07-2008), santiago123 (08-10-2009), szypd (10-29-2008)

  5. #3
    CepiPerez's Avatar
    offline Developer
    Join Date
    Jun 2008
    Location
    Buenos Aires, Argentina
    Posts
    954
    Thanks
    566
    Thanked 4,352 Times in 607 Posts
    Downloads
    28
    Uploads
    0
    no entiendo un carajo tu codigo...
    o sea, lo entiendo, pero:
    - en Pictures tenes que usar ezxlocal en lugar de ezx_user
    - en el caso de que llegue a funcionar te va a renombrar todas las imagenes con el mismo nombre, ya que el sleep tiene que estar entre foto y foto, por lo que vas a conseguir que todas las fotos de la carpeta se pierdan y te quede una sola

    proba con algo como esto:

    Code:
    showQ "zFotoren" "Desea renombrar?" 0 ||
    {
    	LISTA=`find /ezxlocal/download/mystuff/Pictures -name 'LM_*'`
    	for I in *LISTA
    	do
    		NUMRO=`date +%d-%m-%y_%H%M%S`
    		mv *I /ezxlocal/download/mystuff/Pictures/*NUMRO.jpg
    		sleep 1
    	done
    
    
    	showNotify "" "Listo!" 0
    pero vas a tener que hacer de a una las carpetas
    Last edited by CepiPerez; 10-29-2008 at 07:29 PM.

  6. 6 Users Say Thank You to CepiPerez For This Useful Post

    c_ro87 (10-29-2008), Dark Hawk (10-31-2008), kakashiambu (10-30-2008), racinglocura07 (11-06-2008), santiago123 (08-10-2009), szypd (10-29-2008)

  7. #4
    c_ro87's Avatar
    offline MOTOCAKER
    Join Date
    Jan 2008
    Location
    Argentina
    Posts
    848
    Thanks
    678
    Thanked 4,294,967,295 Times in 400 Posts
    Downloads
    16
    Uploads
    0
    yo no entiendo tu codigo

    NUMRO=`date +%d-%m-%y_%H%M%S`
    mv /ezxlocal/download/mystuff/Pictures/.jpg

    no entiendo que hace eso?? o sea me parece que no esta haciendo nada util

  8. 2 Users Say Thank You to c_ro87 For This Useful Post

    kakashiambu (10-30-2008), szypd (10-29-2008)

  9. #5
    CepiPerez's Avatar
    offline Developer
    Join Date
    Jun 2008
    Location
    Buenos Aires, Argentina
    Posts
    954
    Thanks
    566
    Thanked 4,352 Times in 607 Posts
    Downloads
    28
    Uploads
    0
    no salieron las variables
    ahi te lo arregle (cambia los asteriscos por el signo pesos)

  10. The Following User Says Thank You to CepiPerez For This Useful Post:

    szypd (10-30-2008)

  11. #6
    disckjockey's Avatar
    offline Mixing n' Modding
    Join Date
    Jan 2008
    Location
    Colombia,Popayan
    Posts
    583
    Thanks
    283
    Thanked 138 Times in 71 Posts
    Downloads
    50
    Uploads
    0
    Quote Originally Posted by c_ro87 View Post
    yo no entiendo tu codigo

    NUMRO=`date +%d-%m-%y_%H%M%S`
    mv /ezxlocal/download/mystuff/Pictures/.jpg

    no entiendo que hace eso?? o sea me parece que no esta haciendo nada util
    pues la variable NUMRO es igual al dia y el mes y el año_hora minutos segundos. nombre que se pone en el jpeg deseado, PERO lo mueve con mv, el comando mv tiene dos propositos, porque puede mover un archivo , y cambiarle el nombre dentro del mismo directorio, "moviendo" el archivo al mismo directorio con un nuevo nombre, mv es similar a cp excepto que borra el origen.

  12. 2 Users Say Thank You to disckjockey For This Useful Post

    kakashiambu (10-30-2008), szypd (10-30-2008)

  13. #7
    offline MOTOCAKER
    Join Date
    Aug 2008
    Posts
    302
    Thanks
    93
    Thanked 997 Times in 145 Posts
    Downloads
    32
    Uploads
    0
    Ahora el que hace una consulta soy yo!!

    tengo esta parte de codigo:

    S=0
    M=0
    while [ $M != $TIEMPO ]
    do
    sleep 1
    let S=+1
    if [ $S = 60 ]
    then
    S=0
    M=$M+1
    done


    Como hago para hacer q esto:

    let S=+1
    if [ $S = 60 ]
    then
    S=0
    M=$M+1

    Se haga al mismo tiempo que esto:

    Sleep 1

    Lo necesito para mejorar el cronometro!
    Last edited by racinglocura07; 10-30-2008 at 08:34 AM.

  14. The Following User Says Thank You to racinglocura07 For This Useful Post:

    szypd (10-30-2008)

  15. #8
    CepiPerez's Avatar
    offline Developer
    Join Date
    Jun 2008
    Location
    Buenos Aires, Argentina
    Posts
    954
    Thanks
    566
    Thanked 4,352 Times in 607 Posts
    Downloads
    28
    Uploads
    0
    como al mismo tiempo?
    no es mas facil convertir los minutos a segundos y usar esto?

    sleep $S

  16. The Following User Says Thank You to CepiPerez For This Useful Post:

    szypd (10-31-2008)

  17. #9
    offline MOTOCAKER
    Join Date
    Aug 2008
    Posts
    302
    Thanks
    93
    Thanked 997 Times in 145 Posts
    Downloads
    32
    Uploads
    0
    Como convertir los minutos a segundos?? mira mi major problema es q cuando pongo shownotify, se tiene q esperar por lo menos un segundo para continuar con el script, entonces eso me genera una demora en la cuenta de aproximadamente 3 segundos cada minuto

  18. The Following User Says Thank You to racinglocura07 For This Useful Post:

    szypd (10-31-2008)

  19. #10
    CepiPerez's Avatar
    offline Developer
    Join Date
    Jun 2008
    Location
    Buenos Aires, Argentina
    Posts
    954
    Thanks
    566
    Thanked 4,352 Times in 607 Posts
    Downloads
    28
    Uploads
    0
    pero eso pasa con bash, porque el shownotify es una aplicacion nativa y entonces el bash tiene que cargar y descargar aplicaciones a cada rato.
    creo que para un cronometro tendrias que hacer directo en c++, que te carga las librerias de entrada y despues no hay demora en mostrar el notify (aunque no lo vas a necesitar, porque podes mostrar el tiempo directamente en la pantalla principal del programa

  20. The Following User Says Thank You to CepiPerez For This Useful Post:

    szypd (10-31-2008)

  21. #11
    offline MOTOCAKER
    Join Date
    Aug 2008
    Posts
    302
    Thanks
    93
    Thanked 997 Times in 145 Posts
    Downloads
    32
    Uploads
    0
    ya tengo un cronometro hecho en c++ anda perfecto!!! el tema es q no lo puedo adaptar al celular! me ayudas? y de paso se pone en el post principal!

  22. The Following User Says Thank You to racinglocura07 For This Useful Post:

    szypd (10-31-2008)

  23. #12
    CepiPerez's Avatar
    offline Developer
    Join Date
    Jun 2008
    Location
    Buenos Aires, Argentina
    Posts
    954
    Thanks
    566
    Thanked 4,352 Times in 607 Posts
    Downloads
    28
    Uploads
    0
    jaja, justo estaba probando en C++ como hacer uno, pero el problema que tengo es que cuando dejo el cronometro encendido y se apaga la pantalla despues de un tiempo, se pausa solo.

    mandame el codigo del que tenes por MP que me fijo de adaptarlo al sdk
    Last edited by CepiPerez; 10-31-2008 at 09:27 AM.

  24. #13
    offline MOTOCAKER
    Join Date
    Aug 2008
    Posts
    302
    Thanks
    93
    Thanked 997 Times in 145 Posts
    Downloads
    32
    Uploads
    0
    no me podrias dar una explicacion de como se hace eso? darnos a todos en realidad! ya que cree este post para tambien agregarle c++!!

    POr favor cepi!

  25. The Following User Says Thank You to racinglocura07 For This Useful Post:

    szypd (10-31-2008)

  26. #14
    CepiPerez's Avatar
    offline Developer
    Join Date
    Jun 2008
    Location
    Buenos Aires, Argentina
    Posts
    954
    Thanks
    566
    Thanked 4,352 Times in 607 Posts
    Downloads
    28
    Uploads
    0
    Es que la verdad es un quilombo explicar como funciona
    Y no la tengo clara tampoco, aca el que sabe de verdad es c_ro87

    Mira lo que estoy haciendo:


    Aunque no me creas no se como hacer un tutorial para explicar como lo hice, ya que agarre como base una app de darktech y despues le fui agregando librerias y codigo a lo loco, sacando ejemplos de otras apps.

    Ya puedo armar una aplicacion sin problemas (creo), pero empezarla desde cero ni a palos, no tengo idea como armar los .h, yo nada mas agrego codigo hasta que ande.

  27. 2 Users Say Thank You to CepiPerez For This Useful Post

    FeNixCln (12-10-2008), szypd (10-31-2008)

  28. #15
    offline MOTOCAKER
    Join Date
    Aug 2008
    Posts
    302
    Thanks
    93
    Thanked 997 Times in 145 Posts
    Downloads
    32
    Uploads
    0
    mira yo estuve viendo muchos codigos y analizandolos, el problema major, porque el menu y eso lo puedo hacer sin problemas, pero mi problema mayor es cuando tengo q hacer q se ejecute algo!! osea cuando haces click en activar crnometro q este empiece!!!
    Desde 0 no creo q sepa nadie!!!
    Estaria bueno q hagas con algun codigo explicandolo y eso porque desde 0 es imposible!

Page 1 of 5 12345 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •