tgy icon indicating copy to clipboard operation
tgy copied to clipboard

e-skateboard brakes

Open youbobcat opened this issue 8 years ago • 3 comments

Trying to replicated https://endless-sphere.com/forums/viewtopic.php?f=35&t=74880 braking.

currently hacking:

run_reverse: rcall wait_for_low nFET_brake_on i_temp1 sync_on rcall wait_for_high nFET_brake_off i_temp1 rcall wait_for_low nFET_brake_on i_temp1 rcall wait_for_high nFET_brake_off i_temp1 sync_off rcall wait_for_low nFET_brake_on i_temp1 rcall wait_for_high nFET_brake_off i_temp1

.macro nFET_brake_on
	AnFET_on
	BnFET_on
	CnFET_on
.endmacro

.macro nFET_brake_off
	in	@0, AnFET_port
	.if (INIT_PB & ((AnFET_port == PORTB) << AnFET)) | (INIT_PC & ((AnFET_port == PORTC) << AnFET)) | (INIT_PD & ((AnFET_port == PORTD) << AnFET))
	cbr	@0, (1<<AnFET)+(1<<BnFET)+(1<<CnFET)
	.else
	sbr	@0, (1<<AnFET)+(1<<BnFET)+(1<<CnFET)
	.endif
	out	AnFET_port, @0
.endmacro

This is as far as I have gotten any help would be very much appreciated!

youbobcat avatar Oct 15 '17 02:10 youbobcat

http://vedder.se/2015/01/vesc-open-source-esc/ might be of interest to you if you haven't seen it.

tracernz avatar Oct 15 '17 03:10 tracernz

Thanks I have read about VESC but my aim was to get working a cheap redbrick ESC I own. I have everything but the dynamic throttle controlled brakes working.

youbobcat avatar Oct 17 '17 21:10 youbobcat

Did you made any progress? I am now dealing with the same thing :(, recently bought RED BRICK 100A and find out that it is braking too hard.

Tomonickb avatar Jun 24 '20 19:06 Tomonickb