hmm can you use ubuntu wsl?
maybe cpython on windows doesnt have select.poll
Need to migrate project--Please suggest
-
- Posts: 969
- Joined: Sat Feb 03, 2018 7:02 pm
Re: Need to migrate project--Please suggest
Kevin Köck
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode
Micropython Smarthome Firmware (with Home-Assistant integration): https://github.com/kevinkk525/pysmartnode
Re: Need to migrate project--Please suggest
Actually planning to run it on raspberry Pi finally. Presently running the desktop version of Pi in virtual box. Since it is running on Ubuntu core, so will give it a try. Need to adjust the IP and port forwarding in VBox for WiFi connectivity. I will update the result here.
- pythoncoder
- Posts: 5956
- Joined: Fri Jul 18, 2014 8:01 am
- Location: UK
- Contact:
Re: Need to migrate project--Please suggest
I have a long term test running at the moment where the server is running on a Pi (an ancient V1 Pi at that). I'm running the server under the Unix build of MicroPython. I haven't tried CPython 3.8 on the Pi but I have tested it on a PC in a Debian VM.
Peter Hinch
Index to my micropython libraries.
Index to my micropython libraries.
Re: Need to migrate project--Please suggest
Ok, I will try ( Obviously with some help from you) on Raspibian. It will ensure the cross-platform compatibility. Windows 10 does not seem to be a good platform for this. I have no problem with that as my final target is to run it on Raspibian (which is a debian core, I think). The client is ready, only I need to have a proper platform to run the server.
When the Master developer himself is helping me, I am sure I will be able to make it work. Thanx Peter.
When the Master developer himself is helping me, I am sure I will be able to make it work. Thanx Peter.
Re: Need to migrate project--Please suggest
Yes finally it seems running under Raspibian (Raspberry pi desktop running on Virtual box under windows 10) and forwarding the port for wifi connectivity. As per instruction I have installed python 3'8 (original was 3.5, which failed to run). The output I am getting on client is
And on server
in an infinite loop with my blue LED blinking on ESP board.
Everything is on WiFi, connected via home router.
It was really hard for a noob like me to setup initial development environment.
If Peter confirms that the system is working as intended, then I can proceed to the original migration problem.
Code: Select all
Welcome to MicroPython!
Password:
WebREPL connected
>>> import iot.examples.c_app
App awaiting connection.
WiFi OK
Connection state: True
Code: Select all
pi@raspberry:~/Desktop/micropython-iot $ python3 -m iot.examples.s_app_cp
Awaiting connection. 8123
Client 2 Awaiting connection.
Client 4 Awaiting connection.
Client 3 Awaiting connection.
Client 1 Awaiting connection.
Got connection from client 1
Started reader
Started writer
Sent [0, 0, 0] to remote 1
Got [16, 88, 20176] from remote 1
Sent [1, 88, 20176] to remote 1
Got [17, 89, 20032] from remote 1
Got [17, 90, 20016] from remote 1
Sent [2, 90, 20016] to remote 1
Got [17, 91, 20016] from remote 1
Sent [3, 91, 20016] to remote 1
Got [17, 92, 20016] from remote 1
Sent [4, 92, 20016] to remote 1
Everything is on WiFi, connected via home router.
It was really hard for a noob like me to setup initial development environment.
If Peter confirms that the system is working as intended, then I can proceed to the original migration problem.
- pythoncoder
- Posts: 5956
- Joined: Fri Jul 18, 2014 8:01 am
- Location: UK
- Contact:
Re: Need to migrate project--Please suggest
Yes, that looks good.
Peter Hinch
Index to my micropython libraries.
Index to my micropython libraries.
Re: Need to migrate project--Please suggest
@Peter, I am starting a new thread with MPU 6050 aspect and will ask lots of stupid questions.
I am focusing on the two projects by you, particularly one with the sensor fusion.
I am focusing on the two projects by you, particularly one with the sensor fusion.