Autentificare
facebook MW pe Facebook
twitter MW pe Twitter
© Mobilewave.ro
versiunea desktop
Inițiator acum 14 ani
otzy_007
MW Addicted
Ultimul acum 9 ani
linux91
MW Liker
Cauta in topic
Unelte topic
Dacă vă place acest articol trimiteți mai departe!

programare pe mobil

749 vizualizări
28 răspunsuri
autor subiect #16
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
17 octombrie 2006, 18:25:10
luati-l de aici atunci
Publicitate
Publicitate
#17
modoran
MW Addicted
7605 mesaje
din 26/01/2006
33 aprecieri
Opera Mini
17 octombrie 2006, 18:25:20
Linkul direct:
http://www.mobilebasic.com/MB/MobileBASIC.jad

Asta merge cu browserul telefonului,pagina nu.
autor subiect #18
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
17 octombrie 2006, 18:26:52
mie mi-a mers si direct de pe wap.mobilebasic.com, nu stiu ce vi s-a intamplat voua ???
#19
calc
MW Addicted
2952 mesaje
din 01/09/2006
10% warn
Opera Mini
17 octombrie 2006, 18:32:10
otzy_007 17-10-2006 18:07:54
eu am luat-o de aici fara sa platesc http://wap.mobilebasic.com/#install
Ce aleg: MIDlet 1.8 Mobile BASIC sau MIDlet 1.8 (No Network Support) ??? :hmm:
autor subiect #20
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
17 octombrie 2006, 18:36:25
care vrei tu;)
#21
modoran
MW Addicted
7605 mesaje
din 26/01/2006
33 aprecieri
Opera Mini
17 octombrie 2006, 18:39:33
otzy_007 17-10-2006 18:25:10
luati-l de aici atunci
Asta e acelasi fisier,nu?
Doar ca e .jar
#22
win32
MW Veteran
526 mesaje
din 25/01/2006
Symbian
17 octombrie 2006, 18:41:54
cosmo1 cind iti cere userul si codul apesi tasta back si apoi OK!
autor subiect #23
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
17 octombrie 2006, 18:43:41
modoran 17-10-2006 18:39:33
otzy_007 17-10-2006 18:25:10
luati-l de aici atunci
Asta e acelasi fisier,nu?
Doar ca e .jar
da nu are si jadul, e cel cu network
#24
nexuiz
MW Lurker
293 mesaje
din 30/12/2005
SonyEricssonK500i
17 octombrie 2006, 18:54:57
Merge dar cum functioneaza mai exact?un compile,ceva?
autor subiect #25
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
17 octombrie 2006, 18:56:28 • actualizat 17 octombrie 2006, 19:00:49 (2 ori)
SUB MAIN
OPEN #1,"http://www.mobilebasic.com/ImageServer.jpg","INPUT"

IMAGE$=""

TRAP Finished
WHILE (1)
GET #1,CH%
IMAGE$=IMAGE$+CHR$(CH%)
I%=I%+1
ENDWHILE

Finished:
CLOSE #1

GELDATA "Image",IMAGE$
SPRITEGEL "Sprite","Image"

X%=0
Y%=0
W%=GELWIDTH("Image")
H%=GELHEIGHT("Image")

XDIR%=1
YDIR%=1

WHILE (1)
SPRITEMOVE "Sprite",X%,Y%
REPAINT
SLEEP 25

T%=X%+XDIR%
IF (T%+W% >= SCREENWIDTH()) THEN XDIR%=-1
IF (T% < 0) THEN XDIR%=1

T%=Y%+YDIR%
IF (T%+H% >= SCREENHEIGHT()) THEN YDIR%=-1
IF (T% < 0) THEN YDIR%=1

X%=X%+XDIR%
Y%=Y%+YDIR%
ENDWHILE
ENDSUB
program pentru descarcarea unei imagini
SUB MAIN
REM
REM Calculator Engine Rules
REM 1. Functions operate on displayed value
REM 2. Operators operate on Accumulator Values
REM

MENUFLAG%=0
TRAP NoMenus
EXIT$="Finish"
MENU_ADD EXIT$,7,1
MENUFLAG%=1

NoMenus:
TRAP OFF

MAPLOAD "Display.map","Tiles.til"
GELLOAD "KeyReleased","Cursor.png"
GELLOAD "KeyPressed","Cursor2.png"

H%=STRINGHEIGHT("X")
VPW%=MAPWIDTH()
VPH%=MAPHEIGHT()
VPX%=(SCREENWIDTH()-VPW%)/2
VPY%=H%

SETCOLOR 0,0,0
FILLRECT 0,0,SCREENWIDTH(),SCREENHEIGHT()

SETVIEWPORT VPX%,VPY%,VPW%,VPH%

S$="Calculator - Powered By Mobile BASIC - The easy way to write mobile phone programs. See http://www.mobilebasic.com/ for Details."

X%=SCREENWIDTH()
W%=STRINGWIDTH(S$)
WHILE (INKEY()=0) AND (X%+W%>0)
SETCOLOR 0,0,0
FILLRECT 0,0,SCREENWIDTH(),H%
SETCOLOR 255,255,255
DRAWSTRING S$,X%,0
REPAINT
X%=X%-1
SLEEP 10
IF (MENUFLAG% = 1) THEN
IF (MENUITEM() = EXIT$) THEN GOSUB Finish
ENDIF
ENDWHILE

REPEAT
SLEEP 1
UNTIL INKEY()=0

SPRITEGEL "Cursor","KeyReleased"

X%=1
Y%=2

GETPROPERTY "M0",M$

IF M$<>"" THEN
MEMORY=FLOAT(M$)
ELSE
MEMORY=0.0
ENDIF

ACCUMULATOR=0.0
DISPLAY=0.0
PREV_OPCODE%=0
NEW_NUMBER_FLAG%=1
ErrorState%=0

GOSUB MoveCursor
GOSUB UpdateDisplay

WHILE 1
IF (LEFT()<>0) THEN
X%=X%-1
IF (X% < 0) THEN X%=5
GOSUB MoveCursor
ENDIF

IF (RIGHT()<>0) THEN
X%=X%+1
IF (X% > 5) THEN X%=0
GOSUB MoveCursor
ENDIF

IF (UP()<>0) THEN
Y%=Y%-1
IF (Y% < 0) THEN Y%=5
GOSUB MoveCursor
ENDIF

IF (DOWN()<>0) THEN
Y%=Y%+1
IF (Y% > 5) THEN Y%=0
GOSUB MoveCursor
ENDIF

IF (FIRE()<>0) THEN
IF (ErrorState%) THEN
IF (Y%=0 AND X%=0) THEN
DISPLAY=0.0
NEW_NUMBER_FLAG%=1
ACCUMULATOR=0.0
PREV_OPCODE%=0
ErrorState%=0
GOSUB UpdateDisplay
ENDIF
ELSE
TRAP Error

OPCODE%=-1
DIGIT%=-2

IF (Y%=0) THEN
IF (X%=0) THEN DISPLAY=0.0:NEW_NUMBER_FLAG%=1:ACCUMULATOR=0.0:PREV_OPCODE%=0:ErrorState%=0
IF (X%=1) THEN DISPLAY=0.0:NEW_NUMBER_FLAG%=1
IF (X%=2) THEN
MEMORY=DISPLAY
SETPROPERTY "M0",STR$(MEMORY)
NEW_NUMBER_FLAG%=1
ENDIF
IF (X%=3) THEN DISPLAY=MEMORY:NEW_NUMBER_FLAG%=1
IF (X%=4) THEN MEMORY=MEMORY+DISPLAY:NEW_NUMBER_FLAG%=1
IF (X%=5) THEN MEMORY=MEMORY-DISPLAY:NEW_NUMBER_FLAG%=1
ENDIF

IF (Y%=1) THEN
IF (X%=0) THEN DIGIT%=7
IF (X%=1) THEN DIGIT%=8
IF (X%=2) THEN DIGIT%=9
IF (X%=3) THEN OPCODE%=1
IF (X%=4) THEN DISPLAY=SIND(DISPLAY):NEW_NUMBER_FLAG%=1
IF (X%=5) THEN DISPLAY=ASIND(DISPLAY):NEW_NUMBER_FLAG%=1
ENDIF

IF (Y%=2) THEN
IF (X%=0) THEN DIGIT%=4
IF (X%=1) THEN DIGIT%=5
IF (X%=2) THEN DIGIT%=6
IF (X%=3) THEN OPCODE%=2
IF (X%=4) THEN DISPLAY=COSD(DISPLAY):NEW_NUMBER_FLAG%=1
IF (X%=5) THEN DISPLAY=ACOSD(DISPLAY):NEW_NUMBER_FLAG%=1
ENDIF

IF (Y%=3) THEN
IF (X%=0) THEN DIGIT%=1
IF (X%=1) THEN DIGIT%=2
IF (X%=2) THEN DIGIT%=3
IF (X%=3) THEN OPCODE%=3
IF (X%=4) THEN DISPLAY=TAND(DISPLAY):NEW_NUMBER_FLAG%=1
IF (X%=5) THEN DISPLAY=ATAND(DISPLAY):NEW_NUMBER_FLAG%=1
ENDIF

IF (Y%=4) THEN
IF (X%=0) THEN DIGIT%=0
IF (X%=1) THEN DIGIT%=-1
IF (X%=2) THEN OPCODE%=5
IF (X%=3) THEN OPCODE%=4
IF (X%=4) THEN DISPLAY=LOG(DISPLAY):NEW_NUMBER_FLAG%=1
IF (X%=5) THEN DISPLAY=EXP(DISPLAY):NEW_NUMBER_FLAG%=1
ENDIF

IF (Y%=5) THEN
IF (X%=0) THEN DISPLAY=-DISPLAY
IF (X%=1) THEN DISPLAY=3.1415926:NEW_NUMBER_FLAG%=1
IF (X%=2) THEN DISPLAY=DISPLAY*DISPLAY:NEW_NUMBER_FLAG%=1
IF (X%=3) THEN DISPLAY=SQR(DISPLAY):NEW_NUMBER_FLAG%=1
IF (X%=4) THEN DISPLAY=LOG(DISPLAY)/LOG(10):NEW_NUMBER_FLAG%=1
IF (X%=5) THEN DISPLAY=EXP(DISPLAY*LOG(10)):NEW_NUMBER_FLAG%=1
ENDIF

IF (DIGIT% <> -2) THEN
IF (NEW_NUMBER_FLAG%) THEN
DISPLAY=0.0
MULT=10.0
DIV=1.0
NEW_NUMBER_FLAG% = 0
ENDIF

IF (DIGIT% = -1) THEN
IF (DIV = 1.0) THEN
MULT=1.0
DIV=10.0
ENDIF
ELSE
DISPLAY=DISPLAY*MULT+DIGIT%/DIV
IF (DIV <> 1.0) THEN DIV=DIV*10
ENDIF
ENDIF

IF (OPCODE% <> -1) THEN
IF (PREV_OPCODE%=0) THEN ACCUMULATOR=DISPLAY
IF (PREV_OPCODE%=1) THEN ACCUMULATOR=ACCUMULATOR*DISPLAY:DISPLAY=ACCUMULATOR
IF (PREV_OPCODE%=2) THEN ACCUMULATOR=ACCUMULATOR/DISPLAY:DISPLAY=ACCUMULATOR
IF (PREV_OPCODE%=3) THEN ACCUMULATOR=ACCUMULATOR+DISPLAY:DISPLAY=ACCUMULATOR
IF (PREV_OPCODE%=4) THEN ACCUMULATOR=ACCUMULATOR-DISPLAY:DISPLAY=ACCUMULATOR
NEW_NUMBER_FLAG%=1
IF (OPCODE%=5) THEN
PREV_OPCODE%=0
ELSE
PREV_OPCODE%=OPCODE%
ENDIF
ENDIF

GOSUB UpdateDisplay
GOTO NoError

Error:
TRAP OFF
ErrorState%=1
GOSUB ErrorDisplay

NoError:
ENDIF

SPRITEGEL "Cursor","KeyPressed"
ENDIF

REPAINT

REPEAT
SLEEP 1
UNTIL INKEY()=0

SPRITEGEL "Cursor","KeyReleased"
REPAINT

REPEAT
IF (MENUFLAG% = 1) THEN
IF (MENUITEM() = EXIT$) THEN GOSUB Finish
ENDIF
SLEEP 1
UNTIL INKEY()<>0
ENDWHILE
END

MoveCursor:
SPRITEMOVE "Cursor",VPX%+X%*16,VPY%+Y%*8+1
RETURN

UpdateDisplay:
SETCOLOR 0,0,0
FILLRECT 0,0,SCREENWIDTH(),H%
SETCOLOR 255,255,255
S$=STR$(DISPLAY)
W%=STRINGWIDTH(S$)
DRAWSTRING S$,SCREENWIDTH()-W%,0
RETURN

ErrorDisplay:
SETCOLOR 0,0,0
FILLRECT 0,0,SCREENWIDTH(),H%
SETCOLOR 255,255,255
S$="Error"
W%=STRINGWIDTH(S$)
DRAWSTRING S$,SCREENWIDTH()-W%,0
RETURN

Finish:
IF (MENUFLAG% = 1) THEN
I%=SELECT("Exit Calculator?","Yes,No")
IF I%=0 THEN END
RETURN
ENDIF
ENDSUB
calculator stintific
eu apas pe joystick dar poti si din tasta 0, o apesi de doua ori

Note: Posts were merged

SUB MAIN
WHILE 1
TIME#=TIME()
YEAR%=YEAR(TIME#)
MONTH%=MONTH(TIME#)
DAY%=DAY(TIME#)
HOUR%=HOUR(TIME#)
MINUTE%=MINUTE(TIME#)
SECOND%=SECOND(TIME#)
DATE$=STR$(DAY%) + "/" + STR$(MONTH%) + "/" + STR$(YEAR%)
TIME$=STR$(HOUR%) + ":" + STR$(MINUTE%) + "."

IF (SECOND% < 10) THEN TIME$=TIME$+"0"
TIME$=TIME$+STR$(SECOND%)

SETCOLOR 0,0,0
FILLRECT 0,0,SCREENWIDTH(),SCREENHEIGHT()
SETCOLOR 255,255,255
Y1%=SCREENHEIGHT()/3
Y2%=Y1%+Y1%
DRAWSTRING DATE$,(SCREENWIDTH()-STRINGWIDTH(DATE$))/2,Y1%
DRAWSTRING TIME$,(SCREENWIDTH()-STRINGWIDTH(TIME$))/2,Y2%
REPAINT
SLEEP 500
ENDWHILE
ENDSUB
script care iti da data si ora

Note: Posts were merged
#26
calc
MW Addicted
2952 mesaje
din 01/09/2006
10% warn
Opera Mini
17 octombrie 2006, 19:31:17
Eu am vazut ca doar poti sa scri, dar programe...canci :hmm: Please :help:
autor subiect #27
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
SAGEM-myX6-2
17 octombrie 2006, 19:35:37
Scrii scriptul dupa care apesi de doua ori pe zero
autor subiect #28
otzy_007
MW Addicted
1350 mesaje
din 09/09/2006
SAGEM-myX6-2
01 decembrie 2006, 13:01:20
Stie cineva cum poti sa dai enter la mobilebasic sau nu sa inventat asa ceva ???
#29
linux91
MW Liker
60 mesaje
din 08/10/2009
1 aprecieri
11 ianuarie 2012, 17:07:57 • actualizat 11 ianuarie 2012, 17:08:32 (1 ori)
pentru cine mai este interesat sa programeza pe telefonul mobil se poate folosi de compilatoare online
de exemplu eu am uitilizat si am fost multumit de codepad.org
suporta o groaza de limbaje de programare
Înapoi la Creative Corner
cine e aici?
Subiectul a fost creat la .
versiunea desktop
0.020⋅4⋅0