Closed GoogleCodeExporter closed 9 years ago
I have successfully baked the TCP server into the Start-up process. I did the
following:
1. Create file "/boot/startup.sh"
2. Add the following text:
[ code ]
# CUSTOM COMMANDS TO START ON START UP
# Link with /etc/rc.locals
python /root/TCP.py
[ /code ]
3. Add the following to "/etc/rc.local":
[ code ]
su -c "/boot/startup.sh" root
exit 0
[ /code ]
restart and there we go... also not that when a disconnect occurs, the server
is restarting! :D
I think we have success on "Thing to do: #1"
Original comment by cian.by...@sydstu.catholic.edu.au
on 27 Nov 2012 at 7:22
"Check direction through only two variables...so eliminate dir_y" I think
rather the opposite of this needs to occur, particularly for CMDrecon because
at teh moment we only have general direction we cannot control individual motor
direction, something we need for pivot turning.
Anyways the other stuff definitely needs to be done!
Original comment by thomas.i...@sydstu.catholic.edu.au
on 27 Nov 2012 at 9:44
Files for TCP.py @ start-up.
Original comment by cian.by...@sydstu.catholic.edu.au
on 27 Nov 2012 at 9:45
Attachments:
How can I sent a loop so that if the server fails to connect a number of times,
then it can say so connection...We need to check if the connection has succeed
and then continue through to the script.
Currently, you can say that you **want** to use TCP server but if it fails to
find the connection the 1st time, you have to start the script again. If it
was a fluke that you didn't find it the first time, we need say: 5 attempts at
a connection before the script can decide to abort (where there should be a
sys.exit so that errors do not occur).
Original comment by cian.by...@sydstu.catholic.edu.au
on 27 Nov 2012 at 10:28
The server will wait for clients though? It can't fail, thats only the client!
Original comment by thomas.i...@sydstu.catholic.edu.au
on 28 Nov 2012 at 3:21
It will wait for clients to connect like before. There is no checking for
which client has connected. This can come later.
Original comment by cian.by...@sydstu.catholic.edu.au
on 28 Nov 2012 at 8:05
CLOSED
Original comment by thomas.i...@sydstu.catholic.edu.au
on 29 Nov 2012 at 10:00
You can't close this topic...It is important!
Original comment by cian.by...@sydstu.catholic.edu.au
on 30 Nov 2012 at 1:17
Some of this is CBFD but not all of it!
List what is CBFD!
Original comment by cian.by...@sydstu.catholic.edu.au
on 30 Nov 2012 at 1:30
hahahaha ok fine!! Work on CMDrecon=cbfd/actually have to do something... :(
Original comment by thomas.i...@sydstu.catholic.edu.au
on 1 Dec 2012 at 7:53
Things to do in next update:
- TCP Client - get rid of apostrophes for question about the Manual IP address
- Chack which RPi is using Module.
Original comment by cian.by...@sydstu.catholic.edu.au
on 1 Dec 2012 at 8:30
The Hostname is only fetching the local host name not the remote. This needs
to be fixed.
Original comment by cian.by...@sydstu.catholic.edu.au
on 1 Dec 2012 at 9:39
socket.gethostbyaddr('<address goes here inside inverted commas> ')
>>> socket.gethostbyaddr('192.168.12.2')
('MAIN-WIN7-PC-LAN.fritz.box', [], ['192.168.12.2'])
look more at this for me...I will follow up tomorrow.
Original comment by cian.by...@sydstu.catholic.edu.au
on 1 Dec 2012 at 11:14
Issue with hostname fetching local name has been apprehended. We have replaced
code with gethostbyaddr(HOST)
Original comment by thomas.i...@sydstu.catholic.edu.au
on 2 Dec 2012 at 7:55
Original issue reported on code.google.com by
cian.by...@sydstu.catholic.edu.au
on 27 Nov 2012 at 7:16