![bladox.com Forum Index](t
emplates/subSilver/images/logo_phpBB.gif) |
bladox.com Turbo SIM Toolkit Adapter Forums
|
View previous topic :: View next topic |
Author |
Message |
x54321 Guest
|
Posted: Fri Jan 25, 2008 9:48 pm Post subject: Problemy s nahravanim aplikaci |
|
|
Dobry den,
zacal jsem s psanim aplikaci pro Turbo Lite 2. Snazim se napsat jednoduchy dalkove ovladany termostat. Zatim jsem se ale dostal pouze k testovani existujich aplikaci a ladeni velmi jednoduche aplikace vlastni.
Turbo se pri nahravani aplikace chova divne:
1) turbo-app trval velmi dlouho. Aplikace orezana az na kost o velikosti .trb file 317 B se nahrava cca 30 minut. Je to obvykle nebo je neco spatne?
Spusteno z bash:
$ ( date; turbo-app -b115200 -dcom1 -v thermostat2.trb 2>&1 ; date ) | tee thermostatloadoutput
Zdrojak:
Code: |
----------------------------
#include <config.h>
#include <turbo/turbo.h>
#include <avr/sfr_defs.h>
#include <avr/io.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
/* strings for menu */
lc_char PROGMEM lc_Thermostat[] = {
LC_EN ("Thermostat")
LC_CZ ("Termostat")
LC_END
};
lc_char PROGMEM lc_State[] = {
LC_EN ("State")
LC_CZ ("Stav")
LC_END
};
/* spider node declaration */
extern SNodeP g_Thermostat;
extern SNodeP g_ThermostatState;
/* spider callbacks */
extern u8 ThermostatStateCallBack(SCtx * ctx, u8 action);
/* spider definitions */
SEdgeP g_ThermostatEdges[] = {
{&g_Thermostat, &g_ThermostatState},
NULL
};
/* main menu */
SNodeP g_Thermostat = { lc_Thermostat, NULL };
SNodeP g_ThermostatState = { lc_State, ThermostatStateCallBack };
/* global variable data type */
typedef struct structTPersGlobVar
{
u8 m_bState;
} TPersGlobVar;
/* pointer to the global variables*/
TPersGlobVar *g_PersGlobVar;
/* menu handler */
void ThermostatMenuSelection (Menu_selection_data * x);
/* main event handles */
void turbo_handler (u8 action, void *data) {
switch (action) {
case ACTION_APP_REGISTER: {
TPersGlobVar *pGlobVars=emalloc (sizeof (TPersGlobVar));
if (pGlobVars!=NULL) {
reg_app_data (pGlobVars);
}
}
break;
case ACTION_APP_UNREGISTER: {
TPersGlobVar *pGlobVars=app_data ();
efree (pGlobVars);
}
break;
case ACTION_APP_INIT: {
g_PersGlobVar=app_data ();
}
break;
/* main menu insertion */
case ACTION_INSERT_MENU: {
insert_menu (locale (lc_Thermostat));
}
break;
/* menu handling */
case ACTION_MENU_SELECTION: {
if (g_PersGlobVar!=NULL) {
stk_thread (ThermostatMenuSelection, data);
}
}
break;
}
}
/* menu handling */
void ThermostatMenuSelection (Menu_selection_data * x) {
SCtx *spiderContext;
spiderContext = spider_init ();
if (spiderContext != NULL) {
spider_set_order (spiderContext, ORDER_P, ORDER_R, ORDER_E, ORDER_D);
spiderContext->eP = &g_ThermostatEdges;
spiderContext->n = &g_Thermostat;
spider (spiderContext);
}
}
/* Thermostat / State callback */
extern u8 ThermostatStateCallBack(SCtx * ctx, u8 action) {
return APP_OK;
}
----------------------------
|
Telefon Siemens ME45, Turbo Lite 2 verze 1.1.16, nahravano pres seriovou linku (turbo-cable-utils-0.7.0) z Windows s cygwin.
Vystup :
Code: |
----------------------------
Fri Jan 25 21:58:29 CEST 2008
SRC thermostat2.trb
SIZE 371
initializing modem
1 -> ATV1
1 <-
1 -> ATE1
1 <-
1 -> AT+CPMS="SM","SM"
1 <-
1 -> AT+CMGF=0
1 <-
1 -> AT+CPMS?
1 <-
modem initiated
SEND: 02 029100110000810004FF020C00
1 -> AT+CMGW=10
1 <-
ANS
1 -> 029100110000810004FF020C00
1 <-
ANS
SEND: 83 029100110000810004FF830C01800102991C011A56657273696F6E3A20302E302E312056656E646F723A2049766FF400000002002E004200010B546865726D6F7374617400200A5465726D6F7374617400000000010653746174650020055374617600000000300004360000003600043C000000000000003C000400000000000000003E00041C00000088000CEE
1 -> AT+CMGW=139
1 <-
ANS
1 -> 029100110000810004FF830C01800102991C011A56657273696F6E3A20302E302E312056656E646F723A2049766FF400000002002E004200010B546865726D6F7374617400200A5465726D6F7374617400000000010653746174650020055374617600000000300004360000003600043C000000000000003C000400000000000000003E00041C00000088000CEE
1 <-
ANS
SEND: 83 029100110000810004FF830C01800000000000992782309105E1F0833091052CF4009749F0019781F0089586309105F9F00A97B1F0089581E090E00E94C6ED009701F10E94E8ED08950E94EEED0E94C8ED08950E94EEED90938C0084010000008093900084000000000895920001000080E0A00002000090E00E94DAED0E94DCED08958091A40084000000009091
1 -> AT+CMGW=139
1 <-
ANS
1 -> 029100110000810004FF830C01800000000000992782309105E1F0833091052CF4009749F0019781F0089586309105F9F00A97B1F0089581E090E00E94C6ED009701F10E94E8ED08950E94EEED0E94C8ED08950E94EEED90938C0084010000008093900084000000000895920001000080E0A00002000090E00E94DAED0E94DCED08958091A40084000000009091
1 <-
ANS
SEND: 76 029100110000810004FF760C0173AA008401000000892B21F0AC0009B40080E0D0000AB40090E00E94D4ED08950F93CF93DF930E945CEEEC01009789F003E020E041E062E00E9484EED200012E0080E0D800022E0090E08A839B83DA0001360080E0FFFF02360090E08D879E87CE010E9456EEDF91CF910F91089580E090E00895
1 -> AT+CMGW=126
1 <-
ANS
1 -> 029100110000810004FF760C0173AA008401000000892B21F0AC0009B40080E0D0000AB40090E00E94D4ED08950F93CF93DF930E945CEEEC01009789F003E020E041E062E00E9484EED200012E0080E0D800022E0090E08A839B83DA0001360080E0FFFF02360090E08D879E87CE010E9456EEDF91CF910F91089580E090E00895
1 <-
ANS
SEND: 12 029100110000810004FF120C02746865726D6F73746174322E74726200
1 -> AT+CMGW=26
1 <-
ANS
1 -> 029100110000810004FF120C02746865726D6F73746174322E74726200
1 <-
ANS
OK. No Error
Fri Jan 25 22:31:01 CEST 2008
----------------------------
|
2) Aplikaci nelze v menu telefonu nalezt - v menu Turbo na telefonu je pouze Pager a Nastaveni, nic dalsiho. Zkousel jsem i restart telefonu a nepomohlo to. Jaky zpusobem a kde se da nova aplikace najit?
Zkousel jsem i nahrat sysinfo.trb z sysinfo-1.0.1 a trvalo to nekolik hodin (log uz nemam, ale skoncilo "No error"). Tez po nahrani v menu Turbo na telefonu nebyla.
Muzete mi prosim rici v cem je chyba? Diky za pomoc. |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
x54321 Guest
|
Posted: Sat Jan 26, 2008 7:55 am Post subject: Dalsi test s HelloWorld |
|
|
Obavam se ze je neco spatne.
Nefunguje ani HelloWorld - nahravani skoncilo OK, ale v Turbo menu se HelloWorld neobjevi.
Spusteno:
$ ( date; turbo-app -b115200 -dcom1 -v helloworld.trb 2>&1 ; date ) | tee helloloadoutput2
Vystup:
Code: |
Sat Jan 26 08:12:34 CEST 2008
SRC helloworld.trb
SIZE 131
initializing modem
1 -> ATV1
1 <-
1 -> ATE1
1 <-
1 -> AT+CPMS="SM","SM"
1 <-
1 -> AT+CMGF=0
1 <-
1 -> AT+CPMS?
1 <-
modem initiated
SEND: 02 029100110000810004FF020C00
1 -> AT+CMGW=10
1 <-
ANS
1 -> 029100110000810004FF020C00
1 <-
ANS
SEND: 83 029100110000810004FF830C01800102A61D011B56657273696F6E3A20302E302E312056656E646F723A2049766F323A000000000010001A0048656C6C6F20576F726C6421000060E8120001000080E0260002000090E00E948CEE089599278630910539F00A9749F4280001000080E0300002000090E00E94DCED08953200090E0080E0FFFF0A0E0090E00E94D4
1 -> AT+CMGW=139
1 <-
ANS
1 -> 029100110000810004FF830C01800102A61D011B56657273696F6E3A20302E302E312056656E646F723A2049766F323A000000000010001A0048656C6C6F20576F726C6421000060E8120001000080E0260002000090E00E948CEE089599278630910539F00A9749F4280001000080E0300002000090E00E94DCED08953200090E0080E0FFFF0A0E0090E00E94D4
1 <-
ANS
SEND: 06 029100110000810004FF060C0103ED0895
1 -> AT+CMGW=14
1 <-
ANS
1 -> 029100110000810004FF060C0103ED0895
1 <-
ANS
SEND: 11 029100110000810004FF110C0268656C6C6F776F726C642E74726200
1 -> AT+CMGW=25
1 <-
ANS
1 -> 029100110000810004FF110C0268656C6C6F776F726C642E74726200
1 <-
ANS
OK. No Error
Sat Jan 26 08:39:41 CEST 2008
--------------------------------
|
Divny je i vystup turbo-info - nezobrazi se zadne informace, jen ze je to OK.
Spusteno:
$ ( date; turbo-info -b115200 -dcom1 -v 2>&1 ; date ) | tee turboinfoload
Vystup:
Code: |
--------------------------------
Sat Jan 26 08:41:16 CEST 2008
initializing modem
1 -> ATV1
1 <-
1 -> ATE1
1 <-
1 -> AT+CPMS="SM","SM"
1 <-
1 -> AT+CMGF=0
1 <-
1 -> AT+CPMS?
1 <-
modem initiated
SEND: 01 029100110000810004FF0110
1 -> AT+CMGW=9
1 <-
ANS
1 -> 029100110000810004FF0110
1 <-
ANS
OK. No Error
Sat Jan 26 08:52:06 CEST 2008
--------------------------------
|
Nepomohl ani restart telefonu.
Nevite nekdo jak nahranou aplikaci na telefonu zobrazit (v menu Turbo je jen Nastaveni a Pager)? |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
pz Guest
|
Posted: Sat Jan 26, 2008 8:13 am Post subject: |
|
|
Ano, je to spatne, normalne to trva desitky vterin, minutu, dve, podle velikosti aplikace.
Z logu je videt, ze SEND je stejne jako ANS, tj. co se poslalo do telefonu se i precetlo, tj. se vubec nedostalo k turbu, ktere by melo sanci nejak odpovedet. To OK na konci je spatne osetrene chovani. Divne je, ze siemensy vetsinou funguji (fungovaly) pekne.
Mate SMS misto na SIM karte? Pro nahravani se pouzivaji SMS, ty se musi dostat k Turbo, tj. byt (jako) ukladany na SIM. |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
x54321 Guest
|
Posted: Sat Jan 26, 2008 8:15 am Post subject: |
|
|
Uz to mam. Problem byl ze jsem pouzival turbo-cable-utils prelozene z C souboru v src adresari turbo-cable-utils-0.7.0.
Pokud jsem vzal primo binarky z bin-win32, tak vse jede OK. |
|
Back to top |
|
![](templates/subSilver/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|