-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
unable to Autodetect the pins of my board GD32F130C6T6 & UART control #85
Comments
I've been using ST-Link Utility, STM32CubeProgrammer, ST Visual Programmer, and KeilVision5 to upload various binaries using ST-link V2 I'm unable to detect the pins on the hall sensors, driver gates, .... and other pins. My motherboard version doesn't seem to match any of the versions you're providing. I'm having trouble establishing a connection between ESP32 and STM32 using USART. Any guidance you could provide would be greatly appreciated. Thank you! |
As you have Keil running, select target GD32F130 and for config.h
F7 + F8 and watch my latest autodetect youtube video :-) |
Yes, the max 2A cc is fine.
|
for the autodetec.ino here's the ESP32 i'm using and the code : #define ESP32 // comment out if using Arduino #define _DEBUG // uncomment to get additional debug output // Serial interface, baud, RX GPIO, TX GPIO void setup() #ifdef ESP32 #define PINS_DETECT 18 typedef struct attribute((packed, aligned(1))) { enum { DATA_None, DATA_Request, DATA_Save }; unsigned long iTimeTest = 0; void loop() if (oSerialHover.available()) // If anything comes in from hoverboard
} yes my bad it's usart1 PA2 and PA3 |
|
this has only a RX pin to receive data from remote. DSO = oscilloscope. Buy this one: https://www.aliexpress.com/item/1005006019697163.html best value for $30. |
trim.7F2387BC-3DEF-4E0F-993B-4033310945EC.MOV |
Will watch the move later. There is a debug led define you have to uncomment in config.h Usage can be seen in main.c But you will have to use a defines_2-0.h with your manually traced pins. And not autodetect.. |
I would find the pin array definition in RemoteAutodetect.c and change the first value from 0 to 42. |
no, line 94: |
the pins get printed in line 103ff of autodetect.ino
So you must have received a full data struct before the pins get printed. |
all i can see in the monitor so far |
in the last screenshot you got random numbers, no nice zeros for all pins. You have to try and error which hoverboard pin is rx and which is tx. only two possibilities. Try to get the nice zeros consistently. Then attach your osscilloscope to see the data being sent from hoverboard to esp32. If you trace the three hall sensors manually, you could compile a pa2/pa3 RemoteUart and forget about the autodetect.. |
please do not ask too many questions. |
maybe this pin-array storage is the problem.. Or you could send "1" + enter and see if the firmware enters voltage pin detection. Then motor will start to spin and stop and spin and stop and spin. Then we would know that the firmware is working correctly but that your esp rx line is not receiving the output. |
Thank you so much for all the information and for taking from you valuable time to help me with my school project. finally The UART connections are made, and I can compile the AUTODETECT program, the smiley faces shining :-) :-) :-) using CoolTerm software Starting with Hall pins
I will follow through with it until defining all the pins. Could you please guide me on what I should do next after this step? 🤝 |
i cant believe im late but im here just working on android developement things idk whats your logic, but these too large number may overflow and cause problem in the code(imagine there is debugging for gd32, you can watch variable then), and idk why there is random value, the esp dont need eeprom, just store in ram, so just reboot the esp and all is gone you can watch the video toturial about auto detect, all be is not very good video but you can still understand how to use it if you are not a idiot the gd32 support is unfortunately not hapenning any time soon, because someone say he want to help with spin0280 and after i made pinfinder for it he disappeared, so i cant make any action to the code now or i wont be able to support 0280 forever, because itll get out of sync and cannot merge, i should never trust anyone, i should only work on it if he is willing to send me the board |
and maybe watch the wiki also if you havent |
@RoboDurden now you understand why detect unsupported terminal is necessary |
@HRAFRH , Could you please tell me what went wrong so long and how did you resolve that problem ! The order should be from top to botton - of course. @I-hate-2FA , yes i did not want to call you for help because i am happy if you have time for the real problems. |
you can call me in, i am not like the gen1 dev that are not helpful, even if it is your firmware i dont have to but ill still try to help |
Mankind is evil.. This guy here will also disappear. There is no happiness in the world to build something together. Mankind is totally egositic. |
It was all diagram-cables, Power supply issues the code was working fine (tested the RX Tx in stm32 the signal was there), |
he will, if you trying to ask him to do additional things after he got his project working but like come on for the 0280 he didnt even want to try the code i written for him that he demand, and i already told him the consiquence of not sending me the board is you have to do allot of testing for me, because no programmer can do it in the first try |
Hi?@I-hate-2FA, I don’t fully understand the last conversation, but if it’s about me, I’m definitely down to help with anything you need, as long as I know how to do it. Just let me know! |
It is not, you have out done most bdc users, I'm just complaining about other things about my firmware with robo |
I'm here to help not blame you, although this is not my firmware I can only give limited help, as I don't fully understand how everything is done |
During my testing, I ran three different tests, and each test gave me different pin configurations. I want to ask if this is normal and why the code provides different pins in each test. Additionally, could you please explain the concept behind the code and why it might give different pin results? Should I use the pin configuration from the last test, or is there a specific way to determine the correct pins? Thank you for your help! |
The detection method used in gd32 is not 100% reliable, but in your case it works quite well actually the board only need hall sensor to run, so you can already try to use main with the hall sensor and serial line pins |
Hi @RoboDurden @I-hate-2FA , I want to try the UART controls on my hoverboard using a potentiometer or RC Controller, joystick or a similar input device. However, I've tried the
and nothing seems to move. The wheels don't respond, and I don't see any signal using the oscilloscope. Could you please advise on which parts of the code I need to change and which layout I should use? I have various defines, and I'm unsure which one is the correct one to use. Thank you for your assistance ! |
please use your brain.
|
I'm having trouble understanding the principle of layouts and how to use the defines in the project. :/ |
did you enable remote uart or remote uartbus |
I have enabled Both of them, and and nothing seems to move |
how is it possible to enable both of them? |
I’ve enabled both |
ok, what did you enabled on the esp |
|
in the ESP i can only find remote_uartbus, i'm using
|
this is all i can get in the serial monitor so far : and the motor still not moving :(, please @RoboDurden @I-hate-2FA any guidance with the code |
Sorry, i will not help you anymore. |
please i really don't know what to do! |
there is 5 pin that must be set for the board to work
did you set it correctly already |
and need to use uartbus mode on both, with correct slave id set |
![2024-06-02 21 41](https://github.com/RoboDurden/Hoverboard-Firmware-Hack-Gen2.x/assets/125764830/d41efa82-adf7-4225-94d8-e5968e69acfb
I tried a lot but i need help on detecting the correct pin for only board i got (i think it's a master) that i want to control it using ESP32, but board is not listed in the Wiki could you please help me !!
The text was updated successfully, but these errors were encountered: