ECA Board Issues

If you made your own board, post here, unless you built a Maple or Maple mini clone etc
zmemw16
Posts: 1294
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: ECA Board Issues

Post by zmemw16 » Wed Dec 02, 2015 8:53 pm

i'm going to regret this, but why can't you just waggle the lot?

stephen

User avatar
RogerClark
Posts: 6375
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: ECA Board Issues

Post by RogerClark » Wed Dec 02, 2015 9:02 pm

zmemw16 wrote:i'm going to regret this, but why can't you just waggle the lot?

stephen
I see what you mean, but...

It seems bad practice, as we have no idea what people have connected to the pins or even if they are shorted to GND etc

And it would be impossible to flash the led without constantly reseting the usb

User avatar
BrotherV
Posts: 20
Joined: Sat Nov 21, 2015 12:44 pm
Location: Iran, Esfahan
Contact:

Re: ECA Board Issues

Post by BrotherV » Thu Dec 03, 2015 9:54 am

[quote="RogerClark"]
Hello Roger, it's connected to PD2. So after I loaded the bootloader should be able to connect the PC directly to the USB on the STM32, Right?

User avatar
RogerClark
Posts: 6375
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: ECA Board Issues

Post by RogerClark » Thu Dec 03, 2015 10:27 am

You need a Bootloader which uses PD2 to reset the USB,

But I just checked and there isnt a version which uses PD2 to cause the USB to re-enumerate

Its fairly easy for me to recompile a new version, but I'm afraid It can't do it today, as its 21:25 local time, and I've just finished work.
i.e I"ve been working for 12 hours as I have a deadline for tomorrow morning

So its too late for me to make you a new bootloader today

Perhaps some other kind person can add you a new build target or perhaps you can make a new target and rebuild it

User avatar
BrotherV
Posts: 20
Joined: Sat Nov 21, 2015 12:44 pm
Location: Iran, Esfahan
Contact:

Re: ECA Board Issues

Post by BrotherV » Thu Dec 03, 2015 3:34 pm

Thanks Roger, hope you are well.
I try my best, I read many topics but how do I change the bootloader for this board? :D
I mean, how do I define the usb reset pin in config.h and how to make a new bin file?!!!!

Thanks

fredbox
Posts: 94
Joined: Tue Jul 07, 2015 4:44 pm

Re: ECA Board Issues

Post by fredbox » Thu Dec 03, 2015 10:56 pm

Code: Select all

#elif defined TARGET_ECA
	#define HAS_MAPLE_HARDWARE 1
	#define LED_BANK           GPIOC
	#define LED_PIN            13
	#define LED_ON_STATE	    0	
	/* USB Disc Pin Setup.     USB DISC is PD2 */
	#define USB_DISC_BANK      GPIOD
	#define USB_DISC           2	
Try this one - USB disc on PD2 and led on PC13.
Attachments
eca_boot20_fixed.zip
(4.9 KiB) Downloaded 18 times
Last edited by fredbox on Fri Dec 04, 2015 8:19 pm, edited 1 time in total.

User avatar
BrotherV
Posts: 20
Joined: Sat Nov 21, 2015 12:44 pm
Location: Iran, Esfahan
Contact:

Re: ECA Board Issues

Post by BrotherV » Fri Dec 04, 2015 6:52 am

fredbox wrote:

Code: Select all

#elif defined TARGET_ECA
	#define HAS_MAPLE_HARDWARE 1
	#define LED_BANK           GPIOC
	#define LED_PIN            13
	#define LED_ON_STATE	    0	
	/* USB Disc Pin Setup.     USB DISC is PD2 */
	#define USB_DISC_BANK      GPIOD
	#define USB_DISC           2	
Try this one - USB disc on PD2 and led on PC13.
Thanks fredbox, ;)

User avatar
RogerClark
Posts: 6375
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: ECA Board Issues

Post by RogerClark » Fri Dec 04, 2015 10:11 am

Thanks Fredbox

I was going to do it at the weekend

One thing to note is that the board will not automatically reset prior to upload

You will need a new board Variant in order to do that.

Probably your best bet is to copy the Maple RET6 folder and change lines 102 and 103 in board/board.h

Code: Select all

/* USB configuration.  BOARD_USB_DISC_DEV is the GPIO port containing
 * the USB_DISC pin, and BOARD_USB_DISC_BIT is that pin's bit. */
#define BOARD_USB_DISC_DEV      GPIOC
#define BOARD_USB_DISC_BIT      12

Or just change the Maple RET6 file and use select Maple ret6 from the boards menu

Change it to

Code: Select all

/* USB configuration.  BOARD_USB_DISC_DEV is the GPIO port containing
 * the USB_DISC pin, and BOARD_USB_DISC_BIT is that pin's bit. */
#define BOARD_USB_DISC_DEV      GPIOD
#define BOARD_USB_DISC_BIT      2


Then the board should reboot when you upload from the IDE and it should automatically upload via DFU

User avatar
BrotherV
Posts: 20
Joined: Sat Nov 21, 2015 12:44 pm
Location: Iran, Esfahan
Contact:

Re: ECA Board Issues

Post by BrotherV » Fri Dec 04, 2015 12:07 pm

Thanks Roger
Still some questions remaining. I'll ask after the weekend.
I've uploaded bootloader via Demonstrator GUI, but pc13 is not blinking and pc doesn't recognize stm32 board when I plug in the usb cable.
(I've installed maple dfu drivers and changed lines 102 and 103 in board/board.h)

Have a nice weekend

User avatar
RogerClark
Posts: 6375
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: ECA Board Issues

Post by RogerClark » Fri Dec 04, 2015 7:52 pm

Sounds like there is a problem with the firmware @fredbox posted, or possibly the same issue we have with startup on some cheap STM32F103C8 boards

I will try loading the @fredbox firmware onto a "redpill" board that has an led on pc13

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest