Serial port no sent electric signal - Windows Mobile Development and Hacking General

:?:
HI all !
We have program writen in eVC that open serial port. The program open serial port, is returned handle, program is sending data but no electric signal sent to our device. Is need any incoming signel to MDA and what signal ?
Thanks
Honza.

not quite sure what exactly, but it is true that the serial port only starts giving signals when it is connected.

I work in VB.NET but use a free DLL: CFSerialClass.dll from Richard Grier. http://www.hardandsoftware.net/
It works excellently!

I am interested to know what baud rate you are using. I have noticed problems with TX data on the XDA1 with less than 1200 baud.
2400 and above are fine and 1200 can be a problem with missed characters.
Receive is always fine but TX does not work, I found it helped to write multiple characters and not 1 at a time.
Anyone else had this happen ?

I do not know if you are asking me this, but my app uses over 9600 without errors, because I use the DRS and DTR (Data Set Ready and Data Terminal Ready) signals (handshaking). With this option I have the sending device wait until I am ready.
So the receiving application controls when the sender can send.

Honza said:
:?:
HI all !
We have program writen in eVC that open serial port. The program open serial port, is returned handle, program is sending data but no electric signal sent to our device. Is need any incoming signel to MDA and what signal ?
Thanks
Honza.
Click to expand...
Click to collapse
It is OK, now.
EscapeCommFunction is malfunction. THANKS.

Related

Using as general modem via TAPI (or RIL if need be)

I am trying (unsuccessfully so far) to develop a program that will create a data (modem) connection to a modem connected to any other phone. I then want to transfer a small file using xmodem.
I have done extensive searches and tried solutions with TAPI calls based on samples I have found. I can dial the number of my laptop from the i-mate and the laptop on my desk rings. I tell it to pickup the line (ATA) and it does, but there is no "LINECALLSTATE_CONNECTED" from the "lineInitialize" callback function on the imate. All I get is a "LINECALLSTATE_DISCONNECTED" with the type as "LINEDISCONNECTMODE_UNREACHABLE". finally the it all hangs up, no connection.
I seem to be banging my head against a wall at the moment. There must be many of you out there who have done this or very similar.
I can post source is you want that type of thing, but I dont expect anyone to debug my app, but any pointers or others experiences are appreciated. I have come across the RIL interface, but I get the impression that TAPI is the "correct" way.
Thanks in advance.
Frustrated...
Have you got data enabled on your SIM. I was also banging my head against a wall until I thought I would check that with my service provider. There are 2 data things they can enable, one is fax but there is also data. Without data enabled you will never get a sucessfull modem connection.
arrhh!.. that's is. lol. I knew it would be something silly. Ill call today.
Thanks also. God bless you.
Well sorry to say that was not the issue, I still only get repeated
"LINEDISCONNECTMODE_UNREACHABLE"
errors. I am starting to wonder if I am just getting really bad lines. Can someone who has made a modem connection from the PPC to a desktop modem please post their experience on how reliable it is and what type of connection speed it should connect at (9600? 1200? 300? any connection?).
Is their any working sample code for creating a data connection from the PPC using the TAPI?
I will be happy to publish the code to the small project I am doing so future developers have something to work from as I havent been able to find a working example so far. (when it works that is)
Any help appreciated.
Thank-you
Figured out why it would not connect, for anyone else who has similar problems. Mine was the "CSC Line Type" option in the connection settings area.
It was set to "9600 v110" and "Non-transparent".
Im in australia, I understand the v.110 is the american standard, I changed it to
"9600 v.32" and "Non-transparent" and it connects fine. (dont you hate this type of bug)
Im still unsure what the "Transparent" and "Non-transparent" are todo with, if anyone could expain it would be appreciated.
I am glad you got it working. So I guess your code must be OK. I did not set any special communication mode so I guess that my XDA must of been set correctly anyway. It seems sensible that you are supplied with a setup for the country your device is meant for. I say this is bad of the provider.
How do you get to this setting ? I can't even seem to find it on my XDA. I have got a CSD setting that has a choice of 'Analogue' or 'ISDN' mode, mine is set to 'Analogue'.
I did post some code on this forum that is cut from an application I wrote, have a look at
http://forum.xda-developers.com/viewtopic.php?p=7857&highlight=#7857
Cheers
Paul
The code actually worked almost first time when I had all the connection settings right. Ive got the XModem transfer working now also.
The "CSD Line Type" on my device (an i-mate) is an icon in the setting connection tab. In the same tab there is also
"Beam" - allows you to turn on recieve all incoming beams
"Bluetooth" - on/off/discoverable and bonding
"Connections" - normal connection setup
"GPRS Settings" - PAP/CHAP auth and class 8(4RIT)/class 10(3R2T)
not sure what the different GPRS settings are for either, but that side seems to work.
Hey to you all,
I'm trying to set up a CSD connection via RIL , AT commands and TAPI!!! You seem to have accomplished the TAPI solution which i have not started yet, could you advice me on the necessary TAPI functions to use in order to make this work ?
Any help would be very appreciated. Thanks to all.
Have you seen this link?
http://forum.xda-developers.com/viewtopic.php?t=1716&highlight=csd

Revisited: GSM modem port

I have followed various posts regarding establishing a data connection using good old "Hayes AT Commands" over COM2 - there is a wash of great info to be found here! Only I get a bit confused when everyone starts telling me I should use the TAPI or even the RIL-API or whatever... I can't - I am just not good enough to understand these complex structures. I am just about good enough to open a COM port, issue my ATD[tel.no] and wait for the "CONNECTxxx", just like I have done for the last hundred years! I don't think I am alone - I am sure there are loads of developers who are not comfortable to leave their C# / VB world.
So, a wopsy big please: has anybody managed to encapsulate the complexity of establishing a GSM call for data in a way that can be easily consumed in C#? :?
If someone has got a commercial solution to this issue, I do not have a problem to pay a licence fee! That has to be less painful than banging my head against this brick wall!!!!
have u managed to establish the data call u wanted ??
nutitija, if you want to establish datacall...
TAPI
1)kill cprog.exe
2)initialize TAPI (lineInitializeEx)
3)find device with 9600 (lineGetDevCaps lineGetAddressCaps)
4)Open Line and set to receive datacalls(lineOpen)
5)Receive message from line in cycle (lineGetMessage)
6)For originate call - lineMakeCall
7)For Answer - lineAnswer
8)for Hangup - lineDrop
9)After connect get COM-device (lineGetID)
RIL
1)Deny to TAPI to drop datacalls (search on this forum)
2)Initialize RIL and set callbacks(RIL_Initialize)
3)For originate - RIL_Dial
4)For answer - RIL_Answer
5)For hangup - RIL_Hangup
6)After connect get COM-device (RIL_GetSerialPortHandle)
AT
1)Deny to RIL to use com ports (search on this forum for mamich posts)
2)Open COM2
3)For send and receive commands use COM2
4)After connection open COM9
5)For send and receive data use COM9
for more details use search on this form
many thanks my friend ,
I just needed validation from somebody that actually did implement before wasting hours of my time for something that cant work
cheers
When using the AT command method. I open COM2 i send my ATD command. Its succesfull my device rings. Now i would like to retrieve the information from COM9.
1) Should i close COM2 before retrieving data from COM9.
2) Should i reactivate RIL before retrieving data from COM9.
3) When using Readfile shall I implement it in a while loop to accumulate the GPS stream that will be sent to the buffer ? Or by calling readfile just once would it return all the data ?
Thanks for your helps.

incoming on atom ):

I am in the testing stage on a soon to be released program. It uses the phone and works 100% on my xda mini, xda II, XDA I but on the atom I can only get outward bound call to work with data.
normal opperation:
OFFERING
lineSetCallPrivilege
lineAnswer
CONECTED
lineGetID
SetCommState
SetCommTimeouts
......15 -20 seconds
CONECTED
read etc.
with the atom all goes for outbound calls but with inbound calls the 15-20 second delay when the modems talk is 0 seconds. The remote party still stops for 15-20 seconds and then it gets a connected message.
the handle i get for the serial port when answering a call dose not cause any read/write errors such as 6(bad handle) it just times out depending on my settings.
Has anyone succesfully answered and received data with an atom?
Dose anyone have a link to the manufacturess (quanta) site so I can ask if they implemented the TSPI_lineGetID fully.
I would just flush the atom if I owned another mobile 2005, but until then I cant be sure if its the hardware the operating system or my code.
I have confirmation that my code is good and wm2005 is good. My friend bought a jamin and we tested it.
edit:
replace:THE ATOM DOSE NOT WORK. with:MAKES MORE PROBLEMS THAN ITS WORTH FIXING...
If you are thinking of bying it I strongly recomend not doing so. I will be buying a jamin or kjam in a couple of weeks and never look back to the atom. IMO the origional XDA is better than the atom, it isn't fancy but its never let me down.
I seem to have found a very strange fix for this problem. I have been opening the line using lineOpen() and passing a dwCallbackInstance of 1. This has worked well on every device and because the documentation says...
User-instance data passed back to the application with each message associated with this line or with addresses or calls on this line. This parameter is not interpreted by TAPI.
I assumed it would have no effect on the way a call is made other than if I use it to sort out messages. Today I changed this to an arbitrary 3019 while cleaning up some of my code, just to make sure I am probably not conflicting with other people programs and now the atom can answer calls properly.
The timing of the line event messages is still wrong and my ui looks like its malfunctioning but after waiting the normal time for a connection the read/write opperations succeed. I have not changed any other code in relation to how the call is sent or answered so this baffles me but at least it works.
This may not be related, but I think the whole implementation of KernelIOControl function is a bit different on the atom then on most other phones (and PPC in general).
I encountered this when I tried to retrieve the devices UUID with a buffer bigger that 16. On most other devices it should be 36 or 40 (which actually matches, by size if not by content, the MSDN documentation) but on atom it was 52 (if I am not mistaken).
Very odd.
I had not noticed that, its a long time since I used the id but my old code still works. Its probably because I use a huge buffer the difference was not causing any problems.

using bluetooth modem on WM5 HTC Wizard, HOW???

Hey, just picked up a pre-pay 3 Skypephone, and its a nifty phone for the price, however what i would like to do is be able to use its good internet connection on my wizard, I have tried setting it up as a bluetooth modem, but when it tries connecting it claims there is no mobile at the number dialled (*99***1#). i think it may be something to do with it wanting to fill in the area code.
Any ideas? or anyone know how to get this to work properly?
thanks in advance
I was right, I figured out that i needed to turn off the dialling rules (schoolboy error i know)
anyway, all fixed now i have cheap fast browsing on the go

TomTom 7 on iPAQ 614c

I installed TomTom Mobile 7 on my iPAQ 614c but when I run the programme it says theres no GPS receiver in the PDA and i selected integrated GPS receiver in the settings. What's the problem here and how can i sort it?
Smasher77 said:
I installed TomTom Mobile 7 on my iPAQ 614c but when I run the programme it says theres no GPS receiver in the PDA and i selected integrated GPS receiver in the settings. What's the problem here and how can i sort it?
Click to expand...
Click to collapse
Hi,
The problem is that 'integrated GPS' in the eyes of TT means 'SirF Starxx' ... You just need to change the GPS to 'Other NMEA', Baud 115200, Port 6 (or 8 depending your GPS settings) ....
FYI, I set HW port on 8, and SW port on 6 in the GPS applet on the main Settings menu.
Dirk
PS remeber, there's now a dedicated forum for HP 614 here
Well that worked now it says "Awaiting for valid signal" and in the menu it says the signal strenght is weak I dont know if this is normal but if i wait i may get signal is that right?
Smasher77 said:
Well that worked now it says "Awaiting for valid signal" and in the menu it says the signal strenght is weak I dont know if this is normal but if i wait i may get signal is that right?
Click to expand...
Click to collapse
Hi,
Yep, it might take some time to get a fix, but once TT finds the GPS it's up and running.
;D
Dirk
i have the same problem.
I have the tomtom 7 installed.
But always says: waiting for a signal but never starts....
¿Are there any fix to resolve this problem?
thank you
try to go to a empty area that have open sky, the ipaq first fix can take long time (can be as long as like 5 minutes) and it does not work well in place that have a lot of tall buildings, if everything does not work, you may want to contact hp for exchange i suppose.
Make sure you select Other NEMA receiver and port 6 in configure GPS.
There are people saying flashing to unofficial rom will make fix faster but i cannot confirm that other than usually those unofficial rom will include a program call ipaq qk position that can download data to make fix faster
keyx said:
try to go to a empty area that have open sky, the ipaq first fix can take long time (can be as long as like 5 minutes) and it does not work well in place that have a lot of tall buildings, if everything does not work, you may want to contact hp for exchange i suppose.
Make sure you select Other NEMA receiver and port 6 in configure GPS.
There are people saying flashing to unofficial rom will make fix faster but i cannot confirm that other than usually those unofficial rom will include a program call ipaq qk position that can download data to make fix faster
Click to expand...
Click to collapse
Hi,
Tnx for your ROM The iPAQ QK is indeed loading the ephemeris via internet. But TT is not using these files. It loads instead the data directly from the satellites, which takes longer. The iPAQ files are used by other programs like VisualGPSce or Navio. Hence no difference in getting a fix.
Dirk

Categories

Resources