Menu

Echo Log in to Edit

Using the UART of an AVR controller is very easy using the [UART] package.

with AVR;                          use AVR;
with AVR.UART;

procedure Main is
   C : Character;
begin
   UART.Init (UART.Baud_19200_16MHz);
   loop
      C := UART.Get;
      UART.Put (C);
   end loop;
end Main;

See the file avr-uart.ads for the available input and output routines. Essentially you can put all kinds of strings and characters and quite some integer values. Input is a bit more restricted.


Related

Wiki: Home
Wiki: UART

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.