Chapter 2. PIC Programs

Table of Contents



When you create a FlowCode or a Text document, you'll notice a drop down menu in the toolbar with a rocket icon. From here, you can manipulate your PIC program; changing it to different forms.

  • Convert to Microbe - This is used only in FlowCode documents. This is explained further in Chapter 4, FlowCode.

  • Convert to Assembly - This can be used in four contexts. When a FlowCode document is open, it will output the FlowCode as assembly instructions. When a Microbe document is open, it will invoke the microbe program distributed with KTechlab to compile the program. Similarly, if a C program is open, it will attempt to compile it via SDCC. When a text document containing PIC hex is open, it will invoke gpdasm to disassemble the hex.

  • Convert to Hex - This can also be used in four contexts. As with Convert to Assembly, this can be used with FlowCode, Microbe and C documents. It will also be enabled when an assembly document is open to assemble it via gpasm.

  • Upload to PIC - This assembles the PIC program currently being edited, and uploads it using the programmer that the user has selected.

None of these actions require the current document to be saved - very useful for when a quick program is required. For non-PIC targets, the Output dialog invoked on clicking on one of these actions can either output the result (always text in the above three cases) to a fresh document, or to a file. If the output is saved to file, it also provides options to load the file after creation, and adding the newly created file to the open project (if one is open).

Note that you can make KTechlab always use the same view for displaying the outputted content by selecting the option under General settings.