AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Computer controlled switches

 
Reply to topic    AutoHotkey Community Forum Index -> General Chat
View previous topic :: View next topic  
Author Message
alrobnett
Guest





PostPosted: Sun Feb 18, 2007 10:25 pm    Post subject: Computer controlled switches Reply with quote

I teach astronomy at Gallatin High, Gallatin, TN. We have built a 9-foot domed observatory for our 12" Meade LX200 telescope. We can control the telescope from the classroom via VNC, the school network and standard software. We have bought a 12vdc gearbox motor to rotate the dome and have created a program that determines the necessary aximuth for the dome slit. We plan to use an inexpensive barcode reader to sense dome orientation. What we lack is computer controlled switches to send either 6 or 12 volt, positive or negative, to the motor. I was dismayed to read on a site that XP doesn't permit access to the ports. Isn't this something that we should be able to do with Euphoria? If XP doesn't permit access, can we still accomplish it on a DOS level, even though the computer is running XP?
Allen Robnett
Back to top
BoBo
Guest





PostPosted: Sun Feb 18, 2007 10:57 pm    Post subject: Reply with quote

Quote:
I was dismayed to read on a site that XP doesn't permit access to the ports
Which ports?
Back to top
alrobnett
Guest





PostPosted: Mon Feb 19, 2007 3:19 am    Post subject: computer controlled switches Reply with quote

Which ports?

Please pardon my ignorance. I did a search on "computer controlled switches and found the following paragraph on a site called "learn-c.com".

>>The tutorial examples will work on most operating systems that allow direct access to ports (more on ports later). Linux, DOS, Windows 3.x, Windows 95, Windows 98, and Windows Me will work, among others. To use Linux, follow the guidelines at the Linux I/O port programming mini-HOWTO. Direct port access is not permitted byControl And Embedded Systems NT, 2000, XP and some other operating systems. It's still possible to get at the ports however, by using special procedures that add a layer you can go through. Experienced programmers and brave beginners can look in Programmer's Heaven for information on gaining such access.
>>

I know the difference between a parallel connection and a serial connection, and I know that USB connections are much less trouble for the novice. I assume that a "port" is an address that can be connected to a physical data connector. I remember that com1, com2, com3, com4 could be assigned to a variety of different uses, but I'm pretty much in the dark about the details. It makes sense that the computer should be able to issue a signal that causes a switch to be operated, but I don't know how that is done.
Back to top
BoBo
Guest





PostPosted: Mon Feb 19, 2007 7:53 am    Post subject: Reply with quote

(Un)fortunately I don't know much (means close to nothing) about that topic. Nevertheless I've tried to identify some usefull information about it.
Now the tough part/outcome of the story.
a) the following is in German (while the author seems to study in the US at the moment). Might make sense to contact him directly.
b) you've to download the webpage (see AHKCode below), otherwise it will be refreshed/redirected within 5 sec, so you won't be able to check it Mad
Code:
urldownloadtofile, http://www.dyckonline.de/u_p_pwm.htm, %USERPROFILE%\Desktop\u_p_pwm.htm ; file dropped to Desktop

c) there's a good chance that I've lost you. Bare with me Embarassed

Good luck, and greetings to Jean Luc and Janeway Very Happy
Back to top
WrongSectionAlert
Guest





PostPosted: Mon Feb 19, 2007 7:55 am    Post subject: Reply with quote

General Chat! Cool
Back to top
Dippy46



Joined: 06 Jul 2004
Posts: 171
Location: Manchester, England.

PostPosted: Thu Feb 22, 2007 1:35 pm    Post subject: Reply with quote

@alrobnett,

It is correct that winxp does not allow direct access to control ports, this is the area covered by kernal mode drivers. A number of drivers are available on the net to provide the required access via DllCalls making them compatable with AHK. So in effect any external hardware device can be read or controlled directly from AHK under winXp. A number of advanced solutions also allow for bidirectional control using USB driven by a standard com1 codebase. Take a look at the site below to give you more ideas and options. If need be get back to this thread and I'll dig into my archives for some appropriate code handlers. It may be worth noting that using Alt Az is generally considered the most effective method for linear telescope tracking. More info on astromaths et al if you need it.

Regards
Dave.

[url]
http://www.beyondlogic.org
[/url]
_________________
Simple ideas lie within reach, only of complex minds
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> General Chat All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group