Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 02/26/23 in all areas

  1. Hello, some time ago I thought of making a program that could be used by young programmers and students who need to write a project document and show them the possibilities of programs they could develop with Delphi. I have recently published the program and it is called TICdoc. The program also has a diagram editor and a code editor for saving code snippets that can be tagged for further searches. A project document is generated by uniting various types of sections (functional requirements, table of contents, Gantt charts, use cases, etc). Some of these sections have their own editor and the editable sections have a text editor (html) to which styles (css) can be applied. The program uses a SQLite database. It is free and does not have any usage restrictions. It is signed with an OV certificate, which I know shows some warning when downloading it in the browser. You can see it at TICdoc , there is also a youtube channel (currently only in spanish) where you can watch short videos of program features Small task editor at intro page: Code editor to save snippets (SynEdit component): Diagram editor (TMS Diagram Studio), you can insert this diagrams into project document: Document editor (HTML component library): In the editable section you can insert images, formulas, tables, data-bound tables, editor diagrams or PlantUML diagrams: By clicking on the active language in the lower bar we can change the language (it is in a json file, so it can be translated into other languages, it is currently in Spanish and English)
  2. It most certainly is. I've never been surprised by how cheap a product is, when I had to ask for a price. On the other hand it's sometimes worth to ask for a discount when the price is published.
  3. shineworld

    First Python + DelphiVCL Program

    Actually, I was a little poor in the description because I thought I shouldn't bore you. Let's see if I can group the ideas. 1] The IP Camera The IP camera is made with an embedded board + a motorized camera sensor + Linux. The IP camera, mounted on the Z axis of the CNC, uses a LAN connection to receive commands (eg: manual focus, brightness, resolution, etc) and return a stream of encoded and compressed frames. To do this, it uses the TCP / UDP protocols. The management software was initially made with Python but then I will calmly rewrite it completely in C ++. Theoretically, the code is already performing even in Python, as the bottleneck remains the acquisition of the frames from the sensor, their encoding, and compression, which is already done using native code libraries. In any case, a large part of the Python project was then compiled with Cython, creating python modules .so that a few percentage points of profit made me get. 2] Delphi and its expansion modules for Python. Initially, I tried to manage TCP/UPD streams directly in Python via sockets and threads, but unfortunately, Python gives the worst, as threading management is always subject to the rules of the GIL and therefore in fact creating more threads in python does not always mean being able to optimize the use of cores. I will not dwell on this question, which I too was not aware of, there are many discussions on the net. I, therefore, thought of using Delphi to create an extension module for Python in which I entered all the communication work between PC and Camera using Delphi's TThread (more practically internally I used INDY both for the TCP Client and for the UDP server) In python, I no longer needed to create threads for managing TCP/UDP packets with the resolution of many problems that I had had in the first tests. Still in the Python expansion module written in Delphi, I was able to manage other features not present in ready-made libraries for Python, but which I already had working fine in Delphi, certainly gaining performances. 3] Python program The Python program is actually made up of Python + DelphiVCL + Skia + OpenCV and other minor libraries, plus an image processing framework that I built from scratch in pure python language. To improve performance, the whole package, apart from the main file, was also compiled with Cython, obtaining a series of .pyd modules that make up the final product. 4] CNC The CNC is actually made up of an embedded board with a REAL TIME industrial operating system that I wrote years ago and that we have been using for years for CNC and PLC and all the CNC part is done directly on the board. The CNC board, which controls the motors/inputs/outputs/EtherCAT /etc, communicates with the PC and with the CNC control software via LAN. The control software is just a UI interface, has a G-code compiler, and takes care of transferring motion instructions or pre-processed blocks to the CNC board's execution buffer. In the CNC control software, there is an API server (TCP/Server) which allows an external program/process, through an API Client, to access all the functions of the CNC, including sending programs, MDI programs, JOG, etc. So for Python, I have created a package that implements the client core API allowing a Python program to have full control of the CNC. NOTE The program can use Themes. Without a theme, the assignment of a Bitmap to TImage objects (a Window control) can generate flickering (due to the WM_ERASExxx message). Using Themes the flickering increase a lot. So I've created a new DelphiVCL branch with Graphics32:TImgView32 which is a TGraphicControl-based object and solved the flickering phase managing the PAINT event. Now I've been really boring :) Sorry!
×