[Tutor] Trying to send a cursor down key press string to a device
Alan Gauld
alan.gauld at btinternet.com
Sat Mar 17 15:05:29 CET 2012
On 17/03/12 11:55, dave selby wrote:
> I have an attatched mymobiler device which I can send string to, I
> need to send a cursor down command but am having problems,
I have no idea what a mymobiler device is, nor how you would go about
using Python with it.
> I need to send ... 224 followed by 80 I found this by monitering msvcrt.getch()
So send 224 followed by 80?
Or maybe construct a byte string using the struct module and send that?
> However I do not know how to construct this, chr(224) + chr(80)
> returns a loud bleep from my mymobiler device instead of moving the
> highlighte down one line
Given we have no idea what you are doing to "send" the data we can only
make wild guesses as to what might be happening.
It might help if you posted on a mymobiler specific forum? Or maybe the
main python list, since this is not really about learning Python, more
about learning how to communicate with your device.
But as a minimum, provide a lot more context and at least some code.
HTH,
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
More information about the Tutor
mailing list