Jump to content

Open-source EUC motherboard


Inductores

Recommended Posts

10 hours ago, Restless said:

And what I've learned, the stm32 m3 should have plenty of power for this task, specially because it already has hw solutions for motor controller etc.

 

10 hours ago, Restless said:

It might be a good thing to look at this project for building the FW. Since it adds the possibility of multithreading. Which is a very nice thing, for a device which should handle multiple things parallel

If there is plenty of power available, there is nothing against multithreading if one wants.

The measurement, calculation and control loop is a sequentiel procedure by definition. One can "easier" guarantee time constraints. And there should not be any race conditions possible to stop this main duty.

But this could be nicely done with freeRTOS by starting this main task with "highest" priority in at defined time intervalls, and do all the fancy light, sound, whatever stuff with low priority/just once the main task sleeps...

... If one trusts the scheduler, but imho freeRTOS should be reliable?

10 hours ago, Restless said:

And what I've learned, the stm32 m3 should have plenty of power for this task, specially because it already has hw solutions for motor controller etc.

Imho their unique feature are the two motor pwm timers with dead time generation and emergency stop.

Another nice hardware feature in other modells are build in comperators, which could be used to generate an interupt in case of too high motor current. Don't know how this is realized by now on the boards - presumably just with looking at the current values in the "normal" control loop. Which is "slow" polling instead of a "fast" interrupt from the comperator?

 

  • Upvote 1
Link to comment
Share on other sites

Nice work!

I cant figure out if this is already done, but just seeing the Antenna part (which i guess is from the Bluetooth module?), i think it would be nice to expose some currently unmapped pins from the uC. Mostly thinking, that the STM32F103 has multiple USART ports which are nice for having external modules which could extend the featureset (like an dedicated led controller wich uses informations from the stm).

Simple pin headers would be enough.

Link to comment
Share on other sites

Just a sidenote, to everyone ordering the Chinese "Blue pills" (the "bare-bones STM32F103"-board) and ST-link copies: Original Nucleo STM32Fx -devkits that come with built-in programmer/debugger (basically they have built ST-Link V2 directly on the board) cost something like <10€ + VAT from Mouser for the "lower end" models with 32 or 64 pins, for the "higher end" -models it's something like 15-20€ with higher pin-counts/more memory/etc if you fear you're going to run out of I/Os (up to 144 pin versions) or memory. If you order stuff for 50€ worth, you get free shipping, and it arrives in a couple of days.  ;)

Nucleo STM32F103RB:

https://www.mouser.fi/ProductDetail/STMicroelectronics/NUCLEO-F103RB?qs=sGAEpiMZZMtw0nEwywcFgIZtmIQSvK4F7SgvqhUm0of%2Bpet9mJDudA%3D%3D

All Nucleos:

https://www.mouser.fi/Embedded-Solutions/Engineering-Tools/Embedded-Processor-Development-Kits/Development-Boards-Kits-ARM/_/N-cxd2t?Keyword=nucleo&FS=True&Ns=Pricing|0

 

Edited by esaj
  • Like 2
Link to comment
Share on other sites

20 hours ago, Inductores said:

I attach a photo with the current status of the board layout. I would say 90% done:

Layout.PNG.6a677cf7647bac9980129ccce905d572.PNG

Sorry for a slight thread hijack/off-topic, but looking at this board, I don't see many capacitors near the corners of the MCU (I'm assuming it's the U4 on the left side), and it's hard to follow from the low resolution picture where the lines go. Do you know the values of the capacitors feeding the VDD/VDDIO/VDDA -lines of the MCU?

The reason I'm asking is that I need to add an STM32F0 -MCU to a board I'm designing, and the datasheet seems to suggest somewhat excessive amounts of capacitance for the power inputs:

TLR5ewq.png

Even ST's own Nucleo-board has just 1uF + 100nF near the regulator, a couple of 100nF's combined for VDD's, and a single 100nF for VDDA with a ferrite bead to filter noise (apparently the capacitance on VDDA should be lower, because the VDDA-line must come up faster than the rest). Maybe they're just being conservative on the datasheet, but it's funny that their own dev-kit board doesn't follow their suggestions... And now I'm struggling trying to fit all the caps near the MCU on an already crowded board with strict size-limitations :P

Edited by esaj
  • Like 1
Link to comment
Share on other sites

Hey If we are starting from scratch what about a modular approach? This could empower a lot more flexible platform that would pull in more people and grow the movement.  For example high voltage EUC batteries at around 350 volts can use the motor inverter to fast  charge the batteries eliminating the need for a charger. There are just so many opportunities to improve the EUC platform but right now all the hardware and software is closed source. However just making it open source is not enough, EMI is hard to perfect when designing a pcb. That's why i think a modular platform will win long term. 

I know board to board connectors are not as easy as you might think. Apple had lots of issues back in the day. I'm thinking a soldered board to board because header pins fail with corrosion and they are costly. Here an example modular platform :

   

61911729_2320473331554466_884888796280127488_o.jpg

Link to comment
Share on other sites

I work on building management systems so come across different types of control boards.

Tbh they all seem to have about the same failure rate regardless if they're directly connected or have flexible fly lead connections. Main issues i have are normally down to a poor design or bad installation practice. Today i was replacing 2 valves with actuator control with had been working on an exposed roof for 11 years.They didn't have any reasonable IP rating as they were supposed to be used inside shielded from the elements.

If that can work for 11 years i reckon how the board is joined is a matter of preference. I like flexible connections, the kind used similarly to connect a laptop screen with the base, as i feel they allow for any movement that hadn't been expected.

Been following this for ages, properly interesting reading.

 

Keep up the good work!!!!

Pete

Link to comment
Share on other sites

Hi to all,

sadly I couldn't extract the original firmware and no one helped me with the firmware yet. So I was wondering if someone has a damaged board from a Ninebot, Kingsong or Inmotion, due to their FW is available from the manufacturer...

Link to comment
Share on other sites

Here's what im working on testing. I found some one that made a balancing robot with the px4. Due to the friction of email and webites I setup a facebook group and chat to speed up the dev cycle. Please join and help. We are on the edge of the next evolution of the euc. I think the euc will be faster than any production car in the next 2 years. This is going to be a wild ride

https://www.facebook.com/groups/1221706261331356/?ref=share

CC508B36-6E3A-4E90-9700-8058EEA33232.jpeg

Link to comment
Share on other sites

6 hours ago, Inductores said:

Hi to all,

sadly I couldn't extract the original firmware and no one helped me with the firmware yet. So I was wondering if someone has a damaged board from a Ninebot, Kingsong or Inmotion, due to their FW is available from the manufacturer...

Afair kingsong has their stm32 protected, so no firmware readout (easily) possible, too.

  • Upvote 1
Link to comment
Share on other sites

On 6/1/2019 at 4:29 AM, Chriull said:

Afair kingsong has their stm32 protected, so no firmware readout (easily) possible, too.

A friend once told me that he got firmware extracted out from a gate opener controller 10 years ago. He said the process is quite simple, the package is cut with laser to expose the silicon die then re-solder back the read enable pin. This is done of course you know where & it cost about USD 500, nowadays it should be cheaper, thats why if you launch any product there, they can have it mass produce in just a few days time :lol:

Just found a few worth reading here & here

Update Info

Spoiler

O1CN01TO158724VsAwOE0As_!!1695907397.thumb.jpg.21f38ff52db5b0c5760c5912b498536d.jpg

Found one on Taobao that is able to crack STM32 for about the same price.

Shop link

TB2P9vIlFXXXXaoXXXXXXXXXXXX_!!1695907397.jpg.e6766a29549aa962e382c4f416ac5abc.jpg

They even have the GotWay complete package ready for mass production but its not cheap !

Direct link

 

Edited by yuweng
Update info
  • Like 1
Link to comment
Share on other sites

Why steal code? That will only slow down the development of a better open source controller. We need to first understand EUC control theory and then make fresh clean modern code for a modern controller. For example no EUC are using servo controllers. This any many other things will improve the EUC a lot.

Link to comment
Share on other sites

On 5/31/2019 at 3:55 PM, Inductores said:

Hi to all,

sadly I couldn't extract the original firmware and no one helped me with the firmware yet. So I was wondering if someone has a damaged board from a Ninebot, Kingsong or Inmotion, due to their FW is available from the manufacturer...

I found a broken gotway msv3 for very cheap, that comes with 2 new mainboards. Maybe it is interesting? I'm probably going to purchase it.

Regarding firmware help, I have completed 2/3 exams and the last one is in one week. After that I'll be available for coding. What is the first thing we need to program? 

Link to comment
Share on other sites

58 minutes ago, h3X said:

I found a broken gotway msv3 for very cheap, that comes with 2 new mainboards. Maybe it is interesting? I'm probably going to purchase it.

Regarding firmware help, I have completed 2/3 exams and the last one is in one week. After that I'll be available for coding. What is the first thing we need to program? 

Oh yes, a MSV3 would be a great base to test, and if the batteries are still OK, then it will for sure become alive again.

According to the FW, I guess the first thing to be programmed should be the basics: BLDC motor control and data acquisition from the gyroscope (implementing a Kalman filter might be more tricky, but maybe someone can help).

I would suggest to use a bigger uC than the STM32F103C8T6, I think the new board should need extra I/O pins to add new functionalities (what about the one implemented on the One Z10?). So the one(s) programming the uC should choose for a proper uC, I'll adapt it to the board.

Link to comment
Share on other sites

I think we should focus on getting the motor running in the first place, and only implement balancing when that works. I suppose some pins of the mcu control the mosfets and what needs to come out of the mcu is three phases of sinusoidal/trapezoidal waveforms to be amplified by the board?

I'm more worried about getting the basics in order first, and don't want to complicate it with concerns about future upgradeability. If the platforms are code compatible it shouldn't matter.

 

Edit: In regards to the broken euc I'm buying, the motor is busted so I'm not sure if I can get it running, but in any case it's a heap of spare parts and also there are 2 motherboards. :)

Edit 2: Unfortunately the purchase fell through as someone outbid me. No msv3 motherboards after all. :(

Edited by h3X
Link to comment
Share on other sites

The original MOSFET driver integrated on the GT16 board is this one:

http://fortiortech.com/zh-cn/productshow.asp?id=125&i=3

But I don't like it because:

1) It's a chinese company and I found nothing in the usual european sellers (Farnell, Digikey, Mouser...)

2) The datasheet is incomplete, I don't even know the pinout!

 

So I took a look to different well-known manufacturers and I found these ones:

http://www.ti.com/product/DRV8350R

http://www.ti.com/product/DRV8353R

 

I already ordered samples and I got them, so I can integrate them in a custom board.

Edited by Inductores
Link to comment
Share on other sites

I went a couple days off the grid, just pure wilderness :D Now back, there is some new people here following and willing to contribute, thats nice!

 

I also like the idea of having a module approach, very much. And i'm pretty sure, that is going to be the way at some point. (Makes it easier to improve / modify)

For the Development POV at this moment, it doesn't really matter if its single board or module based, given we have no FW / Software at all, atm.
Both ways we have to start coding the software, which runs the motor and the balancing system.

 

I'm still waiting for my dev kit (STM32F1) + mpu etc. so i can start coding.

 

Reading out / Reverse engineer the FW would be interesting, in point of an faster approach, but is also not the thinking behind Open Source. Not to mention, that there might be legal issues with publishing closed source code.

 

Link to comment
Share on other sites

Someone's selling on the cheap / giving away a broken Airwheel + chargers:

It's a low power motor (350W nominal, I think), but might be useful for testing purposes for anyone in the US interested in the development, assuming the motor's not the busted part (more likely the mainboard's gone poof).

 

Edited by esaj
Link to comment
Share on other sites

On 6/9/2019 at 2:53 PM, h3X said:

I am now done with all my work and I'm ready to write code for this project.

Great! So tell me what microcontroller you are comfortable with (STM32F103 or another one) and I can update the board and add more outputs

Link to comment
Share on other sites

I haven't programmed mcu's in years, but I've used  atmel avr, arduino, ti msp430, and now I got an stm32. All the setup guides are using the arduino IDE, but as I understand it that isn't necessary, it's just that people like to use it as a faster arduino alternative. Are you planning to use the stm32 with arduino ide?

Link to comment
Share on other sites

2 hours ago, h3X said:

I haven't programmed mcu's in years, but I've used  atmel avr, arduino, ti msp430, and now I got an stm32. All the setup guides are using the arduino IDE, but as I understand it that isn't necessary, it's just that people like to use it as a faster arduino alternative. Are you planning to use the stm32 with arduino ide? 

It was a possibility, but as I'm not an expert in programming, I just want the programmer feel comfortable :D

In any case, I would look for a uC with more pins than the used in the Rockwheel board (it's running out of free pins to add extra peripherals like the handle switch, fan control, an external memory for logs...)

 

Edited by Inductores
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...