This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2011-11-20 21:36:34

frebas
New Scratcher
Registered: 2011-11-20
Posts: 3

Using Remote Sensor with Norton Firewall

I'm trying to configure my computer to allow Scratch to communicate with Python.  When I run the sample code (from http://wiki.scratch.mit.edu/wiki/Communicating_to_Scratch_via_Python) in Python and get the error as follows:
File "C:\scratchtest", line 22, in <module>
    scratchSock.connect((HOST, PORT))
socket.error: [Errno 10061] No connection could be made because the target machine actively refused it

In the sample code,
HOST = '127.0.0.1'
PORT = 42001

Any ideas on what I need to do to Norton Firewall to unblock the right host/port combination?

Offline

 

#2 2011-11-20 22:42:10

frebas
New Scratcher
Registered: 2011-11-20
Posts: 3

Re: Using Remote Sensor with Norton Firewall

Update to this...I have completely removed Norton Firewall, and I'm still getting the error.  Any suggestions?

Offline

 

#3 2011-11-20 23:14:15

bbbeb
Scratcher
Registered: 2009-06-11
Posts: 1000+

Re: Using Remote Sensor with Norton Firewall

It means your machine refuses it.
Check firewall and such, and make sure your computer allows Python.


Back in my day.... there were no laws that censored the internet... now, there are.... nah.

Offline

 

#4 2011-11-21 15:32:08

TRocket
Scratcher
Registered: 2009-08-18
Posts: 1000+

Re: Using Remote Sensor with Norton Firewall

check scratch is running and remote sensor connections are enabled (sensing -> right click (<      ^> sensor value) -> enable remote sensor connections)


http://i.imgur.com/1QqnHxQ.png

Offline

 

#5 2011-11-21 15:43:46

Magnie
Scratcher
Registered: 2007-12-12
Posts: 1000+

Re: Using Remote Sensor with Norton Firewall

TRocket wrote:

check scratch is running and remote sensor connections are enabled (sensing -> right click (<      ^> sensor value) -> enable remote sensor connections)

Yeah, this may be the problem, check that.

Usually the computer does not block 127.0.0.1 since it's on the same machine.

Offline

 

#6 2011-11-21 20:42:30

frebas
New Scratcher
Registered: 2011-11-20
Posts: 3

Re: Using Remote Sensor with Norton Firewall

Thanks all. Looks like I needed to disable then enable remote connections once python was running. Odd, but seemed like scratch needed to reset or something.

Got it working.

Thanks, scratchers, for the quick advice!

Offline

 

Board footer