MrYsLab / s2m

Scratch to micro:bit bridge.
https://mryslab.github.io/s2m/
GNU Affero General Public License v3.0
35 stars 19 forks source link

cannot connect microbit in windows. it is red, why? #34

Closed junhuanchen closed 5 years ago

junhuanchen commented 5 years ago

1 2

try install https://scratch.mit.edu/help/studio/tips/howto/wedo2win-1/

but still cant connect.

look at this scratch2.0 never request(http://localhost:50209/poll).

MrYsLab commented 5 years ago

@junhuanchen I am sorry you are having problems with s2m. The s2m program works only with the off-line version of Scratch and it connects to the micro:bit using a USB cable. The device manager that the Scratch team provides is not compatible with s2m. This incompatibility is a choice of the Scratch and not mine.

To try and help you, I have some questions:

  1. Are you connecting your micro:bit with a USB cable to your computer?
  2. Did you load the special micro:bit program on to your micro:bit? Instructions for doing this can be found here
  3. What operating system are you using - Windows, macOS or Raspberry Pi?
junhuanchen commented 5 years ago

1.sure 2.Because I confirmed that the underlying can enter g instructions to get the data, but also confirmed the pages localhost can get data, so I think, is scratch2.0 no communication with http://localhost:50209/poll 3.in winodws10 python3.5

MrYsLab commented 5 years ago

We need to make sure that the proper driver is installed and that s2m is selecting the correct com port.

Please do the following:

  1. Plug the micro:bit into your Windows computer.
  2. Open the Windows Device Manager and expand the Ports tab image
  3. If you do not see the "mbed Serial Port", you will need to install the mbed serial driver.
  4. Once you are able to see the "mbed Serial Port", look at the COM port that windows assigned. In the screenshot above this is COM7. Your COM port may be different.
  5. When you start s2m, the COM port is identified on the console: image In this Screenshot, the COM port is com4. If the com port that is listed in the device manager is different than the com port that s2m chose, then you will need to manually identify the correct com port when starting s2m. To do, use the -p option. This is documented here.
  6. If the com ports are correct but Scratch still does't connect, try starting in a manual mode. This is documented here.

Please let me know if any of this solved your problem. Thanks.

junhuanchen commented 5 years ago

well, you known that i can get http://localhost:50209/poll data. so i think this is windows bugs. but it can running in linux, so keep watching.