** Sorry in advance for the code blocks with no newlines, I can't seem to get them formatted properly..? **
Hey there,
First off, everyone who has worked with this in the past, big Thanks! :) Also to loathingKernel for your wonderful continuation!
I'm having a look at this bootloader as I would like to use it for programming a couple of units in a remote location.. Which this bootloader should be able to do, which is great :)
However, I'm having a few problems.
Which software are you using for editing and uploading the bootloader to the target?
-
I've tried Arduino 1.8.3 which seems to be a no go. I've tried to put the "hardware" and "libraries" both under /arduino/ and also in the /arduino path, but also in the "C:/program.../arduino" path but I just get errors that the board.txt file can't be read and similar. I can of course provide more errors when I'm told exactly where the files should be put, but as of right now, when I follow the Readme file, it just doesn't work.
-
I've also tried Atmel Studio 7 which can compile the code, create an HEX file and upload it to the target. However, I still can't ping the device either on the default IP which ends in .128 or the IP I've set which should be .33
I've edited the net.h file with my network settings, like the following;
/ Network settings /
#define IP_ADDR 192,168,1,33
#define SUB_MASK 255,255,255,0
#define GW_ADDR 192,168,1,1
#define MAC_ADDR 0x55,0xD7,0x53,0x00,0x01,0x0B
But, I can't ping the device on this address. The Gateway address I suppose should be the real network gateway, such as the router, correct?
Also, how do I enable debugging in the source code, so that it outputs data to the Serial port, just like the "ariadne_debug2560_w5100.hex" file does when it is uploaded?
When I upload the bootloader file "ariadne_debug2560_w5100.hex" I do get debug output and the IP address is set to 192.168.1.128 - which by the way is matching my network and it is a free IP. I still can't ping the device though.
The device I'm using is actually an Controllino Maxi. This device is based off the Atmega2560 with a WizNet 5100 chip. The following are the pin connections which is hardwired and can't be changed in any way.
Arduino 52 / PB1 - WizNet SCK
Arduino 51 / PB2 - WizNet MOSI
Arduino 50 / PB3 - WizNet MISO
Arduino xx / PJ3 - WizNet SS/CS
I've thought that maybe the PJ3 should be configured in the spi.h file as the chipselect, but not sure if that does anything? I've tried changing both #define SS and #define ETH_SS to PINJ3, but no change in response from the unit on the network.
Something I've noticed is that the PINB7, defined as LED in spi.h, the led is not flashing or blinking, just solid on.
Also, I don't see any traffic on WireShark that could be the bootloader. But I guess thats only when inbound traffic is active. The bootloader isn't transmitting anything without an incomming call, right?
Pinout for the Controllino, Ethernet chip just right of center on the pinout sheet, below SD card connector..
http://controllino.biz/wp-content/uploads/2017/05/CONTROLLINO-MAXI-Pinout.pdf
I think that is all for the moment, would it possible to help me out in any way? :)
Edit..
If I run the debug version of the hex file "ariadne_debug2560_w5100.hex" available within the Git download I get the following output on the serial line;
Main: Ariadne for Arduino Mega2560, Version 0.5
Net: Built-in settings
Net: Address: 0xC0.0xA8.0x01.0x80
Net: Subnet: 0xFF.0xFF.0xFF.0x00
Net: Gateway: 0xC0.0xA8.0x01.0xFE
Net: MAC: 0xDE.0xAD.0xBE.0xEF.0xFE.0xED
Net: Network init done
Tftp: Init socket to port 0x0045
Many thanks in advance!
// Christopher