My Cargo bike build.

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
It wasn't in any, I just downloaded the zipped file to local files C: to see if I could find that box. I simply righ clicked to select to extractall files and then opened the .bat file with note++. I then did start to copy the text as in #182 but had to go to work so abandonned it.
If the file was in this directory on C:

C:\TSDZ2-Smart-EBike-1-20.1C\src\controller\

Then editing that file is what we need to do. Delete the line beiginning with PATH, and replace with this. You can highlight the text in the browser and right-click copy. Then paste it excatly into where the old line was.

PATH = %PATH%;C:\STMicroelectronics\stvp;"C:\Program Files (x86)\STMicroelectronics\stvp"
 
Last edited:
  • Like
Reactions: Bikes4two

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
This is the bit confusing me, I haven't even come across a src\ controller folder.
Enough already for tonight as it is rest time for me after coming in from work.
If you've extracted the files to C: and are not looking at a zip file which looks like a folder, the \src folder should be inside the \control folder, which is inside the \TSDZ2-Smart-EBike-1-20.1C folder on C:
 
  • Like
Reactions: Bikes4two

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
It's great that you've installed Notepad++, it's very handy.
 

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
This is the bit confusing me, I haven't even come across a src\ controller folder.
Enough already for tonight as it is rest time for me after coming in from work.
Same here, tiring stuff... and I still have oodles to do tonight so I'll be up for ages. When extracted, you should see subfolders like this, but in Windows 10 stylee. Or it won't work.


46985

...and inside the \src folder, there are these folders:

46986

...and inside the \controller folder, there are these files and folders:

46987

...which contains the file we need to edit.
 
Last edited:
  • Like
Reactions: Bikes4two

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
If you install Winrar, then right click open with Winrar, or open Winrar and select File > Open archive, and open the zip file that way... (there are at least three ways of opening zip files in Winrar, but we might need the additional step of associating zip files to open automatically with Winrar, when zip files are double-clicked) - you can then highlight the folder and drag it onto C: then find the file called compile_and_flash.bat in this subdirectory

C:\TSDZ2-Smart-EBike-1-20.1C \src\controller\

Then find that .bat file, edit it, and save.

BTW We don't need to edit:

compile_and_flash_20.bat - if you're looking at that .bat file in Notepad++, we need to leave that as is.
 
Last edited:
  • Like
Reactions: Bikes4two

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
Same here, tiring stuff... and I still have oodles to do tonight so I'll be up for ages. When extracted, you should see subfolders like this, but in Windows 10 stylee. Or it won't work.


View attachment 46985

...and inside the \src folder, there are these folders:

View attachment 46986

...and inside the \controller folder, there are these files and folders:

View attachment 46987

...which contains the file we need to edit.
Right, I have found all of these extracted files & yes they were in the unzipped file, smart tsdz2 -1-20.1C2 folder
I will have to have another play in the week to see if I can crack this walnut.

I 100% really appreciate the effort you are trying to give me, It's just stuff I can't really understand fully.
 
  • Like
Reactions: Bikes4two

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
Right, I have found all of these extracted files & yes they were in the unzipped file, smart tsdz2 -1-20.1C2 folder
I will have to have another play in the week to see if I can crack this walnut.

I 100% really appreciate the effort you are trying to give me, It's just stuff I can't really understand fully.
You will crack this walnut! It's best to be relaxed about this sort of stuff, the firmware isn't going anywhere and it isn't going to go off/past it's sell by date.
 
  • Like
Reactions: Bikes4two

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
Ok got it the file we want is in the Src folder under the tsdz2 file, and then in the src we need the controller folder where the compile flash.bat file is.
Bloddy hell it is one layer after another hidden here and there.

I feel I'm slowly getting to grips where to find some of the stuff now, I now need to go back and read all the last couple of pages again and then sort thru the process again.

You have the patience of St Guerney.
 

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
Ok got it the file we want is in the Src folder under the tsdz2 file, and then in the src we need the controller folder where the compile flash.bat file is.
Bloddy hell it is one layer after another hidden here and there.
It's a tree structure where the computer is the trunk, the drives are the branches, and then there are oodles and oodles of twigs upon twigs... and eventually you get to the leaves, which are files.

On the left pane of Windows Explorer, any time you see an arrow or plus sign next to a drive, if you click that you'll see sub-folders. Eventually there are no subfolders, then the arrow or plus sign disappears.
 
  • Like
Reactions: Bikes4two

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
Well for now I have got the JRE, SDCC, STM8 and the github repository all saved in the Downloads folder. From there I can simply copy them to the correct folders I need the to go in.
 
  • Like
Reactions: Bikes4two

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
Have you picked the CF up yet ?
Mine has been handy ove Friday and Saturday as I have loaded the trailer upto visit my bees to deal with them, at the mo they are caning in the spring nectar.
I hopefully should get my govm't funded free test sample results soon from last year, then I will have an idea what the mass forage source may be.

Anyway St Guerney, I'm done for this morning and time for me and the pussy's bed time.
 

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
Have you picked the CF up yet ?
Mine has been handy ove Friday and Saturday as I have loaded the trailer upto visit my bees to deal with them, at the mo they are caning in the spring nectar.
I rang to arrange picking up the CF and the seller didn't want it picked up from his house, it sounded like he made up a story about moving to Leeds and the house being in chaos... also said he doesn't live in Leamington Spa anymore - why couldn't he have just said "I don't want to give my address out to some buyer from ebay!", because I would have. Hope it isn't a stolen CF! Meeting at a train station for the exchange in a couple of days. I'll using it for a trailer AirBnB holiday, and moving loads which call for a flat bed... but for the pumpkins, only the Homcom is practical because I won't need to use a big box strong enough to hold them. They can't be transported on top of each other. Any strong box I could purchase or make for the CF, would be heavier than the Homcom side bars, and not strong enough to withstand the momentum of these mega dense and heavy pumpkins.

I hopefully should get my govm't funded free test sample results soon from last year, then I will have an idea what the mass forage source may be.
That'll be interesting, learning what they get up to. It's nice to see more grass verges being left wild for the bees locally. But I do wish they wouldn't mow sections around the tufts left to grow wild - I expect to see hedgehog body parts.

Anyway St Guerney
I'm no saint, believe me! While showing a friend how to list and sell something on ebay, she was terrified and it turned out she didn't understand double-clicks, something we take for granted and do without thinking about. So I showed her how to adjust the double-click speed so that it suited her. She also took a free "Computer Driving Course" at the local library, which helped. It all took almost a year, but we got there in the end and she's now selling costume jewellery on ebay, for which I didn't think there was much of a demand, but apparently there is. Or maybe she's selling fake jewellery posing as real, I don't know.
 
Last edited:

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
You just need the JRE, SDCC and your chosen firmware version in a zip file.

I also highly recommend Winrar. Or 7zip. Or both. Anything but Windows 10's method of displaying and working with zip files.

JRE needs double clicking to install.

Before double clicking this file:

sdcc-4.2.0-x64-setup.exe

...you need to make a new folder on C: called the folowing exactly, with capitals STM:

STMicroelectronics

...then install into this folder, not in program files - bypass the program files option by clicking "browse" during installation, then select C:\STMicroelectronics from the dropdown box.

STM8 is for Linux or MAC, it does the jame job that STVP does on Windows.

"1. Download STVP for Windows here. This software is from the STM8S105 manufacture for flashing the firmware. NOTE: if you are on Linux or MAC, you can use other alternative tool. For instance, on Linux you can use stm8flash. "

 
Last edited:

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
sdcc-4.2.0-x64-setup.exe

is an .exe or executable file:


Among other files this .exe file needs to carry out the installation process, it also contains an archive file, to save space. That achive file could be a zip, cab or ther type of archive file. Often, you can open an .exe installer file with Winrar and see the archive file, and extract for fits and chuckles. But you don't need to worry about it, just install it into the

C:\STMicroelectronics

folder durring installation, after a double-click and having created that folder first. It doesn't matter what folder sdcc-4.2.0-x64-setup.exe is in, when you double click it. Just double click from your downloads folder.
 
Last edited:

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
Still very slowly learning this stuff and have finally deduced that and wording following \ means having to look to open another folder or file, so \src is another folder and \ controller is a file within this folder within the main tdsz2 repository.

Also downloaded the Godzilla search engine which does appear to be quite good and have replaced the Win edge with it.
 

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
@Bikes4two It's been a very long time since I had to use the PATH command myself! I don't use Windows 10 and so wasn't sure if the Windows 10 Notepad was capable of displaying that type of file - here's how that uncorrected compile_and_flash.bat file looks in Windows XP Notepad. In Windows 7, it's better but still not easy enough to read, fiddly to correct and easy to make a mistake, hence my recommending Notepad++, which is capable of the display and editing of more file standards.

Windows XP

View attachment 46949

Windows 7

View attachment 46950

Notepad++

View attachment 46951



View attachment 46952
Yes the notepad++ looks much neater and easier to follow.
 

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
Another stupid question ?
Java runtime/Jre, it simply is located in local disk C: and not another folder !!!
 

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
Another stupid question ?
Java runtime/Jre, it simply is located in local disk C: and not another folder !!!
If the installer is located on C: - it needs double clicking to start the installation program. If it doesn't start to install when you double click the installer, post up the filename and details of where it is exactly, ie on C:\ , or in what sub folder.
 

Nealh

Esteemed Pedelecer
Aug 7, 2014
20,866
8,508
61
West Sx RH
It is installed on > This PC > Local Disk (C:)
When I 2x click it takes an gae to open, in the bottom left corner there is a change destination folder unchecked. One assumes this is left unchecked.
 

guerney

Esteemed Pedelecer
Sep 7, 2021
11,208
3,177
It is installed on > This PC > Local Disk (C:)
When I 2x click it takes an gae to open, in the bottom left corner there is a change destination folder unchecked. One assumes this is left unchecked.
It can be checked or unchecked - once installed, the JAVA Runtime Environment will work anyway... but for ease of finding JAVA components at some later stage (totally unnecessary for updating the firmware), leave it unchecked.
 

Related Articles

Advertisers