Hello.The Stig said:Ok who's gonna sell me an open source controller
casainho said:The Stig said:Ok who's gonna sell me an open source controller
Thank you for your interest. How much money would pay for this Smart Controller?
Ok thank you. I must say I am not a commercial and I didn't any market research (but I have some connections to repair workshops of EBikes/EScooters and EBicycles). To say the true, I do not depend of this project to get the food on the table BUT I believe it must be useful, have value to users and be commercial project to have success.The Stig said:Thats a good question!casainho said:The Stig said:Ok who's gonna sell me an open source controller
Thank you for your interest. How much money would pay for this Smart Controller?
Sorry I haven't had time to read the thread yet but...
Depending on it being comparable to lyens controllers in terms of most features: I might do $100 on a 72V+ 20A controller. or 48V 25A.
$170 for a 72V+ 50A controller.
Ease and versatility of programming will be a big thing.
What would the rest of you pay...?
Are still planning on implementing close loop phase current/torque control?casainho said:- Current control works (using DAC, TIM1_ETR and Opamp LM258). Thanks to NJay for explaining me with great detail how this should work.
Seems complex what you say about "adaptive traction control for a 2wd with accelerometer and gyro feedback and stuff". But OpenSource is the way to go - look at the success of OpenSource Arduino and all the tools (hardware and firmware libs) available to hackers like us -- the same is going on with the more recent OpenSource RaspberryPI...The Stig said:Anything open source is good. I don't know much electronics or programming but if I could give work with a programmer to start playing around and programming things like adaptive traction control for a 2wd with accelerometer and gyro feedback and stuff... eventually we might make something reliable
"close loop phase current/torque control" <--- what is this?walls99 said:Are still planning on implementing close loop phase current/torque control?casainho said:- Current control works (using DAC, TIM1_ETR and Opamp LM258). Thanks to NJay for explaining me with great detail how this should work.
This is when the PWM is controlled by a fast PI loop to achieve a target phase current. The throttle command is then used to set this phase current/torque target instead of the PWM directly . If you want the throttle to command motor speed, you just need an outer loop (slower) to control the torque target.casainho said:"close loop phase current/torque control" <--- what is this?
My BMS is quite basic, it only controls the charge/balancing and per cell HVC/LVC. My BMS controller cannot measurement the cell voltage nor measure the output current. Coulomb counting is implemented in the motor controller. 2moto has built a "Smarter" version of my BMS, you should check with him, see here: http://endless-sphere.com/forums/viewtopic.php?f=14&t=45383casainho said:Walls99, I am thinking in future to use your OpenSource BMS and make it "Smart" (if not enough already). What kind of functionalities does it have? Does the controller read/have each cell voltage?
Hmmm, ok, thanks for the explanation. I am used to KUxxx controllers for my EBicycle and I am pretty sure the throttle setups PWM directly. On EBicycles I have almost no experience, I can't say how the ones I tried works.walls99 said:This is when the PWM is controlled by a fast PI loop to achieve a target phase current. The throttle command is then used to set this phase current/torque target instead of the PWM directly . If you want the throttle to command motor speed, you just need an outer loop (slower) to control the torque target.casainho said:"close loop phase current/torque control" <--- what is this?
GREAT!!! Other like me that prefer C and not the ASM And I am thank you for sharing your project just as 2moto did. I credit here: "This prototype hardware is based on the hardware from Open Sensorless BLDC controller project from walls99. The main differencies are a different microcontroller and no BEMF circuit. Also the firmware were is C instead of assembly."walls99 said:My BMS is quite basic, it only controls the charge/balancing and per cell HVC/LVC. My BMS controller cannot measurement the cell voltage nor measure the output current. Coulomb counting is implemented in the motor controller. 2moto has built a "Smarter" version of my BMS, you should check with him, see here: http://endless-sphere.com/forums/viewtopic.php?f=14&t=45383casainho said:Walls99, I am thinking in future to use your OpenSource BMS and make it "Smart" (if not enough already). What kind of functionalities does it have? Does the controller read/have each cell voltage?
Thank you for your explanation. I understand it can be a problem and I just remember I did cut 1 of the 2 shunt resistors of my KU123 controller, just to have half of max current on it, to have a soft start. I also want a soft start, with a programmable ramp up on speed -- that's also one of the reasons I started this project!The Stig said:close loop phase current control would be a huge benefit. Currently throttle control with todays ebike controllers is very bad, and you have to adjust to them because they are unlike cars or motorcycles. The worst thing is with medium to high powered setups, if someone is not very careful about the throttle control, the bike will jerk - making potential future ebike lovers uncomfortable.
Those are cycling pants, they are popular here among road and mountain cyclists. And I use them when inside house, to keep warmArlo1 said:What the hell kinda pants you wereing? LOL Im just bigging don't realy need to know.
The blue trace on oscilloscope is PWM signal from STM32F100. Here is the schematic (note that board is currently all wires):Arlo1 said:So what was the blue trace? Negative-source on one phase? Looks like some ringing going up and down.... How well is your paower stage set up. Im sorry I have sent you files yet but im trying to make sure mine can be used othewise the SCH is about all you will be able to look at.
It depends on what you what to measure. Right now, the capacitors are on the "circuit ground" side of the sensor, so they will filter the phase current and you will only see the battery current. If you want to measure the instantaneous phase current which is only possible during the PWM ON part of the cycle, then you need to place the capacitors on the "battery ground" side. On my controller, I configured the ADC to automatically sample the phase current at the end of the ON cycle for every cycle. When the conversion is finish, about 5us later, it triggers an interrupt so it can process the PI control loop to update the PWM based on the phase current/torque target command.casainho said:Walls99, can you please see on the schematic the 10mF capacitors? are they ok there (GND after the current sensor??)
That's what I want to do, control the current on PWM cycle by cycle.walls99 said:It depends on what you what to measure. Right now, the capacitors are on the "circuit ground" side of the sensor, so they will filter the phase current and you will only see the battery current. If you want to measure the instantaneous phase current which is only possible during the PWM ON part of the cycle, then you need to place the capacitors on the "battery ground" side.casainho said:Walls99, can you please see on the schematic the 10mF capacitors? are they ok there (GND after the current sensor??)
Ok, good to know/understand how you do. On my controller, STM32 and the OpAmp already do the current control but not with PID, I will need to implement PID If I want.walls99 said:On my controller, I configured the ADC to automatically sample the phase current at the end of the ON cycle for every cycle. When the conversion is finish, about 5us later, it triggers an interrupt so it can process the PI control loop to update the PWM based on the phase current/torque target command.
The PIC doesn't have an opamp for HW current limiting. The current control come from the PI loop and it takes several cycle for the current to converge towards the target. Over current protection is also supported but in SW by comparing the instantaneous phase current with a predefined maximum.casainho said:Ok, good to know/understand how you do. On my controller, STM32 and the OpAmp already do the current control but not with PID, I will need to implement PID If I want.walls99 said:On my controller, I configured the ADC to automatically sample the phase current at the end of the ON cycle for every cycle. When the conversion is finish, about 5us later, it triggers an interrupt so it can process the PI control loop to update the PWM based on the phase current/torque target command.
Good that PIC you uses that includes an opamp, the STM32F100 I use don't have one but others STM32 more expensive have. But mine have an ADCs with "comparator/watch dog" that may work as the same as the comparator, I never used such thing before...
Good idea. I wish some forum operator can make this change.crossbreak said:Nice project You really build a controller, it should be in the Motor/Controller forum, this way I would have read it earlier!
It is not a PIC nor an AVR, it is a ARM STM32F100, the same used on Open-BLDC project.crossbreak said:The pic you chose seems to be great for our job.
It is not implemented yet, but it should be only firmware. There is an application note for the controller:crossbreak said:I need CLCC, since high phase currents/torque during start up always kills the gears in my converted hubmotors http://endless-sphere.com/forums/viewtopic.php?f=28&t=45245
This project needs people like you, that want to build, test and develop it! It also needs someone to commercialize it, but that can happen later.crossbreak said:Your controller seems to be a wider shot, I would like to build one after I finished my project.
I will take advantage of cheap from China color touch screen display: http://dx.com/p/mini-stm32-stm32f103rbt6-development-board-w-2-8-tft-lcd-touch-screen-157301crossbreak said:About your display:
I Would not want to use a touchscreen, since it's more or less forbidden in Europe to use such things during driving. I use a monochrome LCD, since it can be read flawlessly even in bright sunlight. I want buttons directly accessable from the handle bar for switching speed and display modes. For setup and data logging, one can still use the smartphone via bluetooth.
Thanks for the interest, is really important for the success of this project. Right now is all development, there isn't any stable version yet, so, I would prefer you put only a description and a link to project page that I update myself. If you post a video or pictures, please use the date.crossbreak said:I would like to add this project to the wiki. Also the schematics and code. Would this be ok for you?