How to use windows as raspberry pi and connect the windows with another raspberry pi [closed]

我怕爱的太早我们不能终老 提交于 2019-12-12 06:39:42

问题


I'm using Python 3,ı want to send input from first raspi and change the output from second raspi.For example ı have a button,when ı press the button,ı want one message to be seen on the screen,when ı release the button ı want the message on the screen to be changed.I did everything correctly up to here.Now I want to use first raspi as button and ı want the messages to be seen and changed on second raspi.But the problem is that ı don't have second raspi,my boss said that ı could use my windows/laptop as second raspi.I could not find how to do that –


回答1:


You can't "use windows as a raspberry pi".

What your boss probably meant was to run the same code on your own computer and have the Pi communicate with it...

You would need to look into using the socket module or a library like SocketIO or ZMQ, where your Windows machine would "listen" for incoming requests on some port, and the raspberry pi would have to connect explicitly to that port on the remote machine

If by "screen" you mean a web browser, then you would just use Javascript to update the display, and the backing API server (of any language) would store your change



来源:https://stackoverflow.com/questions/59083217/how-to-use-windows-as-raspberry-pi-and-connect-the-windows-with-another-raspberr

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!