1

I have got a Cognex Advantage 100 camera connected to my PC via ethernet.

After pressing F5 in the inSight Explorer to trigger the camera I can use the captured image in a Python script.

Can I make the Python script trigger the image capture itself?

jwpfox
  • 5,124
  • 11
  • 45
  • 42
TiMey
  • 13
  • 1
  • 4
  • My Camera has software yes, it is working correctly. I searched alot in the Internet but didnt find that much, not even if it is possible. It is a Cognex Advantage 100 camera – TiMey Nov 16 '16 at 06:59

2 Answers2

2

I'm not very familiar with the Advantage series, but I am quite familiar with the other In-Sight cameras. I'm going to assume the Advantage is similar to other In-Sight cameras.

You should be able to achieve a trigger from python by opening a telnet connection to the camera (on port 23), logging in (default username: admin, password: ), and sending the command 'SE8'. The camera trigger mode must be set to External, Manual or Network. If the command is successful, it will respond with a '1'. I'd suggest trying this with a telnet client before trying it in python. Suggested telnet clients: Putty or Hercules.

More information can be found in the In-Sight Explorer help file. From the contents, go to 'Communications Reference -> Native Mode Communications'.

Don
  • 181
  • 8
  • Thanks for youre answer. Thats right, i got i working like this. I got it already before youre answer, but the question is now answered for others, thanks. – TiMey Jan 03 '17 at 06:54
1

Possibly you could simulate a key press. This answer here and this answer here, might help you do that.

Apart from that, your camera software doesn't allow you to interact with it via python, but it does supply it own method of programming the camera here. Try that instead, it seems to be the indented way of doing this.

Community
  • 1
  • 1
Elliot Roberts
  • 910
  • 5
  • 10
  • Could work yes, but requiers the inSight Explorer to be open. My software is saved on the camera so i dont need and dont want the inSight Explorer to be open in future. – TiMey Nov 16 '16 at 07:11
  • Your code runs on the camera? How do you initiate the code? Is there an api you are using to interact with the camera? – Elliot Roberts Nov 16 '16 at 07:12
  • Yes, i use the inSight Explorer, if that is what you asked for. – TiMey Nov 16 '16 at 07:17