Jump to content

problem to read UART1 pin PC4 serial1

Recommended Posts

I own a tive C TM4C123G and I'm trying to read from PORT C UART1 RX pin PC4.
I've tried from the port B PB0 UART RX without problem.
any can help me?
thanks in advance
(energia E0015)
//serial1 UART1
//PC4 midi in RX
//PC5 midi out TX
#define LED RED_LED

boolean lowhigh;
byte incomingByte;

void setup() {
  Serial1.begin(31250);//  Set MIDI baud rate:
  pinMode(LED, OUTPUT);

void loop() {

if (Serial1.available() > 0) {

   incomingByte = Serial1.read();
   incomingByte=(incomingByte & 0xF0);//dejamos pasar 1111000 4 primeros bits
   if (incomingByte==0x90){           //tenemos un note on si es 1001
             digitalWrite(LED, HIGH); // turn the LED on 
             digitalWrite(LED, LOW);


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...