pocket pc raw IR problem

G

giampow kappa

I'm trying to write an application which serves as a TV remote control.
I have read IR COM port for raw IR on PPC is COM4: but when I use the
CreateFile Win API I get the error "create failed" (error code 55).
In my PPC registry I have found the value Port="4" in
HKLM\Comm\XSC1_IrDA1 so I think COM4 should work fine, but It does not.

Please answer if you have some ideas!
Thanks a lot in advance
 
I

info

Can you send some source ? I'm trying an similar thing perhaps I can
see something.
 
G

giampow kappa

int hPort = CreateFile("COM4:", GENERIC_READ, 0, 0, OPEN_EXISTING, 0,
0);// check for success

EscapeCommFunction(hPort, SETIR);

// read port value
ReadFile(hPort, buffer, 2048, ref read, 0);
if(read>0){
...
}

CloseHandle(hPort);
 
G

giampo

I stopped ActiveSync, but the problem remains. How can I control if COM4 is
really installed?

I call the native Win32 CE API CreateFile from C# code on .NET Compact
Framework. Could it be the reason of the problem?
 
C

Chris Tacke, eMVP

Something on the device has it open already. I don't use PPCs often, so I
can't tell you what it is, but guesses would be ActiveSync, OBEX or some
third-party listener scanning for incoming IrDA. "Stopping" ActiveSync
probably isn't enough - you likely have to explicitly tell it to quit
looking at the port.

--
Chris Tacke
Co-founder
OpenNETCF.org
Are you using the SDF? Let's do a case study.
Email us at d c s @ o p e n n e t c f . c o m
http://www.opennetcf.org/donate
 
G

giampow kappa

thanks a lot Chris. So learned I have to to make some apps release the
port. But I don't know how to detect those apps. I will study the problem.
Thanks again
 
G

giampow kappa

in HKLM\Drivers\Active\07

I have Name="COM4:" and Key="Drivers\BuiltIn\IrDA"
so I think COM4: is the right port name for raw IR.

I make quit ActiveSync, but the problem remains. No other apps seems to run
and listen to IR port.
 
P

Paul G. Tobey [eMVP]

Can we assume that this is just for fun and not a real application? I've
heard several times that the range of such an IR remote based on PPC devices
is a foot or two...

Paul T.
 
G

giampo

not for fun, but real application!
You are right about the max distance, but there are cheap booster
devices which receive the pocket pc IR signal and resend it amplified.
These devices are to be attached to the IR transmitter.

giampo,
AT technologies researcher
 
C

Chris Tacke, eMVP

So you have a PPC ($300-$500) that needs to be charged every few days, plus
another external device (unknown cost) that somehow attaches to it, with
it's own power supply? And people will want that instead of a one-piece
universal remote that the battery lasts months on?

Did the purchasers of this device also invest heavily in eToys.com?

--
Chris Tacke
Co-founder
OpenNETCF.org
Are you using the SDF? Let's do a case study.
Email us at d c s @ o p e n n e t c f . c o m
http://www.opennetcf.org/donate
 
G

giampo

yes, since this is determined by other features required: the remote
control is only one of many features of a more complex environment
control system for the home automation for people with physical
disabilities. The PPC platform offer the interesting possibility of a
full programmable and custom-made user interface with the "scanning"
feature: buttons are selected periodically through a loop and people can
select one of them through a special input device (for example a general
purpose sensor connected through a blue tooth device).
Can you suggest me other better platform to implement this project? I
greatly appreciate comments.
thanks!

giampo,
Assistive Technologies researcher
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top