CFW for KSGER/Quicko STM32 Soldering Stations - Page 1
Forum section: electronics / general

author: ricktendo
author_rank: Regular Contributor
timestamp: March 14, 2018, 05:16:31 am
content: GitHub:https://github.com/deividAlfa/stm32_soldering_iron_controller

author: ricktendo
author_rank: Regular Contributor
timestamp: March 15, 2018, 09:45:14 pm
content: Update: I requested a CFW Flashing video, he delivered

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 12:05:48 am
content: Hi Ricardo,We can move the discussion regarding building from source here.As I pointed on youtube the first step is to download System Workbench fromhttp://www.openstm32.org/System%2BWorkbench%2Bfor%2BSTM32. It is free but requires an account.

author: ricktendo
author_rank: Regular Contributor
timestamp: March 17, 2018, 06:34:13 pm
content: Thank you for the instructions, I can build debug but when I try to try to build release I get these 3 errorsCode:12:29:51 **** Build of configuration Release for project iron ****make allBuilding file: ../startup/startup_stm32f103xb.sInvoking: MCU GCC AssemblerC:\Users\Ricardo\workspace\stm32_soldering_iron_controller-master.zip_expanded\stm32_soldering_iron_controller-master\Releasearm-none-eabi-as -mcpu=cortex-m3 -mthumb -mfloat-abi=soft -o "startup/startup_stm32f103xb.o" "../startup/startup_stm32f103xb.s"Finished building: ../startup/startup_stm32f103xb.sBuilding file: ../Src/iron.cInvoking: MCU GCC CompilerC:\Users\Ricardo\workspace\stm32_soldering_iron_controller-master.zip_expanded\stm32_soldering_iron_controller-master\Releasearm-none-eabi-gcc -mcpu=cortex-m3 -mthumb -mfloat-abi=soft '-D__weak=__attribute__((weak))' '-D__packed="__attribute__((__packed__))"' -DUSE_HAL_DRIVER -DSTM32F103xB -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Inc" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/STM32F1xx_HAL_Driver/Inc" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/STM32F1xx_HAL_Driver/Inc/Legacy" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/CMSIS/Device/ST/STM32F1xx/Include" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/CMSIS/Include" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/graphics" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/graphics" -I"C:/Users/Ricardo/workspace/stm32_soldering_iron_controller-master.zip_expanded/stm32_soldering_iron_controller-master/Drivers/graphics/gui" -Og -g3 -Wall -fmessage-length=0 -ffunction-sections -c -fmessage-length=0 -MMD -MP -MF"Src/iron.d" -MT"Src/iron.o" -o "Src/iron.o" "../Src/iron.c"../Src/iron.c:11:25: fatal error: tempsensors.h: No such file or directory#include "tempsensors.h"^compilation terminated.Src/subdir.mk:36: recipe for target 'Src/iron.o' failedmake: *** [Src/iron.o] Error 112:29:56 Build Finished (took 5s.46ms)Also when I build, how do I make sure its for hakko tips and not jbc?

author: TT_Vert
author_rank: Regular Contributor
timestamp: March 17, 2018, 07:34:39 pm
content: Can you tell me what that bottom right temp is and what it's purpose is?ThanksDave

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 08:11:35 pm
content: Quote from: ricktendo on March 17, 2018, 06:34:13 pmYou can use the debug build, that is what I use, it is a bit larger but it behaves the same. If you do want to use the release build I have just pushed a fix for that issue, you can clone the repository and it should build without issues.Quote from: ricktendo on March 17, 2018, 06:34:13 pmJust useCode:#define JBCsomewhere on the start of settings.c to build for JBC and remove that define to build for hakko.

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 08:14:06 pm
content: Quote from: TT_Vert on March 17, 2018, 07:34:39 pmIt is supposed to be the ambient temperature in degrees Celsius, it is used for the cold junction compensation. Since I didn't see too much of a variation between sensors the calibration is hard coded, I can make it configurable if found necessary.

author: TT_Vert
author_rank: Regular Contributor
timestamp: March 17, 2018, 08:23:30 pm
content: Thanks much, that's over my head.Dave

author: ricktendo
author_rank: Regular Contributor
timestamp: March 17, 2018, 09:11:46 pm
content: Quote from: PT_Dreamer on March 17, 2018, 08:11:35 pmYou are correct, the ELF is different between the builds but the resulting BIN file is the exact same.I did get these 3 warnings, hope they are not seriousCode:DescriptionResourcePathLocationTypesuggest parentheses around arithmetic in operand of '|' [-Wparentheses]ugui.c/iron/Drivers/graphicsline 5326C/C++ Problemsuggest parentheses around arithmetic in operand of '|' [-Wparentheses]ugui.c/iron/Drivers/graphicsline 5328C/C++ Problemsuggest parentheses around arithmetic in operand of '|' [-Wparentheses]ugui.c/iron/Drivers/graphicsline 5375C/C++ Problemsuggest parentheses around arithmetic in operand of '|' [-Wparentheses]ugui.c/iron/Drivers/graphicsline 5377C/C++ Problemunused variable 'tmp' [-Wunused-variable]ugui.c/iron/Drivers/graphicsline 5810C/C++ Problemunused variable 'xs' [-Wunused-variable]ugui.c/iron/Drivers/graphicsline 5808C/C++ ProblemThanks for everything

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 09:26:50 pm
content: Quote from: ricktendo on March 17, 2018, 09:11:46 pmThose are from the uGui library I'm using, I have checked and they are harmless.

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 09:41:23 pm
content: Quote from: TT_Vert on March 17, 2018, 08:23:30 pmThe cold junction compensation bit? That is not hard to understand at all.The "temperature sensors" used on these soldering iron tips are thermocouples. A thermocouple reads a difference in temperatures not the absolute temperature, so in a iron tip it measures the difference between the tip temperature and the ambient temperature (not so simple but close enough). So in order for you to know the real iron tip temperature you need the thermocouple measure and another sensor reading which can provide the ambient temperature. Than you just compute the tip temperature real temperature.Now you can ask what is the real value of having the ambient temperature being displayed, and you are right it isn't critical, I see it more like a sanity check, if it is on the ballpark of the ambient temperature it means the cold junction temperature sensing is at least reading something close to reality.

author: TT_Vert
author_rank: Regular Contributor
timestamp: March 17, 2018, 10:39:55 pm
content: So should that thermistor in the handle actually be in the base away from the handle where the heat of holding it will change the value? Or should that be assumed to be the same temp each time you hold it since the human hand doesn't change in temp that much?ThanksDave

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 10:56:21 pm
content: Quote from: TT_Vert on March 17, 2018, 10:39:55 pmIdeally it should be as close to the termistor as possible, or to be more accurate to the cold junction, that is where the two dissimilar metals become copper. In reality is doesn't really matter much.

author: TT_Vert
author_rank: Regular Contributor
timestamp: March 17, 2018, 11:05:24 pm
content: But if it is using the thermistor in part of the calibration and the thermistor is in the handle where the ambient temp it is measuring changes just by the action of holding it, doesn't that skew the calibration?Dave

author: PT_Dreamer
author_rank: Contributor
timestamp: March 17, 2018, 11:53:53 pm
content: Quote from: TT_Vert on March 17, 2018, 11:05:24 pmCalibration has nothing to do with this, so no it doesn't skew calibration.Increasing the handle temperature by holding it is why the thermistor should be placed there, so it can measure that increase.As I said above a thermocouple "reads" the difference in temperature between its hot and cold junctions, and the cold junction is on the handle so that is the temperature that you should read to make the proper compensation.

author: TT_Vert
author_rank: Regular Contributor
timestamp: March 17, 2018, 11:56:42 pm
content: ok that makes sense now.Thanks muchDave

author: giovannirat
author_rank: Regular Contributor
timestamp: April 15, 2018, 11:10:00 am
content: Hi PT_Dreamer,thank you for sharing your firmware.I've got a controller , flashed the firmware for JBC. Everything went fine except two minor issues:1) The display content seems to be shifted a few columns to the left2) Even with no iron connected the display shows about 167 degree and not an error....Is there an explanation?Thanky you very much....

author: ricktendo
author_rank: Regular Contributor
timestamp: April 15, 2018, 03:18:37 pm
content: Quote from: giovannirat on April 15, 2018, 11:10:00 amWhat size is your LCD?You may also want to post your bug on the github issues page:https://github.com/PTDreamer/stm32_soldering_iron_controller/issues

author: giovannirat
author_rank: Regular Contributor
timestamp: April 15, 2018, 04:51:17 pm
content: It is this controller and looks like te same PT_Dreamer used (except the two colour display in his video) :https://www.aliexpress.com/item/STM32-OLED-V3-5-OLED-T12-Soldering-Station-Temperature-Control-Board-1-3-Size-Screen-OLED/32822843496.htmlhas a 1.3 inch display....

author: ricktendo
author_rank: Regular Contributor
timestamp: April 15, 2018, 04:55:10 pm
content: Quote from: giovannirat on April 15, 2018, 04:51:17 pmYea its the exact same board revision V1.5, only difference is the LCD size: 1.3'' vs 0.96''

author: PT_Dreamer
author_rank: Contributor
timestamp: April 17, 2018, 09:58:14 pm
content: Quote from: giovannirat on April 15, 2018, 11:10:00 amHi sorry for the late reply, I'll have to look at the forum settings because it seems I'm not receiving new post alerts.1- As already referred above your screen is different than the one I got. It is bigger and doesn't have the upper yellow line. If you want I can try to write some changes to fix the issue you are having. Unfortunately since I don't have a similar screen to play with it will probably require a few iterations before we get it.2- Not having the iron connected means that noise is being fed to the input of the double stage amplifier which is then fed to the ADC. On the board I have this condition will made it appear as if a temperature above specs is present and trigger a "NO IRON" message. If your hardware is working properly it seems to be reading noise with an average level similar to a termoucouple inside the temperature spec of a normally running iron and as such impossible to detect as a non connected iron. I can think of a few ways to improve the behavior but all hacky and prone to fail on edge cases. Open to ideas though.

author: PT_Dreamer
author_rank: Contributor
timestamp: April 17, 2018, 10:32:48 pm
content: @giovanniratYou can try the attached firmware to see if it fixes the screen issue. It is compiled for JBC, no idea if it is what you need but should be ok just for testing the screen.EDIT: Please let me think about it some more and I'll post a better firmware tomorrow night.

author: giovannirat
author_rank: Regular Contributor
timestamp: April 18, 2018, 06:18:26 am
content: Hi PT_Dreamer,thank you very much for your support....I will try the attached firmware and give you feedback soon.

author: giovannirat
author_rank: Regular Contributor
timestamp: April 18, 2018, 09:40:50 am
content: Hi PT_Dreamer,one step forward...The left side of the screen looks ok now, but on the right side is still a two column "interference"....And the temperature looks a bit high without any iron (jumps between 100° an 960°), but that's obvoiusly the noisy input...Thanks a lot!

author: PT_Dreamer
author_rank: Contributor
timestamp: April 18, 2018, 06:00:03 pm
content: @giovannirat please try this new firmware, I tried fixing the screen issue in another way, after reading some docs it seems your screen uses a 132x64 controller while only having the normal 128 point horizontal resolution...which is weird....I also tried lowering the "NO IRON" detection threshold.@moderators if this kind of discussion/testing is outside the scope of this forum please let me know and I will move it to gitHub.