Skip to content

Bare metal C programming example of a serial relay controller for industrial automation.

License

Notifications You must be signed in to change notification settings

JustZeus/AVR128DB_Controller

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AVR128DBXX Controller

IC AVR128DB48

The purpose of this project is to create a serial programmable relay controller (PLC similar). Taking advantage of the Microchip's Technology AVR128DB48 microcontroller characteristics.

The second parallel purpose is to demonstrate the C language bare metal programming for this microcontroller family using the AVR-GCC compiler and the Visual Studio Based IDE: Microchip Studio.

The target, the user will be able to:

  • Command and program the controller via a USART CLI.
  • Program Time based routines using the I2C RTC.
  • Program temperature treshold based routings.

Current State

As 02/04/2023 the firmware allows the user to change the state of the relays manually using a USART CLI with argumented commands.

The USART peripheral is configured to operate by interruption service routines. Leaving the main loop empty, this will help for future low power configurations.

For example:

$ ctrl 1,3 -tgl

All commands must start with the $ sign, then the main command, followed by the selected elements and finally the operations, the above command will toggle the state of the selected relays.

command line

More Command examples

$ ctrl 1,3,4 -on Will turn ON the selected Relays

$ ctrl 3,4 -off Will turn OFF the selected Relays

Getting Started

These instructions will guide you to get copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

🔵 Hardware

Development hardware

The project is developed around the following development boards:

Microchip Technology

MIKROE

🔵 Software

Requirements for the software and other tools to build.

Authors

License

Released under MIT License

Acknowledgments

  • The code in this Repo is based in the application notes from the engineering team at Microchip Technology.

About

Bare metal C programming example of a serial relay controller for industrial automation.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages