This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Use UART DFU implementation in Atmel for upload to nRF51

Hi. I would like upload firmware from Atmel microcontroller to nRF51822 with SD130. I suppose that I have to use single_bank_serial_s130 in nRF51822AA, but what I have to do on other side (Atmel side) ? I found this document, but I don't know if it is relevant for central device using SDK11 and SD130. Does exist any application for PC using bootloader over UART ?

Parents Reply
  • Looking at the source for nrfutil v0.5.2 it appears that the byte order is in compliance with the core spec.

    def slip_parts_to_four_bytes(seq, dip, rp, pkt_type, pkt_len):
        """
        Creates a SLIP header.
    
        For a description of the SLIP header go to:
        developer.nordicsemi.com/.../a00093.html
    
        :param int seq: Packet sequence number
        :param int dip: Data integrity check
        :param int rp: Reliable packet
        :param pkt_type: Payload packet
        :param pkt_len: Packet length
        :return: str with SLIP header
        """
        ints = [0, 0, 0, 0]
        ints[0] = seq | (((seq + 1) % 8) << 3) | (dip << 6) | (rp << 7)
        ints[1] = pkt_type | ((pkt_len & 0x000F) << 4)
        ints[2] = (pkt_len & 0x0FF0) >> 4
        ints[3] = (~(sum(ints[0:3])) + 1) & 0xFF
    
Children
No Data
Related