Serial Communication from the Yocto

Discuss use it and firmware update
  • yup, that's one of the discouraging aspects of the yocto cpu
    the fact that the PCB is black also doesn't help much
    there is a 10pin (5x2) header near the cpu, which smells like avr ISP connector, but it's not labelled, so who knows

    other than that, you could check the available USARTs on the chip, and try to see if those pins go onto traces somewhere on the PCB (that would be easiest if you have a schematic and/or board layout files to look at)
    if you find an USART module with both TX and RX pins not used (and not connected to anything on the PCB) then i can think of a little dirty hack:
    use a an extra 40-pin IC socket, plug the CPU onto it, bend the pins where the RX+TX are on that socket sideways and solder wires to them, then plug that whole thing into the socket on the PCB
    you'd also need to connect another wire to a ground point (preferably taken from somewhere in the digital section of the circuit)
    now, you have three wires TX RX GND, you can use a USART<->RS232 converter box, or a USART<->USB converter box
    don't connect the USART directly to a RS232 port on a computer because RS232 is not 5V

    if you actually only need to print out debug information - you only need the TX pin (and GND), but having both TX and RX available on the same USART module is a better option, because then that can be used for a serial bootloader (because MIDI is damn slow)
  • I've figured it out with a good guess and a multimeter. The pair of pins next to the SPI header are the serial RX/TX lines. You can get serial out from the ATmega1284 on the Yocto that way.

    Using an Arduino Uno to read serial from the Yocto:
    Image
    • Make the connections described in the image above (if you don't want to program the Yocto over SPI, you still need the GND connection from the SPI header)
    • Connect GND to RST on the Uno (note that you must break this connection if you want to program the Yocto over SPI!)
    • Use the "Serial Monitor" under the "Tools" section of the Arduino IDE
    • Set the baud rate to 115200
    Things to watch out for:
    • The TX line can't be connected during programming over SPI, avrdude will spit out a "not in sync" error.
  • Neat!

    I've been doing my debugging in a very crude way, by lighting up LED's. Using the serial port must be much nicer.
  • jvq wrote:Neat!

    I've been doing my debugging in a very crude way, by lighting up LED's. Using the serial port must be much nicer.
    Thanks!
  • I've been trying this to get serial text out from the Yocto

    RX TX connection as described in above image.
    Also Yocto GND to Arduino RST
    Using a cheap UNO clone

    When I open serial monitor some characters I print are corrupt. Space prints as 8, 0 as <, A as a, ... It's semi random, sometimes some characters get corrupt, sometimes they don't.. Baud rate is correct. Very confusing for debugging of course.

    I first blamed my Uno clone, tried another type of clone and the problem is the same. Then blamed the Yocto, took another one (from same batch though), same issue. Then blamed my Mac, so tried a raspberry pi with the Arduino IDE and the same problem occurs.

    Not sure where to go from here.. I could try to get my hands on a real arduino uno.. Or maybe make something to connect the yocto straight to the raspberry pi.

    Anyone got any clues?


    EDIT: :roll: why is it always right after I ask for help online that I figure it out :roll:
    The problem is I didn't connect GND of the Yocto to GND of the Arduino. Fixed now, time to debug 8-)
    Get the latest unofficial Yocto V1 firmware here.
    Be sure to check the revised manual.
    Leave your comments in this thread.