OpenPLC-version1-with-LDmicro/C2/Installation-of-LDmicro-on-Linux/English

From Script | Spoken-Tutorial
Jump to: navigation, search
Visual Cue
Narration
Slide 1:

Welcome slide

Welcome to the spoken tutorial on Installation of LDmicro on Linux.
Slide 2:

Learning Objectives

In this tutorial, we will see how to install,
  • LDmicro
  • AVRDUDE
  • Drivers for USBasp programmer
Slide 3:

System Requirements

To record this tutorial I am using:
  • Ubuntu Linux 16.04 operating system
  • USBasp programmer
Slide 4a:

What is LDmicro?

What is LDmicro?
  • LDmicro is an open source software.
  • It is used to draw a ladder diagram or ladder logic to program PLCs.
Slide 4b:

What is LDmicro?

  • We can simulate this ladder diagram or ladder logic in real time on our computer.
  • It can also generate native code for certain PIC16 and Atmel AVR microcontrollers.
Now we’ll see how to install LDmicro.
OpenPLC website To download the installation files, open the web browser of your choice.

Make sure you’ve an active internet connection.

Go to the website https://openplc.fossee.in

OpenPLC website In the top menu bar, click on the Resources link.

Click on User Downloads link present under the Downloads tab.

OpenPLC website

<point to various links>

Here we will find links to download LDmicro installation files for different versions of Ubuntu Linux.
OpenPLC website

Click LDmicro for Linux(deb) >> Click Save File >> Click OK

Click on appropriate link depending upon your operating system’s version.

I will click on LDmicro for Ubuntu 16.04(deb) link .

A dialog box opens.

Click on Save File, and then click OK button.

Point to the .deb file in the downloads folder In the Downloads folder, the downloaded .deb file is available.

Note that, the extension for the downloaded file for Linux will be (.deb).

Open the terminal.

Press CTRL+ALT+T

Now let us open the Terminal by pressing CTRL +ALT + T keys simultaneously.
Terminal

Type >> cd Downloads

Go to the Downloads folder by typing cd <space> Downloads and press ‘Enter’.
Terminal

Type >> ls

Type ls to see the LDmicro package name

Press Enter.

Highlight the LDmicro version Here, in my system, it shows LDMicro-2.2.4-Linux.deb

The name may vary in future.

Type

>> sudo dpkg -i LDMicro-2.2.4-Linux.deb

To do the installation, type the command sudo dpkg -i LDMicro-2.2.4-Linux.deb and press Enter
Type >> <password> Type the admin password if prompted and press Enter.
Now, LDmicro software is installed.
Type >> ldmicro To make sure, type LDMicro in the terminal and press Enter.
LDmicro interface LDMicro interface opens.

This ensures that LDmicro is installed successfully.

Next we’ll see how to install AVRDUDE.
Slide 5:

What is AVRDUDE?

What is AVRDUDE?

AVRDUDE stands for AVR Downloader Uploader.

It is a tool for downloading or uploading the on-chip memories of AVR microcontrollers.

Switch back to terminal To install AVRDUDE, switch back to terminal.
Type sudo apt-get install avrdude

Type y

Press ENTER


Type, sudo apt <hyphen> get install avrdude and press ENTER.

It will ask for your permission to continue the installation.

Type ‘y’ and press Enter.

Wait until the installation is completed.

Type avrdude

Highlight the version

To check the installed version, type avrdude and press ENTER.

Here, you can find version number at the bottom of the terminal.

Next, we will see about USBasp programmer
Slide 6:

(picture of USBasp programmer, USBasp_Programmer.jpg)

This is a picture of a USBasp programmer
Slide 7:

Why USBasp drivers?

Why USBasp drivers?
  • A USBasp programmer is used to program the controller on OpenPLC main board.
  • AVRDUDE will not recognize the USBasp, if drivers are not installed.
Now, we’ll see how to install USBasp drivers.

In Linux OS, the USBasp drivers are pre-installed.

Switch to the terminal Switch back to the terminal.
Terminal

Type >>lsusb

Type lsusb and press Enter.

This will give the information about USB buses in the system and the devices connected to them.

The information you get on the terminal may not be same as mine.
Connect USBasp to an USB port of Computer Now, connect a USBasp programmer to one of the USB ports of your computer.
Terminal

Type >> lsusb’

Now again, in the terminal type ‘lsusb’ and press Enter.
Terminal

(Highlight to that extra line, in particular the word libusb)

We can observe there is an extra line of information of the bus and the device connected to it.

We can find a keyword libusb in the new line which indicates that USBasp programmer is connected.

This indicates that the drivers are installed successfully.

This brings us to the end of this tutorial.

Let us summarize.

Slide 8:

Summary

In this tutorial, we learnt to install

  • LDmicro
  • AVRDUDE
  • Drivers for USBasp programmer

In this tutorial, we learnt to install

  • LDmicro
  • AVRDUDE and
  • Drivers for USBasp programmer
Slide 9:

About Spoken Tutorial project

The video at the following link summarizes the Spoken Tutorial project.

Please download and watch it

Slide 10:

Spoken Tutorial workshops

The Spoken Tutorial Project team:
  • conducts workshops using spoken tutorials and
  • gives certificates on passing online tests.

For more details, please write to us

Slide 11:

Forum for specific questions:

Do you have questions in THIS Spoken Tutorial?
  • Please visit this site
  • Choose the minute and second where you have the question
  • Explain your question briefly
  • Someone from our team will answer them
Slide 12:

Forum for specific questions:

Do you have any general / technical questions on OpenPLC?

Please visit the FOSSEE forum and post your question.

Slide 13:

Acknowledgement

Spoken Tutorial Project is funded by NMEICT, MHRD, Government of India.

More information on this mission is available at

this link.

Slide 14:

Thank you slide

This tutorial has been contributed by FOSSEE and Spoken Tutorial Project, IIT Bombay.

And this is Harsha Priyanka from FOSSEE team, signing off.

Thanks for watching.

Contributors and Content Editors

Nancyvarkey, Nirmala Venkat, Priyanka.guntaka123