minimal port dosent work on pyboardV1.1

The official pyboard running MicroPython.
This is the reference design and main target board for MicroPython.
You can buy one at the store.
Target audience: Users with a pyboard.
Post Reply
john_mayne
Posts: 2
Joined: Fri Jun 28, 2019 6:26 am

minimal port dosent work on pyboardV1.1

Post by john_mayne » Fri Jun 28, 2019 6:39 am

I built and flashed the minimal port to the pyboardV1.1 and I don't see any serial device to connect to when I'm done flashing. In the main I see that it initializes uart but nothing shows up. What could I be doing wrong?

User avatar
jimmo
Posts: 2754
Joined: Tue Aug 08, 2017 1:57 am
Location: Sydney, Australia
Contact:

Re: minimal port dosent work on pyboardV1.1

Post by jimmo » Fri Jun 28, 2019 7:22 am

The minimal port doesn't include any drivers other than a basic stm32f4 USART (USART1 tx=B6, rx=B7, which are X9/X10 on the Pyboard). So you should be able to plug an USB/UART adaptor into those pins.

It sounds like you're expecting to see a CDC ACM virtual serial port through the pyboard's USB port though, which the main firmware provides. This doesn't exist in the minimal port.

If you're used to something like an Arduino Uno or a micro:bit, the USB interface is provided by an external chip. On the pyboard (or an Arduino Leonardo) the USB interface is handled by the main microcontroller, so needs to be implemented in the firmware.

john_mayne
Posts: 2
Joined: Fri Jun 28, 2019 6:26 am

Re: minimal port dosent work on pyboardV1.1

Post by john_mayne » Fri Jun 28, 2019 1:14 pm

so to clarify I would need to bring in the USB drivers myself, remap the UART pins to the USB out right?

User avatar
jimmo
Posts: 2754
Joined: Tue Aug 08, 2017 1:57 am
Location: Sydney, Australia
Contact:

Re: minimal port dosent work on pyboardV1.1

Post by jimmo » Fri Jun 28, 2019 9:35 pm

Not quite, there's no pins or hardware UART involved. You use the USB driver to make a virtual UART that the host PC knows how to detect as a CDC ACM device.

i.e. to send a byte, instead of writing to the USART register, you'll make a USB frame and send it out through the endpoint you've defined.

User avatar
dhylands
Posts: 3821
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: minimal port dosent work on pyboardV1.1

Post by dhylands » Fri Jun 28, 2019 9:49 pm

The minimal port worked fine on my Pyboard 1.1.

Things to note:
- You need to connect the USB serial TX to UART1 RX (i.e. pin X10) - you need to cross TX and RX - don't connect TX to TX
- You need to connect the USB serial RX to UART1 TX (i.e. pin X9)
- You need to connect Ground from the USB serial to GROUND on the pyboard
- You need to connect to the USB serial at 9600 baud.
- Sending Control-D will hang the board (it doesn't support soft reset), so you need to use a real terminal program. Something like rshell won't work.

Code: Select all

MicroPython v1.11-64-gced340d73 on 2019-06-28; minimal with unknown-cpu
>>> 

Post Reply